From patchwork Mon Mar 8 13:18:50 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 12122253 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=-13.7 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,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 6BD59C433DB for ; Mon, 8 Mar 2021 13:20:44 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (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 0EB006519D for ; Mon, 8 Mar 2021 13:20:44 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 0EB006519D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: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:List-Owner; bh=IfioCRGR07Q8efqovO2UpqiTzCdly3o5c7YU4QPeung=; b=Tz7Ak7pyFxCQDdu67hpYkDn7S bJGrPHmREkqubiIvwgDJfj31ZH98KrKfHAstH+hEg1s85qnGiZOhz0Ir4O5UASan9cagyEZjReyVe txaSvLo03h0kJCsLrHtYoG0u0CrAM8GlDKG3oYDwPt9fE8Q5amD0ooSllKzNBrRQzJptSFhkkjTmK SFvaM5qo6SpMuATcWT/m9dY4SRtttIKTZ6xbBO9/bRX/0nMtav1idLjt4Yofbc/vd2AhxIuerXI/f UHVUI/8vQ1SRlH36z4izVhI43lQqsZZc9BwDEYxf9pO8yKhnG8a2ic4PKca2wQMksoCKBOPpRTr3a OPlqm4Z5g==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lJFmy-00HOtS-Qq; Mon, 08 Mar 2021 13:19:12 +0000 Received: from mail-lf1-x130.google.com ([2a00:1450:4864:20::130]) by desiato.infradead.org with esmtps (Exim 4.94 #2 (Red Hat Linux)) id 1lJFmp-00HOqx-Nm for linux-arm-kernel@lists.infradead.org; Mon, 08 Mar 2021 13:19:05 +0000 Received: by mail-lf1-x130.google.com with SMTP id m22so20918082lfg.5 for ; Mon, 08 Mar 2021 05:19:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=W7hRSuYz0egD1pYEQHcu7GvDadtcTgO0G3hqzJ5RxFQ=; b=pkkxcUP/7lkkiK4y+fqzUmmRMy/TZDQrWk74dUeaUDwop1WdWiS0f0EpFm3cHwURGc 6xBv/onPlKPvTgJ2VmHoNlWL6ehFktvI8AUIL8JONJAynjaAIf2tEdSO0dA9e4kVLbYY 5YZcXIEe25Csfx33/ssGGKm/RZbwI3MKbtzAVzmG2rl4u0XHPlKmVBPiNiJe76xxLysS 5aWe5Dk6eueImK5SGcdl+CbbpU2lYZ2eWEh41Z4lgns+wI6xrFyAgS8JR4L7duLzo8B2 LGVpeDQi/eHxCG72PJi9cNwaYdNJO2b4T396jr4cZ+lIehwkwPGnMBPWNkpVLM7cuApq lbrQ== 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=W7hRSuYz0egD1pYEQHcu7GvDadtcTgO0G3hqzJ5RxFQ=; b=mXJLusAcOilHsJGYxQA6EKp2koEeoPuSowsZLXZCimb1cvyCLmSV5fGzjhecW7TrzB 82JTmxLon9Om1yzrFuPhA62K9TLp4i4JR8HoJO4xZnK1Xy4lRwvXOfevp6UjJr5HWQmM bFwwhKtiRCd2zK7Z7Sy2lqZMVFh1XLCr7w0tdblmuhFTGd6sRWeRwggBolEzU5AgZZEh jDUsMGYJgEFinK5C6yqmJd9XztEnn8vuSfa2UMXIz7Kb99f+dR9qqrCnpi8/OExLwgnZ b8f3UcqvZC4hOzcgFWtetDwqxjQThUUcH3m7h4cZx6gZRmcA4HqTakS43iin9M6nHuw1 YX0g== X-Gm-Message-State: AOAM5335t8vOjlextYfdS/6okDvCguWn8DLz0tbIITAyYROXgxY9t/Hz qEbt36pVROfEAesJzayyPqmYfz2dlA8= X-Google-Smtp-Source: ABdhPJzDufj9Dq1l2IX1rSnziXnCKJSZ8LjkJQlFOek57vsGGm8cJoRN5juRcFLJuXbBFG7twh/euA== X-Received: by 2002:a05:6512:12c1:: with SMTP id p1mr15243339lfg.374.1615209542930; Mon, 08 Mar 2021 05:19:02 -0800 (PST) Received: from localhost.lan (ip-194-187-74-233.konfederacka.maverick.com.pl. [194.187.74.233]) by smtp.gmail.com with ESMTPSA id z81sm1354735lfc.149.2021.03.08.05.19.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 08 Mar 2021 05:19:02 -0800 (PST) From: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= To: Florian Fainelli , Rob Herring Cc: linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, bcm-kernel-feedback-list@broadcom.com, =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH V2 2/2] arm64: dts: broadcom: bcm4908: add TP-Link Archer C2300 V1 Date: Mon, 8 Mar 2021 14:18:50 +0100 Message-Id: <20210308131850.22576-2-zajec5@gmail.com> X-Mailer: git-send-email 2.26.2 In-Reply-To: <20210308131850.22576-1-zajec5@gmail.com> References: <20210305125907.21943-1-zajec5@gmail.com> <20210308131850.22576-1-zajec5@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210308_131904_044235_7A11C50C X-CRM114-Status: GOOD ( 16.04 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Rafał Miłecki Archer C2300 V1 is a home router based on the BCM4906 (2 CPU cores). It has 512 MiB of RAM, NAND flash, USB 2.0 and USB 3.0 ports, 4 LAN ports, 1 WAN port. Signed-off-by: Rafał Miłecki --- V2: Fix nodes names for power and USB LEDs. V1 got debugging names. --- arch/arm64/boot/dts/broadcom/bcm4908/Makefile | 1 + .../bcm4906-tplink-archer-c2300-v1.dts | 182 ++++++++++++++++++ 2 files changed, 183 insertions(+) create mode 100644 arch/arm64/boot/dts/broadcom/bcm4908/bcm4906-tplink-archer-c2300-v1.dts diff --git a/arch/arm64/boot/dts/broadcom/bcm4908/Makefile b/arch/arm64/boot/dts/broadcom/bcm4908/Makefile index ebebc0cd421f..cc75854519ac 100644 --- a/arch/arm64/boot/dts/broadcom/bcm4908/Makefile +++ b/arch/arm64/boot/dts/broadcom/bcm4908/Makefile @@ -1,3 +1,4 @@ # SPDX-License-Identifier: GPL-2.0 dtb-$(CONFIG_ARCH_BCM4908) += bcm4906-netgear-r8000p.dtb +dtb-$(CONFIG_ARCH_BCM4908) += bcm4906-tplink-archer-c2300-v1.dtb dtb-$(CONFIG_ARCH_BCM4908) += bcm4908-asus-gt-ac5300.dtb diff --git a/arch/arm64/boot/dts/broadcom/bcm4908/bcm4906-tplink-archer-c2300-v1.dts b/arch/arm64/boot/dts/broadcom/bcm4908/bcm4906-tplink-archer-c2300-v1.dts new file mode 100644 index 000000000000..7bb75359aef8 --- /dev/null +++ b/arch/arm64/boot/dts/broadcom/bcm4908/bcm4906-tplink-archer-c2300-v1.dts @@ -0,0 +1,182 @@ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT + +#include +#include +#include + +#include "bcm4906.dtsi" + +/ { + compatible = "tplink,archer-c2300-v1", "brcm,bcm4906", "brcm,bcm4908"; + model = "TP-Link Archer C2300 V1"; + + memory@0 { + device_type = "memory"; + reg = <0x00 0x00 0x00 0x20000000>; + }; + + leds { + compatible = "gpio-leds"; + + power { + function = LED_FUNCTION_POWER; + color = ; + gpios = <&gpio0 0 GPIO_ACTIVE_LOW>; + }; + + 2ghz { + function = "2ghz"; + color = ; + gpios = <&gpio0 2 GPIO_ACTIVE_LOW>; + }; + + 5ghz { + function = "5ghz"; + color = ; + gpios = <&gpio0 3 GPIO_ACTIVE_LOW>; + }; + + wan-amber { + function = LED_FUNCTION_WAN; + color = ; + gpios = <&gpio0 4 GPIO_ACTIVE_HIGH>; + }; + + wan-blue { + function = LED_FUNCTION_WAN; + color = ; + gpios = <&gpio0 10 GPIO_ACTIVE_LOW>; + }; + + lan { + function = LED_FUNCTION_LAN; + color = ; + gpios = <&gpio0 12 GPIO_ACTIVE_LOW>; + }; + + wps { + function = LED_FUNCTION_WPS; + color = ; + gpios = <&gpio0 14 GPIO_ACTIVE_LOW>; + }; + + usb2 { + function = "usb2"; + color = ; + gpios = <&gpio0 15 GPIO_ACTIVE_LOW>; + }; + + usb3 { + function = "usbd3"; + color = ; + gpios = <&gpio0 17 GPIO_ACTIVE_LOW>; + }; + + brightness { + function = LED_FUNCTION_BACKLIGHT; + color = ; + gpios = <&gpio0 19 GPIO_ACTIVE_LOW>; + }; + }; + + gpio-keys-polled { + compatible = "gpio-keys-polled"; + poll-interval = <100>; + + brightness { + label = "LEDs"; + linux,code = ; + gpios = <&gpio0 18 GPIO_ACTIVE_LOW>; + }; + + wps { + label = "WPS"; + linux,code = ; + gpios = <&gpio0 21 GPIO_ACTIVE_LOW>; + }; + + wifi { + label = "WiFi"; + linux,code = ; + gpios = <&gpio0 22 GPIO_ACTIVE_LOW>; + }; + + restart { + label = "Reset"; + linux,code = ; + gpios = <&gpio0 23 GPIO_ACTIVE_LOW>; + }; + }; +}; + +&usb_phy { + brcm,ioc = <1>; + status = "okay"; +}; + +&ehci { + status = "okay"; +}; + +&ohci { + status = "okay"; +}; + +&xhci { + status = "okay"; +}; + +&ports { + port@0 { + label = "lan4"; + }; + + port@1 { + label = "lan3"; + }; + + port@2 { + label = "lan2"; + }; + + port@3 { + label = "lan1"; + }; + + port@7 { + reg = <7>; + phy-mode = "internal"; + phy-handle = <&phy12>; + label = "wan"; + }; +}; + +&nandcs { + nand-ecc-strength = <4>; + nand-ecc-step-size = <512>; + nand-on-flash-bbt; + + #address-cells = <1>; + #size-cells = <0>; + + partitions { + compatible = "brcm,bcm4908-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + partition@0 { + label = "cferom"; + reg = <0x0 0x100000>; + }; + + partition@100000 { + compatible = "brcm,bcm4908-firmware"; + reg = <0x100000 0x3900000>; + }; + + partition@5800000 { + compatible = "brcm,bcm4908-firmware"; + reg = <0x3a00000 0x3900000>; + }; + }; +};