mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-27 00:10:51 +07:00
USB: serial: mos7720: Fix possible null pointer dereference
Signed-off-by: Huzaifa Sidhpurwala <huzaifas@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
d866150a19
commit
91f58ae619
@ -2052,7 +2052,7 @@ static int mos7720_startup(struct usb_serial *serial)
|
||||
struct usb_device *dev;
|
||||
int i;
|
||||
char data;
|
||||
u16 product = le16_to_cpu(serial->dev->descriptor.idProduct);
|
||||
u16 product;
|
||||
int ret_val;
|
||||
|
||||
dbg("%s: Entering ..........", __func__);
|
||||
@ -2062,6 +2062,7 @@ static int mos7720_startup(struct usb_serial *serial)
|
||||
return -ENODEV;
|
||||
}
|
||||
|
||||
product = le16_to_cpu(serial->dev->descriptor.idProduct);
|
||||
dev = serial->dev;
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user