From patchwork Wed Feb 17 23:22:49 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 80128 Received: from lists.sourceforge.net (lists.sourceforge.net [216.34.181.88]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o1HNOEt9016774 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Wed, 17 Feb 2010 23:24:50 GMT Received: from localhost ([127.0.0.1] helo=sfs-ml-4.v29.ch3.sourceforge.com) by sfs-ml-4.v29.ch3.sourceforge.com with esmtp (Exim 4.69) (envelope-from ) id 1NhtER-0006pz-8V; Wed, 17 Feb 2010 23:22:59 +0000 Received: from sfi-mx-1.v28.ch3.sourceforge.com ([172.29.28.121] helo=mx.sourceforge.net) by sfs-ml-4.v29.ch3.sourceforge.com with esmtp (Exim 4.69) (envelope-from ) id 1NhtEQ-0006pu-CE for dri-devel@lists.sourceforge.net; Wed, 17 Feb 2010 23:22:58 +0000 Received-SPF: pass (sfi-mx-1.v28.ch3.sourceforge.com: domain of gmail.com designates 209.85.219.221 as permitted sender) client-ip=209.85.219.221; envelope-from=zajec5@gmail.com; helo=mail-ew0-f221.google.com; Received: from mail-ew0-f221.google.com ([209.85.219.221]) by sfi-mx-1.v28.ch3.sourceforge.com with esmtp (Exim 4.69) id 1NhtEO-0007GP-2Y for dri-devel@lists.sourceforge.net; Wed, 17 Feb 2010 23:22:58 +0000 Received: by mail-ew0-f221.google.com with SMTP id 21so1830013ewy.2 for ; Wed, 17 Feb 2010 15:22:55 -0800 (PST) Received: by 10.213.96.206 with SMTP id i14mr3342176ebn.74.1266448974846; Wed, 17 Feb 2010 15:22:54 -0800 (PST) Received: from localhost.localdomain (c3-107.icpnet.pl [62.21.3.107]) by mx.google.com with ESMTPS id 24sm22479675eyx.30.2010.02.17.15.22.53 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 17 Feb 2010 15:22:54 -0800 (PST) From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= To: dri-devel@lists.sourceforge.net, Dave Airlie Subject: [RFC][PATCH] drm/radeon/kms: check if card is multi GPU Date: Thu, 18 Feb 2010 00:22:49 +0100 Message-Id: <1266448969-4528-1-git-send-email-zajec5@gmail.com> X-Mailer: git-send-email 1.6.4.2 MIME-Version: 1.0 X-Spam-Score: -0.8 (/) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for sender-domain -0.0 SPF_PASS SPF: sender matches SPF record -0.0 DKIM_VERIFIED Domain Keys Identified Mail: signature passes verification 0.0 DKIM_SIGNED Domain Keys Identified Mail: message has a signature 0.7 AWL AWL: From: address is in the auto white-list X-Headers-End: 1NhtEO-0007GP-2Y X-BeenThere: dri-devel@lists.sourceforge.net X-Mailman-Version: 2.1.9 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.sourceforge.net X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Wed, 17 Feb 2010 23:24:51 +0000 (UTC) diff --git a/drivers/gpu/drm/radeon/radeon.h b/drivers/gpu/drm/radeon/radeon.h index db98924..d00f984 100644 --- a/drivers/gpu/drm/radeon/radeon.h +++ b/drivers/gpu/drm/radeon/radeon.h @@ -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; diff --git a/drivers/gpu/drm/radeon/radeon_device.c b/drivers/gpu/drm/radeon/radeon_device.c index fb55faf..7110529 100644 --- a/drivers/gpu/drm/radeon/radeon_device.c +++ b/drivers/gpu/drm/radeon/radeon_device.c @@ -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;