Skip to content

Commit 909009a

Browse files
committed
fix: ls2k500sfb build error, gpio_device_find_by_label should be used
1 parent f3d8fa7 commit 909009a

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

drivers/video/fbdev/ls2k500sfb.c

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -283,19 +283,13 @@ irqreturn_t ls2k500sfb_interrupt(int irq, void *arg)
283283
#define GPIO_INTPOL ((void *)IO_BASE+0x1fe00000+0x510)
284284
#define GPIO_INTEN ((void *)IO_BASE+0x1fe00000+0x514)
285285

286-
static int gpiochip_match_name(struct gpio_chip *chip, void *data)
287-
{
288-
const char *name = data;
289-
290-
return !strcmp(chip->label, name);
291-
}
292286
static int get_gpio_irq_from_acpi_table(int gpio)
293287
{
294288
struct gpio_chip *chip;
295289
struct gpio_desc *desc;
296290

297-
chip = gpiochip_find("LOON0007:00", gpiochip_match_name);
298-
if (!chip)
291+
chip->gpiodev = gpio_device_find_by_label("LOON0007:00");
292+
if (!chip->gpiodev)
299293
return -ENOENT;
300294
desc = gpiochip_request_own_desc(chip, gpio, "reboot", GPIO_LOOKUP_FLAGS_DEFAULT, GPIOD_IN);
301295
if (!desc)

0 commit comments

Comments
 (0)