[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZSkyoFkBKPavk6Jg@Sun>
Date: Fri, 13 Oct 2023 20:05:52 +0800
From: Hongren Zheng <i@...ithal.me>
To: Shuah Khan <shuah@...nel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Valentina Manea <valentina.manea.m@...il.com>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc: linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org,
sfr@...b.auug.org.au
Subject: Re: [PATCH -next] usb/usbip: fix wrong data added to platform device
On Fri, Oct 13, 2023 at 06:52:09PM +0800, Hongren Zheng wrote:
> .data of platform_device_info will be copied into .platform_data of
> struct device via platform_device_add_data.
>
> However, vhcis[i] contains a spinlock, is dynamically allocated and
> used by other code, so it is not meant to be copied. The workaround
> was to use void *vhci as an agent, but it was removed in the commit
> suggested below.
>
> This patch adds back the workaround and changes the way of using
> platform_data accordingly.
>
> Reported-by: syzbot+e0dbc33630a092ccf033@...kaller.appspotmail.com
> Closes: https://lore.kernel.org/linux-usb/00000000000029242706077f3145@google.com/
> Reported-by: syzbot+6867a9777f4b8dc4e256@...kaller.appspotmail.com
> Closes: https://lore.kernel.org/linux-usb/0000000000007634c1060793197c@google.com/
> Fixes: b8aaf639b403 ("usbip: Use platform_device_register_full()")
> Signed-off-by: Hongren Zheng <i@...ithal.me>
> ---
Tested-by: syzbot+6867a9777f4b8dc4e256@...kaller.appspotmail.com
Link: https://lore.kernel.org/r/0000000000007ac87d0607979b6b@google.com/
Powered by blists - more mailing lists