[PATCH 7/9] eeepc-laptop: make fan1_input really read-only

2014-09-17 Thread Frans Klaver
In the instantiation of the fan1_input device attribute, NULL is passed as set function to store_sys_hwmon. The function pointer is never checked before dereferencing it. This is fine if we can guarantee that it will never be called with an invalid pointer, but we can't. If someone from user space

[PATCH 7/9] eeepc-laptop: make fan1_input really read-only

2014-09-17 Thread Frans Klaver
In the instantiation of the fan1_input device attribute, NULL is passed as set function to store_sys_hwmon. The function pointer is never checked before dereferencing it. This is fine if we can guarantee that it will never be called with an invalid pointer, but we can't. If someone from user space