From patchwork Thu Oct 20 11:42:57 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 9386653 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 EDF3760487 for ; Thu, 20 Oct 2016 11:45:49 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DAAB929ABE for ; Thu, 20 Oct 2016 11:45:49 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CB31029ADA; Thu, 20 Oct 2016 11:45:49 +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_SIGNED, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id A0AED29ABE for ; Thu, 20 Oct 2016 11:45:48 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1bxBm0-0004FF-Dq; Thu, 20 Oct 2016 11:44:36 +0000 Received: from casper.infradead.org ([2001:770:15f::2]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1bxBl3-0003sh-Cx for linux-arm-kernel@bombadil.infradead.org; Thu, 20 Oct 2016 11:43:37 +0000 Received: from mail-qk0-x22c.google.com ([2607:f8b0:400d:c09::22c]) by casper.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1bxBl0-0007gP-Kg for linux-arm-kernel@lists.infradead.org; Thu, 20 Oct 2016 11:43:35 +0000 Received: by mail-qk0-x22c.google.com with SMTP id o68so88711852qkf.3 for ; Thu, 20 Oct 2016 04:43:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=G0NX36GOT2lwycc6d36LJwozjUCpivR9OyUTTKGfDWw=; b=D7i3qNCuA/uP+hX5/+wf3NoIXGWEhzPlMfzCQvxvkQv6fGijtFEBAOLAMSNR1C8j/h lWqjU7YrkZQLknceFA33ECRcajjPK4meg+rKM9IkJ0EsK5BIUQDeoB0O1cZvc1nbcriv kGxvBZnOG6QaLQp0AYIkUMpT4POBjg/iu+t2yq+28QkCyjvZvRKnALhOqEiuBlQQioXR psPT5U8wYu3EnlrCsJL1hghDlaiQowKvokNz2d3YzUjfevKZoxATCWYizYyLrXV0Khda uZMIEdsWdHGIr2e6mS+xLUqSsEtTQ7fsQjv6/DVi22Y6ab5VohxtAzzay3OrgluO8HGk yHcQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=G0NX36GOT2lwycc6d36LJwozjUCpivR9OyUTTKGfDWw=; b=HBYioqtJwrD3aniFSwV5ZG3wAJzfDmvtbf/9Sur8nn7t7NJvqqfwsDwVHX5LimXcQF CsasFv9g7hCXAlo5ahqMZhfbz6ZL0C2Gqi6vRH9TVCUCQJvZt1YfuzWg1hIkh3VuhWvK F0v2huJqXtaL6TDt3HO4QEUapU21XWat0BlyrSXCRLoGgr295uBBCaaazj92IhuKI0jO H8ekQE7Vd5FMvyQKiwbV6u/5frnGHKxFYwlpqTyzZ4vx9t6nMMfFmzBSO7rVLSevKiRQ rhKo93hdLXWFRynuc+J3sK9rNoDPw8MBHKGKWOFbpIwuX3z6ZP0MSYvYuySOK2jjidDd KMaw== X-Gm-Message-State: AA6/9Rn35KbJcmbdnLn2W46s2SWV8iT1nDnjvrdJO0rlD+b8e0kL61f3J7h+4ixN50pWKq3f X-Received: by 10.194.55.41 with SMTP id o9mr150127wjp.228.1476963791812; Thu, 20 Oct 2016 04:43:11 -0700 (PDT) Received: from localhost.localdomain ([90.63.244.31]) by smtp.gmail.com with ESMTPSA id wh3sm78121585wjb.49.2016.10.20.04.43.11 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 20 Oct 2016 04:43:11 -0700 (PDT) From: Neil Armstrong To: carlo@caione.org, khilman@baylibre.com Subject: [PATCH 4/4] ARM64: dts: meson-gxbb: Add MMC nodes to Nexbox A95x Date: Thu, 20 Oct 2016 13:42:57 +0200 Message-Id: <1476963777-1804-5-git-send-email-narmstrong@baylibre.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1476963777-1804-1-git-send-email-narmstrong@baylibre.com> References: <1476963777-1804-1-git-send-email-narmstrong@baylibre.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20161020_124334_830358_F171F31A X-CRM114-Status: GOOD ( 11.54 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-amlogic@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Neil Armstrong MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP Add support for eMMC/SD/SDIO on the Nexbox A95x. Signed-off-by: Neil Armstrong --- .../boot/dts/amlogic/meson-gxbb-nexbox-a95x.dts | 122 +++++++++++++++++++++ 1 file changed, 122 insertions(+) diff --git a/arch/arm64/boot/dts/amlogic/meson-gxbb-nexbox-a95x.dts b/arch/arm64/boot/dts/amlogic/meson-gxbb-nexbox-a95x.dts index 399d85f..9696820 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gxbb-nexbox-a95x.dts +++ b/arch/arm64/boot/dts/amlogic/meson-gxbb-nexbox-a95x.dts @@ -87,6 +87,61 @@ gpios = <&gpio_ao GPIOAO_3 GPIO_ACTIVE_LOW>; }; }; + + vddio_card: gpio-regulator { + compatible = "regulator-gpio"; + + regulator-name = "VDDIO_CARD"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <3300000>; + + gpios = <&gpio_ao GPIOAO_5 GPIO_ACTIVE_HIGH>; + gpios-states = <1>; + + /* Based on P200 schematics, signal CARD_1.8V/3.3V_CTR */ + states = <1800000 0 + 3300000 1>; + }; + + vddio_boot: regulator-vddio_boot { + compatible = "regulator-fixed"; + regulator-name = "VDDIO_BOOT"; + regulator-min-microvolt = <1800000>; + regulator-max-microvolt = <1800000>; + }; + + vddao_3v3: regulator-vddao_3v3 { + compatible = "regulator-fixed"; + regulator-name = "VDDAO_3V3"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + }; + + vcc_3v3: regulator-vcc_3v3 { + compatible = "regulator-fixed"; + regulator-name = "VCC_3V3"; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; + }; + + emmc_pwrseq: emmc-pwrseq { + compatible = "mmc-pwrseq-emmc"; + reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>; + }; + + wifi32k: wifi32k { + compatible = "pwm-clock"; + #clock-cells = <0>; + clock-frequency = <32768>; + pwms = <&pwm_ef 0 30518 0>; /* PWM_E at 32.768KHz */ + }; + + sdio_pwrseq: sdio-pwrseq { + compatible = "mmc-pwrseq-simple"; + reset-gpios = <&gpio GPIOX_6 GPIO_ACTIVE_LOW>; + clocks = <&wifi32k>; + clock-names = "ext_clock"; + }; }; &uart_AO { @@ -107,3 +162,70 @@ pinctrl-0 = <&remote_input_ao_pins>; pinctrl-names = "default"; }; + +/* Wireless SDIO Module */ +&sd_emmc_a { + status = "okay"; + pinctrl-0 = <&sdio_pins>; + pinctrl-names = "default"; + #address-cells = <1>; + #size-cells = <0>; + + bus-width = <4>; + cap-sd-highspeed; + max-frequency = <100000000>; + + non-removable; + disable-wp; + + mmc-pwrseq = <&sdio_pwrseq>; + + vmmc-supply = <&vddao_3v3>; + vqmmc-supply = <&vddio_boot>; +}; + +/* SD card */ +&sd_emmc_b { + status = "okay"; + pinctrl-0 = <&sdcard_pins>; + pinctrl-names = "default"; + + bus-width = <4>; + cap-sd-highspeed; + max-frequency = <100000000>; + disable-wp; + + cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_HIGH>; + cd-inverted; + + vmmc-supply = <&vddao_3v3>; + vqmmc-supply = <&vddio_card>; +}; + +/* eMMC */ +&sd_emmc_c { + status = "okay"; + pinctrl-0 = <&emmc_pins>; + pinctrl-names = "default"; + + bus-width = <8>; + cap-sd-highspeed; + cap-mmc-highspeed; + max-frequency = <200000000>; + non-removable; + disable-wp; + mmc-ddr-1_8v; + mmc-hs200-1_8v; + + mmc-pwrseq = <&emmc_pwrseq>; + vmmc-supply = <&vcc_3v3>; + vqmmc-supply = <&vddio_boot>; +}; + +&pwm_ef { + status = "okay"; + pinctrl-0 = <&pwm_e_pins>; + pinctrl-names = "default"; + clocks = <&clkc CLKID_FCLK_DIV4>; + clock-names = "clkin0"; +};