Skip to content

Commit

Permalink
s390/qdio: remove checks for ccw device internal state
Browse files Browse the repository at this point in the history
Prior to starting IO qdio checks for the internal state of the ccw
device. These checks happen without locking, so consistency between
state evaluation and starting of the IO is not guaranteed.

Since the internal state is checked during ccw_device_start it is
safe to get rid of these additional checks.

Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
  • Loading branch information
Sebastian Ott authored and Martin Schwidefsky committed Aug 8, 2016
1 parent ddebf66 commit 6e30c54
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions drivers/s390/cio/qdio_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1352,9 +1352,6 @@ int qdio_establish(struct qdio_initialize *init_data)
if (!irq_ptr)
return -ENODEV;

if (cdev->private->state != DEV_STATE_ONLINE)
return -EINVAL;

mutex_lock(&irq_ptr->setup_mutex);
qdio_setup_irq(init_data);

Expand Down Expand Up @@ -1425,9 +1422,6 @@ int qdio_activate(struct ccw_device *cdev)
if (!irq_ptr)
return -ENODEV;

if (cdev->private->state != DEV_STATE_ONLINE)
return -EINVAL;

mutex_lock(&irq_ptr->setup_mutex);
if (irq_ptr->state == QDIO_IRQ_STATE_INACTIVE) {
rc = -EBUSY;
Expand Down

0 comments on commit 6e30c54

Please sign in to comment.