Commit 4e526a00 authored by Roland Kammerer's avatar Roland Kammerer Committed by Jens Axboe

drbd: get rid of empty statement in is_valid_state

This should silence a warning about an empty statement. Thanks to Fabian
Frederick <fabf@skynet.be> who sent a patch I modified to be smaller and
avoids an additional indent level.
Signed-off-by: default avatarRoland Kammerer <roland.kammerer@linbit.com>
Signed-off-by: default avatarPhilipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: default avatarJens Axboe <axboe@fb.com>
parent 7e5fec31
...@@ -814,7 +814,7 @@ is_valid_state(struct drbd_device *device, union drbd_state ns) ...@@ -814,7 +814,7 @@ is_valid_state(struct drbd_device *device, union drbd_state ns)
} }
if (rv <= 0) if (rv <= 0)
/* already found a reason to abort */; goto out; /* already found a reason to abort */
else if (ns.role == R_SECONDARY && device->open_cnt) else if (ns.role == R_SECONDARY && device->open_cnt)
rv = SS_DEVICE_IN_USE; rv = SS_DEVICE_IN_USE;
...@@ -862,6 +862,7 @@ is_valid_state(struct drbd_device *device, union drbd_state ns) ...@@ -862,6 +862,7 @@ is_valid_state(struct drbd_device *device, union drbd_state ns)
else if (ns.conn >= C_CONNECTED && ns.pdsk == D_UNKNOWN) else if (ns.conn >= C_CONNECTED && ns.pdsk == D_UNKNOWN)
rv = SS_CONNECTED_OUTDATES; rv = SS_CONNECTED_OUTDATES;
out:
rcu_read_unlock(); rcu_read_unlock();
return rv; return rv;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment