search for: tcm_vhost_inc_inflight

Displaying 4 results from an estimated 4 matches for "tcm_vhost_inc_inflight".

Did you mean: tcm_vhost_dec_inflight
2013 Mar 11
4
[PATCH] tcm_vhost: Wait for pending requests in vhost_scsi_flush()
...) +{ + /* + * Wakeup the waiter when all the requests issued before the flush + * operation are finished and we are during the flush operation. + */ + if (inflight && !atomic_dec_return(&inflight->count)) + wake_up(&inflight->wait); +} + +static struct vhost_scsi_inflight *tcm_vhost_inc_inflight(struct vhost_scsi *vs) +{ + struct vhost_scsi_inflight *inflight = ACCESS_ONCE(vs->vs_inflight); + /* FIXME: possible race window here, if inflight points to old value + * before we set the new value in _flush, and the wait_event() runs + * before we call atomic_inc(), this way we may free old...
2013 Mar 11
4
[PATCH] tcm_vhost: Wait for pending requests in vhost_scsi_flush()
...) +{ + /* + * Wakeup the waiter when all the requests issued before the flush + * operation are finished and we are during the flush operation. + */ + if (inflight && !atomic_dec_return(&inflight->count)) + wake_up(&inflight->wait); +} + +static struct vhost_scsi_inflight *tcm_vhost_inc_inflight(struct vhost_scsi *vs) +{ + struct vhost_scsi_inflight *inflight = ACCESS_ONCE(vs->vs_inflight); + /* FIXME: possible race window here, if inflight points to old value + * before we set the new value in _flush, and the wait_event() runs + * before we call atomic_inc(), this way we may free old...
2013 Mar 22
4
[PATCH V2 0/3] tcm_vhost pending requests flush
Changes in v2: - Increase/Decrease inflight requests in vhost_scsi_{allocate,free}_cmd and tcm_vhost_{allocate,free}_evt Asias He (3): tcm_vhost: Wait for pending requests in vhost_scsi_flush() tcm_vhost: Wait for pending requests in vhost_scsi_clear_endpoint() tcm_vhost: Fix tv_cmd leak in vhost_scsi_handle_vq drivers/vhost/tcm_vhost.c | 131
2013 Mar 22
4
[PATCH V2 0/3] tcm_vhost pending requests flush
Changes in v2: - Increase/Decrease inflight requests in vhost_scsi_{allocate,free}_cmd and tcm_vhost_{allocate,free}_evt Asias He (3): tcm_vhost: Wait for pending requests in vhost_scsi_flush() tcm_vhost: Wait for pending requests in vhost_scsi_clear_endpoint() tcm_vhost: Fix tv_cmd leak in vhost_scsi_handle_vq drivers/vhost/tcm_vhost.c | 131