On 02/17/2015 08:23 PM, Viresh Kumar wrote:
On 17 February 2015 at 23:45, Rafael J. Wysocki rjw@rjwysocki.net wrote:
- And then during unregistration the sysfs remove will get called?
I meant subsys-remove here, sorry :(
The CPU device goes away then and that should trigger the remove of all the sysfs directories under it.
How will the cpufreq core know about it? cpufreq_remove_dev() will get called?
Is there a way to emulate it? So that I can test it in my setup..
During logical hotplug, you only get the hotplug notifiers. During physical hotplug, you get the subsys_remove.
So, we have all the information needed to distinguish. Remove the sysfs entries only in subsys-remove.
-Saravana