staging: unisys: visorbus: just check for GUID

Every channel_type must have a valid GUID, checking for the name was just
redundant.

Signed-off-by: David Kershner <david.kershner@unisys.com>
Reviewed-by: Tim Sell <timothy.sell@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
David Kershner 2017-08-30 13:36:32 -04:00 committed by Greg Kroah-Hartman
parent d7f1589a1d
commit 425eaf47e9
1 changed files with 1 additions and 3 deletions

View File

@ -151,9 +151,7 @@ static int visorbus_match(struct device *xdev, struct device_driver *xdrv)
if (!drv->channel_types)
return 0;
for (i = 0;
!guid_is_null(&drv->channel_types[i].guid) || drv->channel_types[i].name;
i++)
for (i = 0; !guid_is_null(&drv->channel_types[i].guid); i++)
if (guid_equal(&drv->channel_types[i].guid, channel_type))
return i + 1;