Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1705425
| From | Linus Walleij <linus.walleij@linaro.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] gpio: add gpio_add_lookup_tables() to add several tables at once |
| Date | 2017-08-07 14:20 +0200 |
| Message-ID | <ubPaO-83T-13@gated-at.bofh.it> (permalink) |
| References | <u7f5W-7HQ-93@gated-at.bofh.it> <u7rJM-7vZ-11@gated-at.bofh.it> <u9L1D-85L-5@gated-at.bofh.it> <ua0N4-1m9-21@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Wed, Aug 2, 2017 at 2:06 PM, Andy Shevchenko <andriy.shevchenko@linux.intel.com> wrote: > On Tue, 2017-08-01 at 12:24 -0700, Dmitry Torokhov wrote: >> On Wed, Jul 26, 2017 at 01:21:37PM +0300, Andy Shevchenko wrote: >> > On Tue, 2017-07-25 at 13:58 -0700, Dmitry Torokhov wrote: >> > > When converting legacy board to use gpiod API() there migt be >> > > several >> > > lookup tables in board file, let's provide a way to register them >> > > all >> > > at >> > > once. >> > >> > Looking into the code which is using several GPIO look up tables I >> > noticed that the pattern often something like >> > >> > >> > gpiod_add_lookup_table(x_tbl); >> > platform_device_register(x_dev); >> > >> > ... >> > >> > gpiod_add_lookup_table(y_tbl); >> > platform_device_register(y_dev); >> > >> > which looks also logical. >> > >> > So, I have no strong opinion here, though it would be nice to have >> > an >> > example where it makes sense. >> >> Here is an example. It actually does not have multiple GPIO tables, >> but >> it allows to keep the structure of init sequence for the board, which >> relies on having series of arrays conditionally populated with devices >> and other data that need to be registered. > > I see your point. Okay, no objections from me. > > Please, add a stub for !GPIOLIB case. > > After addressing it, > > Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> OK I wait for the stub-inclusive patch. Yours, Linus Walleij
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
Re: [PATCH] gpio: add gpio_add_lookup_tables() to add several tables at once Dmitry Torokhov <dmitry.torokhov@gmail.com> - 2017-08-01 21:30 +0200
Re: [PATCH] gpio: add gpio_add_lookup_tables() to add several tables at once Andy Shevchenko <andriy.shevchenko@linux.intel.com> - 2017-08-02 14:20 +0200
Re: [PATCH] gpio: add gpio_add_lookup_tables() to add several tables at once Linus Walleij <linus.walleij@linaro.org> - 2017-08-07 14:20 +0200
csiph-web