Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3821844pxk; Tue, 29 Sep 2020 07:09:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw0B7XH3Uq+cK/pLYFvxT/9XgFWgazoi3qaarGkfG64634R76npm6vB3QxnqUBE4Y0PMlX0 X-Received: by 2002:a17:906:c8ca:: with SMTP id gc10mr3833133ejb.461.1601388551292; Tue, 29 Sep 2020 07:09:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601388551; cv=none; d=google.com; s=arc-20160816; b=xcMlkOokFBjxz2ySM39U+ojSleQsrHLnIu0vT2H9zFQnh5x1urRDalqhDv6xi3YTz1 Ne7tkRfkrtL+P0tLeaXY6qvn06zbuL+OornhXZh2OVaMpb/cgsW4GendOXTxdAjkfHP7 gfL35QW5b1JWMk5WdJ+wobtEw2SJk10RQNL2MLcYNeuStA1FwlBPc2TjAhbYNMzMO7Py LBJ6feBIwyGOafIYVBrqWeGYCVp/ZnKj9/uT1QWh2bNhJqlrULWouCFyjmhPMXO40lZx EJ7/wWIRCc5gFOB3I9jKsrl+zmQ2T9aqwdqmW4d8fbXBZIT4E0EqJmhjvqrDj78A1Lkc eerw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=Yo4q37cHRS0Cqs/GLbEngjanSGgIHGdnWgx4DjR/+gs=; b=s9Fxaq0Dw5tKaEeZZ6qJytOBQBYLSRPiJUtKqS6W0hdMa8ElJ7pp3mVN6O5lCZYeVO GRB9Hc743Qv4vbRS1Lj/uJ6E3hU3QLNhiCHEHvRck7pNVKt79kkEOAuae3B3bMGxpSGW 8awCRdpJNT7h6U5Lhz0fBCmCJhHG2Ud+fZyYukrrgKtuyf14nzeoymMAyOYcNrDSUZ/G tHtK3VgdsA3Usz/VqQF7OuX14ClWStVfcaGIdDFIDxUHFYMD0WLIqwhKPxYH3nBfJm32 ZYVXLeBEXjGEwMRt2oCPpuwciIEyKWdkPcnMphq0TeOjPc28FHobIQ8Gx9vuZtmhRou1 lHqQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id nd6si2749419ejb.189.2020.09.29.07.08.42; Tue, 29 Sep 2020 07:09:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730430AbgI2OFH (ORCPT + 99 others); Tue, 29 Sep 2020 10:05:07 -0400 Received: from relmlor2.renesas.com ([210.160.252.172]:21448 "EHLO relmlie6.idc.renesas.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728481AbgI2OFH (ORCPT ); Tue, 29 Sep 2020 10:05:07 -0400 X-IronPort-AV: E=Sophos;i="5.77,318,1596466800"; d="scan'208";a="58254312" Received: from unknown (HELO relmlir5.idc.renesas.com) ([10.200.68.151]) by relmlie6.idc.renesas.com with ESMTP; 29 Sep 2020 23:05:05 +0900 Received: from localhost.localdomain (unknown [10.226.36.204]) by relmlir5.idc.renesas.com (Postfix) with ESMTP id 8E7F34006DF0; Tue, 29 Sep 2020 23:05:03 +0900 (JST) From: Lad Prabhakar To: Geert Uytterhoeven , Magnus Damm , Rob Herring , linux-renesas-soc@vger.kernel.org, devicetree@vger.kernel.org Cc: Laurent Pinchart , linux-kernel@vger.kernel.org, Lad Prabhakar , Prabhakar Subject: [PATCH v3] ARM: dts: r8a7742-iwg21d-q7: Add LCD support Date: Tue, 29 Sep 2020 15:05:02 +0100 Message-Id: <20200929140502.16017-1-prabhakar.mahadev-lad.rj@bp.renesas.com> X-Mailer: git-send-email 2.17.1 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The iwg21d comes with a 7" capacitive touch screen, therefore add support for it. Signed-off-by: Lad Prabhakar Reviewed-by: Marian-Cristian Rotariu Reviewed-by: Laurent Pinchart Reviewed-by: Geert Uytterhoeven --- v2->v3 * Renamed vcc-supply to power-supply due to recent bindings changes [4] (similar changes done for G1[MN] [5]). * Restored RB tags from Laurent and Geert. * Sorted the DTS v1->v2 * This patch is part of series [1] (rest of the patches have be accepted by Geert [2]). * Added regulator for lvds * Added reset pin for touchpanel * This patch is based on series [3] [1] https://patchwork.kernel.org/project/linux-renesas-soc/list/ ?series=330277 [2] https://git.kernel.org/pub/scm/linux/kernel/git/geert/ renesas-devel.git/log/?h=renesas-arm-dt-for-v5.10 [3] https://patchwork.kernel.org/project/linux-renesas-soc/list/ ?series=330957 [4] https://patchwork.kernel.org/patch/11792205/ [5] https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/ commit/?h=next-20200929&id=08d7a73fffb6769b1cf2278bf697e692daba3abf --- arch/arm/boot/dts/r8a7742-iwg21d-q7.dts | 99 +++++++++++++++++++++++++ 1 file changed, 99 insertions(+) diff --git a/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts index c2c05c9685d1..0063ef92f50e 100644 --- a/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts +++ b/arch/arm/boot/dts/r8a7742-iwg21d-q7.dts @@ -30,6 +30,7 @@ /dts-v1/; #include "r8a7742-iwg21m.dtsi" +#include / { model = "iWave Systems RainboW-G21D-Qseven board based on RZ/G1H"; @@ -52,6 +53,16 @@ clock-frequency = <26000000>; }; + lcd_backlight: backlight { + compatible = "pwm-backlight"; + pwms = <&tpu 2 5000000 0>; + brightness-levels = <0 4 8 16 32 64 128 255>; + pinctrl-0 = <&backlight_pins>; + pinctrl-names = "default"; + default-brightness-level = <7>; + enable-gpios = <&gpio3 11 GPIO_ACTIVE_HIGH>; + }; + leds { compatible = "gpio-leds"; @@ -62,6 +73,41 @@ }; }; + lvds-receiver { + compatible = "ti,ds90cf384a", "lvds-decoder"; + power-supply = <&vcc_3v3_tft1>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@0 { + reg = <0>; + lvds_receiver_in: endpoint { + remote-endpoint = <&lvds0_out>; + }; + }; + port@1 { + reg = <1>; + lvds_receiver_out: endpoint { + remote-endpoint = <&panel_in>; + }; + }; + }; + }; + + panel { + compatible = "edt,etm0700g0dh6"; + backlight = <&lcd_backlight>; + power-supply = <&vcc_3v3_tft1>; + + port { + panel_in: endpoint { + remote-endpoint = <&lvds_receiver_out>; + }; + }; + }; + reg_1p5v: 1p5v { compatible = "regulator-fixed"; regulator-name = "1P5V"; @@ -85,6 +131,17 @@ }; }; + vcc_3v3_tft1: regulator-panel { + compatible = "regulator-fixed"; + + regulator-name = "vcc-3v3-tft1"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + enable-active-high; + startup-delay-us = <500>; + gpio = <&gpio5 28 GPIO_ACTIVE_HIGH>; + }; + vcc_sdhi2: regulator-vcc-sdhi2 { compatible = "regulator-fixed"; @@ -139,6 +196,16 @@ VDDIO-supply = <®_3p3v>; VDDD-supply = <®_1p5v>; }; + + touch: touchpanel@38 { + compatible = "edt,edt-ft5406"; + reg = <0x38>; + interrupt-parent = <&gpio0>; + interrupts = <24 IRQ_TYPE_EDGE_FALLING>; + /* GP1_29 is also shared with audio codec reset pin */ + reset-gpios = <&gpio1 29 GPIO_ACTIVE_LOW>; + vcc-supply = <&vcc_3v3_tft1>; + }; }; &can1 { @@ -152,6 +219,18 @@ status = "okay"; }; +&du { + status = "okay"; +}; + +&gpio0 { + touch-interrupt { + gpio-hog; + gpios = <24 GPIO_ACTIVE_LOW>; + input; + }; +}; + &gpio1 { can-trx-en-gpio{ gpio-hog; @@ -167,6 +246,17 @@ status = "okay"; }; +&lvds0 { + status = "okay"; + ports { + port@1 { + lvds0_out: endpoint { + remote-endpoint = <&lvds_receiver_in>; + }; + }; + }; +}; + &msiof0 { pinctrl-0 = <&msiof0_pins>; pinctrl-names = "default"; @@ -229,6 +319,11 @@ function = "avb"; }; + backlight_pins: backlight { + groups = "tpu0_to2"; + function = "tpu0"; + }; + can1_pins: can1 { groups = "can1_data_b"; function = "can1"; @@ -335,6 +430,10 @@ shared-pin; }; +&tpu { + status = "okay"; +}; + &usbphy { status = "okay"; }; -- 2.17.1