From patchwork Mon Mar 13 21:05:09 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alban Bedel X-Patchwork-Id: 9622127 X-Patchwork-Delegate: kvalo@adurom.com Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id CB4E4604CC for ; Mon, 13 Mar 2017 21:06:36 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BAF5B209CD for ; Mon, 13 Mar 2017 21:06:36 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id AF91A284F6; Mon, 13 Mar 2017 21:06:36 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5D505209CD for ; Mon, 13 Mar 2017 21:06:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753547AbdCMVF5 (ORCPT ); Mon, 13 Mar 2017 17:05:57 -0400 Received: from smtp5-g21.free.fr ([212.27.42.5]:62426 "EHLO smtp5-g21.free.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751374AbdCMVFx (ORCPT ); Mon, 13 Mar 2017 17:05:53 -0400 Received: from localhost.localdomain (unknown [78.54.115.31]) (Authenticated sender: albeu) by smtp5-g21.free.fr (Postfix) with ESMTPA id 4ADD85FF9E; Mon, 13 Mar 2017 22:05:31 +0100 (CET) From: Alban To: QCA ath9k Development Cc: John Crispin , Alban , Kalle Valo , Rob Herring , Mark Rutland , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/7] Documentation: dt: net: Update the ath9k binding for SoC devices Date: Mon, 13 Mar 2017 22:05:09 +0100 Message-Id: <1489439116-4233-1-git-send-email-albeu@free.fr> X-Mailer: git-send-email 2.7.4 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The current binding only cover PCI devices so extend it for SoC devices. Most SoC platforms use an MTD partition for the calibration data instead of an EEPROM. The qca,no-eeprom property was added to allow loading the EEPROM content using firmware loading. This new binding replace this hack with NVMEM cells, so we also mark the qca,no-eeprom property as deprecated in case anyone ever used it. Signed-off-by: Alban Acked-by: Rob Herring --- .../devicetree/bindings/net/wireless/qca,ath9k.txt | 41 ++++++++++++++++++++-- 1 file changed, 38 insertions(+), 3 deletions(-) diff --git a/Documentation/devicetree/bindings/net/wireless/qca,ath9k.txt b/Documentation/devicetree/bindings/net/wireless/qca,ath9k.txt index b7396c8..61f5f6d 100644 --- a/Documentation/devicetree/bindings/net/wireless/qca,ath9k.txt +++ b/Documentation/devicetree/bindings/net/wireless/qca,ath9k.txt @@ -27,16 +27,34 @@ Required properties: - 0034 for AR9462 - 0036 for AR9565 - 0037 for AR9485 + For SoC devices the compatible should be "qca,-wmac" + and one of the following fallbacks: + - "qca,ar9100-wmac" + - "qca,ar9330-wmac" + - "qca,ar9340-wmac" + - "qca,qca9550-wmac" + - "qca,qca9530-wmac" - reg: Address and length of the register set for the device. +Required properties for SoC devices: +- interrupt-parent: phandle of the parent interrupt controller. +- interrupts: Interrupt specifier for the controllers interrupt. + Optional properties: +- mac-address: See ethernet.txt in the parent directory +- local-mac-address: See ethernet.txt in the parent directory +- clock-names: has to be "ref" +- clocks: phandle of the reference clock +- resets: phandle of the reset line +- nvmem-cell-names: has to be "eeprom" and/or "address" +- nvmem-cells: phandle to the eeprom nvmem cell and/or to the mac address + nvmem cell. + +Deprecated properties: - qca,no-eeprom: Indicates that there is no physical EEPROM connected to the ath9k wireless chip (in this case the calibration / EEPROM data will be loaded from userspace using the kernel firmware loader). -- mac-address: See ethernet.txt in the parent directory -- local-mac-address: See ethernet.txt in the parent directory - In this example, the node is defined as child node of the PCI controller: &pci0 { @@ -46,3 +64,20 @@ In this example, the node is defined as child node of the PCI controller: qca,no-eeprom; }; }; + +In this example it is defined as a SoC device: + wmac@180c0000 { + compatible = "qca,ar9132-wmac", "qca,ar9100-wmac"; + reg = <0x180c0000 0x30000>; + + interrupt-parent = <&cpuintc>; + interrupts = <2>; + + clock-names = "ref"; + clocks = <&extosc>; + + nvmem-cell-names = "eeprom", "address"; + nvmem-cells = <&wmac_eeprom>, <&wmac_address>; + + resets = <&rst 22>; + };