From patchwork Wed Nov 30 17:08:22 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allen Ballway X-Patchwork-Id: 27921 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp1051430wrr; Wed, 30 Nov 2022 09:21:04 -0800 (PST) X-Google-Smtp-Source: AA0mqf6nCl3a/I6ZtVZ49Zkq3T72/+4TFL+iUmRPetHzd8IATElDl3ncpFY42qvwUN+fhXF7eg+i X-Received: by 2002:a17:90a:458a:b0:214:166e:e202 with SMTP id v10-20020a17090a458a00b00214166ee202mr66641956pjg.165.1669828864434; Wed, 30 Nov 2022 09:21:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1669828864; cv=none; d=google.com; s=arc-20160816; b=CICOMIcKtcZanE9TOOhSPguYQimBWi58SjGLa6dF1tAAQxS3KwVaZCUr9x3+m66Xsj hwyPFa+PKpFu9WzJQuoZL3tadcxAuGHT2kv3lvE0sFS8H8yhgbAV9PQlqWba8mlj1iFy umImTzhMBRue6p1T6iVAFsZd3XK2fGsFNjbcn4aS/ORseG4Tq+7qKnug+uYtVr5kOa3Z nQR5E5anTnafuAHNt+Cj3fq/UO24yUrDzexUkQNNBDDid9goFIvPKsS9BRmlJJ0Z8ohu SUyg6FjMIShGzQVja5TDXCH8iQ3siR45KI29UFUS1zJ6CvZSjixo9P7+FmwPne0J9lUs Aa1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=BtB22ckpAeQTvW+2h2vhfpvkHho96FIUyOTjkXi8z4s=; b=V8XsZfE6YB80Mh03UeK6yw0FQzpLeTYXce67xpmC1c5o78pj6IfXNl2jb4my9Lw20V m5J74T2Zf2yGxQBctWF4c4GXhubiwBhZLqegWk9IqULDujatC7dg0pi3SYgv6GUoHRfb WG1+tm9eV4BBwTEcZpMllREDUDTmewN5QwHMiW2kZYNO6XTXpLKaEeFnECroj+JSq/Kp ZKbv5tSGm9eKDA/s+dRqXdjfciGGhCb0bGkL8aUC97puZ7k2BivH0KpRe6sO0pz1UWVa HNdAYMGxLV8iF4UDtxDEjCIZ+uWoxuYMIJ6GMDpAGGiccn5K+h0G1WxokMGMhPzazNJl c2eQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=mNLuBvJP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id b16-20020a63d310000000b00477b8c80220si1755157pgg.301.2022.11.30.09.20.51; Wed, 30 Nov 2022 09:21:04 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=mNLuBvJP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231131AbiK3RNL (ORCPT + 99 others); Wed, 30 Nov 2022 12:13:11 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40150 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231161AbiK3RMb (ORCPT ); Wed, 30 Nov 2022 12:12:31 -0500 Received: from mail-pf1-x42c.google.com (mail-pf1-x42c.google.com [IPv6:2607:f8b0:4864:20::42c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 13181837E9 for ; Wed, 30 Nov 2022 09:08:43 -0800 (PST) Received: by mail-pf1-x42c.google.com with SMTP id 140so17411356pfz.6 for ; Wed, 30 Nov 2022 09:08:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=BtB22ckpAeQTvW+2h2vhfpvkHho96FIUyOTjkXi8z4s=; b=mNLuBvJPsaKHf2okXvPTyzE7P7jC2dz2zM38h0ssXWF93vRO18bNkEgbK4pb6Q/aRY 0Cf/H2DxiDMJOrq55Ea28d+DlkItHPqnRNPZdyVpcUgghgc7omeVnNNiQfj3HIkv5CeH ZZUZl9K0SrMLiAxNYuLTKm8KFjJOI/ZWfW25Y= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=BtB22ckpAeQTvW+2h2vhfpvkHho96FIUyOTjkXi8z4s=; b=ZxbA2j1BFpRLY6Ag3se2CApsmUM9u3DtdW1TY+HgqtfuHN3VlNZ43OZWFlRskDuL9z EVb/h/3N/3ocMoHkb4rVzaj0dN8rikgo3RHbCp6ACOr63zkqA4brUI6dVMz6OyJcGFFX QdaSaxZmsnl0H4E5GsKVvCJP04glhlT38pmQumxFIMdUOivDRKUTsW0dq4XcPGPRHGD4 WG3Px6UO54ZkZAhVSbaOVXSDg186pUD5ILfbpKBqgLSyjXPaniM087uFM8z7RilfSloG Y/3Np8uI74VgxgxRTUerzfrBhi/MjPpUbZrlmXEP4qwcUoGYVYH7CVtetqc8cjiBCcJI 6v9g== X-Gm-Message-State: ANoB5pnJ5yjEVkvozvjEsAD88daTUzVDaC9ySNIAiCJy18v/dnItk5RT 7ErxtUE2tQMkB/AcI/fevICCIBfCmRHB5g== X-Received: by 2002:a63:1464:0:b0:46a:f665:ed96 with SMTP id 36-20020a631464000000b0046af665ed96mr37677681pgu.486.1669828123067; Wed, 30 Nov 2022 09:08:43 -0800 (PST) Received: from ballway1.c.googlers.com.com (97.173.125.34.bc.googleusercontent.com. [34.125.173.97]) by smtp.gmail.com with ESMTPSA id x28-20020aa79a5c000000b0056b8181861esm1707154pfj.19.2022.11.30.09.08.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 30 Nov 2022 09:08:42 -0800 (PST) From: Allen Ballway To: LKML Cc: Daniel Vetter , dri-devel@lists.freedesktop.org, Maxime Ripard , David Airlie , Maarten Lankhorst , Hans de Goede , Thomas Zimmermann , Allen Ballway , David Airlie Subject: [PATCH] drm: Add orientation quirk for DynaBook K50 Date: Wed, 30 Nov 2022 17:08:22 +0000 Message-Id: <20221130170811.1.Iee9a494547541dade9eeee9521cc8b811e76a8a0@changeid> X-Mailer: git-send-email 2.38.1.584.g0f3c55d4c2-goog MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1750942471111245696?= X-GMAIL-MSGID: =?utf-8?q?1750942471111245696?= Like the ASUS T100HAN for which there is already a quirk, the DynaBook K50 has a 800x1280 portrait screen mounted in the tablet part of a landscape oriented 2-in-1. Update the quirk to be more generic and apply to this device. Signed-off-by: Allen Ballway Reviewed-by: Hans de Goede --- .../gpu/drm/drm_panel_orientation_quirks.c | 20 ++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) -- 2.38.1.584.g0f3c55d4c2-goog diff --git a/drivers/gpu/drm/drm_panel_orientation_quirks.c b/drivers/gpu/drm/drm_panel_orientation_quirks.c index 52d8800a8ab86..14f870fb2db04 100644 --- a/drivers/gpu/drm/drm_panel_orientation_quirks.c +++ b/drivers/gpu/drm/drm_panel_orientation_quirks.c @@ -30,12 +30,6 @@ struct drm_dmi_panel_orientation_data { int orientation; }; -static const struct drm_dmi_panel_orientation_data asus_t100ha = { - .width = 800, - .height = 1280, - .orientation = DRM_MODE_PANEL_ORIENTATION_LEFT_UP, -}; - static const struct drm_dmi_panel_orientation_data gpd_micropc = { .width = 720, .height = 1280, @@ -121,6 +115,12 @@ static const struct drm_dmi_panel_orientation_data lcd1280x1920_rightside_up = { .orientation = DRM_MODE_PANEL_ORIENTATION_RIGHT_UP, }; +static const struct drm_dmi_panel_orientation_data lcd800x1280_leftside_up = { + .width = 800, + .height = 1280, + .orientation = DRM_MODE_PANEL_ORIENTATION_LEFT_UP, +}; + static const struct drm_dmi_panel_orientation_data lcd1600x2560_leftside_up = { .width = 1600, .height = 2560, @@ -151,7 +151,7 @@ static const struct dmi_system_id orientation_data[] = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "ASUSTeK COMPUTER INC."), DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "T100HAN"), }, - .driver_data = (void *)&asus_t100ha, + .driver_data = (void *)&lcd800x1280_leftside_up, }, { /* Asus T101HA */ .matches = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "ASUSTeK COMPUTER INC."), @@ -196,6 +196,12 @@ static const struct dmi_system_id orientation_data[] = { DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "Hi10 pro tablet"), }, .driver_data = (void *)&lcd1200x1920_rightside_up, + }, { /* Dynabook K50 */ + .matches = { + DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Dynabook Inc."), + DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "dynabook K50/FR"), + }, + .driver_data = (void *)&lcd800x1280_leftside_up, }, { /* GPD MicroPC (generic strings, also match on bios date) */ .matches = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Default string"),