Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp575103ybb; Fri, 20 Mar 2020 04:28:53 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuPYXm8o3clpHtOymbwe2S+irbO5og/vnU+9AeERm0qLK92poKyTtkC6+3NwAVLC8O/kgGQ X-Received: by 2002:a9d:6ad4:: with SMTP id m20mr215600otq.129.1584703733223; Fri, 20 Mar 2020 04:28:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584703733; cv=none; d=google.com; s=arc-20160816; b=Ykf5XhdFrpf8xbjZGFAdRW6VRBi3R52Ksoiq6feRy4NVVm6vq9I1h29OdQPBIJ07mw bXF9oNqs6OtOZOv7LtzJPGGLlXCI/OcGPkZkrTIJDPd+SmJtBoond8cKUmIooTEWS7xL ZkQAV1FGs2kI6wbrIjzomObrSIYXnX5MimtsWhXg5W5mj7KDlj8jDRnoJWHgPv7XBe7f CGHPWknpC08zCZV0CeUWDmThxpKnaHrl3pqONfMInZ/Dj+3emRdSdo7OGz11mpcHySto fXRIo+ogEoPxoVw4JRvpN6BwFz3dlPdLac/WXyrn989os4Fd4eU4aYqEcukJg6dN0U8n fLag== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=46bymtTeZdIRfz8ns1mclDd2aTpPZb8MaF2yz0v69wI=; b=uuxKzNJaCQDn7VV5huuHtcy0+/6apqgqP/+vFTb8hBEnpaT8Y/xjuRP7F8EuDT11cJ aPaxX5DoIlgy+OuLtncMbdRcY0MPdf7nEs19PitPWvGS8TfbhBu/bx20pbX6+We4XL2P ozjtHh3WameMryttO+pbVcy1KNWy4+igkz3abmkgEv2De46g6uB87Gv0ND6fMRYh0MPx 1smCIejFDKHadMAybYTS5gpR3m1oP5uGo0TSt1wQ0CZyNcnvcA6K7zc7tBVkZViZ9BgF WP39PnzmND3EBokHGuJkH8G2gJ4Eqz8d8LC3LrRT2/eW/OsdRUJKLpi7kiVXoIzYXr3i EvEg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@pascalroeleven.nl header.s=x header.b=hLaCnl1W; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=pascalroeleven.nl Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w29si3050447oth.24.2020.03.20.04.28.39; Fri, 20 Mar 2020 04:28:53 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@pascalroeleven.nl header.s=x header.b=hLaCnl1W; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=pascalroeleven.nl Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727022AbgCTL1K (ORCPT + 99 others); Fri, 20 Mar 2020 07:27:10 -0400 Received: from web0081.zxcs.nl ([185.104.29.10]:34380 "EHLO web0081.zxcs.nl" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726912AbgCTL1K (ORCPT ); Fri, 20 Mar 2020 07:27:10 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=pascalroeleven.nl; s=x; h=Content-Transfer-Encoding:MIME-Version:References :In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=46bymtTeZdIRfz8ns1mclDd2aTpPZb8MaF2yz0v69wI=; b=hLaCnl1WS/ptAg34FJWrRB19vY zi2p3dNV+kgs+8f54SROCdvfTlJWqpog8YgVURNvjj3U/7Pw4NufZlDuAcjpE+d7Up8CLxxNmiY+x d5mu2uIExmv9JIE9NjkPMU+vpaWw8J+2acxCWv0qh9sjs1gWpGGX0oLqQwnK8VdGLGk5v5Z9ASGrZ 6RFJ8DWbAv0D2v43kIpkiMwjsXesJ0W7CZI6dEJGeZUYrnjwZzfRgPMABhgE0kDjtMVOQJrtE/3Fm bN5td0rcZPiZfsNVO3qfatn+OGCQtJ+YprIFjBqShKDvnzeQ4rLlzMy1mwT3TplIHC9a3TZt3q86Q FTcBOZvw==; Received: from ip565b1bc7.direct-adsl.nl ([86.91.27.199]:57936 helo=localhost.localdomain) by web0081.zxcs.nl with esmtpsa (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128) (Exim 4.92.3) (envelope-from ) id 1jFFnt-0011ci-Ml; Fri, 20 Mar 2020 12:27:05 +0100 From: Pascal Roeleven To: Rob Herring , Mark Rutland , Maxime Ripard , Chen-Yu Tsai , Thierry Reding , Sam Ravnborg , David Airlie , Daniel Vetter , Mark Brown , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Cc: linux-sunxi@googlegroups.com, Pascal Roeleven Subject: [PATCH v2 5/5] ARM: dts: sun4i: Add support for Topwise A721 tablet Date: Fri, 20 Mar 2020 12:21:36 +0100 Message-Id: <20200320112205.7100-6-dev@pascalroeleven.nl> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200320112205.7100-1-dev@pascalroeleven.nl> References: <20200320112205.7100-1-dev@pascalroeleven.nl> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Authenticated-Id: dev@pascalroeleven.nl Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The Topwise A721/LY-F1 tablet is a tablet sold around 2012 under different brands. The mainboard mentions A721 clearly, so this tablet is best known under this name. Signed-off-by: Pascal Roeleven --- arch/arm/boot/dts/Makefile | 3 +- arch/arm/boot/dts/sun4i-a10-topwise-a721.dts | 242 +++++++++++++++++++ 2 files changed, 244 insertions(+), 1 deletion(-) create mode 100644 arch/arm/boot/dts/sun4i-a10-topwise-a721.dts diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile index 78f144e33..6e6141e00 100644 --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile @@ -1040,7 +1040,8 @@ dtb-$(CONFIG_MACH_SUN4I) += \ sun4i-a10-olinuxino-lime.dtb \ sun4i-a10-pcduino.dtb \ sun4i-a10-pcduino2.dtb \ - sun4i-a10-pov-protab2-ips9.dtb + sun4i-a10-pov-protab2-ips9.dtb \ + sun4i-a10-topwise-a721.dtb dtb-$(CONFIG_MACH_SUN5I) += \ sun5i-a10s-auxtek-t003.dtb \ sun5i-a10s-auxtek-t004.dtb \ diff --git a/arch/arm/boot/dts/sun4i-a10-topwise-a721.dts b/arch/arm/boot/dts/sun4i-a10-topwise-a721.dts new file mode 100644 index 000000000..936171d30 --- /dev/null +++ b/arch/arm/boot/dts/sun4i-a10-topwise-a721.dts @@ -0,0 +1,242 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * Copyright 2020 Pascal Roeleven + */ + +/dts-v1/; +#include "sun4i-a10.dtsi" +#include "sunxi-common-regulators.dtsi" + +#include +#include +#include +#include + +/ { + model = "Topwise A721"; + compatible = "topwise,a721", "allwinner,sun4i-a10"; + + aliases { + serial0 = &uart0; + }; + + backlight: backlight { + compatible = "pwm-backlight"; + pwms = <&pwm 0 100000 PWM_POLARITY_INVERTED>; + power-supply = <®_vbat>; + enable-gpios = <&pio 7 7 GPIO_ACTIVE_HIGH>; /* PH7 */ + brightness-levels = <0 30 40 50 60 70 80 90 100>; + default-brightness-level = <8>; + }; + + chosen { + stdout-path = "serial0:115200n8"; + }; + + panel: panel { + compatible = "starry,kr070pe2t"; + backlight = <&backlight>; + power-supply = <®_lcd_power>; + + port { + panel_input: endpoint { + remote-endpoint = <&tcon0_out_panel>; + }; + }; + }; + + reg_lcd_power: reg-lcd-power { + compatible = "regulator-fixed"; + regulator-name = "reg-lcd-power"; + gpio = <&pio 7 8 GPIO_ACTIVE_HIGH>; /* PH8 */ + enable-active-high; + }; + + reg_vbat: reg-vbat { + compatible = "regulator-fixed"; + regulator-name = "vbat"; + regulator-min-microvolt = <3700000>; + regulator-max-microvolt = <3700000>; + }; + +}; + +&codec { + status = "okay"; +}; + +&cpu0 { + cpu-supply = <®_dcdc2>; +}; + +&de { + status = "okay"; +}; + +&ehci0 { + status = "okay"; +}; + +&ehci1 { + status = "okay"; +}; + +&i2c0 { + status = "okay"; + + axp209: pmic@34 { + reg = <0x34>; + interrupts = <0>; + }; +}; + +#include "axp209.dtsi" + +&ac_power_supply { + status = "okay"; +}; + +&battery_power_supply { + status = "okay"; +}; + +&i2c1 { + status = "okay"; + + mma7660: accelerometer@4c { + compatible = "fsl,mma7660"; + reg = <0x4c>; + }; +}; + +&i2c2 { + status = "okay"; + + ft5406ee8: touchscreen@38 { + compatible = "edt,edt-ft5406"; + reg = <0x38>; + interrupt-parent = <&pio>; + interrupts = <7 21 IRQ_TYPE_EDGE_FALLING>; + touchscreen-size-x = <800>; + touchscreen-size-y = <480>; + vcc-supply = <®_vcc3v3>; + }; +}; + +&lradc { + vref-supply = <®_ldo2>; + status = "okay"; + + button-vol-down { + label = "Volume Down"; + linux,code = ; + channel = <0>; + voltage = <761904>; + }; + + button-vol-up { + label = "Volume Up"; + linux,code = ; + channel = <0>; + voltage = <571428>; + }; +}; + +&mmc0 { + vmmc-supply = <®_vcc3v3>; + bus-width = <4>; + cd-gpios = <&pio 7 1 GPIO_ACTIVE_LOW>; /* PH01 */ + status = "okay"; +}; + +&ohci0 { + status = "okay"; +}; + +&ohci1 { + status = "okay"; +}; + +&otg_sram { + status = "okay"; +}; + +&pio { + vcc-pb-supply = <®_vcc3v3>; + vcc-pf-supply = <®_vcc3v3>; + vcc-ph-supply = <®_vcc3v3>; +}; + +&pwm { + pinctrl-names = "default"; + pinctrl-0 = <&pwm0_pin>; + status = "okay"; +}; + +®_dcdc2 { + regulator-always-on; + regulator-min-microvolt = <1000000>; + regulator-max-microvolt = <1400000>; + regulator-name = "vdd-cpu"; +}; + +®_dcdc3 { + regulator-always-on; + regulator-min-microvolt = <1250000>; + regulator-max-microvolt = <1250000>; + regulator-name = "vdd-int-dll"; +}; + +®_ldo1 { + regulator-name = "vdd-rtc"; +}; + +®_ldo2 { + regulator-always-on; + regulator-min-microvolt = <3000000>; + regulator-max-microvolt = <3000000>; + regulator-name = "avcc"; +}; + +®_usb0_vbus { + status = "okay"; +}; + +®_usb1_vbus { + status = "okay"; +}; + +®_usb2_vbus { + status = "okay"; +}; + +&tcon0_out { + tcon0_out_panel: endpoint@0 { + reg = <0>; + remote-endpoint = <&panel_input>; + }; +}; + +&uart0 { + pinctrl-names = "default"; + pinctrl-0 = <&uart0_pb_pins>; + status = "okay"; +}; + +&usb_otg { + dr_mode = "otg"; + status = "okay"; +}; + +&usb_power_supply { + status = "okay"; +}; + +&usbphy { + usb0_id_det-gpios = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */ + usb0_vbus_det-gpios = <&pio 7 5 GPIO_ACTIVE_HIGH>; /* PH5 */ + usb0_vbus-supply = <®_usb0_vbus>; + usb1_vbus-supply = <®_usb1_vbus>; + usb2_vbus-supply = <®_usb2_vbus>; + status = "okay"; +}; -- 2.20.1