From patchwork Thu Jun 7 13:46:48 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 10453921 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id ADAC1601D4 for ; Fri, 8 Jun 2018 07:14:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 98378292F1 for ; Fri, 8 Jun 2018 07:14:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8C0842931A; Fri, 8 Jun 2018 07:14:32 +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, 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 CC27E292F1 for ; Fri, 8 Jun 2018 07:14:31 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id CE3386F4DB; Fri, 8 Jun 2018 07:14:25 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-pf0-x242.google.com (mail-pf0-x242.google.com [IPv6:2607:f8b0:400e:c00::242]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3933D6F28C for ; Thu, 7 Jun 2018 13:47:10 +0000 (UTC) Received: by mail-pf0-x242.google.com with SMTP id y5-v6so4044113pfn.4 for ; Thu, 07 Jun 2018 06:47:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=p6WRACkNnLRaA9eFoxZmmzDsYSOhuAQJc38TqBrd6Rg=; b=IrhLnQPyrN9bppaPD+Khlulyfo9TVijO70QJ57WtbemzqqL0AKqtBMeOFaaPouuRLV /C+2fRljQF1kGAqt0oXBaH035+GuQ0zX3Gcz61UaNOSTPtjwAneKAsd7KL6gyqfK4B8b L8YihVDaiDGc88wWEy11J2AQI/v/8ZQI21kAwUe6yBLLgF5gTKSkou6QMxeoPc87y/Rh 9dDMcJhNm2wL6l7bsgEYRDrbULzdsQiuPqx7CbGYUBr3JS//0cKbesIphkKd+owAim8r wGbkAWVk5bGyIxH1GCaIEqU3xxKy91ifovywZEogFDLM727enwj6uPbRemG8+cYneRet wL2Q== X-Gm-Message-State: APt69E2VhuRvu6r6C+pLpPbk61O8us5ZrcOLxWsaSJrIKjJ9er3VX2Ho ojiMCqW57aqOIWFACAH1Fkrzwg== X-Google-Smtp-Source: ADUXVKJ2AV/32nIA6BmcGY7F8DmF6eM9SG4A280U0yaOkp5wr78/3fpBvrtnsBRYQVkf668RSsfjxg== X-Received: by 2002:a62:1e02:: with SMTP id e2-v6mr1892464pfe.212.1528379230095; Thu, 07 Jun 2018 06:47:10 -0700 (PDT) Received: from localhost.localdomain ([115.97.190.51]) by smtp.gmail.com with ESMTPSA id f11-v6sm12721381pgq.18.2018.06.07.06.47.03 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 07 Jun 2018 06:47:09 -0700 (PDT) From: Jagan Teki To: Thierry Reding , David Airlie , dri-devel@lists.freedesktop.org, Shawn Guo , linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Sascha Hauer , Fabio Estevam , Rob Herring , Mark Rutland , Fabio maggi , lamiaposta71@gmail.com, Andrea CORTESE , Davide Bonfanti Subject: [PATCH v2 1/4] drm/panel: simple: Add support for Rocktech RK070ER9427 LCD panel Date: Thu, 7 Jun 2018 19:16:48 +0530 Message-Id: <20180607134648.2902-1-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.14.3 X-Mailman-Approved-At: Fri, 08 Jun 2018 07:14:24 +0000 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: , Cc: Michael Trimarchi , Jagan Teki , Shyam Saini MIME-Version: 1.0 Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP This adds support for the Rocktech Display Ltd. RK070ER9427 800(RGB)x480 TFT LCD panel, which can be supported by the simple panel driver. Signed-off-by: Jagan Teki Reviewed-by: Rob Herring --- Changes for v2: - collect Rob r-w-b tag .../display/panel/rocktech,rk070er9427.txt | 25 ++++++++++++++++ drivers/gpu/drm/panel/panel-simple.c | 33 ++++++++++++++++++++++ 2 files changed, 58 insertions(+) create mode 100644 Documentation/devicetree/bindings/display/panel/rocktech,rk070er9427.txt diff --git a/Documentation/devicetree/bindings/display/panel/rocktech,rk070er9427.txt b/Documentation/devicetree/bindings/display/panel/rocktech,rk070er9427.txt new file mode 100644 index 000000000000..eb1fb9f8d1f4 --- /dev/null +++ b/Documentation/devicetree/bindings/display/panel/rocktech,rk070er9427.txt @@ -0,0 +1,25 @@ +Rocktech Display Ltd. RK070ER9427 800(RGB)x480 TFT LCD panel + +This binding is compatible with the simple-panel binding, which is specified +in simple-panel.txt in this directory. + +Required properties: +- compatible: should be "rocktech,rk070er9427" + +Optional properties: +- backlight: phandle of the backlight device attached to the panel + +Optional nodes: +- Video port for LCD panel input. + +Example: + panel { + compatible = "rocktech,rk070er9427"; + backlight = <&backlight_lcd>; + + port { + lcd_panel_in: endpoint { + remote-endpoint = <&lcd_display_out>; + }; + }; + }; diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm/panel/panel-simple.c index cbf1ab404ee7..a6c633fd0559 100644 --- a/drivers/gpu/drm/panel/panel-simple.c +++ b/drivers/gpu/drm/panel/panel-simple.c @@ -745,6 +745,36 @@ static const struct panel_desc avic_tm070ddh03 = { }, }; +static const struct display_timing rocktech_rk070er9427_timing = { + .pixelclock = { 26400000, 33300000, 46800000 }, + .hactive = { 800, 800, 800 }, + .hfront_porch = { 16, 210, 354 }, + .hback_porch = { 46, 46, 46 }, + .hsync_len = { 1, 1, 1 }, + .vactive = { 480, 480, 480 }, + .vfront_porch = { 7, 22, 147 }, + .vback_porch = { 23, 23, 23 }, + .vsync_len = { 1, 1, 1 }, + .flags = DISPLAY_FLAGS_DE_HIGH, +}; + +static const struct panel_desc rocktech_rk070er9427 = { + .timings = &rocktech_rk070er9427_timing, + .num_timings = 1, + .bpc = 6, + .size = { + .width = 154, + .height = 86, + }, + .delay = { + .prepare = 41, + .enable = 50, + .unprepare = 41, + .disable = 50, + }, + .bus_format = MEDIA_BUS_FMT_RGB666_1X18, +}; + static const struct drm_display_mode boe_nv101wxmn51_modes[] = { { .clock = 71900, @@ -2226,6 +2256,9 @@ static const struct of_device_id platform_of_match[] = { }, { .compatible = "qiaodian,qd43003c0-40", .data = &qd43003c0_40, + }, { + .compatible = "rocktech,rk070er9427", + .data = &rocktech_rk070er9427, }, { .compatible = "samsung,lsn122dl01-c01", .data = &samsung_lsn122dl01_c01,