Home
last modified time | relevance | path

Searched refs:trig_info (Results 1 – 4 of 4) sorted by relevance

/drivers/iio/trigger/
Diio-trig-hrtimer.c99 struct iio_hrtimer_info *trig_info; in iio_trig_hrtimer_set_state() local
101 trig_info = iio_trigger_get_drvdata(trig); in iio_trig_hrtimer_set_state()
104 hrtimer_start(&trig_info->timer, trig_info->period, in iio_trig_hrtimer_set_state()
107 hrtimer_cancel(&trig_info->timer); in iio_trig_hrtimer_set_state()
118 struct iio_hrtimer_info *trig_info; in iio_trig_hrtimer_probe() local
121 trig_info = kzalloc(sizeof(*trig_info), GFP_KERNEL); in iio_trig_hrtimer_probe()
122 if (!trig_info) in iio_trig_hrtimer_probe()
125 trig_info->swt.trigger = iio_trigger_alloc("%s", name); in iio_trig_hrtimer_probe()
126 if (!trig_info->swt.trigger) { in iio_trig_hrtimer_probe()
131 iio_trigger_set_drvdata(trig_info->swt.trigger, trig_info); in iio_trig_hrtimer_probe()
[all …]
Diio-trig-loop.c80 struct iio_loop_info *trig_info; in iio_trig_loop_probe() local
83 trig_info = kzalloc(sizeof(*trig_info), GFP_KERNEL); in iio_trig_loop_probe()
84 if (!trig_info) in iio_trig_loop_probe()
87 trig_info->swt.trigger = iio_trigger_alloc("%s", name); in iio_trig_loop_probe()
88 if (!trig_info->swt.trigger) { in iio_trig_loop_probe()
93 iio_trigger_set_drvdata(trig_info->swt.trigger, trig_info); in iio_trig_loop_probe()
94 trig_info->swt.trigger->ops = &iio_loop_trigger_ops; in iio_trig_loop_probe()
96 ret = iio_trigger_register(trig_info->swt.trigger); in iio_trig_loop_probe()
100 iio_swt_group_init_type_name(&trig_info->swt, name, &iio_loop_type); in iio_trig_loop_probe()
102 return &trig_info->swt; in iio_trig_loop_probe()
[all …]
Diio-trig-interrupt.c33 struct iio_interrupt_trigger_info *trig_info; in iio_interrupt_trigger_probe() local
54 trig_info = kzalloc(sizeof(*trig_info), GFP_KERNEL); in iio_interrupt_trigger_probe()
55 if (!trig_info) { in iio_interrupt_trigger_probe()
59 iio_trigger_set_drvdata(trig, trig_info); in iio_interrupt_trigger_probe()
60 trig_info->irq = irq; in iio_interrupt_trigger_probe()
81 kfree(trig_info); in iio_interrupt_trigger_probe()
91 struct iio_interrupt_trigger_info *trig_info; in iio_interrupt_trigger_remove() local
94 trig_info = iio_trigger_get_drvdata(trig); in iio_interrupt_trigger_remove()
96 free_irq(trig_info->irq, trig); in iio_interrupt_trigger_remove()
97 kfree(trig_info); in iio_interrupt_trigger_remove()
/drivers/iio/
Dindustrialio-trigger.c66 int __iio_trigger_register(struct iio_trigger *trig_info, in __iio_trigger_register() argument
71 trig_info->owner = this_mod; in __iio_trigger_register()
73 trig_info->id = ida_simple_get(&iio_trigger_ida, 0, 0, GFP_KERNEL); in __iio_trigger_register()
74 if (trig_info->id < 0) in __iio_trigger_register()
75 return trig_info->id; in __iio_trigger_register()
78 dev_set_name(&trig_info->dev, "trigger%ld", in __iio_trigger_register()
79 (unsigned long) trig_info->id); in __iio_trigger_register()
81 ret = device_add(&trig_info->dev); in __iio_trigger_register()
87 if (__iio_trigger_find_by_name(trig_info->name)) { in __iio_trigger_register()
88 pr_err("Duplicate trigger name '%s'\n", trig_info->name); in __iio_trigger_register()
[all …]