From patchwork Tue Dec 1 20:53:50 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Kettenis X-Patchwork-Id: 7740911 Return-Path: X-Original-To: patchwork-intel-gfx@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id B4F989F30B for ; Tue, 1 Dec 2015 21:12:03 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E5A68206B8 for ; Tue, 1 Dec 2015 21:12:02 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by mail.kernel.org (Postfix) with ESMTP id 96ABA206B0 for ; Tue, 1 Dec 2015 21:12:01 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 849B26E0A4; Tue, 1 Dec 2015 13:12:00 -0800 (PST) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org X-Greylist: delayed 1084 seconds by postgrey-1.34 at gabe; Tue, 01 Dec 2015 13:11:58 PST Received: from sibelius.xs4all.nl (sibelius.xs4all.nl [83.163.83.176]) by gabe.freedesktop.org (Postfix) with ESMTPS id 92D736E0A4 for ; Tue, 1 Dec 2015 13:11:58 -0800 (PST) Received: from glazunov.sibelius.xs4all.nl (kettenis@localhost [127.0.0.1]) by sibelius.xs4all.nl (8.14.5/8.14.5) with ESMTP id tB1Kro9C019158 for ; Tue, 1 Dec 2015 21:53:50 +0100 (CET) Received: (from kettenis@localhost) by glazunov.sibelius.xs4all.nl (8.14.5/8.14.3/Submit) id tB1KroT3014721; Tue, 1 Dec 2015 21:53:50 +0100 (CET) Date: Tue, 1 Dec 2015 21:53:50 +0100 (CET) Message-Id: <201512012053.tB1KroT3014721@glazunov.sibelius.xs4all.nl> From: Mark Kettenis To: intel-gfx@lists.freedesktop.org Subject: [Intel-gfx] Enable GSE interrupt on Broadwell and later? X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP I just committed the following cange to the OpenBSD inteldrm(4) driver, which currently is mostly a port of the Linux 3.14 codebase. This enables the GSE interrupt on Broadwell. Without this interrupt, the ASLE backlight brightness mechanism doesn't work. I've verified that this fixed the ACPI _BCM/_BCQ-based brightness mechanism on a MacBookPro12,1 and a 3rd gen Lenovo X1 Carbon. And as far as I can tell the current Linux code still doesn't enable the GSE interrupt. So people over there might want to consider a diff like the one below. Cheers. Mark Index: i915_irq.c =================================================================== RCS file: /cvs/src/sys/dev/pci/drm/i915/i915_irq.c,v retrieving revision 1.29 diff -u -p -r1.29 i915_irq.c --- i915_irq.c 23 Sep 2015 23:12:12 -0000 1.29 +++ i915_irq.c 1 Dec 2015 20:43:05 -0000 @@ -3019,6 +3019,10 @@ static void gen8_de_irq_postinstall(stru I915_WRITE(GEN8_DE_PORT_IMR, ~GEN8_AUX_CHANNEL_A); I915_WRITE(GEN8_DE_PORT_IER, GEN8_AUX_CHANNEL_A); POSTING_READ(GEN8_DE_PORT_IER); + + I915_WRITE(GEN8_DE_MISC_IMR, ~GEN8_DE_MISC_GSE); + I915_WRITE(GEN8_DE_MISC_IER, GEN8_DE_MISC_GSE); + POSTING_READ(GEN8_DE_MISC_IER); } static int gen8_irq_postinstall(struct drm_device *dev)