RE: [PATCH v2 0/2] usb: host: xhci: rcar: fix the quirks setting of XHCI_NO_64BIT_SUPPORT

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

 



Hi,

> From: Mathias Nyman
> Sent: Wednesday, June 01, 2016 8:42 PM
> 
> >>> isn't the following enough?
> >>>
> >>> @@ -4886,7 +4886,7 @@ int xhci_gen_setup(struct usb_hcd *hcd, xhci_get_quirks_t get_quirks)
> >>>   		xhci->hcc_params2 = readl(&xhci->cap_regs->hcc_params2);
> >>>   	xhci_print_registers(xhci);
> >>>
> >>> -	xhci->quirks = quirks;
> >>> +	xhci->quirks |= quirks;
> >>>
> >>>   	get_quirks(dev, xhci);
> >>
> >> Thank you for the comment!
> >> You're correct. This also can resolve the issue.
> >> Do you prefer such a simple patch?
> >> At least, I prefer such a simple patch :)
> >
> > I'll defer that to Mathias :-)
> >
> 
> I think that xhci->quirks |= quirks will do as a rc fix.

Thank you very much for the comment and submitting such a patch!

> looks like setting xhci->quirks need some generic cleanup for usb-next.
> Now in 4.7-rc1 we set xhci->quirks before xhci_gen_setup in xhci_priv_init_quirk(),
> and during xhci_gen_setup() when copying module parameters quirk, and when calling
> the get_quirk() callback.
> 
> There is nothing special happening between xhci_priv_init_quirk and when calling
> get_quirks() in xhci_gen_setup() that need quirks to be set in two stages.
> 
> xhci pci drivers only use the get_quirk callback, platform drivers use both.
> 
> Looks like the get_quirk() callback is a legacy thing from when the memory for
> the xhci struct was allocated in xhci_gen_setup, and xhci->quirks could only be
> set after that.
> 
> Now xhci struct is part of the usb_hcd, so we could probably get rid of the get_quirk
> callback alltogether by setting the pci quirks in xhci_pci_setup

I understood it.

Best regards,
Yoshihiro Shimoda

> -Mathias
--
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



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

  Powered by Linux