On 12/25/21 1:20 PM, Uwe Kleine-König wrote:
Hello, some sidestory to this series: While working on fixing the struct dev lifetime thing, I saw a few ugly things that I don't intend to fix myself. Here is just a mail to let you know this with a list of issues. Feel free to address or ignore: - 104_QUAD_8 depends on X86, but compiles fine on ARCH=arm. Maybe adding support for COMPILE_TEST would be a good idea. - 104-quad-8.c uses devm_request_irq() and (now) devm_counter_add(). On unbind an irq might be pending which results in quad8_irq_handler() calling counter_push_event() for a counter that is already unregistered. (The issue exists also without my changes.) - I think intel-qep.c makes the counter unfunctional in intel_qep_remove before the counter is unregistered. - I wonder why counter is a bus and not a class device type. There is no driver that would ever bind a counter device, is there? So /sys/bus/counter/driver is always empty.
This last item has been brought up before. The conclusion was yes it should have been a class but it is too late to change it now since it would break userspace. (I think bus was cargo-culted from the iio subsystem.)