Re: [U-Boot] [PATCH 1/3] musb: sunxi: Do not allocate musb struct multiple times

2016-04-05 Thread Ian Campbell
On Sat, 2016-04-02 at 23:39 +0200, Hans de Goede wrote: > Hi, > > On 04/02/2016 08:57 PM, Peter Korsgaard wrote: > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > "Hans" == Hans de Goede writes: > >   > The probe function of the musb host driver can be called > > multiple

Re: [U-Boot] [PATCH 1/3] musb: sunxi: Do not allocate musb struct multiple times

2016-04-02 Thread Hans de Goede
Hi, On 04/02/2016 08:57 PM, Peter Korsgaard wrote: "Hans" == Hans de Goede writes: > The probe function of the musb host driver can be called multiple > times. The code assumes that it can safe the pointer to the allocated > musb struct in the driver model priv_auto_alloc data, but this

Re: [U-Boot] [PATCH 1/3] musb: sunxi: Do not allocate musb struct multiple times

2016-04-02 Thread Peter Korsgaard
> "Hans" == Hans de Goede writes: > The probe function of the musb host driver can be called multiple > times. The code assumes that it can safe the pointer to the allocated > musb struct in the driver model priv_auto_alloc data, but this data > gets free-ed on a probe failure or on remov

[U-Boot] [PATCH 1/3] musb: sunxi: Do not allocate musb struct multiple times

2016-04-02 Thread Hans de Goede
The probe function of the musb host driver can be called multiple times. The code assumes that it can safe the pointer to the allocated musb struct in the driver model priv_auto_alloc data, but this data gets free-ed on a probe failure or on removal, so we must safe the pointer elsewhere. Signed-o