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=-14.6 required=3.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, NICE_REPLY_A,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 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 EF4FBC43461 for ; Thu, 10 Sep 2020 20:39:31 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (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 9D0BD20829 for ; Thu, 10 Sep 2020 20:39:31 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="Rf9RUx8Q"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="VlCxTsGJ" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9D0BD20829 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=merlin.20170209; h=Sender:Content-Type: Content-Transfer-Encoding:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=q6COoFtuZLvrNyPMcz2PSRnVWaboNKYP9jMUe9diOOI=; b=Rf9RUx8Qnyr1r2XT3pGIgbsng eF4ismNlu/CK5YnKgKC82y9p+CdePHa2R4P1Wks3RV0HY7nOZz/6frQTZ3uN/WZHrKpVus0hPjBmI 2eUBWezg0XqbpTPmkamimtlG86oNaXlsdet78P8+n4/OZiYeo7RC/nyWAP7moqDZqF9dEAiKXzWs5 Na5Ik4dVomgnIRSyo0XjQ/2/kpoUXQaZ31n2hE3dwnQ4llkNVMdtj5/Ihcvo8LpfQ/1cQwsxt3t+h PfVO6lp1Ehq5bK8PRitxByxE3f2nOyE1xxy2SllO5mD6GnWVJgDEmpCBOEysKK7pz7WcCtowQSBgx hbImK3B2Q==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kGTKa-0004eD-0o; Thu, 10 Sep 2020 20:38:08 +0000 Received: from mail-pf1-x444.google.com ([2607:f8b0:4864:20::444]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kGTKX-0004dl-99 for linux-arm-kernel@lists.infradead.org; Thu, 10 Sep 2020 20:38:06 +0000 Received: by mail-pf1-x444.google.com with SMTP id c196so5558064pfc.0 for ; Thu, 10 Sep 2020 13:38:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=7rdh8t59KzOzqEhldLslB+LmEEqBOj7wTtl1z/AiJ3w=; b=VlCxTsGJa/7qeAVqdtS0+p24y3vfKqWPxZrZPfZAgsemfV1B1zgosm/iJcriryNxtx 6plsQKjJEE7y/q2L5O8bALEYvqTmen593IeNAToOJSzOPfX4fzwZC84HaC+NSqSHhFtN KuaqnAgSdouH8I+ThuxYpqKJlPKvofUNRUXPijAZl6rCOxQsZXBUJlpw73rutrj78tJK ch44leto9d4GYhUbsytACMSvU2tQhpcMvP2WoswcPeRWgmMIPhCWA/VjWL0U8idXjKNs Jj7yLXnRF/mVyAepYAwIfFJp08u+iextTCbCg4whEt0pPyK+RtsHh+iOeapyHOxSb4Xi NobA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=7rdh8t59KzOzqEhldLslB+LmEEqBOj7wTtl1z/AiJ3w=; b=rGC0cuF7/dmxSIWt4+lzzWXFEWfwmX/JUNSXCMp/i8hIAr4fGwm0Xg3EgtU8ZfsHvS gttP1EdKXxcIsPIL7omZL31teuqFHqhrg4qBRTKvV0ePRcRPA4N3HS04gOJzv45AWRmv K2TgYl729QRXP1xz/N14J+Z3iavoludPMk1ffdHZERNF36t9fW5Pw7LvK6H1wHNSJj1z LNJyPUSt5uH4DPAxqNQS4IQYMsWJXHn2VcmQ4sxIQlg7JYWzGs3hpyUEiVznsbZrrvB+ YiW29bmD1VyufA35e8kKw/02Voj+1DsDP41FWfRZyTUcanlEl/nwi6YrglJGNu1Ot1FM xz8Q== X-Gm-Message-State: AOAM530N8UGrdBCblqrm0utTdqafSo1gZhbny5czqSWyfviuZ36+8l5M Pop+3onheXKDXUiS08fakB4= X-Google-Smtp-Source: ABdhPJy28cgGIlZs/O9BaIELsAaXC4CYCm1hRrUs+wyCGs9H4UrEQqAbFwXsSlg4fc+d39APoLoCZg== X-Received: by 2002:a63:4548:: with SMTP id u8mr6019558pgk.76.1599770283189; Thu, 10 Sep 2020 13:38:03 -0700 (PDT) Received: from [10.230.30.107] ([192.19.223.252]) by smtp.gmail.com with ESMTPSA id k5sm6873938pfp.214.2020.09.10.13.38.01 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 10 Sep 2020 13:38:02 -0700 (PDT) Subject: Re: [PATCH v2 6/6] ARM: BCM5301X: Add DT for Meraki MR32 To: Christian Lamparter , linux-arm-kernel@lists.infradead.org References: From: Florian Fainelli Message-ID: Date: Thu, 10 Sep 2020 13:38:00 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Firefox/78.0 Thunderbird/78.2.1 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200910_163805_333139_B3A65C7B X-CRM114-Status: GOOD ( 32.12 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Florian Fainelli , Scott Branden , Hauke Mehrtens , =?UTF-8?B?UmFmYcWCIE1pxYJlY2tp?= , Chris Blake , Rob Herring , Ray Jui , bcm-kernel-feedback-list@broadcom.com Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 8/22/2020 9:19 AM, Christian Lamparter wrote: > add support for the Cisco Meraki MR32. > This is a dual-band enterprise class 802.11ac access point. > The unit was donated by Chris Blake. Thank you! > > SoC: Broadcom BCM53016A1 (1 GHz, 2 cores) > RAM: 128 MiB > NAND: 128 MiB Spansion S34ML01G2 (~114 MiB useable) > ETH: 1GBit Ethernet Port - PoE > WIFI1: Broadcom BCM43520 an+ac (2x2:2 - id: 0x4352) > WIFI2: Broadcom BCM43520 bgn (2x2:2 - id: 0x4352) > WIFI3: Broadcom BCM43428 abgn (1x1:1 - id: 43428) > > BLE: Broadcom BCM20732 (ttyS1) > LEDS: 1 x Programmable RGB Status LED (driven by a PWM) > 1 x White LED (GPIO) > 1 x Orange LED Fault Indicator (GPIO) > 2 x LAN Activity / Speed LEDs (On the RJ45 Port) > BUTTON: one Reset button > MISC: AT24C64 8KiB EEPROM (i2c - stores Ethernet MAC) > ina219 hardware monitor (i2c) > Kensington Lock > > SERIAL: > WARNING: The serial port needs a TTL/RS-232 3V3 level converter! > The Serial setting is 115200-8-N-1. The board has a populated > right angle 1x4 0.1" pinheader. > The pinout is: VCC, RX, TX, GND. > > Odd stuff: > - uart0 clock frequency is 62.5 MHz. > - The LEDs are labeled as SYS-LED1 through SYS-LED3 > because of the silkscreen on the PCB. > - the original u-boot has been compiled with most functions > and commands disabled. The u-boot env isn't setup properly > either and as a result, the bcm47xxpart probing is not > working. Hence, the nand partitions are specified through a > "fixed-partition" binding. > - The "WICED SMART(TM)" Bluetooth LE 4.0 BCM20732 chip is > connected to uart2 of the SoC. The BCM20732 does not > provide a HCI. So the linux' bluetooth stack is useless. > The mock-up node with the compatible binding and > enable-gpios property is provided solely as documentation. > > Signed-off-by: Christian Lamparter > > --- > > v1 -> v2: > - fixed order of boards in Makefile. (Scott Branden) > - added device_type to memory node. (Florian Fainelli) > - added hw i2c, although doesn't work. (Florian Fainelli) > - renamed gpio-keys to just keys. > - included pinmux configurations for i2c and pwm. > --- > arch/arm/boot/dts/Makefile | 1 + > arch/arm/boot/dts/bcm53016-meraki-mr32.dts | 219 +++++++++++++++++++++ > 2 files changed, 220 insertions(+) > create mode 100644 arch/arm/boot/dts/bcm53016-meraki-mr32.dts > > diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile > index 4572db3fa5ae..d254ca2a942d 100644 > --- a/arch/arm/boot/dts/Makefile > +++ b/arch/arm/boot/dts/Makefile > @@ -127,6 +127,7 @@ dtb-$(CONFIG_ARCH_BCM_5301X) += \ > bcm47094-luxul-xwr-3150-v1.dtb \ > bcm47094-netgear-r8500.dtb \ > bcm47094-phicomm-k3.dtb \ > + bcm53016-meraki-mr32.dtb \ > bcm94708.dtb \ > bcm94709.dtb \ > bcm953012er.dtb \ > diff --git a/arch/arm/boot/dts/bcm53016-meraki-mr32.dts b/arch/arm/boot/dts/bcm53016-meraki-mr32.dts > new file mode 100644 > index 000000000000..7306df7ff704 > --- /dev/null > +++ b/arch/arm/boot/dts/bcm53016-meraki-mr32.dts > @@ -0,0 +1,219 @@ > +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT > +/* > + * Broadcom BCM470X / BCM5301X ARM platform code. > + * DTS for Meraki MR32 / Codename: Espresso > + * > + * Copyright (C) 2018-2020 Christian Lamparter > + */ > + > +/dts-v1/; > + > +#include "bcm4708.dtsi" > +#include "bcm5301x-nand-cs0-bch8.dtsi" > +#include > + > +/ { > + compatible = "meraki,mr32", "brcm,brcm53016", "brcm,bcm4708"; > + model = "Meraki MR32"; > + > + chosen { > + bootargs = " console=ttyS0,115200n8 earlycon"; > + }; > + > + memory { > + reg = <0x00000000 0x08000000>; > + device_type = "memory"; > + }; > + > + aliases { > + serial1 = &uart2; > + }; > + > + leds { > + compatible = "gpio-leds"; > + > + sysled3 { > + function = LED_FUNCTION_FAULT; > + color = ; > + gpios = <&chipcommon 18 GPIO_ACTIVE_LOW>; > + panic-indicator; > + }; > + sysled2 { > + function = LED_FUNCTION_INDICATOR; > + color = ; > + gpios = <&chipcommon 19 GPIO_ACTIVE_HIGH>; > + }; > + }; > + > + keys { > + compatible = "gpio-keys"; > + #address-cells = <1>; > + #size-cells = <0>; > + > + restart { > + label = "Reset"; > + linux,code = ; > + gpios = <&chipcommon 21 GPIO_ACTIVE_LOW>; > + }; > + }; > + > + pwm-leds { > + compatible = "pwm-leds"; > + > + red { > + /* SYS-LED 1 - Tricolor */ > + function = LED_FUNCTION_INDICATOR; > + color = ; > + pwms = <&pwm 0 50000 0>; > + max-brightness = <255>; > + }; > + > + green { > + /* SYS-LED 1 - Tricolor */ > + function = LED_FUNCTION_POWER; > + color = ; > + pwms = <&pwm 1 50000 0>; > + max-brightness = <255>; > + }; > + > + blue { > + /* SYS-LED 1 - Tricolor */ > + function = LED_FUNCTION_INDICATOR; > + color = ; > + pwms = <&pwm 2 50000 0>; > + max-brightness = <255>; > + }; > + }; > + > + i2c { > + /* > + * The platform provided I2C does not budge. > + * This is a replacement until I can figure > + * out what are the missing bits... > + */ > + > + compatible = "i2c-gpio"; > + sda-gpios = <&chipcommon 5 GPIO_ACTIVE_HIGH>; > + scl-gpios = <&chipcommon 4 GPIO_ACTIVE_HIGH>; > + i2c-gpio,delay-us = <10>; /* close to 100 kHz */ > + #address-cells = <1>; > + #size-cells = <0>; > + > + current_sense: ina219@45 { > + compatible = "ti,ina219"; > + reg = <0x45>; > + shunt-resistor = <60000>; /* = 60 mOhms */ > + }; > + > + eeprom: eeprom@50 { > + compatible = "atmel,24c64"; > + reg = <0x50>; > + pagesize = <32>; > + read-only; > + }; > + }; > +}; > + > +&i2c0 { > + /* status = "okay"; - can be enabled once it works. */ > + > + pinctrl-names = "default"; > + pinctrl-0 = <&pinmux_i2c>; > + > + clock-frequency = <100000>; > + > + current_sense: ina219@45 { > + compatible = "ti,ina219"; > + reg = <0x45>; > + shunt-resistor = <60000>; /* = 60 mOhms */ > + }; > + > + eeprom: eeprom@50 { > + compatible = "atmel,24c64"; > + reg = <0x50>; > + pagesize = <32>; > + read-only; > + }; These would create duplicate labels which are hard errors per DTC, so I took out the entire &i2c0 override here into what I merged into devicetree/next. This cannot have built for you unless you run dtc with the force flag, is that how OpenWrt does it? -- Florian _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel