From mboxrd@z Thu Jan 1 00:00:00 1970 From: Peter Korsgaard Date: Sat, 02 Apr 2016 20:57:06 +0200 Subject: [U-Boot] [PATCH 1/3] musb: sunxi: Do not allocate musb struct multiple times In-Reply-To: <1459622771-12704-1-git-send-email-hdegoede@redhat.com> (Hans de Goede's message of "Sat, 2 Apr 2016 20:46:09 +0200") References: <1459622771-12704-1-git-send-email-hdegoede@redhat.com> Message-ID: <87fuv3u9dp.fsf@dell.be.48ers.dk> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de >>>>> "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 removal, so we must safe the > pointer elsewhere. s/safe/save/ (twice). Otherwise it looks sensibe to me. -- Bye, Peter Korsgaard