From patchwork Mon Feb 18 23:35:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?David_Santamar=C3=ADa_Rogado?= X-Patchwork-Id: 10819443 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id A2DA51399 for ; Tue, 19 Feb 2019 08:23:21 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 925712B9A3 for ; Tue, 19 Feb 2019 08:23:21 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 900032BC92; Tue, 19 Feb 2019 08:23:21 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 6EEF22B9A3 for ; Tue, 19 Feb 2019 08:23:08 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 6F38689271; Tue, 19 Feb 2019 08:22:59 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lj1-x243.google.com (mail-lj1-x243.google.com [IPv6:2a00:1450:4864:20::243]) by gabe.freedesktop.org (Postfix) with ESMTPS id 9FF8C89243 for ; Mon, 18 Feb 2019 23:35:22 +0000 (UTC) Received: by mail-lj1-x243.google.com with SMTP id d14so4645121ljl.9 for ; Mon, 18 Feb 2019 15:35:22 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=+3w8YoNrlpNWedxcT+UAD/LIveUAUOvAdrf5JvU++XA=; b=gbfePYGrvFmfkXwGOu7+pLAiTGLCHNbw+AviO1AFYN3VPfAmkRkjsG6GtFOfwMsOqa Eg+eqXehNKPmfEE3FjuYvJU1UcN/arC1zGsM/ivDs9lLZjytSSM/2q2bIgXmBTQ+vaUX FzTYfdljoMBsJUVD49P6X9lzlzjYt6N4gJpXsYY0tNfTnrWIq23V5U9W+LiTfXYQoGuy Q3uWpIZn6/We4n+j8/oowZ/0GboSLOhyvEMXBMJwv+Bv+xa1ENKBOL3ImC0cBbNHgbvR Gpf5t7DWxYCtAcwAwZsY3CqzhjZvjw5oeeq6YaXsn+wSEIoFDkIXAXmPrpTx3oX0w1Yo CLQw== X-Gm-Message-State: AHQUAubTOngPLocPvWyP+hDM1vOfU/oZKF+3r4dthpH6zd/Njz5T2zcp U5X3w1bseGL3xEI6ETDqysnPjB1zwZ4Hiw== X-Google-Smtp-Source: AHgI3Ia8XnX1M1KQ34YYEX8CJ5zjI41V6P3h6qimVvUKYZ66/VwBa7FWILtPlSSnU9PKfCoX1CGZMQ== X-Received: by 2002:a2e:7a08:: with SMTP id v8mr391852ljc.161.1550532920944; Mon, 18 Feb 2019 15:35:20 -0800 (PST) Received: from localhost.lan (179.178.94.90.dynamic.jazztel.es. [90.94.178.179]) by smtp.gmail.com with ESMTPSA id q2sm4374135lfa.63.2019.02.18.15.35.19 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 18 Feb 2019 15:35:20 -0800 (PST) From: =?utf-8?q?David_Santamar=C3=ADa_Rogado?= To: Jani Nikula , David Airlie , Daniel Vetter , Thierry Reding , dri-devel@lists.freedesktop.org Subject: [PATCH RESEND 1/2] drm: panel-orientation-quirks: Get rid of superfluous (void *) casting Date: Tue, 19 Feb 2019 00:35:17 +0100 Message-Id: <20190218233518.22705-1-howl.nsp@gmail.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-Mailman-Approved-At: Tue, 19 Feb 2019 08:22:44 +0000 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=+3w8YoNrlpNWedxcT+UAD/LIveUAUOvAdrf5JvU++XA=; b=rUPGxBV2CI/2OzWTGMrPMfp92vD2JA4QL700NTnRfuk9+Z+uMJD7uKg0XAByJykUvy W3/3Z7hPBOuqv5wN2rRNhvZNiPa6slLajK+k+PWUWHcbB5XjIf+Jp03z6mNos/aNBf9Y 33u068C2JDEPhvHF3ELwLeOGj74XhoBpK3nkSXKU/1nyPw95SO2nj9b6TERz3n0P4W+h 6LH+UNsYXW4Hi4AxEGI+I0nMLAUvGLwzZCcKVgnXPBwF9bUeDar8+ERpu6WXEIEM8TNU U7WCJO7Dptjd/CYszXrf8qmxASO4kvJCnzHhjvAiycO78iJPbZgAsAi47obqWGQdWukT DcxQ== X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP The (void *) casting in the driver_data variable assignment is superfluous. Spotted by Jani Nikula. Signed-off-by: David SantamarĂ­a Rogado --- drivers/gpu/drm/drm_panel_orientation_quirks.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/gpu/drm/drm_panel_orientation_quirks.c b/drivers/gpu/drm/drm_panel_orientation_quirks.c index 52e445bb1aa5..61d3361381b7 100644 --- a/drivers/gpu/drm/drm_panel_orientation_quirks.c +++ b/drivers/gpu/drm/drm_panel_orientation_quirks.c @@ -86,13 +86,13 @@ static const struct dmi_system_id orientation_data[] = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Acer"), DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "One S1003"), }, - .driver_data = (void *)&acer_s1003, + .driver_data = &acer_s1003, }, { /* Asus T100HA */ .matches = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "ASUSTeK COMPUTER INC."), DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "T100HAN"), }, - .driver_data = (void *)&asus_t100ha, + .driver_data = &asus_t100ha, }, { /* * GPD Pocket, note that the the DMI data is less generic then * it seems, devices with a board-vendor of "AMI Corporation" @@ -105,7 +105,7 @@ static const struct dmi_system_id orientation_data[] = { DMI_EXACT_MATCH(DMI_BOARD_SERIAL, "Default string"), DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "Default string"), }, - .driver_data = (void *)&gpd_pocket, + .driver_data = &gpd_pocket, }, { /* GPD Win (same note on DMI match as GPD Pocket) */ .matches = { DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "AMI Corporation"), @@ -113,7 +113,7 @@ static const struct dmi_system_id orientation_data[] = { DMI_EXACT_MATCH(DMI_BOARD_SERIAL, "Default string"), DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "Default string"), }, - .driver_data = (void *)&gpd_win, + .driver_data = &gpd_win, }, { /* GPD Win 2 (too generic strings, also match on bios date) */ .matches = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Default string"), @@ -121,7 +121,7 @@ static const struct dmi_system_id orientation_data[] = { DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "Default string"), DMI_EXACT_MATCH(DMI_BOARD_NAME, "Default string"), }, - .driver_data = (void *)&gpd_win2, + .driver_data = &gpd_win2, }, { /* I.T.Works TW891 */ .matches = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "To be filled by O.E.M."), @@ -129,7 +129,7 @@ static const struct dmi_system_id orientation_data[] = { DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "To be filled by O.E.M."), DMI_EXACT_MATCH(DMI_BOARD_NAME, "TW891"), }, - .driver_data = (void *)&itworks_tw891, + .driver_data = &itworks_tw891, }, { /* * Lenovo Ideapad Miix 310 laptop, only some production batches * have a portrait screen, the resolution checks makes the quirk @@ -140,20 +140,20 @@ static const struct dmi_system_id orientation_data[] = { DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "80SG"), DMI_EXACT_MATCH(DMI_PRODUCT_VERSION, "MIIX 310-10ICR"), }, - .driver_data = (void *)&lcd800x1280_rightside_up, + .driver_data = &lcd800x1280_rightside_up, }, { /* Lenovo Ideapad Miix 320 */ .matches = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "LENOVO"), DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "80XF"), DMI_EXACT_MATCH(DMI_PRODUCT_VERSION, "Lenovo MIIX 320-10ICR"), }, - .driver_data = (void *)&lcd800x1280_rightside_up, + .driver_data = &lcd800x1280_rightside_up, }, { /* VIOS LTH17 */ .matches = { DMI_EXACT_MATCH(DMI_SYS_VENDOR, "VIOS"), DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "LTH17"), }, - .driver_data = (void *)&lcd800x1280_rightside_up, + .driver_data = &lcd800x1280_rightside_up, }, {} }; From patchwork Mon Feb 18 23:35:18 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?David_Santamar=C3=ADa_Rogado?= X-Patchwork-Id: 10819441 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9E23B1399 for ; Tue, 19 Feb 2019 08:23:10 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8E1ED2B514 for ; Tue, 19 Feb 2019 08:23:10 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8203E2BA9D; Tue, 19 Feb 2019 08:23:10 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_ADSP_CUSTOM_MED, FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 440F82B514 for ; Tue, 19 Feb 2019 08:23:10 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3241789286; Tue, 19 Feb 2019 08:23:02 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-lj1-x242.google.com (mail-lj1-x242.google.com [IPv6:2a00:1450:4864:20::242]) by gabe.freedesktop.org (Postfix) with ESMTPS id D27E589243 for ; Mon, 18 Feb 2019 23:35:23 +0000 (UTC) Received: by mail-lj1-x242.google.com with SMTP id l5so12406533lje.1 for ; Mon, 18 Feb 2019 15:35:23 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=8IMg2VtNLUhZX5hVj+7Uggt8NwXOC83YAtu5myTDpoE=; b=NpNKI2A5+e3gkMTAU4Gat776COFVdzIgcWLTlL1xpQCXR7W6S4mCFLdLPBwH7gUn7g NfoVMzWEE+qoT3KKAPTGrF0wfCm8gmfROylqY+jdLIam1x5df+/rn4kjBe8zV2sNfMHN WPTbkzcMs6wHQR2PVOWPkf76orkd5fcas7AzsNKwzCTEEr6GrRDGUeeVGXFvVY+J2HJn TLLOcxg6KiOSAnVckwXfJFut7Tg0ZxKpkvVC4jc+o8z9yroh4HFa8aim/lAoqzEq0fvf dQ24LjAIVq+xcScW3YNmkm8FULY7Mcx3TYr+v5Qo0dC9tYHdNlvuSAKYaX+i17tolWag TBRA== X-Gm-Message-State: AHQUAuYdCQNc1Gn8pYKgcEsI8b4w+k+GmSfbLk7KvlAZUDAqz6Fukm37 0v70W5wxf8HWM14suNDOldw= X-Google-Smtp-Source: AHgI3Ib9902fTzX8a1ok6TXmJ+yzOtF7Z4MWnf8GFmEAQxQTyrvQ/PgMyyzu1Rf97qB63RpcpCWICQ== X-Received: by 2002:a2e:20b:: with SMTP id 11mr12383945ljc.41.1550532922143; Mon, 18 Feb 2019 15:35:22 -0800 (PST) Received: from localhost.lan (179.178.94.90.dynamic.jazztel.es. [90.94.178.179]) by smtp.gmail.com with ESMTPSA id q2sm4374135lfa.63.2019.02.18.15.35.21 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 18 Feb 2019 15:35:21 -0800 (PST) From: =?utf-8?q?David_Santamar=C3=ADa_Rogado?= To: Jani Nikula , David Airlie , Daniel Vetter , Thierry Reding , dri-devel@lists.freedesktop.org Subject: [PATCH RESEND 2/2] drm: panel-orientation-quirks: Add quirk for Lenovo Ideapad D330 Date: Tue, 19 Feb 2019 00:35:18 +0100 Message-Id: <20190218233518.22705-2-howl.nsp@gmail.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190218233518.22705-1-howl.nsp@gmail.com> References: <20190218233518.22705-1-howl.nsp@gmail.com> MIME-Version: 1.0 X-Mailman-Approved-At: Tue, 19 Feb 2019 08:22:44 +0000 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=8IMg2VtNLUhZX5hVj+7Uggt8NwXOC83YAtu5myTDpoE=; b=QdWefy28xmv1IamaYi2JK4T2Bve2/PCHr8+kobnQ8oNpgxOk7z1dqs3gSh+Rc9OgOn TxVy4X9fBPOnZZuw5JvSz8EZZmWL/cIEEWCuYfGqfREm/iyKW6GZhfRv2BDITox3awBp kHh4m45jpd7weVD6scFB4HWmZ995WxP6lQibo+scc5/+re+OK4UoheDCPWo1CdqP84UN lm/guw99IpfMkgR1VrTK5dlnPnHMXbiHOJMkdq6ccXSjw7zyC/lKd0+xGQ7a7reW29G4 mk91jihSpHKEK7wTsD3Y7agBL5z5F/U5Sls05sxSeGj+O0Hwv6nCthHiY5T1PGFjpNkZ Zzdw== X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP Lenovo Ideapad D330 Pentium CPU version has 1920x1200 LCD. Console ouput gets rotated at boot as Miix 310. Signed-off-by: David SantamarĂ­a Rogado --- drivers/gpu/drm/drm_panel_orientation_quirks.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/drivers/gpu/drm/drm_panel_orientation_quirks.c b/drivers/gpu/drm/drm_panel_orientation_quirks.c index 61d3361381b7..835574e2d5bf 100644 --- a/drivers/gpu/drm/drm_panel_orientation_quirks.c +++ b/drivers/gpu/drm/drm_panel_orientation_quirks.c @@ -80,6 +80,12 @@ static const struct drm_dmi_panel_orientation_data lcd800x1280_rightside_up = { .orientation = DRM_MODE_PANEL_ORIENTATION_RIGHT_UP, }; +static const struct drm_dmi_panel_orientation_data lcd1200x1920_rightside_up = { + .width = 1200, + .height = 1920, + .orientation = DRM_MODE_PANEL_ORIENTATION_RIGHT_UP, +}; + static const struct dmi_system_id orientation_data[] = { { /* Acer One 10 (S1003) */ .matches = { @@ -130,6 +136,13 @@ static const struct dmi_system_id orientation_data[] = { DMI_EXACT_MATCH(DMI_BOARD_NAME, "TW891"), }, .driver_data = &itworks_tw891, + }, { /* Lenovo Ideapad D330 */ + .matches = { + DMI_EXACT_MATCH(DMI_SYS_VENDOR, "LENOVO"), + DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "81H3"), + DMI_EXACT_MATCH(DMI_PRODUCT_VERSION, "Lenovo ideapad D330-10IGM"), + }, + .driver_data = &lcd1200x1920_rightside_up, }, { /* * Lenovo Ideapad Miix 310 laptop, only some production batches * have a portrait screen, the resolution checks makes the quirk