Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp609708imm; Wed, 25 Jul 2018 03:04:35 -0700 (PDT) X-Google-Smtp-Source: AAOMgpea3jcAb3Z59nR83BNyUfu8mb5eEfoOaAJ43YFGg6LVrPK0BUtYqJs9PdPXduiMa6u37xCD X-Received: by 2002:a62:3f99:: with SMTP id z25-v6mr21544697pfj.250.1532513075919; Wed, 25 Jul 2018 03:04:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532513075; cv=none; d=google.com; s=arc-20160816; b=AASCa6Gt8c33Mq3Pux9n9TUmtutGyUTMBxy0R3Bd/AktE+bN3v1FvqAeqmActoKXYD 9QDjPNn2xBxHDj4yq/O6OlhLGCIZDDjVcaZAh+Z+cDIA68Hk2q8w8s1eH2H8ZnMMDRki H470cmP5VhHITPthgoIQYecLWEtiBMnLGCWkusiVFUpgNVLOkHle9tCj9sgaWsFhTaMr X9z057fF3YLy/+cmXTCjtJ8rYgH9XSL+LVXMiPoV30ZrQNQSoVsu9Ty8V+5dSoh2F8G1 ewl3OS6uSiVzAJ+FxCkrHOYYllCnsXEgzmeRZMQLn5rGx95sueaW44o4uUgtHhP68dLE O81g== 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 :arc-authentication-results; bh=duqJZTJiT1iAVlcQ19Fpu61HgLuzRugJ0N20VMrCmtg=; b=SmTkanl2AZeDnFJWabSoRClUZ6pwmfdyKjOXYTe8fQSCVlaeixRpvENQFVV/078l17 +nNugFVhaSsP6RT2ywLq7DhEbhKHCCM/uf3jYLxTg8iWM+9Ufww0Aq2Zwzy+cYoCuQIH M4bTzCOqtZ9pecsUkpv8rgljLTAlCnt/tX+tBMBWCdRiHePs5SLtH9Sb7hWzyA5p6Yik rnriil/grir6jTL7TqsKc3x75onM4IqX+kHR4Yl4zE1MjZmXCuO4cn4q3u1QheAaIAHB XgR71raga91QBF2qS9i42SJKVDPEyDemaCNm7EEZtclwvwdzX7272HSGteSrJZMhlvoD zv+A== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n7-v6si11843692plp.363.2018.07.25.03.04.20; Wed, 25 Jul 2018 03:04:35 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728770AbeGYLNp (ORCPT + 99 others); Wed, 25 Jul 2018 07:13:45 -0400 Received: from gloria.sntech.de ([185.11.138.130]:45424 "EHLO gloria.sntech.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728658AbeGYLNo (ORCPT ); Wed, 25 Jul 2018 07:13:44 -0400 Received: from 095-097-149-005.static.chello.nl ([95.97.149.5] helo=phil.localnet) by gloria.sntech.de with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1fiGct-0002ES-CJ; Wed, 25 Jul 2018 12:02:35 +0200 From: Heiko Stuebner To: djw@t-chip.com.cn Cc: linux-rockchip@lists.infradead.org, Wayne Chou , devicetree@vger.kernel.org, Jianqun Xu , Jacob Chen , Brian Norris , Klaus Goger , linux-kernel@vger.kernel.org, Heinrich Schuchardt , Shawn Lin , Ezequiel Garcia , Jagan Teki , Masahiro Yamada , Will Deacon , Mark Rutland , Rob Herring , Catalin Marinas , linux-arm-kernel@lists.infradead.org, Enric Balletbo i Serra Subject: Re: [PATCH v0] arm64: dts: rockchip: add support for ROC-RK3399-PC board Date: Wed, 25 Jul 2018 12:02:34 +0200 Message-ID: <2859712.DISUneb7pN@phil> In-Reply-To: <87in54ge68.fsf@archiso.i-did-not-set--mail-host-address--so-tickle-me> References: <1532161826-2537-1-git-send-email-djw@t-chip.com.cn> <139327780.KNaNigg5Hs@phil> <87in54ge68.fsf@archiso.i-did-not-set--mail-host-address--so-tickle-me> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Levin, Am Mittwoch, 25. Juli 2018, 05:57:51 CEST schrieb djw@t-chip.com.cn: > >> + vcc_vbus_typec0: vcc-vbus-typec0 { > >> + compatible = "regulator-fixed"; > >> + regulator-name = "vcc_vbus_typec0"; > >> + regulator-always-on; > >> + regulator-boot-on; > >> + regulator-min-microvolt = <5000000>; > >> + regulator-max-microvolt = <5000000>; > >> + }; > >> + > >> + vcc12v_sys: mp8859-dcdc1 { > > > > The mp8859 seems to be an i2c-device, as also shown by the > > nearly empty mp8859 entry below, so shouldn't this regulator > > be defined there? > > Question here. Since mp8859 driver is not mainlined yet. Shall I leave > the regulator here (mp8859 defaults to output 5V) and remove the > mp8859 from the i2c? Yep, sounds good ... also please add a comment of sorts that this is temporary until the mp8859 has its own dt-binding. > > [...] > > > >> + vcc_hub_en: vcc_hub_en-regulator { > >> + compatible = "regulator-fixed"; > >> + enable-active-high; > >> + gpio = <&gpio2 RK_PA4 GPIO_ACTIVE_HIGH>; > >> + pinctrl-names = "default"; > >> + pinctrl-0 = <&hub_rst>; > >> + regulator-name = "vcc_hub_en"; > >> + regulator-always-on; > > > > missing vin-supply > This just comes in need of setting GPIO2_A4 (HUB_RST) to high > This dummy regulator should be removed. > > I modify the pinctrl of hub_rst to output high: > > hub_rst: hub-rst { > rockchip,pins = <2 RK_PA4 RK_FUNC_GPIO &pcfg_output_high>; > }; > > and add hub_rst to the pinctrl-0 of vcc5v0_host: > > vcc5v0_host: vcc5v0-host-regulator { > compatible = "regulator-fixed"; > enable-active-high; > gpio = <&gpio1 RK_PA0 GPIO_ACTIVE_HIGH>; > pinctrl-names = "default"; > pinctrl-0 = <&vcc5v0_host_en &hub_rst>; > regulator-name = "vcc5v0_host"; > regulator-always-on; > vin-supply = <&vcc_sys>; > }; > > Tested show that it works. But is it the recommended way to set this > gpio (HUB_RST) high? BTW, vcc5v0_host is the usb host voltage, > and HUB_RST needs to set high for the usb hub chip to work. It seems you can also model usb-hirarchy internals via the devicetree. I guess for these things like soc-gpios and such. See Documentation/devicetree/bindings/usb/usb-device.txt While I don't know if this can handle such reset gpios yet, you could at least move the pinctrl setting there. > >> + reg = <0x66>; > >> + }; > >> + > >> + fusb1: usb-typec@22 { > >> + compatible = "fcs,fusb302"; > >> + reg = <0x22>; > >> + pinctrl-names = "default"; > >> + pinctrl-0 = <&fusb1_int>; > >> + fcs,int-n = <&gpio1 RK_PA1 GPIO_ACTIVE_HIGH>; > > > > mainline binding expects an "interrupts" property not the > > fcs,int-n from above > > > It seems no existing user of fusb302 yet. I take that fcs,int-n > from the driver code. But I look up the binding doc, and come > with this result: > > fusb1: usb-typec@22 { > compatible = "fcs,fusb302"; > reg = <0x22>; > pinctrl-names = "default"; > pinctrl-0 = <&fusb1_int>; > interrupt-parent = <&gpio1>; > interrupts = <1 IRQ_TYPE_LEVEL_LOW>; > status = "okay"; > }; looks good, except please move the interrupt* properties between reg and pinctrl Heiko