Re: [PATCH] usb: phy: add dedicated notifier for charger events

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Nov 14, 2022 at 02:56:02PM +0200, Ivaylo Dimitrov wrote:
> usb_phy::notifier is already used by various PHY drivers (including
> phy_generic) to report VBUS status changes and its usage conflicts with
> charger current limit changes reporting.

How exactly does it conflict?

> Fix that by introducing a second notifier that is dedicated to usb charger
> notifications. Add usb_charger_XXX_notifier functions. Fix charger drivers
> that currently (ab)use usb_XXX_notifier() to use the new API.

Why not just set the notifier type to be a new one instead of adding a
whole new notifier list?  Or use a real callback?  notifier lists are
really horrid and should be avoided whenever possible.

> Fixes: a9081a008f84 ("usb: phy: Add USB charger support")
> 
> Signed-off-by: Ivaylo Dimitrov <ivo.g.dimitrov.75@xxxxxxxxx>

You can't have a blank line between there, checkpatch.pl should have
complained.

thanks,

greg k-h



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux