Skip to content

Commit 0ed9498

Browse files
hadessgregkh
authored andcommitted
USB: Simplify USB ID table match
usb_device_match_id() supports being passed NULL tables, so no need to check for it. Signed-off-by: Bastien Nocera <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 754498c commit 0ed9498

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

drivers/usb/core/generic.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -205,8 +205,6 @@ static int __check_usb_generic(struct device_driver *drv, void *data)
205205
udrv = to_usb_device_driver(drv);
206206
if (udrv == &usb_generic_driver)
207207
return 0;
208-
if (!udrv->id_table)
209-
return 0;
210208

211209
return usb_device_match_id(udev, udrv->id_table) != NULL;
212210
}

0 commit comments

Comments
 (0)