| /linux-6.15/drivers/gpio/ |
| H A D | gpio-mmio.c | 230 gc->write_reg(gc->reg_dat, gc->bgpio_data); in bgpio_set() 258 gc->write_reg(gc->reg_set, gc->bgpio_data); in bgpio_set_set() 352 gc->set(gc, gpio, val); in bgpio_simple_dir_out() 366 gc->write_reg(gc->reg_dir_in, ~gc->bgpio_dir); in bgpio_dir_in() 368 gc->write_reg(gc->reg_dir_out, gc->bgpio_dir); in bgpio_dir_in() 406 gc->write_reg(gc->reg_dir_in, ~gc->bgpio_dir); in bgpio_dir_out() 408 gc->write_reg(gc->reg_dir_out, gc->bgpio_dir); in bgpio_dir_out() 656 gc->bgpio_data = gc->read_reg(gc->reg_dat); in bgpio_init() 659 gc->bgpio_data = gc->read_reg(gc->reg_set); in bgpio_init() 670 gc->bgpio_dir = gc->read_reg(gc->reg_dir_out); in bgpio_init() [all …]
|
| H A D | gpiolib.c | 354 ret = gc->get_direction(gc, offset); in gpiochip_get_direction() 698 return gc->init_valid_mask(gc, in gpiochip_init_valid_mask() 721 return gc->add_pin_ranges(gc); in gpiochip_add_pin_ranges() 987 if ((gc->set && gc->set_rv) || in gpiochip_add_data_with_key() 1301 if (gc && match(gc, data)) in gpio_device_find() 2266 pin_range->range.gc = gc; in gpiochip_add_pingroup_range() 2324 pin_range->range.gc = gc; in gpiochip_add_pin_range() 2871 gc->set(gc, offset, value); in gpiochip_set() 3222 ret = gc->get(gc, offset); in gpiochip_get() 3639 gc->set_multiple(gc, mask, bits); in gpiochip_set_multiple() [all …]
|
| H A D | gpio-reg.c | 22 struct gpio_chip gc; member 35 struct gpio_reg *r = to_gpio_reg(gc); in gpio_reg_get_direction() 44 struct gpio_reg *r = to_gpio_reg(gc); in gpio_reg_direction_output() 49 gc->set(gc, offset, value); in gpio_reg_direction_output() 156 r->gc.label = label; in gpio_reg_init() 160 r->gc.set = gpio_reg_set; in gpio_reg_init() 161 r->gc.get = gpio_reg_get; in gpio_reg_init() 164 r->gc.to_irq = gpio_reg_to_irq; in gpio_reg_init() 165 r->gc.base = base; in gpio_reg_init() 166 r->gc.ngpio = num; in gpio_reg_init() [all …]
|
| H A D | gpio-mpc8xxx.c | 111 struct gpio_chip *gc = &mpc8xxx_gc->gc; in mpc8xxx_gpio_irq_cascade() local 126 struct gpio_chip *gc = &mpc8xxx_gc->gc; in mpc8xxx_irq_unmask() local 141 struct gpio_chip *gc = &mpc8xxx_gc->gc; in mpc8xxx_irq_mask() local 156 struct gpio_chip *gc = &mpc8xxx_gc->gc; in mpc8xxx_irq_ack() local 165 struct gpio_chip *gc = &mpc8xxx_gc->gc; in mpc8xxx_irq_set_type() local 196 struct gpio_chip *gc = &mpc8xxx_gc->gc; in mpc512x_irq_set_type() local 214 gc->write_reg(reg, (gc->read_reg(reg) & ~(3 << shift)) in mpc512x_irq_set_type() 222 gc->write_reg(reg, (gc->read_reg(reg) & ~(3 << shift)) in mpc512x_irq_set_type() 229 gc->write_reg(reg, (gc->read_reg(reg) & ~(3 << shift))); in mpc512x_irq_set_type() 322 gc = &mpc8xxx_gc->gc; in mpc8xxx_probe() [all …]
|
| H A D | gpio-cros-ec.c | 111 names = devm_kcalloc(gc->parent, gc->ngpio, sizeof(*names), GFP_KERNEL); in cros_ec_gpio_init_names() 114 gc->names = names; in cros_ec_gpio_init_names() 116 str = devm_kcalloc(gc->parent, gc->ngpio, name_len, GFP_KERNEL); in cros_ec_gpio_init_names() 165 struct gpio_chip *gc; in cros_ec_gpio_probe() local 178 gc = devm_kzalloc(dev, sizeof(*gc), GFP_KERNEL); in cros_ec_gpio_probe() 179 if (!gc) in cros_ec_gpio_probe() 182 gc->ngpio = ngpios; in cros_ec_gpio_probe() 183 gc->parent = dev; in cros_ec_gpio_probe() 188 gc->can_sleep = true; in cros_ec_gpio_probe() 189 gc->label = dev_name(dev); in cros_ec_gpio_probe() [all …]
|
| H A D | gpio-mpc5200.c | 79 __mpc52xx_wkup_gpio_set(gc, gpio, val); in mpc52xx_wkup_gpio_set() 118 __mpc52xx_wkup_gpio_set(gc, gpio, val); in mpc52xx_wkup_gpio_dir_out() 139 struct gpio_chip *gc; in mpc52xx_wkup_gpiochip_probe() local 148 gc = &chip->mmchip.gc; in mpc52xx_wkup_gpiochip_probe() 150 gc->ngpio = 8; in mpc52xx_wkup_gpiochip_probe() 153 gc->get = mpc52xx_wkup_gpio_get; in mpc52xx_wkup_gpiochip_probe() 238 __mpc52xx_simple_gpio_set(gc, gpio, val); in mpc52xx_simple_gpio_set() 278 __mpc52xx_simple_gpio_set(gc, gpio, val); in mpc52xx_simple_gpio_dir_out() 298 struct gpio_chip *gc; in mpc52xx_simple_gpiochip_probe() local 308 gc = &chip->mmchip.gc; in mpc52xx_simple_gpiochip_probe() [all …]
|
| H A D | gpio-tps68470.c | 26 struct gpio_chip gc; member 95 tps68470_gpio_set(gc, offset, value); in tps68470_gpio_output() 135 tps68470_gpio->gc.label = "tps68470-gpio"; in tps68470_gpio_probe() 136 tps68470_gpio->gc.owner = THIS_MODULE; in tps68470_gpio_probe() 139 tps68470_gpio->gc.get = tps68470_gpio_get; in tps68470_gpio_probe() 141 tps68470_gpio->gc.set = tps68470_gpio_set; in tps68470_gpio_probe() 142 tps68470_gpio->gc.can_sleep = true; in tps68470_gpio_probe() 143 tps68470_gpio->gc.names = tps68470_names; in tps68470_gpio_probe() 144 tps68470_gpio->gc.ngpio = TPS68470_N_GPIO; in tps68470_gpio_probe() 145 tps68470_gpio->gc.base = -1; in tps68470_gpio_probe() [all …]
|
| H A D | gpio-max77650.c | 36 struct gpio_chip gc; member 160 chip->gc.base = -1; in max77650_gpio_probe() 161 chip->gc.ngpio = 1; in max77650_gpio_probe() 162 chip->gc.label = i2c->name; in max77650_gpio_probe() 163 chip->gc.parent = dev; in max77650_gpio_probe() 164 chip->gc.owner = THIS_MODULE; in max77650_gpio_probe() 165 chip->gc.can_sleep = true; in max77650_gpio_probe() 169 chip->gc.set_rv = max77650_gpio_set_value; in max77650_gpio_probe() 170 chip->gc.get = max77650_gpio_get_value; in max77650_gpio_probe() 172 chip->gc.set_config = max77650_gpio_set_config; in max77650_gpio_probe() [all …]
|
| H A D | gpio-tb10x.c | 45 struct gpio_chip gc; member 130 tb10x_gpio->gc.label = in tb10x_gpio_probe() 132 if (!tb10x_gpio->gc.label) in tb10x_gpio_probe() 151 tb10x_gpio->gc.base = -1; in tb10x_gpio_probe() 152 tb10x_gpio->gc.parent = dev; in tb10x_gpio_probe() 158 tb10x_gpio->gc.ngpio = ngpio; in tb10x_gpio_probe() 187 tb10x_gpio->gc.ngpio, in tb10x_gpio_probe() 194 tb10x_gpio->gc.ngpio, 1, tb10x_gpio->gc.label, in tb10x_gpio_probe() 200 gc = tb10x_gpio->domain->gc->gc[0]; in tb10x_gpio_probe() 222 if (tb10x_gpio->gc.to_irq) { in tb10x_gpio_remove() [all …]
|
| H A D | gpio-mockup.c | 54 struct gpio_chip gc; member 279 struct gpio_chip *gc; in gpio_mockup_debugfs_read() local 289 gc = &chip->gc; in gpio_mockup_debugfs_read() 366 gc = &chip->gc; in gpio_mockup_debugfs_setup() 406 struct gpio_chip *gc = &chip->gc; in gpio_mockup_dispose_mappings() local 445 gc = &chip->gc; in gpio_mockup_probe() 446 gc->base = base; in gpio_mockup_probe() 447 gc->ngpio = ngpio; in gpio_mockup_probe() 448 gc->label = name; in gpio_mockup_probe() 450 gc->parent = dev; in gpio_mockup_probe() [all …]
|
| H A D | gpio-ep93xx.c | 34 struct gpio_chip gc; member 151 gpiochip_disable_irq(gc, hwirq); in ep93xx_gpio_irq_mask_ack() 162 gpiochip_disable_irq(gc, hwirq); in ep93xx_gpio_irq_mask() 171 gpiochip_enable_irq(gc, hwirq); in ep93xx_gpio_irq_unmask() 189 gc->direction_input(gc, hwirq); in ep93xx_gpio_irq_type() 215 if (gc->get(gc, hwirq)) in ep93xx_gpio_irq_type() 270 struct gpio_chip *gc = &egc->gc; in ep93xx_setup_irqs() local 302 IRQF_SHARED, gc->label, gc); in ep93xx_setup_irqs() 331 struct gpio_chip *gc; in ep93xx_gpio_probe() local 348 gc = &egc->gc; in ep93xx_gpio_probe() [all …]
|
| H A D | gpio-brcmstb.c | 40 struct gpio_chip gc; member 101 struct gpio_chip *gc = &bank->gc; in brcmstb_gpio_set_imask() local 306 i += bank->gc.ngpio; in brcmstb_gpio_hwirq_to_bank() 498 struct gpio_chip *gc = &bank->gc; in brcmstb_gpio_bank_save() local 510 struct gpio_chip *gc; in brcmstb_gpio_quiesce() local 518 gc = &bank->gc; in brcmstb_gpio_quiesce() 543 struct gpio_chip *gc = &bank->gc; in brcmstb_gpio_bank_restore() local 640 struct gpio_chip *gc; in brcmstb_gpio_probe() local 674 gc = &bank->gc; in brcmstb_gpio_probe() 686 if (!gc->label) { in brcmstb_gpio_probe() [all …]
|
| H A D | gpio-grgpio.c | 62 struct gpio_chip gc; member 94 struct gpio_chip *gc = &priv->gc; in grgpio_set_imask() local 107 if (offset >= gc->ngpio) in grgpio_to_irq() 341 struct gpio_chip *gc; in grgpio_probe() local 357 gc = &priv->gc; in grgpio_probe() 373 if (!gc->label) in grgpio_probe() 376 gc->base = -1; in grgpio_probe() 382 gc->ngpio); in grgpio_probe() 384 gc->ngpio = prop; in grgpio_probe() 396 size, gc->ngpio); in grgpio_probe() [all …]
|
| H A D | gpio-altera.c | 37 struct gpio_chip gc; member 50 gpiochip_enable_irq(gc, irqd_to_hwirq(d)); in altera_gpio_irq_unmask() 192 for_each_set_bit(i, &status, gc->ngpio) in altera_gpio_irq_edge_handler() 215 for_each_set_bit(i, &status, gc->ngpio) in altera_gpio_irq_leveL_high_handler() 250 altera_gc->gc.ngpio = reg; in altera_gpio_probe() 261 altera_gc->gc.get = altera_gpio_get; in altera_gpio_probe() 263 altera_gc->gc.owner = THIS_MODULE; in altera_gpio_probe() 264 altera_gc->gc.parent = &pdev->dev; in altera_gpio_probe() 265 altera_gc->gc.base = -1; in altera_gpio_probe() 268 if (!altera_gc->gc.label) in altera_gpio_probe() [all …]
|
| H A D | gpio-raspberrypi-exp.c | 26 struct gpio_chip gc; member 60 gpio = gpiochip_get_data(gc); in rpi_exp_gpio_get_polarity() 80 gpio = gpiochip_get_data(gc); in rpi_exp_gpio_dir_in() 109 gpio = gpiochip_get_data(gc); in rpi_exp_gpio_dir_out() 138 gpio = gpiochip_get_data(gc); in rpi_exp_gpio_get_direction() 145 dev_err(gc->parent, in rpi_exp_gpio_get_direction() 162 gpio = gpiochip_get_data(gc); in rpi_exp_gpio_get() 170 dev_err(gc->parent, in rpi_exp_gpio_get() 192 dev_err(gc->parent, in rpi_exp_gpio_set() 221 rpi_gpio->gc.parent = dev; in rpi_exp_gpio_probe() [all …]
|
| /linux-6.15/kernel/irq/ |
| H A D | generic-chip.c | 43 irq_gc_lock(gc); in irq_gc_mask_disable_reg() 253 if (gc) { in irq_alloc_generic_chip() 257 return gc; in irq_alloc_generic_chip() 299 if (d->gc) in irq_domain_alloc_generic_chips() 326 dgc->gc[i] = gc = tmp; in irq_domain_alloc_generic_chips() 440 return !IS_ERR(gc) ? gc : NULL; in irq_get_domain_generic_chip() 513 if (!gc) in irq_unmap_generic_chip() 577 gc->irq_cnt = i - gc->irq_base; in irq_setup_generic_chip() 663 virq = irq_find_mapping(gc->domain, gc->irq_base + __ffs(gc->installed)); in irq_gc_get_irq_data() 683 gc->suspend(gc); in irq_gc_suspend() [all …]
|
| /linux-6.15/drivers/irqchip/ |
| H A D | irq-atmel-aic.c | 63 struct irq_chip_generic *gc = dgc->gc[0]; in aic_handle() local 81 irq_gc_lock(gc); in aic_retrigger() 83 irq_gc_unlock(gc); in aic_retrigger() 109 irq_gc_lock(gc); in aic_suspend() 110 irq_reg_writel(gc, gc->mask_cache, AT91_AIC_IDCR); in aic_suspend() 111 irq_reg_writel(gc, gc->wake_active, AT91_AIC_IECR); in aic_suspend() 119 irq_gc_lock(gc); in aic_resume() 120 irq_reg_writel(gc, gc->wake_active, AT91_AIC_IDCR); in aic_resume() 121 irq_reg_writel(gc, gc->mask_cache, AT91_AIC_IECR); in aic_resume() 129 irq_gc_lock(gc); in aic_pm_shutdown() [all …]
|
| H A D | irq-tb10x.c | 33 irq_reg_writel(gc, val, reg); in ab_irqctl_writereg() 38 return irq_reg_readl(gc, reg); in ab_irqctl_readreg() 48 irq_gc_lock(gc); in tb10x_irq_set_type() 70 irq_gc_unlock(gc); in tb10x_irq_set_type() 79 ab_irqctl_writereg(gc, AB_IRQCTL_SRC_MODE, mod); in tb10x_irq_set_type() 81 ab_irqctl_writereg(gc, AB_IRQCTL_INT_STATUS, im); in tb10x_irq_set_type() 83 irq_gc_unlock(gc); in tb10x_irq_set_type() 101 struct irq_chip_generic *gc; in of_tb10x_init_irq() local 143 gc = domain->gc->gc[0]; in of_tb10x_init_irq() 144 gc->reg_base = reg_base; in of_tb10x_init_irq() [all …]
|
| H A D | irq-sunxi-nmi.c | 87 irq_reg_writel(gc, val, off); in sunxi_sc_nmi_write() 92 return irq_reg_readl(gc, off); in sunxi_sc_nmi_read() 108 struct irq_chip_type *ct = gc->chip_types; in sunxi_sc_nmi_set_type() 114 irq_gc_lock(gc); in sunxi_sc_nmi_set_type() 131 irq_gc_unlock(gc); in sunxi_sc_nmi_set_type() 140 for (i = 0; i < gc->num_ct; i++, ct++) in sunxi_sc_nmi_set_type() 149 irq_gc_unlock(gc); in sunxi_sc_nmi_set_type() 158 struct irq_chip_generic *gc; in sunxi_sc_nmi_irq_init() local 183 gc = irq_get_domain_generic_chip(domain, 0); in sunxi_sc_nmi_irq_init() 185 if (IS_ERR(gc->reg_base)) { in sunxi_sc_nmi_irq_init() [all …]
|
| H A D | irq-lan966x-oic.c | 74 irq_gc_lock(gc); in lan966x_oic_irq_startup() 77 map = irq_reg_readl(gc, chip_regs->reg_off_map); in lan966x_oic_irq_startup() 79 irq_reg_writel(gc, map, chip_regs->reg_off_map); in lan966x_oic_irq_startup() 81 irq_gc_unlock(gc); in lan966x_oic_irq_startup() 98 irq_gc_lock(gc); in lan966x_oic_irq_shutdown() 101 map = irq_reg_readl(gc, chip_regs->reg_off_map); in lan966x_oic_irq_shutdown() 105 irq_gc_unlock(gc); in lan966x_oic_irq_shutdown() 175 gc->reg_base = lan966x_oic->regs; in lan966x_oic_chip_init() 185 gc->private = chip_regs; in lan966x_oic_chip_init() 196 irq_reg_writel(gc, ~0U, gc->chip_types[0].regs.disable); in lan966x_oic_chip_exit() [all …]
|
| H A D | irq-loongson-liointc.c | 60 struct irq_chip_generic *gc; member 75 struct irq_chip_generic *gc = handler->priv->gc; in liointc_chained_handle_irq() local 109 gc->reg_base + offset); in liointc_set_bit() 112 gc->reg_base + offset); in liointc_set_bit() 172 writel(gc->mask_cache, gc->reg_base + LIOINTC_REG_INTC_ENABLE); in liointc_resume() 287 gc->private = priv; in liointc_init() 288 gc->reg_base = base; in liointc_init() 289 gc->domain = domain; in liointc_init() 293 ct = gc->chip_types; in liointc_init() 302 gc->mask_cache = 0; in liointc_init() [all …]
|
| H A D | irq-orion.c | 39 struct irq_chip_generic *gc = in orion_handle_irq() local 42 gc->mask_cache; in orion_handle_irq() 46 gc->irq_base + hwirq); in orion_handle_irq() 76 struct irq_chip_generic *gc = in orion_irq_init() local 86 if (!gc->reg_base) in orion_irq_init() 89 gc->chip_types[0].regs.mask = ORION_IRQ_MASK; in orion_irq_init() 94 writel(0, gc->reg_base + ORION_IRQ_MASK); in orion_irq_init() 114 gc->mask_cache; in orion_bridge_irq_handler() 143 struct irq_chip_generic *gc; in orion_bridge_irq_init() local 181 gc = irq_get_domain_generic_chip(domain, 0); in orion_bridge_irq_init() [all …]
|
| /linux-6.15/include/linux/gpio/ |
| H A D | driver.h | 264 int (*init_hw)(struct gpio_chip *gc); 432 int (*request)(struct gpio_chip *gc, 434 void (*free)(struct gpio_chip *gc, 442 int (*get)(struct gpio_chip *gc, 447 void (*set)(struct gpio_chip *gc, 452 int (*set_rv)(struct gpio_chip *gc, 461 int (*to_irq)(struct gpio_chip *gc, 465 struct gpio_chip *gc); 558 int (*of_xlate)(struct gpio_chip *gc, 664 #define gpiochip_add_data(gc, data) gpiochip_add_data_with_key(gc, data, NULL, NULL) argument [all …]
|
| /linux-6.15/drivers/input/joystick/ |
| H A D | gamecon.c | 70 struct gc { struct 202 static void gc_n64_process_packet(struct gc *gc) in gc_n64_process_packet() argument 252 struct gc *gc = input_get_drvdata(dev); in gc_n64_play_effect() local 355 static void gc_nes_process_packet(struct gc *gc) in gc_nes_process_packet() argument 578 static void gc_psx_read_packet(struct gc *gc, in gc_psx_read_packet() argument 729 struct gc *gc = from_timer(gc, t, timer); in gc_timer() local 767 struct gc *gc = input_get_drvdata(dev); in gc_open() local 784 struct gc *gc = input_get_drvdata(dev); in gc_close() local 919 struct gc *gc; in gc_attach() local 951 gc = kzalloc(sizeof(*gc), GFP_KERNEL); in gc_attach() [all …]
|
| /linux-6.15/drivers/net/ethernet/microsoft/mana/ |
| H A D | gdma_main.c | 31 gc->db_page_base = gc->bar0_va + in mana_gd_init_pf_regs() 47 gc->db_page_base = gc->bar0_va + in mana_gd_init_vf_regs() 50 gc->phys_db_page_base = gc->bar0_pa + in mana_gd_init_vf_regs() 53 gc->shm_base = gc->bar0_va + mana_gd_r64(gc, GDMA_REG_SHM_OFFSET); in mana_gd_init_vf_regs() 106 if (gc->max_num_queues > gc->num_msix_usable - 1) in mana_gd_query_max_resources() 107 gc->max_num_queues = gc->num_msix_usable - 1; in mana_gd_query_max_resources() 168 gc->mana.gdma_context = gc; in mana_gd_detect_devices() 172 gc->mana_ib.gdma_context = gc; in mana_gd_detect_devices() 1470 mana_smc_init(&gc->shm_channel, gc->dev, gc->shm_base); in mana_gd_setup() 1550 gc = vzalloc(sizeof(*gc)); in mana_gd_probe() [all …]
|