Author: dumbbell
Date: Wed Dec  4 19:04:56 2013
New Revision: 258930
URL: http://svnweb.freebsd.org/changeset/base/258930

Log:
  drm: Read PCIER_LINK_CAP/PCIER_LINK_CAP2 from the PCI bridge
  
  Before this fix, capabilities were read from vgapci and were incorrect.

Modified:
  head/sys/dev/drm2/drm_pci.c

Modified: head/sys/dev/drm2/drm_pci.c
==============================================================================
--- head/sys/dev/drm2/drm_pci.c Wed Dec  4 18:25:04 2013        (r258929)
+++ head/sys/dev/drm2/drm_pci.c Wed Dec  4 19:04:56 2013        (r258930)
@@ -134,7 +134,11 @@ int drm_pcie_get_speed_cap_mask(struct d
        if (!drm_device_is_pcie(dev))
                return -EINVAL;
 
-       root = device_get_parent(dev->device);
+       root =
+           device_get_parent( /* pcib             */
+           device_get_parent( /* `-- pci          */
+           device_get_parent( /*     `-- vgapci   */
+           dev->device)));    /*         `-- drmn */
 
        pos = 0;
        pci_find_cap(root, PCIY_EXPRESS, &pos);
_______________________________________________
svn-src-head@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to