From patchwork Fri Feb 25 21:49:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans de Goede X-Patchwork-Id: 12761002 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 826F5C433FE for ; Fri, 25 Feb 2022 21:50:48 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id BF12810E989; Fri, 25 Feb 2022 21:50:47 +0000 (UTC) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7E7DD10E989 for ; Fri, 25 Feb 2022 21:50:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1645825844; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=CpsyqJPq2MznxP2J5dghU5/XW2pfoZw6gIMFRiSICa4=; b=XsBX4svz+fknXy3ymwY3EEZzJnGcSN+Q07Sln8UmayjLVorUSF5TdrnxB39fGh4eLENLnm Tdk5t3kj6B4kri4sOLRv53bN7MQdM3T0yRppVy8IiY0nkwN0JtLPg9jufeOJEEcl+aAVcg cmD7RQLm6M5h9E2k+eqDTrHePovUDWk= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-65-N7PGusDaPruXf-YimEVX3Q-1; Fri, 25 Feb 2022 16:50:43 -0500 X-MC-Unique: N7PGusDaPruXf-YimEVX3Q-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E742F51DC; Fri, 25 Feb 2022 21:50:41 +0000 (UTC) Received: from x1.localdomain (unknown [10.39.192.23]) by smtp.corp.redhat.com (Postfix) with ESMTP id 17DCC87BB5; Fri, 25 Feb 2022 21:50:31 +0000 (UTC) From: Hans de Goede To: Jani Nikula , Joonas Lahtinen , =?utf-8?b?VmlsbGUgU3ly?= =?utf-8?b?asOkbMOk?= Date: Fri, 25 Feb 2022 22:49:34 +0100 Message-Id: <20220225214934.383168-5-hdegoede@redhat.com> In-Reply-To: <20220225214934.383168-1-hdegoede@redhat.com> References: <20220225214934.383168-1-hdegoede@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=hdegoede@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Subject: [Intel-gfx] [PATCH 5/5] drm/i915/vlv_dsi: Skip MIPI I2C sequences on Microsoft Surface 3 X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: intel-gfx , Javier Martinez Canillas , dri-devel@lists.freedesktop.org Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" The VBT DSI MIPI sequences of the panel on the Microsoft Surface 3 contain a couple of I2c writes to what seems to be a non existing TI LP855x backlight controller, leading to the following errors: i915 0000:00:02.0: [drm] mipi_exec_i2c bus 5 client-addr 0x2c reg 0x01 data 01 i2c_designware 808622C1:04: controller timed out i915 0000:00:02.0: [drm] *ERROR* Failed to xfer payload of size (1) to reg (1) i915 0000:00:02.0: [drm] mipi_exec_i2c bus 5 client-addr 0x2c reg 0x16 data 07 i2c_designware 808622C1:04: controller timed out i915 0000:00:02.0: [drm] *ERROR* Failed to xfer payload of size (1) to reg (22) Besides these errors this also causes the screen turning on to be delayed by 2 seconds. At a DMI based quirk to ignore VBT DSI MIPI I2C writes on the Microsoft Surface 3. Signed-off-by: Hans de Goede --- drivers/gpu/drm/i915/display/vlv_dsi.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/drivers/gpu/drm/i915/display/vlv_dsi.c b/drivers/gpu/drm/i915/display/vlv_dsi.c index 0ddc0c8cd4f7..9ba45a928719 100644 --- a/drivers/gpu/drm/i915/display/vlv_dsi.c +++ b/drivers/gpu/drm/i915/display/vlv_dsi.c @@ -1873,6 +1873,16 @@ static void vlv_dsi_lenovo_yoga_tab2_size_fixup(struct intel_dsi *intel_dsi, } } +/* + * The VBT DSI MIPI sequences on the MS Surface 3 contain I2C writes to + * a non existing TI LP855x backlight controller which time out. + */ +static void vlv_dsi_ms_surface3_disable_mipi_i2c(struct intel_dsi *intel_dsi, + struct drm_display_mode *fixed_mode) +{ + intel_dsi->i2c_bus_num = INTEL_DSI_I2C_BUS_INVALID; +} + static const struct dmi_system_id vlv_dsi_dmi_quirk_table[] = { { /* Asus Transformer Pad TF103C */ @@ -1896,6 +1906,14 @@ static const struct dmi_system_id vlv_dsi_dmi_quirk_table[] = { }, .driver_data = (void *)vlv_dsi_lenovo_yoga_tab2_size_fixup, }, + { + /* Microsoft Surface 3 */ + .matches = { + DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Microsoft Corporation"), + DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "Surface 3"), + }, + .driver_data = (void *)vlv_dsi_ms_surface3_disable_mipi_i2c, + }, { } };