1
0
Fork 0

GPIO fixes for v5.4:

- Fix debounce delays on the MAX77620 GPIO expander
 - Use the correct unit for debounce times on the BD70528 GPIO expander
 - Get proper deps for parallel builds of the GPIO tools
 - Add a specific ACPI quirk for the Terra Pad 1061
 -----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCAAdFiEElDRnuGcz/wPCXQWMQRCzN7AZXXMFAl3WN7gACgkQQRCzN7AZ
 XXPjQxAAxCIzkDZdg9gFWuITHWzwicPpt8k+lr7QgFEjqm4EPLsGwbM5zy8P8y7t
 MpMARB79pkleCgtdjfclrQzhCo4Q6jZU2mis8QbTZb6SHzoyL5Qyb1t/i/Q1YdVq
 imkdQh5jJHoEbSXXxwZZoto+Qv6yWTx7lIMElUlJmf853StYmiEts3RCOaw71E4F
 3eFC16TjTneEgbvdjjpB+Re99/GlwjAnNWfSiCDNN/JHbj7tpPUY4J8ltHlyp4tj
 V6oZkfW4uInE97v6nWtg8Y/crL6GE5Ew9uwk8nqFsrULxSYCYK82a93rMeg/j3v9
 mTEXn89dUXq4mXHYST+uYam0oMtexknQBxFCnqY9hdTzAcpkzJEpcyqrpyloUVr9
 kyzEs9S2IVvVR3uZtE95ytoD5iYClR/CPq9hQjh8gGx7jPvL0hkrj3pm1292ADSO
 iKAAcJaTw3IWxy21Wsl1enl9zsdXvMmriUfogpvZYsoqz9EgjvI5G5KikDMc2BWw
 5pbOOSkQ8wPA5HcBcnpJtBu1CTJG4pYMXggk88mbNzylfge1LIkTg93RPtbUDHOs
 UFA7/4xD9+rrfbLoV25vzpDvnLibcjU8VpPeefbHUssJUfQd6bOw/0weiBiyHL2S
 4BG0BcbCBIKiLVIehCMAxyH5DEqSipe7QnDns+InTwtLMZv7LMQ=
 =+VQr
 -----END PGP SIGNATURE-----

Merge tag 'gpio-v5.4-5' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio

Pull GPIO fixes from Linus Walleij:
 "A last set of small fixes for GPIO, this cycle was quite busy.

   - Fix debounce delays on the MAX77620 GPIO expander

   - Use the correct unit for debounce times on the BD70528 GPIO expander

   - Get proper deps for parallel builds of the GPIO tools

   - Add a specific ACPI quirk for the Terra Pad 1061"

* tag 'gpio-v5.4-5' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-gpio:
  gpiolib: acpi: Add Terra Pad 1061 to the run_edge_events_on_boot_blacklist
  tools: gpio: Correctly add make dependencies for gpio_utils
  gpio: bd70528: Use correct unit for debounce times
  gpio: max77620: Fixup debounce delays
alistair/sunxi64-5.4-dsi
Linus Torvalds 2019-11-21 12:01:30 -08:00
commit cec353f6c2
5 changed files with 31 additions and 9 deletions

View File

@ -25,13 +25,13 @@ static int bd70528_set_debounce(struct bd70528_gpio *bdgpio,
case 0:
val = BD70528_DEBOUNCE_DISABLE;
break;
case 1 ... 15:
case 1 ... 15000:
val = BD70528_DEBOUNCE_15MS;
break;
case 16 ... 30:
case 15001 ... 30000:
val = BD70528_DEBOUNCE_30MS;
break;
case 31 ... 50:
case 30001 ... 50000:
val = BD70528_DEBOUNCE_50MS;
break;
default:

View File

@ -192,13 +192,13 @@ static int max77620_gpio_set_debounce(struct max77620_gpio *mgpio,
case 0:
val = MAX77620_CNFG_GPIO_DBNC_None;
break;
case 1000 ... 8000:
case 1 ... 8000:
val = MAX77620_CNFG_GPIO_DBNC_8ms;
break;
case 9000 ... 16000:
case 8001 ... 16000:
val = MAX77620_CNFG_GPIO_DBNC_16ms;
break;
case 17000 ... 32000:
case 16001 ... 32000:
val = MAX77620_CNFG_GPIO_DBNC_32ms;
break;
default:

View File

@ -1304,11 +1304,28 @@ late_initcall_sync(acpi_gpio_handle_deferred_request_irqs);
static const struct dmi_system_id run_edge_events_on_boot_blacklist[] = {
{
/*
* The Minix Neo Z83-4 has a micro-USB-B id-pin handler for
* a non existing micro-USB-B connector which puts the HDMI
* DDC pins in GPIO mode, breaking HDMI support.
*/
.matches = {
DMI_MATCH(DMI_SYS_VENDOR, "MINIX"),
DMI_MATCH(DMI_PRODUCT_NAME, "Z83-4"),
}
},
{
/*
* The Terra Pad 1061 has a micro-USB-B id-pin handler, which
* instead of controlling the actual micro-USB-B turns the 5V
* boost for its USB-A connector off. The actual micro-USB-B
* connector is wired for charging only.
*/
.matches = {
DMI_MATCH(DMI_SYS_VENDOR, "Wortmann_AG"),
DMI_MATCH(DMI_PRODUCT_NAME, "TERRA_PAD_1061"),
}
},
{} /* Terminating entry */
};

View File

@ -1,3 +1,4 @@
gpio-utils-y += gpio-utils.o
lsgpio-y += lsgpio.o gpio-utils.o
gpio-hammer-y += gpio-hammer.o gpio-utils.o
gpio-event-mon-y += gpio-event-mon.o gpio-utils.o

View File

@ -35,11 +35,15 @@ $(OUTPUT)include/linux/gpio.h: ../../include/uapi/linux/gpio.h
prepare: $(OUTPUT)include/linux/gpio.h
GPIO_UTILS_IN := $(output)gpio-utils-in.o
$(GPIO_UTILS_IN): prepare FORCE
$(Q)$(MAKE) $(build)=gpio-utils
#
# lsgpio
#
LSGPIO_IN := $(OUTPUT)lsgpio-in.o
$(LSGPIO_IN): prepare FORCE
$(LSGPIO_IN): prepare FORCE $(OUTPUT)gpio-utils-in.o
$(Q)$(MAKE) $(build)=lsgpio
$(OUTPUT)lsgpio: $(LSGPIO_IN)
$(QUIET_LINK)$(CC) $(CFLAGS) $(LDFLAGS) $< -o $@
@ -48,7 +52,7 @@ $(OUTPUT)lsgpio: $(LSGPIO_IN)
# gpio-hammer
#
GPIO_HAMMER_IN := $(OUTPUT)gpio-hammer-in.o
$(GPIO_HAMMER_IN): prepare FORCE
$(GPIO_HAMMER_IN): prepare FORCE $(OUTPUT)gpio-utils-in.o
$(Q)$(MAKE) $(build)=gpio-hammer
$(OUTPUT)gpio-hammer: $(GPIO_HAMMER_IN)
$(QUIET_LINK)$(CC) $(CFLAGS) $(LDFLAGS) $< -o $@
@ -57,7 +61,7 @@ $(OUTPUT)gpio-hammer: $(GPIO_HAMMER_IN)
# gpio-event-mon
#
GPIO_EVENT_MON_IN := $(OUTPUT)gpio-event-mon-in.o
$(GPIO_EVENT_MON_IN): prepare FORCE
$(GPIO_EVENT_MON_IN): prepare FORCE $(OUTPUT)gpio-utils-in.o
$(Q)$(MAKE) $(build)=gpio-event-mon
$(OUTPUT)gpio-event-mon: $(GPIO_EVENT_MON_IN)
$(QUIET_LINK)$(CC) $(CFLAGS) $(LDFLAGS) $< -o $@