From: Bjorn Helgaas Date: Fri, 4 Jan 2013 19:10:32 +0000 (+0000) Subject: drm/pci: Use the standard #defines for PCIe Link Capability bits X-Git-Tag: v3.9-rc1~83^2~25 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9fe0423eac2c0781a3ece8779b086acd3e76f2c8;p=profile%2Fcommon%2Fkernel-common.git drm/pci: Use the standard #defines for PCIe Link Capability bits Use the standard #defines rather than bare numbers for the PCIe Link Capabilities speed bits. Signed-off-by: Bjorn Helgaas Signed-off-by: Dave Airlie --- diff --git a/drivers/gpu/drm/drm_pci.c b/drivers/gpu/drm/drm_pci.c index 754bc96..11c8add 100644 --- a/drivers/gpu/drm/drm_pci.c +++ b/drivers/gpu/drm/drm_pci.c @@ -504,9 +504,9 @@ int drm_pcie_get_speed_cap_mask(struct drm_device *dev, u32 *mask) if (lnkcap2 & PCI_EXP_LNKCAP2_SLS_8_0GB) *mask |= DRM_PCIE_SPEED_80; } else { - if (lnkcap & 1) + if (lnkcap & PCI_EXP_LNKCAP_SLS_2_5GB) *mask |= DRM_PCIE_SPEED_25; - if (lnkcap & 2) + if (lnkcap & PCI_EXP_LNKCAP_SLS_5_0GB) *mask |= DRM_PCIE_SPEED_50; }