[PATCH v7 1/9] usb: typec: Add notifier functions

Heikki Krogerus heikki.krogerus at linux.intel.com
Fri Oct 24 01:16:16 PDT 2025


> +#include <linux/notifier.h>
> +#include <linux/usb/typec_notify.h>
> +
> +static BLOCKING_NOTIFIER_HEAD(typec_notifier_list);
> +
> +int typec_register_notify(struct notifier_block *nb)
> +{
> +	return blocking_notifier_chain_register(&typec_notifier_list, nb);
> +}
> +EXPORT_SYMBOL_GPL(typec_register_notify);
> +
> +int typec_unregister_notify(struct notifier_block *nb)
> +{
> +	return blocking_notifier_chain_unregister(&typec_notifier_list, nb);
> +}
> +EXPORT_SYMBOL_GPL(typec_unregister_notify);

Better name these more clearly:

typec_altmode_register_notify()
typec_altmode_unregister_notify()

thanks,

-- 
heikki



More information about the linux-arm-kernel mailing list