Skip to content

Commit

Permalink
xen/xenbus: Remove the unnecessary check.
Browse files Browse the repository at this point in the history
.. we check whether 'xdev' is NULL - but there is no need for
it as the 'dev' check is done before. The 'dev' is embedded in
the 'xdev' so having xdev != NULL with dev being being checked
is not going to happen.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
  • Loading branch information
Konrad Rzeszutek Wilk committed Oct 19, 2011
1 parent e659922 commit d98b15d
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions drivers/xen/xenbus/xenbus_probe_backend.c
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,6 @@ static int xenbus_uevent_backend(struct device *dev,

xdev = to_xenbus_device(dev);
bus = container_of(xdev->dev.bus, struct xen_bus_type, bus);
if (xdev == NULL)
return -ENODEV;

if (add_uevent_var(env, "MODALIAS=xen-backend:%s", xdev->devicetype))
return -ENOMEM;
Expand Down

0 comments on commit d98b15d

Please sign in to comment.