Re: [PATCH v2] usb: dwc3: gadget: Move null pinter check after window closed
From: Greg KH
Date: Thu May 12 2022 - 05:39:46 EST
On Thu, May 12, 2022 at 05:31:46PM +0800, Albert Wang wrote:
> After inspecting further, we do see the locking is implicit, with the
> main gotcha being the unlock/re-lock. That creates a window for a race
> to happen. This change moves the NULL check to be adjacent to where
> to it's used and after the window is "closed".
>
> Fixes: 26288448120b ("usb: dwc3: gadget: Fix null pointer exception")
>
> Signed-off-by: Albert Wang <albertccwang@xxxxxxxxxx>
No blank line between Fixes: and signed-off-by please.
> ---
> v2: Remove redundant 'else' and add additional comments and more
> descriptive commit text
I see two v2 copies on the lists for this commit.
Please send a v3, never duplicate the versions, that just causes
confusion, right?
thanks,
greg k-h