Received: by 2002:a05:7412:b995:b0:f9:9502:5bb8 with SMTP id it21csp7117758rdb; Wed, 3 Jan 2024 05:22:38 -0800 (PST) X-Google-Smtp-Source: AGHT+IFlV5lz1gJ+LVnngP/cLq2WSYp19sUdW9Enu5H21D1twMwXm1NHsAmikT9Zk7JccxQmlL6/ X-Received: by 2002:a17:902:7285:b0:1d4:b012:60d with SMTP id d5-20020a170902728500b001d4b012060dmr2335745pll.46.1704288158020; Wed, 03 Jan 2024 05:22:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704288158; cv=none; d=google.com; s=arc-20160816; b=v9NTqQkhI+M9ebOkf/9G3F4FRs961era7BZlMkH5X8okzAzhjxIox/RM6Xhd7GWn6B e50tictbUB8Gi3oktLZ4hxmG5mJcgrglIy3Vw1auZC506gMSfcqk/GRHc6uk2RAstCh1 4RL4LAaL4sWHORNznDi+HQ/D48IHPFu1iXIWb5DTTUDmYPbCbaE8aemROpoYm1ZDNpan tIYDF9li1/gAWV9GRa1ru93zgOLk/R9SE9D581zZCv/aq/Kbq9AVWJW7l+fwo9Xn3vOr UJhNAU9uKfgmJTpjWf2ONVmioirvu6Zvl9FF0M6TW6mbViwm1WqF3aT2Zu0+VHljbKlP nqPA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :references:message-id:subject:to:from:date:dkim-signature; bh=HwSe76KY0H/RsYYmdGNSjsosRJjjZ+RYpjPD2WKLyKM=; fh=aRh2SCqgGkQyXMQ7YIGk205cWsefY0aqLDUUlC0nWW4=; b=FPsei/B31cVSzyz5n/cRIcTzwkHVYgYvuN8+YfqXx33/Y54xXi8+jBumNjYjw3Q6Gs 4DhhI6ES3Ks3+rRuSUTcu4+PpwajM4hdvqZ0QquwDi36b92a23aJpcAH9uwIxSGNHGIH W0/vhOPqWs2JzF2YIyhehBODv7yiBCLhdcXxsbIgldYtTRA5f6E4lF1hYlMNYRYVB1bh lelJApoTixvTXTQwfGGZ64IV6KaN1LQEdZX0AsyPRe3qOwrHqxu5ui0PTXDyUX9LZs09 cYpMRs54Xdvb2psFyXv+kPTRfZc7/Ddf+NDevbg51aNF2oNtc6Le81s8p6DDngeO2oRW p2dg== ARC-Authentication-Results: i=1; mx.google.com; dkim=temperror (no key for signature) header.i=@mecka.net header.s=2016.11 header.b=gigy8Xom; spf=pass (google.com: domain of linux-kernel+bounces-15561-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-15561-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id i13-20020a17090332cd00b001d4be2e82f5si3947949plr.167.2024.01.03.05.22.37 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Jan 2024 05:22:38 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-15561-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=temperror (no key for signature) header.i=@mecka.net header.s=2016.11 header.b=gigy8Xom; spf=pass (google.com: domain of linux-kernel+bounces-15561-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-15561-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id A793D284CB9 for ; Wed, 3 Jan 2024 13:22:37 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C16DF199AB; Wed, 3 Jan 2024 13:22:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=fail reason="key not found in DNS" (0-bit key) header.d=mecka.net header.i=@mecka.net header.b="gigy8Xom" X-Original-To: linux-kernel@vger.kernel.org Received: from mecka.net (mecka.net [159.69.159.214]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A37321947C; Wed, 3 Jan 2024 13:22:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=mecka.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=mecka.net DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mecka.net; s=2016.11; t=1704288144; bh=jI38MkiHkb6c5DZuzb+pvbd/Eze9cPlo8CmwRLCLqrM=; h=Date:From:To:Subject:References:In-Reply-To:From; b=gigy8Xom3an2US+AIMPH7e3W5YVhBtfs9THOE0aly9+wfI62SaVJ/wqj88fR9XBIS 0Tmb/JrVpNW5zAvnZueh63ddNOkl++BCDUX1C+l061pFLEoWCfxyxhdxTaf8pqwtJ6 m1nqm3jdt40GudCzGaJzCX/Re2J1mxAT8MaMEETwqzYULuld4MXtwNJKEw3a4l4ris +kgWAqHTOO+0MJeWAPqDdFoDEfHD8uxDsfzSXdxHAsscBJytq/omZpuKWmREZAwmrK Q+F2BhPk1xxBGFd1Yp1fAwnMYQDUoqZkWxudCse8wVFY3Eng2DG1uoOaTL3ePJ0PhE 1Kq1COlzWtPJA== Received: from mecka.net (unknown [185.147.11.134]) by mecka.net (Postfix) with ESMTPSA id 6F475379CE7; Wed, 3 Jan 2024 14:22:23 +0100 (CET) Date: Wed, 3 Jan 2024 14:22:22 +0100 From: Manuel Traut To: =?utf-8?Q?Ond=C5=99ej?= Jirman , Neil Armstrong , Jessica Zhang , Sam Ravnborg , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Heiko Stuebner , Sandy Huang , Mark Yao , Diederik de Haas , Segfault , Arnaud Ferraris , Danct12 , dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org Subject: Re: [PATCH v3 4/4] arm64: dts: rockchip: Add devicetree for Pine64 PineTab2 Message-ID: References: <20240102-pinetab2-v3-0-cb1aa69f8c30@mecka.net> <20240102-pinetab2-v3-4-cb1aa69f8c30@mecka.net> <775vjfucu2g2s6zzeutj7f7tapx3q2geccpxvv4ppcms4hxbq7@cbrdmlu2ryzp> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <775vjfucu2g2s6zzeutj7f7tapx3q2geccpxvv4ppcms4hxbq7@cbrdmlu2ryzp> On Tue, Jan 02, 2024 at 07:07:56PM +0100, Ondřej Jirman wrote: > Hello Manuel, Hello Ondřej, > On Tue, Jan 02, 2024 at 05:15:47PM +0100, Manuel Traut wrote: > > From: Alexander Warnecke > > > > [...] > > > > + > > + backlight: backlight { > > + compatible = "pwm-backlight"; > > + pwms = <&pwm4 0 25000 0>; > > + brightness-levels = <20 220>; > > + num-interpolated-steps = <200>; > > Does this linear brightness -> PWM duty cycle mapping lead to linear > relationship between brighntess level and subjective brightness on this HW? > > I doubt it a bit... I tested it with the brightness slider in phosh, for me it looks good. > > + > > + hdmi-con { > > hdmi-connector ack, changed for v4 > > + compatible = "hdmi-connector"; > > + type = "d"; > > + > > + port { > > + hdmi_con_in: endpoint { > > + remote-endpoint = <&hdmi_out_con>; > > + }; > > + }; > > + }; > > + > > + leds { > > + compatible = "gpio-leds"; > > + > > Spurious newline ^ ack, changed for v4 > > + vcc_3v3: vcc-3v3 { > > Regulator node names shoule end with -regulator suffix. The same applies for > all of the below nodes. ack, changed for v4 > > + compatible = "regulator-fixed"; > > + regulator-name = "vcc_3v3"; > > + regulator-always-on; > > + regulator-boot-on; > > + regulator-min-microvolt = <3300000>; > > + regulator-max-microvolt = <3300000>; > > + vin-supply = <&vcc3v3_sys>; > > + }; > > + > > + vdd1v2_dvp: vdd1v2-dvp { > > + compatible = "regulator-fixed"; > > + regulator-name = "vdd1v2_dvp"; > > + regulator-min-microvolt = <1200000>; > > + regulator-max-microvolt = <1200000>; > > + vin-supply = <&vcc_3v3>; > > + /*enable-supply = <&vcc2v8_dvp>;*/ > > There's no such property. Delete this commented out line. ack, changed for v4 > > + lcd: panel@0 { > > + compatible = "boe,th101mb31ig002-28a"; > > + reg = <0>; > > + backlight = <&backlight>; > > + enable-gpios = <&gpio0 RK_PC7 GPIO_ACTIVE_HIGH>; > > + pinctrl-names = "default"; > > + pinctrl-0 = <&lcd_pwren_h &lcd0_rst_l>; > > Re lcd0_rst_l: > > It's a bit weird conceptually to reference from dtsi something that's only > declared in dts that includes the dtsi. Maybe move pinctrl-* properties > to dts &lcd, too... Will be better I guess, changed for v4. > > + vcc5v_midu: BOOST { > > + regulator-always-on; > > + regulator-boot-on; > > + regulator-min-microvolt = <5000000>; > > + regulator-max-microvolt = <5000000>; > > + regulator-name = "boost"; > > + regulator-state-mem { > > + regulator-off-in-suspend; > > I guess this prevents remote USB wakeup by USB devices. Like wakeup via USB > keyboard. Probably not a bad thing, though. That is true. After 'echo mem > /sys/power/state' It is not possible to wakeup the device with a USB Keyboard or mouse. However if the surface like keyboard is used that is shipped with the device, wakeup works if the keyboard/tablet gets unfold. For me this behaviour is fine. Other opinions? > > +&pcie2x1 { > > + pinctrl-names = "default"; > > + pinctrl-0 = <&pcie_reset_h>; > > + reset-gpios = <&gpio1 RK_PB2 GPIO_ACTIVE_HIGH>; > > + vpcie3v3-supply = <&vcc3v3_minipcie>; > > + status = "okay"; > > +}; > > Does it make sense to enable this HW block by default, when it isn't used on > actual HW? There is a flat ribbon connector, if someone wants to build sth. it might be helpful. However I am also fine with removing it for now. > > +&pinctrl { > > + bt { > > + bt_wake_host_h: bt-wake-host-h { > > + rockchip,pins = <0 RK_PB5 RK_FUNC_GPIO &pcfg_pull_down>; > > + }; > > + }; > > ^^^ unused I do not bother to removing unused pinctrls, however even if there is no user at the moment, if we look at a dtb as a machine parseable device description it is probably ok, that it is there? > > + > > + camerab { > > + camerab_pdn_l: camerab-pdn-l { > > + rockchip,pins = <4 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>; > > + }; > > + > > + camerab_rst_l: camerab-rst-l { > > + rockchip,pins = <4 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>; > > + }; > > + }; > > + > > + cameraf { > > + cameraf_pdn_l: cameraf-pdn-l { > > + rockchip,pins = <4 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>; > > + }; > > + > > + cameraf_rst_l: cameraf-rst-l { > > + rockchip,pins = <4 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>; > > + }; > > + }; > > ^^^ unused > > > + usb { > > + usbcc_int_l: usbcc-int-l { > > + rockchip,pins = <0 RK_PC5 RK_FUNC_GPIO &pcfg_pull_none>; > > + }; > > ^^^ unused > > > + wifi { > > + host_wake_wl: host-wake-wl { > > + rockchip,pins = <0 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>; > > + }; > > + > > + wifi_pwren: wifi-pwren { > > + rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>; > > + }; > > + > > + wifi_wake_host_h: wifi-wake-host-h { > > + rockchip,pins = <0 RK_PC4 RK_FUNC_GPIO &pcfg_pull_down>; > > + }; > > + }; > > ^^^ all of this wifi stuff is unused > > Also wifi_pwren is not really useful on actual HW. W_VBAT is routed directly > to wifi chip, with wifi_pwren_h signal having no effect: (short via R9664) > > https://megous.com/dl/tmp/b499859c1012f969.png ack, removed for v4 > > +&uart1 { > > + pinctrl-names = "default"; > > + pinctrl-0 = <&uart1m0_xfer > > + &uart1m0_ctsn > > + &uart1m0_rtsn>; > > + status = "okay"; > > + uart-has-rtscts; > > +}; > > Not sure about enabling UART for bluetooth, without having the bluetooth driver > hooked in, somehow. UART will by default pull TX signal high, which may cause > current leakage into gpio/uart pin of the bluetooth chip, if it's not powered up. > > Maybe just remove this, until bluetooth is figured out... Makes sense, removed for v4. Thanks for your feedback, Manuel