Dear Alan Stern, > On Tue, 15 May 2012, Marek Vasut wrote: > > This comes handy on the i.MX28 CPU, where the host IRQ also signalises > > that the disconnection detector shall be enabled/disabled on the PHY. > > > > Signed-off-by: Marek Vasut <marex@xxxxxxx> > > Cc: Alan Stern <stern@xxxxxxxxxxxxxxxxxxx> > > Cc: Alexander Shishkin <alexander.shishkin@xxxxxxxxxxxxxxx> > > Cc: Felipe Balbi <balbi@xxxxxx> > > Cc: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> > > Cc: Linux USB <linux-usb@xxxxxxxxxxxxxxx> > > --- > > > > drivers/usb/chipidea/host.c | 4 ++++ > > include/linux/usb/chipidea.h | 1 + > > 2 files changed, 5 insertions(+) > > > > diff --git a/drivers/usb/chipidea/host.c b/drivers/usb/chipidea/host.c > > index 9eacd21..97bb167 100644 > > --- a/drivers/usb/chipidea/host.c > > +++ b/drivers/usb/chipidea/host.c > > @@ -94,6 +94,10 @@ static const struct hc_driver ci_ehci_hc_driver = { > > > > static irqreturn_t host_irq(struct ci13xxx *ci) > > { > > > > + if (ci->udc_driver->notify_event) > > + ci->udc_driver->notify_event(ci, > > + CI13XXX_CONTROLLER_HOST_IRQ_EVENT); > > + > > > > return usb_hcd_irq(ci->irq, ci->hcd); > > > > } > > This is a rather roundabout way of doing things. Why add a new > notifier mechanism when you can simply register another interrupt > handler for the same IRQ? You certainly can, but how would you access the EHCI registers from PHY driver? They have separate memory resources. Because the notifier passes data figured out by reading the EHCI register (USBSTS, PCD bit) and tells PHY to enable/disable the disconnection detector accordingly. > > Alan Stern Best regards, Marek Vasut -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html