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=-3.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=no 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 532F6C11D09 for ; Thu, 20 Feb 2020 13:02:01 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 2A82924672 for ; Thu, 20 Feb 2020 13:02:01 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728072AbgBTNCA (ORCPT ); Thu, 20 Feb 2020 08:02:00 -0500 Received: from michel.telenet-ops.be ([195.130.137.88]:34962 "EHLO michel.telenet-ops.be" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727915AbgBTNCA (ORCPT ); Thu, 20 Feb 2020 08:02:00 -0500 Received: from ramsan ([84.195.182.253]) by michel.telenet-ops.be with bizsmtp id 511u220045USYZQ0611udL; Thu, 20 Feb 2020 14:01:58 +0100 Received: from rox.of.borg ([192.168.97.57]) by ramsan with esmtp (Exim 4.90_1) (envelope-from ) id 1j4lSj-000563-VA; Thu, 20 Feb 2020 14:01:53 +0100 Received: from geert by rox.of.borg with local (Exim 4.90_1) (envelope-from ) id 1j4lSj-0007LK-Ss; Thu, 20 Feb 2020 14:01:53 +0100 From: Geert Uytterhoeven To: Linus Walleij , Bartosz Golaszewski , Pantelis Antoniou , Frank Rowand , Rob Herring , Mark Rutland Cc: Peter Ujfalusi , Chris Brandt , linux-gpio@vger.kernel.org, devicetree@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-kernel@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH v2 0/2] gpio: of: Add DT overlay support for GPIO hogs Date: Thu, 20 Feb 2020 14:01:47 +0100 Message-Id: <20200220130149.26283-1-geert+renesas@glider.be> X-Mailer: git-send-email 2.17.1 Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Hi all, As GPIO hogs are configured at GPIO controller initialization time, adding/removing GPIO hogs in Device Tree overlays currently does not work. Hence this patch series adds support for that, by registering an of_reconfig notifier, as is already done for platform, i2c, and SPI devices. Changes compared to v1[1]: - Drop RFC state, - Document that modifying existing gpio-hog nodes is not supported. After I posted v1, Frank created a unittest[2] to demonstrate the problem, and to verify to my series fixes it (thanks a lot!). Thanks! [1] "[PATCH/RFC 0/2] gpio: of: Add DT overlay support for GPIO hogs" https://lore.kernel.org/r/20191230133852.5890-1-geert+renesas@glider.be/ [2] "[RFC PATCH 0/2] of: unittest: add overlay gpio test to catch gpio hog problem" https://lore.kernel.org/r/1579070828-18221-1-git-send-email-frowand.list@gmail.com/ Geert Uytterhoeven (2): gpio: of: Extract of_gpiochip_add_hog() gpio: of: Add DT overlay support for GPIO hogs drivers/gpio/gpiolib-of.c | 139 +++++++++++++++++++++++++++++++++----- drivers/gpio/gpiolib-of.h | 2 + drivers/gpio/gpiolib.c | 14 +++- drivers/gpio/gpiolib.h | 3 + 4 files changed, 139 insertions(+), 19 deletions(-) -- 2.17.1 Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds