lkml.org 
[lkml]   [2023]   [Sep]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH RFC v2 5/6] ARM: pxa: Convert Spitz hsync to GPIO descriptors
Date
On Tuesday, September 26, 2023 6:19:23 PM CEST Andy Shevchenko wrote:
> On Tue, Sep 26, 2023 at 05:46:26PM +0200, Duje Mihanović wrote:
> > gpiod_add_lookup_table(&spitz_ads7846_gpio_table);
> > gpiod_add_lookup_table(&spitz_spi_gpio_table);
> >
> > + hsync = gpiod_get(NULL, "hsync", GPIOD_IN);
> > + if (IS_ERR(hsync)) {
> > + pr_err("Failed to get hsync GPIO: %ld\n", PTR_ERR(hsync));
> > + return;
> > + }
> >
> > pxa2xx_set_spi_info(2, &spitz_spi_info);
> > spi_register_board_info(ARRAY_AND_SIZE(spitz_spi_devices));
>
> Yeah, but the question is, if GPIO request fails, can we instantiate at
least one device and move on?

I see. If the touchscreen is the first out of 3 devices in that array, would
something like this do:

spi_register_board_info(ARRAY_AND_SIZE(&spitz_spi_devices[1]));

Regards,
Duje



\
 
 \ /
  Last update: 2023-09-27 18:53    [W:0.100 / U:0.268 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site