Lines Matching refs:rcdev
137 static int lirc_bpf_attach(struct rc_dev *rcdev, struct bpf_prog *prog) in lirc_bpf_attach() argument
144 if (rcdev->driver_type != RC_DRIVER_IR_RAW) in lirc_bpf_attach()
151 raw = rcdev->raw; in lirc_bpf_attach()
175 static int lirc_bpf_detach(struct rc_dev *rcdev, struct bpf_prog *prog) in lirc_bpf_detach() argument
182 if (rcdev->driver_type != RC_DRIVER_IR_RAW) in lirc_bpf_detach()
189 raw = rcdev->raw; in lirc_bpf_detach()
213 void lirc_bpf_run(struct rc_dev *rcdev, u32 sample) in lirc_bpf_run() argument
215 struct ir_raw_event_ctrl *raw = rcdev->raw; in lirc_bpf_run()
233 void lirc_bpf_free(struct rc_dev *rcdev) in lirc_bpf_free() argument
238 array = lirc_rcu_dereference(rcdev->raw->progs); in lirc_bpf_free()
250 struct rc_dev *rcdev; in lirc_prog_attach() local
256 rcdev = rc_dev_get_from_fd(attr->target_fd, true); in lirc_prog_attach()
257 if (IS_ERR(rcdev)) in lirc_prog_attach()
258 return PTR_ERR(rcdev); in lirc_prog_attach()
260 ret = lirc_bpf_attach(rcdev, prog); in lirc_prog_attach()
262 put_device(&rcdev->dev); in lirc_prog_attach()
270 struct rc_dev *rcdev; in lirc_prog_detach() local
281 rcdev = rc_dev_get_from_fd(attr->target_fd, true); in lirc_prog_detach()
282 if (IS_ERR(rcdev)) { in lirc_prog_detach()
284 return PTR_ERR(rcdev); in lirc_prog_detach()
287 ret = lirc_bpf_detach(rcdev, prog); in lirc_prog_detach()
290 put_device(&rcdev->dev); in lirc_prog_detach()
299 struct rc_dev *rcdev; in lirc_prog_query() local
306 rcdev = rc_dev_get_from_fd(attr->query.target_fd, false); in lirc_prog_query()
307 if (IS_ERR(rcdev)) in lirc_prog_query()
308 return PTR_ERR(rcdev); in lirc_prog_query()
310 if (rcdev->driver_type != RC_DRIVER_IR_RAW) { in lirc_prog_query()
319 progs = lirc_rcu_dereference(rcdev->raw->progs); in lirc_prog_query()
339 put_device(&rcdev->dev); in lirc_prog_query()