Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp560058ybk; Wed, 13 May 2020 07:14:12 -0700 (PDT) X-Google-Smtp-Source: APiQypJ+2E81B6aQrqW4spZjslu1FHyN3lNHd5XggutdoYRvKtHiT9CoA2JxmJsTc8SMM/wNGS+X X-Received: by 2002:a50:eacb:: with SMTP id u11mr21801669edp.162.1589379252436; Wed, 13 May 2020 07:14:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589379252; cv=none; d=google.com; s=arc-20160816; b=adM8W+6KJp9+Waz4MUaYvuXulx6BGHQh3HNU0OU8OxL7uMcjup5oyYOzs2GbvtalM8 zEclzQIFqIkAkhH/OgQq9FUCfnz4vfLzKeCccn+5CYAXB30UdDw8DgKmT8h+N90j3x1V eO6WiFTGf8iM3x2kxQOhQyIvYbNg6LYa8TbD1rD+JfrVOkEfqX4iNyBbpSXzq0yHKUKX voQU+YAARQ9eJVwJ1f/CagLSGCVYDyW/HJtaXoF2f+d+PK6kRDjFhC0tS1IYklOtgi0e aWeg/WTSPRJOrcWTZitWURJqEVqhuhsXOx1SEsGC4vu/8jU5I08viBTOD6yN95h8kphk eeHw== 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 :ironport-sdr:dkim-signature; bh=0bdJzXTQseyq5oq8gZSY3Qgb7ey19N/XO4NI1rSMrVA=; b=b/xonSimSj7LZ3TmwfKdJztCPY+CV3FSM+aFb3XzmCaBi5/rNSN30vnPEm8xwSHc/4 ilEtUKQwVA7xlBGYYOf04KwsHh64WyqVcLwvSZZCZHNoSC6KYtIeSZBGCDnuCEBay917 lcY2ZoJW64bRWO2eeBztS69w3txT1G2X2qNIbllZIYGptIlK2eSNhGzcbV8pDbDsS5tJ 6E2kmrXwGJP3eYUo+Z61NBmOG0xnKBIHkR2kfskRqFJwCB/rwmuWui5lJgrOPFOIo3vt K48L4qUlew/xEGU/letdmIjnlmGovkoDxro5excvd2e0tYYqWjBxGCHnFDp1SfOdvOIC i5qw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@microchip.com header.s=mchp header.b=GvvFdOv5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=microchip.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id c3si9524363eja.251.2020.05.13.07.13.48; Wed, 13 May 2020 07:14:12 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@microchip.com header.s=mchp header.b=GvvFdOv5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=microchip.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388851AbgEMOLx (ORCPT + 99 others); Wed, 13 May 2020 10:11:53 -0400 Received: from esa3.microchip.iphmx.com ([68.232.153.233]:38182 "EHLO esa3.microchip.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388793AbgEMOLu (ORCPT ); Wed, 13 May 2020 10:11:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1589379109; x=1620915109; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Dj/tqGjjDtj2A9PaqeSsjiB8UtDRZ0jP0v5pZdM7/yE=; b=GvvFdOv5hDTqp67Lz8INK4LbULY9nuhbZyPIe0mBJfw1DlRt3IsV8q3D 0fb77ocElGgMP5+BnxyleRYXmmTWnbodcIJzmnyM5c399+qEtWQmwfAiz y6aABiZjhd9AYEnxgIhRv/P+t6Rk2H2nDEmmRzQUJ7ZBNYuEG7C8mt4me Tw0NYhTJ957KC47PO94+89ggGz993dMu1PEERGHu6NAJEwMA5/yy17SHn CvwyPySaCGobqMkkBZQZApmUzvYnW/gyIMNOHNvo8VywetuD/2EMj3YMv /H2CoiPCCcfN0uemTRpo3RkRZtaH7cOpR7ghwo3vqBfsSE2MbxPZ0iH4C A==; IronPort-SDR: GCvGB2O5qzhphdVtjFPJUTIZwX2bvDRmVC5jMlmG08bTSDE/UpKDexka79h8f1+0xeh1otbyAS ghS/6GRQIEWmYOv/ttTRyTxh4LlbTxjfg/O1nb25iLprkvGj1M+29RjIJKU0wpTvahP2fcP798 n69qE+4Vxm1x/zXGZlttuXMmFPYDnsyz48p/qNSvlug9HzZzkh5o7OHIWdZ7gRVoaOG4S9Fm1i J+hXXCqMsuOaO/y72T+Wop97ARfagWMWYzDwbNqi8QHJN1Ln/Pfp8C39B+0TnD9/0dAEgy2VUP 5rQ= X-IronPort-AV: E=Sophos;i="5.73,388,1583218800"; d="scan'208";a="76510168" Received: from smtpout.microchip.com (HELO email.microchip.com) ([198.175.253.82]) by esa3.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 13 May 2020 07:11:49 -0700 Received: from chn-vm-ex04.mchp-main.com (10.10.85.152) by chn-vm-ex03.mchp-main.com (10.10.85.151) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.1713.5; Wed, 13 May 2020 07:11:48 -0700 Received: from soft-dev15.microsemi.net (10.10.115.15) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server id 15.1.1713.5 via Frontend Transport; Wed, 13 May 2020 07:11:46 -0700 From: Lars Povlsen To: SoC Team , Linus Walleij CC: Lars Povlsen , Microchip Linux Driver Support , , , , , Alexandre Belloni Subject: [PATCH 3/3] arm64: dts: sparx5: Add SGPIO devices Date: Wed, 13 May 2020 16:11:34 +0200 Message-ID: <20200513141134.25819-4-lars.povlsen@microchip.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20200513141134.25819-1-lars.povlsen@microchip.com> References: <20200513141134.25819-1-lars.povlsen@microchip.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This adds SGPIO devices for the Sparx5 SoC and configures it for the applicable reference boards. Reviewed-by: Alexandre Belloni Signed-off-by: Lars Povlsen --- arch/arm64/boot/dts/microchip/sparx5.dtsi | 52 +++++++++++++++++++ .../boot/dts/microchip/sparx5_pcb125.dts | 5 ++ .../dts/microchip/sparx5_pcb134_board.dtsi | 5 ++ 3 files changed, 62 insertions(+) diff --git a/arch/arm64/boot/dts/microchip/sparx5.dtsi b/arch/arm64/boot/dts/microchip/sparx5.dtsi index 60629861a5157..b4fda5616536c 100644 --- a/arch/arm64/boot/dts/microchip/sparx5.dtsi +++ b/arch/arm64/boot/dts/microchip/sparx5.dtsi @@ -213,6 +213,22 @@ si2_pins: si2-pins { function = "si2"; }; + sgpio0_pins: sgpio-pins { + pins = "GPIO_0", "GPIO_1", "GPIO_2", "GPIO_3"; + function = "sg0"; + }; + + sgpio1_pins: sgpio1-pins { + pins = "GPIO_4", "GPIO_5", "GPIO_12", "GPIO_13"; + function = "sg1"; + }; + + sgpio2_pins: sgpio2-pins { + pins = "GPIO_30", "GPIO_31", "GPIO_32", + "GPIO_33"; + function = "sg2"; + }; + uart_pins: uart-pins { pins = "GPIO_10", "GPIO_11"; function = "uart"; @@ -243,6 +259,42 @@ emmc_pins: emmc-pins { }; }; + sgpio0: gpio@61101036c { + compatible = "mscc,ocelot-sgpio"; + status = "disabled"; + clocks = <&sys_clk>; + pinctrl-0 = <&sgpio0_pins>; + pinctrl-names = "default"; + reg = <0x6 0x1101036c 0x100>; + gpio-controller; + #gpio-cells = <2>; + gpio-ranges = <&gpio 0 64 64>; + }; + + sgpio1: gpio@611010484 { + compatible = "mscc,ocelot-sgpio"; + status = "disabled"; + clocks = <&sys_clk>; + pinctrl-0 = <&sgpio1_pins>; + pinctrl-names = "default"; + reg = <0x6 0x11010484 0x100>; + gpio-controller; + #gpio-cells = <2>; + gpio-ranges = <&gpio 0 128 64>; + }; + + sgpio2: gpio@61101059c { + compatible = "mscc,ocelot-sgpio"; + status = "disabled"; + clocks = <&sys_clk>; + pinctrl-0 = <&sgpio2_pins>; + pinctrl-names = "default"; + reg = <0x6 0x1101059c 0x100>; + gpio-controller; + #gpio-cells = <2>; + gpio-ranges = <&gpio 0 192 64>; + }; + i2c0: i2c@600101000 { compatible = "snps,designware-i2c"; status = "disabled"; diff --git a/arch/arm64/boot/dts/microchip/sparx5_pcb125.dts b/arch/arm64/boot/dts/microchip/sparx5_pcb125.dts index 94c4c3fd5a786..fd4f5b3ddcc49 100644 --- a/arch/arm64/boot/dts/microchip/sparx5_pcb125.dts +++ b/arch/arm64/boot/dts/microchip/sparx5_pcb125.dts @@ -55,6 +55,11 @@ spi-flash@1 { }; }; +&sgpio0 { + status = "okay"; + microchip,sgpio-ports = <0x00FFFFFF>; +}; + &i2c1 { status = "okay"; }; diff --git a/arch/arm64/boot/dts/microchip/sparx5_pcb134_board.dtsi b/arch/arm64/boot/dts/microchip/sparx5_pcb134_board.dtsi index 628a05d3f57ce..2f781258f8c99 100644 --- a/arch/arm64/boot/dts/microchip/sparx5_pcb134_board.dtsi +++ b/arch/arm64/boot/dts/microchip/sparx5_pcb134_board.dtsi @@ -47,6 +47,11 @@ spi-flash@0 { }; }; +&sgpio0 { + status = "okay"; + microchip,sgpio-ports = <0x00FFFFFF>; +}; + &gpio { i2cmux_pins_i: i2cmux-pins-i { pins = "GPIO_16", "GPIO_17", "GPIO_18", "GPIO_19", -- 2.26.2