From patchwork Thu Jan 31 12:24:07 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sedat Dilek X-Patchwork-Id: 2073451 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by patchwork1.kernel.org (Postfix) with ESMTP id E77713FD1A for ; Thu, 31 Jan 2013 12:44:59 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id D3CCBE613D for ; Thu, 31 Jan 2013 04:44:59 -0800 (PST) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-bk0-f50.google.com (mail-bk0-f50.google.com [209.85.214.50]) by gabe.freedesktop.org (Postfix) with ESMTP id BD7F5E604F; Thu, 31 Jan 2013 04:24:25 -0800 (PST) Received: by mail-bk0-f50.google.com with SMTP id jg9so1331584bkc.37 for ; Thu, 31 Jan 2013 04:24:24 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer; bh=3ghvxaNan2V8lti3ZSiQ4z9YqMKC2cfo6ctDkdMT/7Y=; b=WZm48A38Qi5XxZuzFblGFz3bexpLNZ5/cyb+IaW4qugxj5gD/OKW4RdtjbPWU56lyI esVIM4jrElxqBJ0QM/ee+riZGMlM4uMDepkzkV0zBLjIPaScumGNHCAnuo/esESxsa1B ge3RjO6FdVboj+Uz7rfhmF+j+BRHCDSeGq06ggEbDBYCF8165n5HlL4MpnNKtMLJOtHD +6jjoHVQb2zC6VNnkoRuQ4LKuqqyqhD1NQwEgpCdEwNWJ2qCH0aQ69GgqztcEQZGYEOd 0NYmaLKWiI3YPE8eKDwkJUoS/TEgrYIaC02BY+szSDOdqN9iJxXnJJIH6YVqEFam5bVW 471w== X-Received: by 10.204.154.87 with SMTP id n23mr1853671bkw.8.1359635064563; Thu, 31 Jan 2013 04:24:24 -0800 (PST) Received: from fambox.fritz.box (p5DE56BD6.dip.t-dialin.net. [93.229.107.214]) by mx.google.com with ESMTPS id hc16sm1705571bkc.2.2013.01.31.04.24.22 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 31 Jan 2013 04:24:23 -0800 (PST) From: Sedat Dilek To: Subject: [PATCH drm-intel-nightly] drm/i915: Add a pipe A force quirk for Samsung NP530U3B-A01DE Date: Thu, 31 Jan 2013 13:24:07 +0100 Message-Id: <1359635047-5314-1-git-send-email-sedat.dilek@gmail.com> X-Mailer: git-send-email 1.8.1.2 X-Mailman-Approved-At: Thu, 31 Jan 2013 04:44:47 -0800 Cc: Sedat Dilek , Daniel Vetter , intel-gfx , DRI X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org IMPORTANT NOTE: *** This is just an experimental patch! *** I fell over some "pipe A assertion" warnings while playing with drm-intel-nightly and contacted Daniel Vetter via PM. [ dmesg ] [ 19.948476] WARNING: at drivers/gpu/drm/i915/intel_display.c:1228 assert_pipe+0xde/0xe0 [i915]() [ 19.948476] Hardware name: 530U3BI/530U4BI/530U4BH [ 19.948477] pipe A assertion failure (expected on, current off) Waiting for a reply, I looked into the code myself and found this snippet and reflected about adding a quirk_pipea_force for my Intel SandyBridge GPU: static struct intel_quirk intel_quirks[] = { /* HP Mini needs pipe A force quirk (LP: #322104) */ { 0x27ae, 0x103c, 0x361a, quirk_pipea_force }, ... } Unfortunately, it was not clear to me what each value of the triple means. I started to investigate more in the logs: [ Xorg.0.log ] [ 16.421] (--) PCI:*(0:0:2:0) 8086:0116:144d:c0c7 rev 9, Mem @0xf0000000/4194304, 0xe0000000/268435456, I/O @ 0x00003000/64 This line gave me a 1st impression how my triple for a quirk line could look like! Finally, Jani Nikula gave me some helpful explanations in [1]: >I guess you figured it out, but just a few lines up there's [1]: struct intel_quirk { int device; int subsystem_vendor; int subsystem_device; void (*hook)(struct drm_device *dev); }; >where device, subsystem_vendor, and subsystem_device map to Device, >SVendor, and SDevice of the gfx controller in 'lspci -vmnn' output. With these informations, I checked immediately here with 'lspci -vmnn' [2]: Device: 00:02.0 Class: VGA compatible controller [0300] Vendor: Intel Corporation [8086] Device: 2nd Generation Core Processor Family Integrated Graphics Controller [0116] SVendor: Samsung Electronics Co Ltd [144d] SDevice: Device [c0c7] Rev: 09 [ Triple revealed (w/o brackets) ] Device (here: [0116]), SVendor (here: [144d]) and SDevice (here: [c0c7]) As a conclusion, I added the below QUIRK and it was successful: [ dmesg ] [ 15.047921] [drm] applying pipe a force quirk Daniel removed the "buggy" patch which introduced the warning for non-HSW GPUs. v3 in commit 693101618a4b [3] should be the revised patch. [ References ] [1] http://lists.freedesktop.org/archives/intel-gfx/2013-January/024160.html [2] http://lists.freedesktop.org/archives/intel-gfx/2013-January/024161.html [3] http://cgit.freedesktop.org/~danvet/drm-intel/commit/?h=drm-intel-nightly&id=693101618a4beedf1b3d291860aee56c5fe44a1c Cc: Daniel Vetter Cc: Jani Nikula Cc: intel-gfx Cc: DRI Signed-off-by: Sedat Dilek --- drivers/gpu/drm/i915/intel_display.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 8c432a4..705fdb6 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -8607,6 +8607,9 @@ static const struct intel_dmi_quirk intel_dmi_quirks[] = { }; static struct intel_quirk intel_quirks[] = { + /* Samsung NP530U3B-A01DE needs pipe A force quirk */ + { 0x0116, 0x144d, 0xc0c7, quirk_pipea_force }, + /* HP Mini needs pipe A force quirk (LP: #322104) */ { 0x27ae, 0x103c, 0x361a, quirk_pipea_force },