Skip to content
Commit a1927fbb authored by Thadeu Lima de Souza Cascardo's avatar Thadeu Lima de Souza Cascardo Committed by Tzung-Bi Shih
Browse files

platform/chrome: cros_ec_typec: add remove driver hook



This allows the driver to be unbound and bound again. Otherwise, when
unbinding the driver, there will be leftover sysfs entries.

When rebinding the driver, it also ends up touching freed memory when
adding to the notifier chain as the old one was not removed and ends up
being traversed.

Add a remove_new driver hook, which removes the notifier from the chain and
unregisters the typec ports.

Signed-off-by: default avatarThadeu Lima de Souza Cascardo <cascardo@igalia.com>
Link: https://lore.kernel.org/r/20240726181235.920335-1-cascardo@igalia.com


Signed-off-by: default avatarTzung-Bi Shih <tzungbi@kernel.org>
parent 62be134a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment