From patchwork Tue Feb 11 21:41:20 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H. Nikolaus Schaller" X-Patchwork-Id: 204919 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=-9.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 15AB0C35242 for ; Tue, 11 Feb 2020 21:43:45 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E06EE206D7 for ; Tue, 11 Feb 2020 21:43:44 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=goldelico.com header.i=@goldelico.com header.b="T7u/i1e3" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728026AbgBKVly (ORCPT ); Tue, 11 Feb 2020 16:41:54 -0500 Received: from mo4-p03-ob.smtp.rzone.de ([85.215.255.104]:10098 "EHLO mo4-p03-ob.smtp.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728005AbgBKVly (ORCPT ); Tue, 11 Feb 2020 16:41:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1581457309; s=strato-dkim-0002; d=goldelico.com; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=v3anE5b2foHTOj2GJ8iyGcibKBz905Yhze/9YVRQ/TQ=; b=T7u/i1e3RmfgbspBSEr7DxIzL7WVAgF3PK3cr45pNCDLR/23YnmLoZ9ROXwnwLeju2 m9vsIr9VrBkUUA8pD7pWA0LIY4/vBX4TAV4c15hhdK09QY0rAPJxnjBAwDyMdC8O1HIk g2JNinDEhm5nO1/klr8qxKr74GoSdUy1KcIA8OeHMFPm5PODfOGzSgQ9KcCVMRrkQEZl iRW/W67nTFUIzqVrirgz758Pefbi/+K0oBwtZSDJKZ/YBgEbPaUuIenUg5nukXC/6eAQ S+JgLDJqu/cQNK2ZtmD+r9GFQqgOIZ9u8cMhs1ASfOjZeyFYh1bFZVp+W5YIFhcMm2vQ xyDg== X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMhflhwDubTJ9o1OAA2UNf2M0P2mp10IM" X-RZG-CLASS-ID: mo00 Received: from iMac.fritz.box by smtp.strato.de (RZmta 46.1.12 DYNA|AUTH) with ESMTPSA id U06217w1BLfZ0EJ (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Tue, 11 Feb 2020 22:41:35 +0100 (CET) From: "H. Nikolaus Schaller" To: Paul Cercueil , Paul Boddie , Alex Smith , Rob Herring , Mark Rutland , Ralf Baechle , Paul Burton , James Hogan , David Airlie , Daniel Vetter , "David S. Miller" , Linus Walleij , "H. Nikolaus Schaller" , Andi Kleen , Krzysztof Kozlowski , Geert Uytterhoeven , Miquel Raynal , =?utf-8?q?Petr_=C5=A0tetiar?= , Richard Fontana , Allison Randal , Stephen Boyd Cc: devicetree@vger.kernel.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-i2c@vger.kernel.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, letux-kernel@openphoenux.org, kernel@pyra-handheld.com Subject: [PATCH 03/14] net: davicom: dm9000: allow to pass MAC address through mac_addr module parameter Date: Tue, 11 Feb 2020 22:41:20 +0100 Message-Id: <4e11dd4183da55012198824ca7b8933b1eb57e4a.1581457290.git.hns@goldelico.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: References: MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org This is needed to give the MIPS Ingenic CI20 board a stable MAC address which can be optionally provided by vendor U-Boot. For get_mac_addr() we use an adapted copy of from ksz884x.c which has very similar functionality. Signed-off-by: H. Nikolaus Schaller --- drivers/net/ethernet/davicom/dm9000.c | 42 +++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/drivers/net/ethernet/davicom/dm9000.c b/drivers/net/ethernet/davicom/dm9000.c index 1ea3372775e6..7402030b0352 100644 --- a/drivers/net/ethernet/davicom/dm9000.c +++ b/drivers/net/ethernet/davicom/dm9000.c @@ -1409,6 +1409,43 @@ static struct dm9000_plat_data *dm9000_parse_dt(struct device *dev) return pdata; } +static char *mac_addr = ":"; +module_param(mac_addr, charp, 0); +MODULE_PARM_DESC(mac_addr, "MAC address"); + +static void get_mac_addr(struct net_device *ndev, char *macaddr) +{ + int i = 0; + int j = 0; + int got_num = 0; + int num = 0; + + while (j < ETH_ALEN) { + if (macaddr[i]) { + int digit; + + got_num = 1; + digit = hex_to_bin(macaddr[i]); + if (digit >= 0) + num = num * 16 + digit; + else if (':' == macaddr[i]) + got_num = 2; + else + break; + } else if (got_num) { + got_num = 2; + } else { + break; + } + if (got_num == 2) { + ndev->dev_addr[j++] = (u8)num; + num = 0; + got_num = 0; + } + i++; + } +} + /* * Search DM9000 board, allocate space and register it */ @@ -1679,6 +1716,11 @@ dm9000_probe(struct platform_device *pdev) ndev->dev_addr[i] = ior(db, i+DM9000_PAR); } + if (!is_valid_ether_addr(ndev->dev_addr)) { + mac_src = "param"; + get_mac_addr(ndev, mac_addr); + } + if (!is_valid_ether_addr(ndev->dev_addr)) { inv_mac_addr = true; eth_hw_addr_random(ndev); From patchwork Tue Feb 11 21:41:21 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H. Nikolaus Schaller" X-Patchwork-Id: 204923 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=-9.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 70CDEC35242 for ; Tue, 11 Feb 2020 21:42:56 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4621A2073C for ; Tue, 11 Feb 2020 21:42:56 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=goldelico.com header.i=@goldelico.com header.b="R1Qu0FUr" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727578AbgBKVmr (ORCPT ); Tue, 11 Feb 2020 16:42:47 -0500 Received: from mo4-p03-ob.smtp.rzone.de ([81.169.146.172]:18655 "EHLO mo4-p03-ob.smtp.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728011AbgBKVlz (ORCPT ); Tue, 11 Feb 2020 16:41:55 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1581457309; s=strato-dkim-0002; d=goldelico.com; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=RzFvreAROfD8+Za4+h0pzFXVuRYDasxapojPV71TMVg=; b=R1Qu0FUrl4GPnBWns53t2aiO9Hb0AtmGr1wMHoax5Oisic/xfziW+y1gV0DWYmFVg2 uSpPiys7jDrRT7gnPfrykJFHj7QfXfQmUNn91ON6l70Q/LbgBKfftTpq76P0XIXZXwWk mwru2DglC+oD8GCGGY/AUUUTjbY56Ik5Ikqx8fPtm+WPrTAigTk7zCaSWiqieppzDFQL LYuXbhE/1/zyGr+yaGIehLes1fqljKoUMNxqNTAAtOujOhN+yZ3sMVrfY212xhy1Od7B z6Zh5fGF9axkoi5mZzTuOlNcN9zIZOuLthERgUFwnqyISQ49XJkOxQy/EcHD7NtUheRA DNWw== X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMhflhwDubTJ9o1OAA2UNf2M0P2mp10IM" X-RZG-CLASS-ID: mo00 Received: from iMac.fritz.box by smtp.strato.de (RZmta 46.1.12 DYNA|AUTH) with ESMTPSA id U06217w1BLfZ0EK (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Tue, 11 Feb 2020 22:41:35 +0100 (CET) From: "H. Nikolaus Schaller" To: Paul Cercueil , Paul Boddie , Alex Smith , Rob Herring , Mark Rutland , Ralf Baechle , Paul Burton , James Hogan , David Airlie , Daniel Vetter , "David S. Miller" , Linus Walleij , "H. Nikolaus Schaller" , Andi Kleen , Krzysztof Kozlowski , Geert Uytterhoeven , Miquel Raynal , =?utf-8?q?Petr_=C5=A0tetiar?= , Richard Fontana , Allison Randal , Stephen Boyd Cc: devicetree@vger.kernel.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-i2c@vger.kernel.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, letux-kernel@openphoenux.org, kernel@pyra-handheld.com Subject: [PATCH 04/14] MIPS: DTS: jz4780: fix #includes for irq.h and gpio.h Date: Tue, 11 Feb 2020 22:41:21 +0100 Message-Id: <5cc02bf80a341262362f8c73d9d5d3efde098482.1581457290.git.hns@goldelico.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: References: MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org The constants from irq.h and gpio.h can be used in the jz4780.dtsi and derived DTS like ci20.dts. Signed-off-by: H. Nikolaus Schaller --- arch/mips/boot/dts/ingenic/jz4780.dtsi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/mips/boot/dts/ingenic/jz4780.dtsi b/arch/mips/boot/dts/ingenic/jz4780.dtsi index f928329b034b..112a24deff71 100644 --- a/arch/mips/boot/dts/ingenic/jz4780.dtsi +++ b/arch/mips/boot/dts/ingenic/jz4780.dtsi @@ -1,6 +1,8 @@ // SPDX-License-Identifier: GPL-2.0 #include #include +#include +#include / { #address-cells = <1>; From patchwork Tue Feb 11 21:41:23 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H. Nikolaus Schaller" X-Patchwork-Id: 204926 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=-9.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 B1851C35242 for ; Tue, 11 Feb 2020 21:42:27 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8A4E02073C for ; Tue, 11 Feb 2020 21:42:27 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=goldelico.com header.i=@goldelico.com header.b="oet+M1Kj" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728103AbgBKVlz (ORCPT ); Tue, 11 Feb 2020 16:41:55 -0500 Received: from mo4-p04-ob.smtp.rzone.de ([85.215.255.123]:30428 "EHLO mo4-p04-ob.smtp.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728002AbgBKVly (ORCPT ); Tue, 11 Feb 2020 16:41:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1581457309; s=strato-dkim-0002; d=goldelico.com; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=tc4xhvDjnfG1jLVOTwuj+X2pkCzFOljdsKLqfh9DWVg=; b=oet+M1KjDaksTT/lPlYyKQaSCuukANRy1MVbvVaHOK9YJkcwahflWxGcM9/kEBPZEO phXzYKcg1ybKNDlgkq16efSSjV2OKdYdPDT15wl3oxSabzJ8QzGosKHwpML9UctmL/oP eu3a5lY9Dsx8QqVlqlwUPGBZFh8z6WV9E4cuCZkp1f4z5VtPJ0+SKfF5Q6btc9EhDwkt wyQyPvv4G9oHzJj6pr0NLOBOl71bHThVBEtly4EMtH7uPrYJNw+ns4xlNtit0JyRy7rq e+M/e3+dhwPRiVymbEPYHlFn6CJZY5RI+Ig/oo9r7sNa/d+S7oeFkaPsS/x/1u7QMwV3 Q+aA== X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMhflhwDubTJ9o1OAA2UNf2M0P2mp10IM" X-RZG-CLASS-ID: mo00 Received: from iMac.fritz.box by smtp.strato.de (RZmta 46.1.12 DYNA|AUTH) with ESMTPSA id U06217w1BLfb0EM (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Tue, 11 Feb 2020 22:41:37 +0100 (CET) From: "H. Nikolaus Schaller" To: Paul Cercueil , Paul Boddie , Alex Smith , Rob Herring , Mark Rutland , Ralf Baechle , Paul Burton , James Hogan , David Airlie , Daniel Vetter , "David S. Miller" , Linus Walleij , "H. Nikolaus Schaller" , Andi Kleen , Krzysztof Kozlowski , Geert Uytterhoeven , Miquel Raynal , =?utf-8?q?Petr_=C5=A0tetiar?= , Richard Fontana , Allison Randal , Stephen Boyd Cc: devicetree@vger.kernel.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-i2c@vger.kernel.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, letux-kernel@openphoenux.org, kernel@pyra-handheld.com Subject: [PATCH 06/14] MIPS: CI20: defconfig: compile leds-gpio driver into the kernel and configure for LED triggers Date: Tue, 11 Feb 2020 22:41:23 +0100 Message-Id: <235c328ff497b5e14009ad9f4e12d2db9520f4d9.1581457290.git.hns@goldelico.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: References: MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org DTS has been augmented to add some gpio-leds. We need the leds-gpio driver and enable the triggers. Signed-off-by: H. Nikolaus Schaller --- arch/mips/configs/ci20_defconfig | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/arch/mips/configs/ci20_defconfig b/arch/mips/configs/ci20_defconfig index e0d3c9d4c2ae..30a47a7a2994 100644 --- a/arch/mips/configs/ci20_defconfig +++ b/arch/mips/configs/ci20_defconfig @@ -167,3 +167,16 @@ CONFIG_STACKTRACE=y # CONFIG_FTRACE is not set CONFIG_CMDLINE_BOOL=y CONFIG_CMDLINE="earlycon console=ttyS4,115200 clk_ignore_unused" +CONFIG_LEDS_CLASS=y +CONFIG_LEDS_GPIO=y +CONFIG_LEDS_TRIGGERS=y +CONFIG_LEDS_TRIGGER_MTD=y +CONFIG_LEDS_TRIGGER_TIMER=y +CONFIG_LEDS_TRIGGER_ONESHOT=y +CONFIG_LEDS_TRIGGER_ONESHOT=y +CONFIG_LEDS_TRIGGER_HEARTBEAT=y +CONFIG_LEDS_TRIGGER_BACKLIGHT=m +CONFIG_LEDS_TRIGGER_CPU=y +CONFIG_LEDS_TRIGGER_DEFAULT_ON=y +CONFIG_LEDS_TRIGGER_TRANSIENT=y +CONFIG_LEDS_TRIGGER_CAMERA=m From patchwork Tue Feb 11 21:41:25 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H. Nikolaus Schaller" X-Patchwork-Id: 204920 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=-9.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 6D497C35242 for ; Tue, 11 Feb 2020 21:43:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3AEB220870 for ; Tue, 11 Feb 2020 21:43:43 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=goldelico.com header.i=@goldelico.com header.b="t1kKf1CM" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728320AbgBKVn3 (ORCPT ); Tue, 11 Feb 2020 16:43:29 -0500 Received: from mo4-p04-ob.smtp.rzone.de ([81.169.146.223]:30035 "EHLO mo4-p04-ob.smtp.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727953AbgBKVly (ORCPT ); Tue, 11 Feb 2020 16:41:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1581457309; s=strato-dkim-0002; d=goldelico.com; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=o2aaGn+CrBGGFUCI/aU8qBP4BNQ+G25EUxt570OpKBY=; b=t1kKf1CMl2v02AQpB3xHcmj4Dwxsrce6Ucp3Rcn2L1lWyYSByeffFSbhC+r41q3yHX lLn9+LSSK0DoXI92s8wQTScT/9lPlD/FN78j2F6yRvjzdbk3vH61iWQcS9oMM5gE4xHo cfAo8P8fjbAbfFvjFgTC8DashBNNSv3MWZnqXz8f3swQW/cwTZjpEj8cYfQwpY1dh6f3 EY/kk65s88jgzkkzoZlm4swb/r8yQStVRScd9ztP30xqhhVE8hKVhddNhMS9XujJR/Eb t/t3XPa/lGpGlztn0IH/WYmkopg9ceV7NYFJPB2t+jgIpYMs5k7dL54AxkvgCiDdI/ZD 3gLQ== X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMhflhwDubTJ9o1OAA2UNf2M0P2mp10IM" X-RZG-CLASS-ID: mo00 Received: from iMac.fritz.box by smtp.strato.de (RZmta 46.1.12 DYNA|AUTH) with ESMTPSA id U06217w1BLfc0EO (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Tue, 11 Feb 2020 22:41:38 +0100 (CET) From: "H. Nikolaus Schaller" To: Paul Cercueil , Paul Boddie , Alex Smith , Rob Herring , Mark Rutland , Ralf Baechle , Paul Burton , James Hogan , David Airlie , Daniel Vetter , "David S. Miller" , Linus Walleij , "H. Nikolaus Schaller" , Andi Kleen , Krzysztof Kozlowski , Geert Uytterhoeven , Miquel Raynal , =?utf-8?q?Petr_=C5=A0tetiar?= , Richard Fontana , Allison Randal , Stephen Boyd Cc: devicetree@vger.kernel.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-i2c@vger.kernel.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, letux-kernel@openphoenux.org, kernel@pyra-handheld.com Subject: [PATCH 08/14] MIPS: CI20: defconfig: configure CONFIG_REGULATOR_ACT8865 for PMU Date: Tue, 11 Feb 2020 22:41:25 +0100 Message-Id: <123a132d735a02c1fcbf989c25551a616b1cb991.1581457290.git.hns@goldelico.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: References: MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org The PMU on the CI20 board is an ACT8600 using the ACT8865 driver. Since it is not compiled, the PMU and the CI20 board is running in power-on reset state of the PMU. Signed-off-by: H. Nikolaus Schaller --- arch/mips/configs/ci20_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/mips/configs/ci20_defconfig b/arch/mips/configs/ci20_defconfig index 30a47a7a2994..74e5775b8a05 100644 --- a/arch/mips/configs/ci20_defconfig +++ b/arch/mips/configs/ci20_defconfig @@ -95,6 +95,7 @@ CONFIG_JZ4740_WDT=y CONFIG_REGULATOR=y CONFIG_REGULATOR_DEBUG=y CONFIG_REGULATOR_FIXED_VOLTAGE=y +CONFIG_REGULATOR_ACT8865=y # CONFIG_VGA_CONSOLE is not set # CONFIG_HID is not set # CONFIG_USB_SUPPORT is not set From patchwork Tue Feb 11 21:41:27 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H. Nikolaus Schaller" X-Patchwork-Id: 204924 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=-9.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 C4D28C3B187 for ; Tue, 11 Feb 2020 21:42:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9E1762082F for ; Tue, 11 Feb 2020 21:42:43 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=goldelico.com header.i=@goldelico.com header.b="dupIz7K1" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728061AbgBKVlz (ORCPT ); Tue, 11 Feb 2020 16:41:55 -0500 Received: from mo4-p04-ob.smtp.rzone.de ([85.215.255.120]:23707 "EHLO mo4-p04-ob.smtp.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727762AbgBKVly (ORCPT ); Tue, 11 Feb 2020 16:41:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1581457310; s=strato-dkim-0002; d=goldelico.com; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=tz5FT9e8j/vOF6dHesX7jElKIt8MXbKvwaqQV2chsVc=; b=dupIz7K1QDO5pGf0QzjaY/pv9gX+ybe0O1d3Bobc6KX5ZyzXJFni4IpZASVsyF7+Ri r0+tbbsNO/SQ79AAgQ+tUFt9EBmXUmIIQMn6XNk17hvLd2ROC8FdVONpck59jqOc5ZzE uiyvx23s7XXMNuZLSulLxIfVS+LNmwCuMH76/NcnczU+WodrKh914bmvtqsZhYdTAsnv bruuayI0ER2VfsoFasLekSNbzYH4b0UvmInlqSaZnpVStIAf0lLrkueCMnldhodZPHzE 6i1gTpTfKvlcFEcnrHzv+LYTz0vGGxZwafAJvD9R+AaKGmIU4rBetwjwNt4r1SEOdeGw lyjQ== X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMhflhwDubTJ9o1OAA2UNf2M0P2mp10IM" X-RZG-CLASS-ID: mo00 Received: from iMac.fritz.box by smtp.strato.de (RZmta 46.1.12 DYNA|AUTH) with ESMTPSA id U06217w1BLfe0EQ (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Tue, 11 Feb 2020 22:41:40 +0100 (CET) From: "H. Nikolaus Schaller" To: Paul Cercueil , Paul Boddie , Alex Smith , Rob Herring , Mark Rutland , Ralf Baechle , Paul Burton , James Hogan , David Airlie , Daniel Vetter , "David S. Miller" , Linus Walleij , "H. Nikolaus Schaller" , Andi Kleen , Krzysztof Kozlowski , Geert Uytterhoeven , Miquel Raynal , =?utf-8?q?Petr_=C5=A0tetiar?= , Richard Fontana , Allison Randal , Stephen Boyd Cc: devicetree@vger.kernel.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-i2c@vger.kernel.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, letux-kernel@openphoenux.org, kernel@pyra-handheld.com Subject: [PATCH 10/14] MIPS: DTS: CI20: add DT node for IR sensor Date: Tue, 11 Feb 2020 22:41:27 +0100 Message-Id: <5ba2ba43f06955bbfcd8465271bb01cfc1101d13.1581457290.git.hns@goldelico.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: References: MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Alex Smith The infrared sensor on the CI20 board is connected to a GPIO and can be operated by using the gpio-ir-recv driver. Add a DT node for the sensor to allow that driver to be used. Signed-off-by: Alex Smith Signed-off-by: H. Nikolaus Schaller --- arch/mips/boot/dts/ingenic/ci20.dts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/mips/boot/dts/ingenic/ci20.dts b/arch/mips/boot/dts/ingenic/ci20.dts index e1364f941c7d..b4a820313992 100644 --- a/arch/mips/boot/dts/ingenic/ci20.dts +++ b/arch/mips/boot/dts/ingenic/ci20.dts @@ -62,6 +62,11 @@ enable-active-high; }; + ir: ir-receiver { + compatible = "gpio-ir-receiver"; + gpios = <&gpe 3 GPIO_ACTIVE_LOW>; + }; + wlan0_power: fixedregulator@1 { compatible = "regulator-fixed"; regulator-name = "wlan0_power"; From patchwork Tue Feb 11 21:41:28 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H. Nikolaus Schaller" X-Patchwork-Id: 204922 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=-9.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 113CBC3B188 for ; Tue, 11 Feb 2020 21:43:13 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DA2E72086A for ; Tue, 11 Feb 2020 21:43:12 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=goldelico.com header.i=@goldelico.com header.b="QCNo7kZy" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727347AbgBKVm4 (ORCPT ); Tue, 11 Feb 2020 16:42:56 -0500 Received: from mo4-p04-ob.smtp.rzone.de ([81.169.146.177]:23185 "EHLO mo4-p04-ob.smtp.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728003AbgBKVly (ORCPT ); Tue, 11 Feb 2020 16:41:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1581457310; s=strato-dkim-0002; d=goldelico.com; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=3bosFD/maVT7s0PxPwS4PL1iP9bgaYLTqR2vJvqzmIk=; b=QCNo7kZyeezapZKnNq2iHmq8qbL+LmjFODLMwnS3tshe4JqxsG/xBgE04yRBCbfO5N XpeWcrroV9tUDab16JUbrzTRR8+i/qaudADWcIiqdB/Lec3QtxkxiS5WMRVfVNrS4D1U QxTvHPISEI85iVxiTvprnD9svhaL5nIDQ6i6LhSQQpXKTIHJTE9pNLeGolZE9ZQ2RvAm 6chD/inDh77hqHN8L9wPliQhv8FrZNsbeE1P62F/8kdvTdx4VfkPwIXFdGWnYIMF9SE2 Bcq6a/WxKm4Rs+iaKREHkuzzlGxbTQW9QSDaXovMMxpf8Q6JnwEQ3xIE6w4gHocHlkc1 plCw== X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMhflhwDubTJ9o1OAA2UNf2M0P2mp10IM" X-RZG-CLASS-ID: mo00 Received: from iMac.fritz.box by smtp.strato.de (RZmta 46.1.12 DYNA|AUTH) with ESMTPSA id U06217w1BLff0ES (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Tue, 11 Feb 2020 22:41:41 +0100 (CET) From: "H. Nikolaus Schaller" To: Paul Cercueil , Paul Boddie , Alex Smith , Rob Herring , Mark Rutland , Ralf Baechle , Paul Burton , James Hogan , David Airlie , Daniel Vetter , "David S. Miller" , Linus Walleij , "H. Nikolaus Schaller" , Andi Kleen , Krzysztof Kozlowski , Geert Uytterhoeven , Miquel Raynal , =?utf-8?q?Petr_=C5=A0tetiar?= , Richard Fontana , Allison Randal , Stephen Boyd Cc: devicetree@vger.kernel.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-i2c@vger.kernel.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, letux-kernel@openphoenux.org, kernel@pyra-handheld.com Subject: [PATCH 11/14] MIPS: CI20: defconfig: compile gpio-ir driver Date: Tue, 11 Feb 2020 22:41:28 +0100 Message-Id: <4cda1587b8e380db7b2b921dfcd21e73c001505b.1581457290.git.hns@goldelico.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: References: MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org The CI20 board has a gpio based IR receiver. Signed-off-by: H. Nikolaus Schaller --- arch/mips/configs/ci20_defconfig | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/mips/configs/ci20_defconfig b/arch/mips/configs/ci20_defconfig index 74e5775b8a05..0458ea4d54e8 100644 --- a/arch/mips/configs/ci20_defconfig +++ b/arch/mips/configs/ci20_defconfig @@ -181,3 +181,8 @@ CONFIG_LEDS_TRIGGER_CPU=y CONFIG_LEDS_TRIGGER_DEFAULT_ON=y CONFIG_LEDS_TRIGGER_TRANSIENT=y CONFIG_LEDS_TRIGGER_CAMERA=m +CONFIG_LIRC=y +CONFIG_MEDIA_SUPPORT=m +CONFIG_RC_DEVICES=y +CONFIG_IR_GPIO_CIR=m +CONFIG_IR_GPIO_TX=m From patchwork Tue Feb 11 21:41:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H. Nikolaus Schaller" X-Patchwork-Id: 204925 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=-9.6 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE, SPF_PASS, URIBL_BLOCKED, USER_AGENT_GIT autolearn=unavailable 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 0D19FC35242 for ; Tue, 11 Feb 2020 21:42:38 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D599B2073C for ; Tue, 11 Feb 2020 21:42:37 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=goldelico.com header.i=@goldelico.com header.b="nKjjKE8y" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727910AbgBKVm3 (ORCPT ); Tue, 11 Feb 2020 16:42:29 -0500 Received: from mo4-p04-ob.smtp.rzone.de ([85.215.255.122]:12041 "EHLO mo4-p04-ob.smtp.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727682AbgBKVlz (ORCPT ); Tue, 11 Feb 2020 16:41:55 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1581457312; s=strato-dkim-0002; d=goldelico.com; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From: X-RZG-CLASS-ID:X-RZG-AUTH:From:Subject:Sender; bh=HJKkK+L/+IvQc4t06WFqnt4bWf+FyU8DIYq2eP8LWiA=; b=nKjjKE8y0iuVhSxf1aDlgkV+vhXAIRL34cIN1KMeYzaESe/Y/CBxtoUifbPMOSRa6r Hc7GszW+vR8oJRxH/p2O7ryxIFKI8IDrB0c/xnnGwZdZuPuKM4J7cXPJ6zpIYCCZqetV La548fWfLtbmo62U4lZrhh+rgHYkt521G+o8tFKzhtFCZd4/B95La8XXLur02Yd6UtJe j4Je8wY/xS7dvpzUItrYOYp06KJL2dLYD+sdpQCK4GrE1MLq6nZqMhArxNajR/WiTHw6 5jUyTiN8FgpxufafnfAnOp70E8FCmrUHT9gMcP0msVZxPocdPXb4vTl94EtRgBcH6Wyj 5tRw== X-RZG-AUTH: ":JGIXVUS7cutRB/49FwqZ7WcJeFKiMhflhwDubTJ9o1OAA2UNf2M0P2mp10IM" X-RZG-CLASS-ID: mo00 Received: from iMac.fritz.box by smtp.strato.de (RZmta 46.1.12 DYNA|AUTH) with ESMTPSA id U06217w1BLfh0EV (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256 bits)) (Client did not present a certificate); Tue, 11 Feb 2020 22:41:43 +0100 (CET) From: "H. Nikolaus Schaller" To: Paul Cercueil , Paul Boddie , Alex Smith , Rob Herring , Mark Rutland , Ralf Baechle , Paul Burton , James Hogan , David Airlie , Daniel Vetter , "David S. Miller" , Linus Walleij , "H. Nikolaus Schaller" , Andi Kleen , Krzysztof Kozlowski , Geert Uytterhoeven , Miquel Raynal , =?utf-8?q?Petr_=C5=A0tetiar?= , Richard Fontana , Allison Randal , Stephen Boyd Cc: devicetree@vger.kernel.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-i2c@vger.kernel.org, netdev@vger.kernel.org, linux-gpio@vger.kernel.org, letux-kernel@openphoenux.org, kernel@pyra-handheld.com Subject: [PATCH 14/14] MIPS: DTS: CI20: fix interrupt for pcf8563 RTC Date: Tue, 11 Feb 2020 22:41:31 +0100 Message-Id: <9d300f1bac15ef4a91052973f2ed593dd2513656.1581457290.git.hns@goldelico.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: References: MIME-Version: 1.0 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Interrupts should not be specified by interrupt line but by gpio parent and reference. Signed-off-by: H. Nikolaus Schaller --- arch/mips/boot/dts/ingenic/ci20.dts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/arch/mips/boot/dts/ingenic/ci20.dts b/arch/mips/boot/dts/ingenic/ci20.dts index 8f9d182566db..4bacefa2cfce 100644 --- a/arch/mips/boot/dts/ingenic/ci20.dts +++ b/arch/mips/boot/dts/ingenic/ci20.dts @@ -298,7 +298,9 @@ Optional input supply properties: rtc@51 { compatible = "nxp,pcf8563"; reg = <0x51>; - interrupts = <110>; + + interrupt-parent = <&gpf>; + interrupts = <30 IRQ_TYPE_LEVEL_LOW>; }; };