Home
last modified time | relevance | path

Searched refs:debounce (Results 1 – 25 of 50) sorted by relevance

12

/drivers/gpio/
A Dgpio-menz127.c39 unsigned debounce) in men_z127_debounce() argument
46 if (!MEN_Z127_DB_IN_RANGE(debounce)) { in men_z127_debounce()
51 if (debounce > 0) { in men_z127_debounce()
53 rnd = fls(debounce) - 1; in men_z127_debounce()
56 debounce = roundup(debounce, MEN_Z127_DB_MIN_US); in men_z127_debounce()
58 debounce = rounddown(debounce, MEN_Z127_DB_MIN_US); in men_z127_debounce()
60 if (debounce > MEN_Z127_DB_MAX_US) in men_z127_debounce()
61 debounce = MEN_Z127_DB_MAX_US; in men_z127_debounce()
64 debounce /= 50; in men_z127_debounce()
71 if (debounce == 0) { in men_z127_debounce()
[all …]
A Dgpio-bcm-kona.c276 unsigned debounce) in bcm_kona_gpio_set_debounce() argument
285 if ((debounce > 0 && debounce < 1000) || debounce > 128000) { in bcm_kona_gpio_set_debounce()
287 debounce); in bcm_kona_gpio_set_debounce()
292 if (debounce != 0) { in bcm_kona_gpio_set_debounce()
294 debounce /= 1000; in bcm_kona_gpio_set_debounce()
296 res = fls(debounce) - 1; in bcm_kona_gpio_set_debounce()
298 if (res > 0 && (debounce & BIT(res - 1))) in bcm_kona_gpio_set_debounce()
308 if (debounce == 0) { in bcm_kona_gpio_set_debounce()
324 u32 debounce; in bcm_kona_gpio_set_config() local
329 debounce = pinconf_to_config_argument(config); in bcm_kona_gpio_set_config()
[all …]
A Dgpio-omap.c43 u32 debounce; member
182 unsigned debounce) in omap2_set_gpio_debounce() argument
186 bool enable = !!debounce; in omap2_set_gpio_debounce()
192 debounce = DIV_ROUND_UP(debounce, 31) - 1; in omap2_set_gpio_debounce()
193 if ((debounce & OMAP4_GPIO_DEBOUNCINGTIME_MASK) != debounce) in omap2_set_gpio_debounce()
200 writel_relaxed(debounce, bank->base + bank->regs->debounce); in omap2_set_gpio_debounce()
216 bank->context.debounce = debounce; in omap2_set_gpio_debounce()
249 bank->context.debounce = 0; in omap_clear_gpio_debounce()
913 unsigned debounce) in omap_gpio_debounce() argument
936 u32 debounce; in omap_gpio_set_config() local
[all …]
A Dgpio-twl4030.c454 static int gpio_twl4030_debounce(u32 debounce, u8 mmc_cd) in gpio_twl4030_debounce() argument
461 message[0] = (debounce & 0xff) | (mmc_cd & 0x03); in gpio_twl4030_debounce()
462 debounce >>= 8; in gpio_twl4030_debounce()
463 message[1] = (debounce & 0xff); in gpio_twl4030_debounce()
464 debounce >>= 8; in gpio_twl4030_debounce()
465 message[2] = (debounce & 0x03); in gpio_twl4030_debounce()
483 &omap_twl_info->debounce); in of_gpio_twl4030()
561 ret = gpio_twl4030_debounce(pdata->debounce, pdata->mmc_cd); in gpio_twl4030_probe()
564 pdata->debounce, pdata->mmc_cd, ret); in gpio_twl4030_probe()
A Dgpio-wm831x.c102 unsigned debounce) in wm831x_gpio_set_debounce() argument
120 if (debounce >= 32 && debounce <= 64) in wm831x_gpio_set_debounce()
122 else if (debounce >= 4000 && debounce <= 8000) in wm831x_gpio_set_debounce()
A Dgpio-blzp1600.c196 unsigned int debounce) in blzp1600_gpio_set_debounce() argument
201 blzp1600_gpio_rmw(chip->base + GPIO_DB_REG, BIT(offset), debounce); in blzp1600_gpio_set_debounce()
208 u32 debounce; in blzp1600_gpio_set_config() local
213 debounce = pinconf_to_config_argument(config); in blzp1600_gpio_set_config()
214 return blzp1600_gpio_set_debounce(gc, offset, debounce); in blzp1600_gpio_set_config()
A Dgpio-rockchip.c49 .debounce = 0x48,
64 .debounce = 0x38,
207 unsigned int debounce) in rockchip_gpio_set_debounce() argument
220 if (debounce > max_debounce) in rockchip_gpio_set_debounce()
223 div = debounce * freq; in rockchip_gpio_set_debounce()
232 if (debounce) { in rockchip_gpio_set_debounce()
244 rockchip_gpio_writel_bit(bank, offset, 1, reg->debounce); in rockchip_gpio_set_debounce()
250 rockchip_gpio_writel_bit(bank, offset, 0, reg->debounce); in rockchip_gpio_set_debounce()
257 if (debounce) in rockchip_gpio_set_debounce()
A Dgpio-rtd.c217 unsigned int debounce) in rtd_gpio_set_debounce() argument
224 switch (debounce) { in rtd_gpio_set_debounce()
263 int debounce; in rtd_gpio_set_config() local
271 debounce = pinconf_to_config_argument(config); in rtd_gpio_set_config()
272 return rtd_gpio_set_debounce(chip, offset, debounce); in rtd_gpio_set_config()
A Dgpio-tangier.c159 unsigned int debounce) in tng_gpio_set_debounce() argument
171 if (debounce) in tng_gpio_set_debounce()
183 u32 debounce; in tng_gpio_set_config() local
191 debounce = pinconf_to_config_argument(config); in tng_gpio_set_config()
192 return tng_gpio_set_debounce(chip, offset, debounce); in tng_gpio_set_config()
A Dgpio-max77620.c195 unsigned int debounce) in max77620_gpio_set_debounce() argument
200 switch (debounce) { in max77620_gpio_set_debounce()
214 dev_err(mgpio->dev, "Illegal value %u\n", debounce); in max77620_gpio_set_debounce()
A Dgpio-ep93xx.c237 u32 debounce; in ep93xx_gpio_set_config() local
242 debounce = pinconf_to_config_argument(config); in ep93xx_gpio_set_config()
243 ep93xx_gpio_int_debounce(gc, offset, debounce ? true : false); in ep93xx_gpio_set_config()
A Dgpio-max3191x.c257 u32 debounce, chipnum, db0_val, db1_val; in max3191x_set_config() local
265 debounce = pinconf_to_config_argument(config); in max3191x_set_config()
266 switch (debounce) { in max3191x_set_config()
A Dgpio-dwapb.c393 unsigned offset, unsigned debounce) in dwapb_gpio_set_debounce() argument
403 if (debounce) in dwapb_gpio_set_debounce()
417 u32 debounce; in dwapb_gpio_set_config() local
420 debounce = pinconf_to_config_argument(config); in dwapb_gpio_set_config()
421 return dwapb_gpio_set_debounce(gc, offset, debounce); in dwapb_gpio_set_config()
/drivers/mmc/core/
A Dslot-gpio.c177 unsigned int debounce) in mmc_gpiod_request_cd() argument
191 if (debounce) { in mmc_gpiod_request_cd()
192 ret = gpiod_set_debounce(desc, debounce); in mmc_gpiod_request_cd()
194 ctx->cd_debounce_delay_ms = debounce / 1000; in mmc_gpiod_request_cd()
249 unsigned int idx, unsigned int debounce) in mmc_gpiod_request_ro() argument
263 if (debounce) { in mmc_gpiod_request_ro()
264 ret = gpiod_set_debounce(desc, debounce); in mmc_gpiod_request_ro()
/drivers/input/touchscreen/
A Dmk712.c81 static int debounce = 1; in mk712_interrupt() local
90 debounce = 1; in mk712_interrupt()
95 debounce = 1; in mk712_interrupt()
100 if (debounce) { in mk712_interrupt()
101 debounce = 0; in mk712_interrupt()
A Dts4800-ts.c45 int debounce; member
54 ts->debounce = DEBOUNCE_COUNT; in ts4800_ts_open()
84 if (ts->debounce) { in ts4800_ts_poll()
85 ts->debounce--; in ts4800_ts_poll()
102 ts->debounce = DEBOUNCE_COUNT; in ts4800_ts_poll()
/drivers/input/keyboard/
A Dmt6779-keypad.c116 u32 debounce; in mt6779_keypad_pdrv_probe() local
156 &debounce)) in mt6779_keypad_pdrv_probe()
157 debounce = 16; in mt6779_keypad_pdrv_probe()
159 if (debounce > MTK_KPD_DEBOUNCE_MAX_MS) { in mt6779_keypad_pdrv_probe()
186 keypad->n_rows, keypad->n_cols, debounce); in mt6779_keypad_pdrv_probe()
199 (debounce * (1 << 5)) & MTK_KPD_DEBOUNCE_MASK); in mt6779_keypad_pdrv_probe()
A Dep93xx_keypad.c64 unsigned int debounce; member
134 val |= (keypad->debounce << KEY_INIT_DBNC_SHIFT) & KEY_INIT_DBNC_MASK; in ep93xx_keypad_config()
226 device_property_read_u32(dev, "debounce-delay-ms", &keypad->debounce); in ep93xx_keypad_probe()
/drivers/pinctrl/mediatek/
A Dmtk-eint.h48 bool debounce; member
95 unsigned int debounce);
116 unsigned int debounce) in mtk_eint_set_debounce() argument
A Dmtk-eint.c95 if (eint->pins[eint_num].debounce && sens != MTK_EINT_EDGE_SENSITIVE) in mtk_eint_can_en_debounce()
413 if (eint->pins[eint_num].debounce) in mtk_eint_irq_handler()
438 unsigned int debounce) in mtk_eint_set_debounce() argument
462 if (debounce <= eint->hw->db_time[i]) { in mtk_eint_set_debounce()
538 eint->pins[i].debounce = (i < eint->hw->db_cnt) ? 1 : 0; in mtk_eint_do_init()
/drivers/extcon/
A Dextcon-palmas.c229 u32 debounce; in palmas_usb_probe() local
231 if (of_property_read_u32(node, "debounce-delay-ms", &debounce)) in palmas_usb_probe()
232 debounce = USB_GPIO_DEBOUNCE_MS; in palmas_usb_probe()
235 debounce * 1000); in palmas_usb_probe()
237 palmas_usb->sw_debounce_jiffies = msecs_to_jiffies(debounce); in palmas_usb_probe()
/drivers/pinctrl/
A Dpinctrl-amd.c128 unsigned int debounce) in amd_gpio_set_debounce() argument
138 debounce = 0; in amd_gpio_set_debounce()
143 if (debounce) { in amd_gpio_set_debounce()
156 if (debounce < 61) { in amd_gpio_set_debounce()
160 } else if (debounce < 976) { in amd_gpio_set_debounce()
161 time = debounce / 61; in amd_gpio_set_debounce()
165 } else if (debounce < 3900) { in amd_gpio_set_debounce()
166 time = debounce / 244; in amd_gpio_set_debounce()
170 } else if (debounce < 250000) { in amd_gpio_set_debounce()
171 time = debounce / 15625; in amd_gpio_set_debounce()
[all …]
/drivers/mfd/
A Dwm8350-gpio.c184 int pol, int pull, int invert, int debounce) in wm8350_gpio_config() argument
208 if (wm8350_gpio_set_debounce(wm8350, gpio, debounce)) in wm8350_gpio_config()
/drivers/pinctrl/intel/
A Dpinctrl-baytrail.c853 u32 conf, pull, val, debounce; in byt_pin_config_get() local
889 debounce = readl(db_reg); in byt_pin_config_get()
891 switch (debounce & BYT_DEBOUNCE_PULSE_MASK) { in byt_pin_config_get()
935 u32 conf, db_pulse, debounce; in byt_pin_config_set() local
1003 debounce = readl(db_reg); in byt_pin_config_set()
1004 debounce = (debounce & ~BYT_DEBOUNCE_PULSE_MASK) | db_pulse; in byt_pin_config_set()
1005 writel(debounce, db_reg); in byt_pin_config_set()
/drivers/staging/greybus/
A Dgpio.c467 u32 debounce; in gb_gpio_set_config() local
472 debounce = pinconf_to_config_argument(config); in gb_gpio_set_config()
473 if (debounce > U16_MAX) in gb_gpio_set_config()
476 return gb_gpio_set_debounce_operation(ggc, (u8)offset, (u16)debounce); in gb_gpio_set_config()

Completed in 60 milliseconds

12