aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Kershner <[email protected]>2017-08-30 13:36:32 -0400
committerGreg Kroah-Hartman <[email protected]>2017-08-31 18:17:40 +0200
commit425eaf47e9461063a600b5d810c9405c41c3b8e2 (patch)
treedf4cbdac22af509d5aff5ba3d378c5c2d7ee8337
parentd7f1589a1df39c0aa6234179c032e2ed9af3e0e6 (diff)
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 <[email protected]> Reviewed-by: Tim Sell <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
-rw-r--r--drivers/staging/unisys/visorbus/visorbus_main.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/staging/unisys/visorbus/visorbus_main.c b/drivers/staging/unisys/visorbus/visorbus_main.c
index 0957eaa247c4..a95901ca5b49 100644
--- a/drivers/staging/unisys/visorbus/visorbus_main.c
+++ b/drivers/staging/unisys/visorbus/visorbus_main.c
@@ -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;