drm/radeon/kms: check if card is multi GPU
Subsystems (2)
RFC PATCH 1/1 drm/radeon/kms: check if card is multi GPU
Signed-off-by Rafał Miłecki <[email protected]>
---
We need to know if GPU is multi one for example for setting PCIE lanes. Can we store this like this patch proposes? I didn't want to touch rdev->flags as this is equal to some BIOS variable AFAIU.
--- drivers/gpu/drm/radeon/radeon.h | 1 + drivers/gpu/drm/radeon/radeon_device.c | 8 ++++++++ 2 files changed, 9 insertions(+), 0 deletions(-)
drivers/gpu/drm/radeon/radeon.h +1 -0
@@ -887,6 +887,7 @@ struct radeon_device {union radeon_asic_config config;enum radeon_family family;unsigned long flags; +bool multi_gpu;int usec_timeout;enum radeon_pll_errata pll_errata;int num_gb_pipes;
drivers/gpu/drm/radeon/radeon_device.c +8 -0
@@ -714,6 +714,14 @@ int radeon_device_init(struct radeon_device *rdev,* ignore it */ vga_client_register (rdev->pdev, rdev,NULL , radeon_vga_set_decode); +if ((rdev->pdev->device ==0x9441 ) ||/* ATI Radeon HD 4870 x2 */ + (rdev->pdev->device ==0x9443 ) ||/* ATI Radeon HD 4850 x2 */ + (rdev->pdev->device ==0x944B ) ||/* ATI Mobility RADEON HD 4850 X2 */ + (rdev->pdev->device ==0x9506 ) ||/* ATI Mobility Radeon HD 3850 X2 */ + (rdev->pdev->device ==0x9509 ) ||/* ATI Mobility Radeon HD 3870 X2 */ + (rdev->pdev->device ==0x950F ))/* ATI Radeon HD3870 X2 */ + rdev->multi_gpu = true; + r =radeon_init (rdev);if (r)return r;
Signature · 14 lines
1.6.4.2 ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev -- _______________________________________________ Dri-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/dri-devel