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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 379B5C433FE for ; Tue, 30 Nov 2021 16:56:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244602AbhK3RAM (ORCPT ); Tue, 30 Nov 2021 12:00:12 -0500 Received: from mga07.intel.com ([134.134.136.100]:42072 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244462AbhK3RAB (ORCPT ); Tue, 30 Nov 2021 12:00:01 -0500 X-IronPort-AV: E=McAfee;i="6200,9189,10184"; a="299652138" X-IronPort-AV: E=Sophos;i="5.87,276,1631602800"; d="scan'208";a="299652138" Received: from orsmga006.jf.intel.com ([10.7.209.51]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 Nov 2021 08:56:25 -0800 X-IronPort-AV: E=Sophos;i="5.87,276,1631602800"; d="scan'208";a="459671782" Received: from smile.fi.intel.com ([10.237.72.184]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 Nov 2021 08:56:23 -0800 Received: from andy by smile.fi.intel.com with local (Exim 4.95) (envelope-from ) id 1ms6PX-000cax-Io; Tue, 30 Nov 2021 18:55:19 +0200 Date: Tue, 30 Nov 2021 18:55:19 +0200 From: Andy Shevchenko To: Bartosz Golaszewski Cc: Kent Gibson , Linus Walleij , Shuah Khan , Geert Uytterhoeven , linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org Subject: Re: [PATCH v11 2/6] gpiolib: allow to specify the firmware node in struct gpio_chip Message-ID: References: <20211130154127.12272-1-brgl@bgdev.pl> <20211130154127.12272-3-brgl@bgdev.pl> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org On Tue, Nov 30, 2021 at 06:19:12PM +0200, Andy Shevchenko wrote: > On Tue, Nov 30, 2021 at 06:14:01PM +0200, Andy Shevchenko wrote: > > On Tue, Nov 30, 2021 at 04:41:23PM +0100, Bartosz Golaszewski wrote: > > ... > > > Not sure I understand the proposal. Can you provide couple of (simplest) > > examples? > > > > And also it sounds like reinventing a wheel. What problem do you have that you > > need to solve this way? > > Have you seen these: > drivers/gpio/gpio-dwapb.c > drivers/mfd/intel_quark_i2c_gpio.c > ? > > GPIO driver has a main (controller level) node along with children on per bank > basis. Currently it works with the provided approach (see second driver). Btw, may be helpful to debug swnodes application https://lore.kernel.org/lkml/20210327222012.54103-3-andriy.shevchenko@linux.intel.com/#t -- With Best Regards, Andy Shevchenko