lkml.org 
[lkml]   [2011]   [Oct]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[PATCH 3/5] virtio-blk: remove the unused list of pending requests
    Signed-off-by: Christoph Hellwig <hch@lst.de>

    Index: linux-2.6/drivers/block/virtio_blk.c
    ===================================================================
    --- linux-2.6.orig/drivers/block/virtio_blk.c 2011-10-03 19:55:29.061215040 +0200
    +++ linux-2.6/drivers/block/virtio_blk.c 2011-10-03 19:55:54.196412176 +0200
    @@ -24,9 +24,6 @@ struct virtio_blk
    /* The disk structure for the kernel. */
    struct gendisk *disk;

    - /* Request tracking. */
    - struct list_head reqs;
    -
    mempool_t *pool;

    /* Process context for config space updates */
    @@ -41,7 +38,6 @@ struct virtio_blk

    struct virtblk_req
    {
    - struct list_head list;
    struct request *req;
    struct virtio_blk_outhdr out_hdr;
    struct virtio_scsi_inhdr in_hdr;
    @@ -85,7 +81,6 @@ static void blk_done(struct virtqueue *v
    }

    __blk_end_request_all(vbr->req, error);
    - list_del(&vbr->list);
    mempool_free(vbr, vblk->pool);
    }
    /* In case queue is stopped waiting for more buffers. */
    @@ -170,7 +165,6 @@ static bool do_req(struct request_queue
    return false;
    }

    - list_add_tail(&vbr->list, &vblk->reqs);
    return true;
    }

    @@ -368,7 +362,6 @@ static int __devinit virtblk_probe(struc
    goto out;
    }

    - INIT_LIST_HEAD(&vblk->reqs);
    spin_lock_init(&vblk->lock);
    vblk->vdev = vdev;
    vblk->sg_elems = sg_elems;
    @@ -526,9 +519,6 @@ static void __devexit virtblk_remove(str

    flush_work(&vblk->config_work);

    - /* Nothing should be pending. */
    - BUG_ON(!list_empty(&vblk->reqs));
    -
    /* Stop all the virtqueues. */
    vdev->config->reset(vdev);



    \
     
     \ /
      Last update: 2011-10-05 21:57    [W:0.022 / U:1.340 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site