summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBenjamin Romer <benjamin.romer@unisys.com>2015-03-16 13:57:48 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-03-20 14:19:16 +0100
commitc394650650b0fc91aebfef601c5a427ef387bb72 (patch)
treeefb9f2f4edf07055971c4c64897ecb838746ef60
parent911e213ea30c119ec0ae8255de5e7c85f85a867b (diff)
downloadcachepc-linux-c394650650b0fc91aebfef601c5a427ef387bb72.tar.gz
cachepc-linux-c394650650b0fc91aebfef601c5a427ef387bb72.zip
staging: unisys: remove unnecessary complication from delete_vbus_device
Take out the variable used to compute a comparison against NULL, and just use the parameter directly. Signed-off-by: Benjamin Romer <benjamin.romer@unisys.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/staging/unisys/virtpci/virtpci.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/staging/unisys/virtpci/virtpci.c b/drivers/staging/unisys/virtpci/virtpci.c
index 3f399e60ae8d..b169d392fce9 100644
--- a/drivers/staging/unisys/virtpci/virtpci.c
+++ b/drivers/staging/unisys/virtpci/virtpci.c
@@ -400,10 +400,9 @@ delete_vbus(struct del_vbus_guestpart *delparams)
static int
delete_vbus_device(struct device *vbus, void *data)
{
- int checkforroot = (data != NULL);
struct device *dev = &virtpci_rootbus_device;
- if ((checkforroot) && match_busid(vbus, (void *)BUS_ID(dev))) {
+ if ((data) && match_busid(vbus, (void *)BUS_ID(dev))) {
/* skip it - don't delete root bus */
return 0; /* pretend no error */
}