From patchwork Fri May 6 14:21:20 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kevin Hilman X-Patchwork-Id: 9033611 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 627D9BF29F for ; Fri, 6 May 2016 14:23:36 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6D9A42035D for ; Fri, 6 May 2016 14:23:35 +0000 (UTC) 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.kernel.org (Postfix) with ESMTPS id 8818C20218 for ; Fri, 6 May 2016 14:23:34 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1aygdk-0007eD-49; Fri, 06 May 2016 14:22:00 +0000 Received: from mail-pf0-x235.google.com ([2607:f8b0:400e:c00::235]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1aygdZ-0007W2-5l for linux-arm-kernel@lists.infradead.org; Fri, 06 May 2016 14:21:50 +0000 Received: by mail-pf0-x235.google.com with SMTP id c189so51943840pfb.3 for ; Fri, 06 May 2016 07:21:28 -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 :mime-version:content-transfer-encoding; bh=Fm9k8fXo5jVnrW4NmJyrHNqI3moAZcU9ovru9lg9ZT8=; b=Q+fPlSQl4spz9ART59Rso20SoIMjrqLdwEy3AN1zfFZnUdq1ZTFuN+XHD/C+hJETh1 BOZq6QDsqdjJCDRTkgKkg/QYq/wgBuBCZPGZOjylnp96qJ2A33iQzJfGowhSio8FM93k McoKqVVndBPE9B7K3iBv+AXbon8VfhnC8c8r3NGMa4axuLTITOk5cF9AVoOTsIyLa0tR q4mSTrcqL6z9p4Z/Et5fRXg0IG6Bte+PG4YRPc987y0gWAJ/1amAd3/Zfe159ueSVnCj r2WQ/dZeVE1ntl0cM0OsfBT+h1yaXN0zjPmJ/nQpx9Vh1qnMeKFzRTpg87IF6/KzGHRa 2hEw== 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:mime-version:content-transfer-encoding; bh=Fm9k8fXo5jVnrW4NmJyrHNqI3moAZcU9ovru9lg9ZT8=; b=M6SjrQUpdokRz3UA6hev7sTUavWHaZ5dgqeZwouATfn8KCquUljz8nVD6pUjkGB5FA H+JQSLz3c45jqd/efEN9cUeLmV///YAFoEn6EP8tQtydphTmHrjB3j9/4FPZ4PpyMi9r lzGBZEEbFpG+aKG7xa0u/gHMfINqKc4EvSmxNmXIxD3sUOxHJzOOhInpGpfmZMpMVPTc kcV/AFqjBIixHFPOYWvGzrfaHHgKOUKudjF/DnvkMIosE7PVvqzUyCTTo9OIaPZRFNc2 DS3QK48NKLSk4GiE+jJD71/M3jFeZxI4qUy9bup3bYkPi9jpb8REJv0sz/MryGgBXYJu pWUQ== X-Gm-Message-State: AOPr4FVQ+YV46yZy64Vq03x6fZ+pi8p91Dy6u2wxptPhCDnfKvlLeym2PWoty1cXxhebbANL X-Received: by 10.98.72.16 with SMTP id v16mr29416698pfa.12.1462544488376; Fri, 06 May 2016 07:21:28 -0700 (PDT) Received: from localhost (c-98-203-232-209.hsd1.wa.comcast.net. [98.203.232.209]) by smtp.gmail.com with ESMTPSA id n10sm21554695pfj.14.2016.05.06.07.21.27 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 06 May 2016 07:21:27 -0700 (PDT) From: Kevin Hilman To: linux-amlogic@lists.infradead.org, Carlo Caione , Linus Walleij Subject: [PATCH 1/7] pinctrl: amlogic: gxbb: add UART_AO_B, I2C Date: Fri, 6 May 2016 07:21:20 -0700 Message-Id: <1462544486-9516-2-git-send-email-khilman@baylibre.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1462544486-9516-1-git-send-email-khilman@baylibre.com> References: <1462544486-9516-1-git-send-email-khilman@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20160506_072149_250835_8F39C236 X-CRM114-Status: GOOD ( 13.13 ) X-Spam-Score: -1.9 (-) 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: Xing Wu , Victor Wan , linux-meson@googlegroups.com, linux-gpio@vger.kernel.org, Carlo Caione , Jerry Cao , =?UTF-8?q?Andreas=20F=C3=A4rber?= , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-6.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_MED,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add pins for some more AO domain devices: UART_AO_B and I2C master & slave. Also, rename UART_AO to UART_AO_A since UART_AO_B has also been added. Cc: Carlo Caione Signed-off-by: Kevin Hilman --- arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi | 2 +- drivers/pinctrl/meson/pinctrl-meson-gxbb.c | 39 ++++++++++++++++++++++++++--- 2 files changed, 37 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi b/arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi index 6dd27685e31e..35397fcc5380 100644 --- a/arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi +++ b/arch/arm64/boot/dts/amlogic/meson-gxbb.dtsi @@ -177,7 +177,7 @@ uart_ao_a_pins: uart_ao_a { mux { groups = "uart_tx_ao_a", "uart_rx_ao_a"; - function = "uart_ao"; + function = "uart_ao_a"; }; }; }; diff --git a/drivers/pinctrl/meson/pinctrl-meson-gxbb.c b/drivers/pinctrl/meson/pinctrl-meson-gxbb.c index eeabafbbf598..50551677b0ee 100644 --- a/drivers/pinctrl/meson/pinctrl-meson-gxbb.c +++ b/drivers/pinctrl/meson/pinctrl-meson-gxbb.c @@ -168,6 +168,16 @@ static const unsigned int uart_tx_ao_a_pins[] = { PIN(GPIOAO_0, 0) }; static const unsigned int uart_rx_ao_a_pins[] = { PIN(GPIOAO_1, 0) }; static const unsigned int uart_cts_ao_a_pins[] = { PIN(GPIOAO_2, 0) }; static const unsigned int uart_rts_ao_a_pins[] = { PIN(GPIOAO_3, 0) }; +static const unsigned int uart_tx_ao_b_pins[] = { PIN(GPIOAO_0, 0) }; +static const unsigned int uart_rx_ao_b_pins[] = { PIN(GPIOAO_1, 0), + PIN(GPIOAO_5, 0) }; +static const unsigned int uart_cts_ao_b_pins[] = { PIN(GPIOAO_2, 0) }; +static const unsigned int uart_rts_ao_b_pins[] = { PIN(GPIOAO_3, 0) }; + +static const unsigned int i2c_sck_ao_pins[] = {PIN(GPIOAO_4, 0) }; +static const unsigned int i2c_sda_ao_pins[] = {PIN(GPIOAO_5, 0) }; +static const unsigned int i2c_slave_sck_ao_pins[] = {PIN(GPIOAO_4, 0) }; +static const unsigned int i2c_slave_sda_ao_pins[] = {PIN(GPIOAO_5, 0) }; static struct meson_pmx_group meson_gxbb_periphs_groups[] = { GPIO_GROUP(GPIOZ_0, EE_OFF), @@ -316,10 +326,18 @@ static struct meson_pmx_group meson_gxbb_aobus_groups[] = { GPIO_GROUP(GPIOAO_13, 0), /* bank AO */ + GROUP(uart_tx_ao_b, 0, 26), + GROUP(uart_rx_ao_b, 0, 25), GROUP(uart_tx_ao_a, 0, 12), GROUP(uart_rx_ao_a, 0, 11), GROUP(uart_cts_ao_a, 0, 10), GROUP(uart_rts_ao_a, 0, 9), + GROUP(uart_cts_ao_b, 0, 8), + GROUP(uart_rts_ao_b, 0, 7), + GROUP(i2c_sck_ao, 0, 6), + GROUP(i2c_sda_ao, 0, 5), + GROUP(i2c_slave_sck_ao, 0, 2), + GROUP(i2c_slave_sda_ao, 0, 1), }; static const char * const gpio_periphs_groups[] = { @@ -365,8 +383,20 @@ static const char * const gpio_aobus_groups[] = { "GPIOAO_10", "GPIOAO_11", "GPIOAO_12", "GPIOAO_13", }; -static const char * const uart_ao_groups[] = { - "uart_tx_ao_a", "uart_rx_ao_a", "uart_cts_ao_a", "uart_rts_ao_a" +static const char * const uart_ao_a_groups[] = { + "uart_tx_ao_a", "uart_rx_ao_a", "uart_cts_ao_a", "uart_rts_ao_a", +}; + +static const char * const uart_ao_b_groups[] = { + "uart_tx_ao_b", "uart_rx_ao_b", "uart_cts_ao_b", "uart_rts_ao_b", +}; + +static const char * const i2c_ao_groups[] = { + "i2c_sdk_ao", "i2c_sda_ao", +}; + +static const char * const i2c_slave_ao_groups[] = { + "i2c_slave_sdk_ao", "i2c_slave_sda_ao", }; static struct meson_pmx_func meson_gxbb_periphs_functions[] = { @@ -375,7 +405,10 @@ static struct meson_pmx_func meson_gxbb_periphs_functions[] = { static struct meson_pmx_func meson_gxbb_aobus_functions[] = { FUNCTION(gpio_aobus), - FUNCTION(uart_ao), + FUNCTION(uart_ao_a), + FUNCTION(uart_ao_b), + FUNCTION(i2c_ao), + FUNCTION(i2c_slave_ao), }; static struct meson_bank meson_gxbb_periphs_banks[] = {