From patchwork Sun Feb 4 17:49:25 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 10199471 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 49564602CA for ; Sun, 4 Feb 2018 21:02:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 361A12847A for ; Sun, 4 Feb 2018 21:02:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2AB18285A2; Sun, 4 Feb 2018 21:02:41 +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=-4.1 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, T_DKIM_INVALID 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 CFA512847A for ; Sun, 4 Feb 2018 21:02:40 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id AAE736E25B; Sun, 4 Feb 2018 21:02:33 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-pg0-x244.google.com (mail-pg0-x244.google.com [IPv6:2607:f8b0:400e:c05::244]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1D262898C4 for ; Sun, 4 Feb 2018 17:54:47 +0000 (UTC) Received: by mail-pg0-x244.google.com with SMTP id w17so16510743pgv.6 for ; Sun, 04 Feb 2018 09:54:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=/ZUfQ1VXyGovivILFu3FDW5rlG4pcbnT8fHzlqCZtSM=; b=GCyxz3GOZOjAY9OWmdpdQ8xo5+B4i0hcsSCyST+qHaJkHZ4OgQGqwyqV14ymzil+Xu InYy5U1dR9goIhOEWP4E/gjVgRp6RUsWwRgTpWLhzTNSn+glNQ0wSnLAPMI+EaLtE1+8 lXAz0ReuGjz2gQxtKteiaTJD/1skPWxJ3HGKeNjmpWOz6ELPweY/8VdqLdnXZYdAYh6X OWe1aL87qMrh1V38/BZaxtaq2CTNfoave1q/Yd++6ApmjjsrkErxm/eqgTLtZRrpTau4 tNbtPdbjtXJDxOuKTtm34yhCfNtZ0KCT1U/wrySRq0ikCJO5O46a5uCVKEryTvyK8c6r Up/Q== 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:in-reply-to :references; bh=/ZUfQ1VXyGovivILFu3FDW5rlG4pcbnT8fHzlqCZtSM=; b=ReIAJRx6QsHIFx+vbj63sUmZX/phSFxjyjvXgO+97Kdfv2xb4PdAAoWVkU029LDfEN x6cbATzZSirtkmn1q+T4mJMZgoEFNL7E6Jp2QFlK2BEspGnFyIEkcBWAVATkUt1PHWz/ tyUNwhNYQkseU1uj+/f92lR2YYjhC8+Ax8sPcqx3TRxITDp/selKpeTrNrLHtwSFTU2C 4QVWkqETZDbPRWFAsK1g6bEb4Wsi0oVWejQZEJ2F5to8Owi6c9mN795BlkFzz29zBMo5 48tnRzq0CIQds2u5JaA7EmiAGitfBK4IUQLYmbE7jYNdnzWWQQpHeQQx3idApDevSUwN mGTg== X-Gm-Message-State: AKwxyte9Tblfm0BPd6QWHhuFZlaDoLnSX6mtY5uz79IR0IzTuX6cDZ1L mfX9rWVv5iU4YJfbwzKtC98= X-Google-Smtp-Source: AH8x225u7DjjDy/bh/WpWCf/blvYjMLpONqcWcSgnizFqtKLYe3tYP05BS7uDGCcpmR74xTuAP9kJg== X-Received: by 10.98.182.16 with SMTP id j16mr15196023pff.220.1517766886606; Sun, 04 Feb 2018 09:54:46 -0800 (PST) Received: from localhost.localdomain ([115.97.187.51]) by smtp.gmail.com with ESMTPSA id u86sm13113279pfa.102.2018.02.04.09.54.41 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 04 Feb 2018 09:54:46 -0800 (PST) From: Jagan Teki X-Google-Original-From: Jagan Teki To: Shawn Guo Subject: [PATCH v3 1/7] drm/panel: simple: add support for Ampire AM-800480AYTZQW-00H Date: Sun, 4 Feb 2018 23:19:25 +0530 Message-Id: <1517766571-409-2-git-send-email-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1517766571-409-1-git-send-email-jagan@amarulasolutions.com> References: <1517766571-409-1-git-send-email-jagan@amarulasolutions.com> X-Mailman-Approved-At: Sun, 04 Feb 2018 21:02:32 +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: devicetree@vger.kernel.org, Matteo Lisi , David Airlie , linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Thierry Reding , Jagan Teki , Sascha Hauer , Fabio Estevam , Michael Trimarchi , linux-arm-kernel@lists.infradead.org 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 Ampire AM-800480AYTZQW-00H 7.0" WGA LCD, which can be supported by the simple panel driver. Signed-off-by: Jagan Teki Reviewed-by: Rob Herring --- Changes for v3: - collect Rob reiew tag Changes for v2: - Updated binding info about optional properties, node and example .../display/panel/ampire,am-800480aytzqw-00h.txt | 25 ++++++++++++++++++++ drivers/gpu/drm/panel/panel-simple.c | 27 ++++++++++++++++++++++ 2 files changed, 52 insertions(+) create mode 100644 Documentation/devicetree/bindings/display/panel/ampire,am-800480aytzqw-00h.txt diff --git a/Documentation/devicetree/bindings/display/panel/ampire,am-800480aytzqw-00h.txt b/Documentation/devicetree/bindings/display/panel/ampire,am-800480aytzqw-00h.txt new file mode 100644 index 0000000..abb5eee --- /dev/null +++ b/Documentation/devicetree/bindings/display/panel/ampire,am-800480aytzqw-00h.txt @@ -0,0 +1,25 @@ +Ampire AM-800480AYTZQW-00H 7.0" WVGA 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 "ampire,am-800480aytzqw-00h" + +Optional properties: +- backlight: phandle of the backlight device attached to the panel + +Optional nodes: +- Video port for LVDS panel input. + +Example: + panel { + compatible = "ampire,am-800480aytzqw-00h"; + backlight = <&backlight_lvds>; + + port { + panel_in: endpoint { + remote-endpoint = <&lvds0_out>; + }; + }; + }; diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm/panel/panel-simple.c index 5591984..2ecc14b 100644 --- a/drivers/gpu/drm/panel/panel-simple.c +++ b/drivers/gpu/drm/panel/panel-simple.c @@ -412,6 +412,30 @@ static const struct panel_desc ampire_am_480272h3tmqw_t01h = { .bus_format = MEDIA_BUS_FMT_RGB888_1X24, }; +static const struct display_timing ampire_am_800480aytzqw_00h_timing = { + .pixelclock = { 27700000, 29200000, 39600000 }, + .hactive = { 800, 800, 800 }, + .hfront_porch = { 12, 40, 212 }, + .hback_porch = { 88, 88, 88 }, + .hsync_len = { 1, 2, 40 }, + .vactive = { 480, 480, 480 }, + .vfront_porch = { 1, 13, 88 }, + .vback_porch = { 32, 32, 32 }, + .vsync_len = { 1, 2, 3 }, + .flags = DISPLAY_FLAGS_DE_HIGH, +}; + +static const struct panel_desc ampire_am_800480aytzqw_00h = { + .timings = &ire_am_800480aytzqw_00h_timing, + .num_timings = 1, + .bpc = 6, + .size = { + .width = 154, + .height = 86, + }, + .bus_format = MEDIA_BUS_FMT_RGB666_1X7X3_SPWG, +}; + static const struct drm_display_mode ampire_am800480r3tmqwa1h_mode = { .clock = 33333, .hdisplay = 800, @@ -2028,6 +2052,9 @@ static const struct of_device_id platform_of_match[] = { .compatible = "ampire,am-480272h3tmqw-t01h", .data = &ire_am_480272h3tmqw_t01h, }, { + .compatible = "ampire,am-800480aytzqw-00h", + .data = &ire_am_800480aytzqw_00h, + }, { .compatible = "ampire,am800480r3tmqwa1h", .data = &ire_am800480r3tmqwa1h, }, {