Re: [PATCH net-next v2] r8152: avoid to change cfg for all devices

From: Simon Horman
Date: Wed Jan 18 2023 - 06:56:47 EST


On Tue, Jan 17, 2023 at 11:03:44AM +0800, Hayes Wang wrote:
> The rtl8152_cfgselector_probe() should set the USB configuration to the
> vendor mode only for the devices which the driver (r8152) supports.
> Otherwise, no driver would be used for such devices.
>
> Fixes: ec51fbd1b8a2 ("r8152: add USB device driver for config selection")
> Signed-off-by: Hayes Wang <hayeswang@xxxxxxxxxxx>
> ---
> v2: fix a typo for the comment.
>
> drivers/net/usb/r8152.c | 20 +++++++++++++++++---
> 1 file changed, 17 insertions(+), 3 deletions(-)

Assuming that all the versions covered in rtl8152_get_version()
support switching the device to vendor mode, then this looks good to me.

Reviewed-by: Simon Horman <simon.horman@xxxxxxxxxxxx>