[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5523E861.7060807@linux.intel.com>
Date: Tue, 07 Apr 2015 17:23:29 +0300
From: Mathias Nyman <mathias.nyman@...ux.intel.com>
To: Roger Quadros <rogerq@...com>, mathias.nyman@...el.com
CC: gregkh@...uxfoundation.org, linux-usb@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/5] usb: xhci: cleanup xhci_hcd allocation
Hi
On 02.04.2015 15:23, Roger Quadros wrote:
> HCD core allocates memory for HCD private data in
> usb_create_[shared_]hcd() so make use of that
> mechanism to allocate the struct xhci_hcd.
>
> Introduce struct xhci_driver_overrides to provide
> the size of HCD private data and hc_driver operation
> overrides. As of now we only need to override the
> reset and start methods.
>
> Signed-off-by: Roger Quadros <rogerq@...com>
I'm not sure I fully understand the what's going on, or what the
intention of this patch is.
So currently xhci driver manages the allocation and freeing of
the xhci_hcd structure. We store a pointer to the xhci_hcd structure in
the content of both the primary and shared usb_hcds structures hcd_priv
field.
With this patch xhci would be part of the usb_hcd structure,
starting at hcd_priv[0]. (Like EHCI I think) It allocates enough space to include
the xhci_hcd in both the primary and shared usb_hcd, but always only use the one
in the primary hcd.
I'm not sure what to do with the space allocated for the shared hcd's
hcd_priv field.
This also means that xhci goes away together with the primary hcd. It's possible
this has some impact as the xhci driver expects xhci to always exists.
-Mathias
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists