From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 44874C4338F for ; Thu, 29 Jul 2021 08:31:03 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0E22360F12 for ; Thu, 29 Jul 2021 08:31:03 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 0E22360F12 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=gTlzv2/iv8NWTTQXNd2D/5pHI8/6SbDE8mwQ3AKPLaU=; b=bKHaBKHuyYkb/y PQXm6qp68ZKS1RxpTg5tjKkhgLVM36ib62XO4ujZLCKZmI6b/Qob9Lpey64c7c2wSWUgTJkuI+f2D rcaBk6AN3mbSp1XXyxjfaQvwxecJkAe3Od24T7B3edAcfhAgX5f6TgejrzhLNW+zqmVLHxNOaDcot gTOEoT1Y+6idtlwB55WgZy8hDEBFCJNeva55fAIncn/LdqZCt1ahCWp3l6no62K0UbUIjsiYff6T5 wqrPfeZtvQqcVWy+GwcpqPOjiYCp/lLhCQv7pdnqFKc7X3m8P3qjfPs8M3InoDKMgInRaSU7Fh/vM Qc/Z9KPwirJwQ9ENAu2g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1m91Pg-003WLR-Hn; Thu, 29 Jul 2021 08:29:08 +0000 Received: from mail-lj1-x22a.google.com ([2a00:1450:4864:20::22a]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1m91Pc-003WKt-KO for linux-arm-kernel@lists.infradead.org; Thu, 29 Jul 2021 08:29:06 +0000 Received: by mail-lj1-x22a.google.com with SMTP id f12so6552318ljn.1 for ; Thu, 29 Jul 2021 01:29:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=8FzB0A0x5Vq+WtWLjbEX8D3/K3ZsLQL9ehnxxr5ESqU=; b=aGoVv0FMbc66zTGTgeFw6cMQLPCKRtbxLizgHXMr7OJp4hj8NIIxc2eAV38gGwHU8n nxaMDwWnGzdBEIe7wItsAIk1KtXZ9Y2CggsxVwboML2BwsKwMk12r/DN0jWP8/1xZU6t EDrpyjxH+Lc6vbjUQeKDrI2/Xa7ZOcAGnIe4IkC3EMAvtj/KsYzSFrQhOV+CmQS5zoha oJABVB1fledx45XlnciEyH1cTeMr0y/b36Lg+4veka7p2VuUBa8iRvY8OaXiTcGM3Szu aFcp/jpl9o0aU+RVaSTpod9r7YxOdIAnU5zKo/Qmi0LmUSMM+pLDPv1RYEtoNCRbYkVp DyWA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=8FzB0A0x5Vq+WtWLjbEX8D3/K3ZsLQL9ehnxxr5ESqU=; b=sEJopB1lrByu1JTlR6uEPWdZSqgkxegj2negFUqEADhHOQFWN3Hmr00tgMSkZdrchj 2uXqE/YnIBwboVlxmcvd/0CpUPuhxb9Nsyqs8dXCS4+ru3kUQj63vAu8sBtZjcHmU1Yq e5bMtQqUqQXXjlynqGpEeemnPFqJi7JGANYLyICz/w6hqhDJ1ybJE4gJg5kP3qWElJCK HlpZ5nHj9ZCAxlvCT7RsbTlCYF/i2m3RYX35+ICvzcoPE8h5iYK+HCSs0Q8iXNn443ds 1pPKC/5jP2f1PhbHw3SIsP7PPb4lMUNTXMvmr6VsIHyT8X4HY075c21b3KB0krNOotmU yuQg== X-Gm-Message-State: AOAM533IdcEUAOgr50NeO0pDuo3jn/SwXeZpcJsSTRyqmjp2kd4Odp2t IjYL0rP91gILrKhECxg8YRnUt33Jw3Tprw== X-Google-Smtp-Source: ABdhPJygvm1flpktbIh/dFhLRobLzn8NsD3IizEtPvNzXAbXxrjodn5N2TQvVgW9FSUzxRJLPDEL6w== X-Received: by 2002:a05:651c:b10:: with SMTP id b16mr2274823ljr.35.1627547342369; Thu, 29 Jul 2021 01:29:02 -0700 (PDT) Received: from localhost.localdomain (c-fdcc225c.014-348-6c756e10.bbcust.telenor.se. [92.34.204.253]) by smtp.gmail.com with ESMTPSA id i16sm235376lfg.139.2021.07.29.01.29.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Jul 2021 01:29:02 -0700 (PDT) From: Linus Walleij To: linux-arm-kernel@lists.infradead.org, Imre Kaloz , Krzysztof Halasa Cc: Linus Walleij , phj@phj.hu Subject: [PATCH] ARM: dts: ixp4xx: Add devicetree for Linksys WRV54G Date: Thu, 29 Jul 2021 10:26:58 +0200 Message-Id: <20210729082658.2815884-1-linus.walleij@linaro.org> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210729_012904_718187_C6A45F54 X-CRM114-Status: GOOD ( 20.61 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org This adds a device tree for the Linksys WRV54G also known as Gemtek GTWX5715. Some enhancements have been folded in from the OpenWrt patches. This supports everything in the upstream kernel with placeholders for the out-of-tree multiphy which exist in OpenWrt. Cc: phj@phj.hu Signed-off-by: Linus Walleij --- arch/arm/boot/dts/Makefile | 1 + .../boot/dts/intel-ixp42x-linksys-wrv54g.dts | 173 ++++++++++++++++++ 2 files changed, 174 insertions(+) create mode 100644 arch/arm/boot/dts/intel-ixp42x-linksys-wrv54g.dts diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile index ac8a4a77584d..c01a8f55892f 100644 --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile @@ -241,6 +241,7 @@ dtb-$(CONFIG_ARCH_INTEGRATOR) += \ integratorcp.dtb dtb-$(CONFIG_ARCH_IXP4XX) += \ intel-ixp42x-linksys-nslu2.dtb \ + intel-ixp42x-linksys-wrv54g.dtb \ intel-ixp42x-welltech-epbx100.dtb \ intel-ixp42x-ixdp425.dtb \ intel-ixp43x-kixrp435.dtb \ diff --git a/arch/arm/boot/dts/intel-ixp42x-linksys-wrv54g.dts b/arch/arm/boot/dts/intel-ixp42x-linksys-wrv54g.dts new file mode 100644 index 000000000000..6b28dda747fd --- /dev/null +++ b/arch/arm/boot/dts/intel-ixp42x-linksys-wrv54g.dts @@ -0,0 +1,173 @@ +// SPDX-License-Identifier: ISC +/* + * Device Tree file for the Linksys WRV54G router + * Also known as Gemtek GTWX5715 + * Based on a board file by George T. Joseph and other patches. + * This machine is based on IXP425. + */ + +/dts-v1/; + +#include "intel-ixp42x.dtsi" +#include + +/ { + model = "Linksys WRV54G / Gemtek GTWX5715"; + compatible = "linksys,wrv54g", "gemtek,gtwx5715", "intel,ixp42x"; + #address-cells = <1>; + #size-cells = <1>; + + memory@0 { + /* 32 MB memory */ + device_type = "memory"; + reg = <0x00000000 0x2000000>; + }; + + chosen { + bootargs = "console=ttyS0,115200n8"; + stdout-path = "uart1:115200n8"; + }; + + aliases { + /* UART2 is the primary console */ + serial0 = &uart1; + serial1 = &uart0; + }; + + /* There is an unpopulated LED slot (3) connected to GPIO 8 */ + leds { + compatible = "gpio-leds"; + led-power { + label = "wrv54g:yellow:power"; + gpios = <&gpio0 2 GPIO_ACTIVE_LOW>; + default-state = "on"; + linux,default-trigger = "heartbeat"; + }; + led-wireless { + label = "wrv54g:yellow:wireless"; + gpios = <&gpio0 9 GPIO_ACTIVE_LOW>; + default-state = "on"; + }; + led-internet { + label = "wrv54g:yellow:internet"; + gpios = <&gpio0 1 GPIO_ACTIVE_LOW>; + default-state = "on"; + }; + led-dmz { + label = "wrv54g:green:dmz"; + gpios = <&gpio0 4 GPIO_ACTIVE_LOW>; + default-state = "on"; + }; + }; + + /* This set-up comes from an OpenWrt patch */ + spi { + compatible = "spi-gpio"; + #address-cells = <1>; + #size-cells = <0>; + + sck-gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>; + miso-gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>; + mosi-gpios = <&gpio0 6 GPIO_ACTIVE_HIGH>; + cs-gpios = <&gpio0 5 GPIO_ACTIVE_LOW>; + num-chipselects = <1>; + + switch@0 { + compatible = "micrel,ks8995"; + reg = <0>; + spi-max-frequency = <50000000>; + }; + }; + + soc { + bus@c4000000 { + flash@0,0 { + compatible = "intel,ixp4xx-flash", "cfi-flash"; + bank-width = <2>; + /* Enable writes on the expansion bus */ + intel,ixp4xx-eb-write-enable = <1>; + /* 8 MB of Flash mapped in at CS0 */ + reg = <0 0x00000000 0x00800000>; + + partitions { + compatible = "fixed-partitions"; + /* + * Partition info from a boot log + * CHECKME: not using redboot? FIS index 0x3f @7e00000? + */ + #address-cells = <1>; + #size-cells = <1>; + partition@0 { + label = "boot"; + reg = <0x0 0x140000>; + read-only; + }; + partition@140000 { + label = "linux"; + reg = <0x140000 0x100000>; + read-only; + }; + partition@240000 { + label = "root"; + reg = <0x240000 0x480000>; + read-write; + }; + }; + }; + }; + + pci@c0000000 { + status = "ok"; + + /* + * We have up to 2 slots (IDSEL) with 2 swizzled IRQs. + * Derived from the GTWX5715 PCI boardfile. + */ + interrupt-map = + /* IDSEL 0 */ + <0x0000 0 0 1 &gpio0 10 IRQ_TYPE_LEVEL_LOW>, /* INT A on slot 0 is irq 10 */ + <0x0000 0 0 2 &gpio0 11 IRQ_TYPE_LEVEL_LOW>, /* INT B on slot 0 is irq 11 */ + /* IDSEL 1 */ + <0x0800 0 0 1 &gpio0 11 IRQ_TYPE_LEVEL_LOW>, /* INT A on slot 1 is irq 11 */ + <0x0800 0 0 2 &gpio0 10 IRQ_TYPE_LEVEL_LOW>; /* INT B on slot 1 is irq 10 */ + }; + + /* + * EthB - connected to the KS8995 switch ports 1-4 + * FIXME: the boardfile defines .phy_mask = 0x1e for this port to enable output to + * all four switch ports, also using an out of tree multiphy patch. + * Do we need a new binding and property for this? + */ + ethernet@c8009000 { + status = "ok"; + queue-rx = <&qmgr 3>; + queue-txready = <&qmgr 20>; + phy-mode = "rgmii"; + phy-handle = <&phy4>; + + mdio { + #address-cells = <1>; + #size-cells = <0>; + + /* Should be ports 1-4 on the KS8995 switch */ + phy4: ethernet-phy@4 { + reg = <4>; + }; + + /* Should be port 5 on the KS8995 switch */ + phy5: ethernet-phy@5 { + reg = <5>; + }; + }; + }; + + /* EthC - connected to KS8995 switch port 5 */ + ethernet@c800a000 { + status = "ok"; + queue-rx = <&qmgr 4>; + queue-txready = <&qmgr 21>; + phy-mode = "rgmii"; + phy-handle = <&phy5>; + }; + }; +}; -- 2.31.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel