Skip to contentSkip to conversation

Remove unused variable in axon_ram_make_request()

PATCH New Zhaolei 1 participant 1 message Jul 14, 2009 1 message not in the archive PowerPC

lore
Share & tools
lore

Zhaolei

author
#1 lore raw

PATCH 1/1 Remove unused variable in axon_ram_make_request()

In reply to a message not in the archive

Variable named "transfered" is not used in this function, we should remove it.

---
arch/powerpc/sysdev/axonram.c | 3 ---

1 files changed, 0 insertions(+), 3 deletions(-)
arch/powerpc/sysdev/axonram.c +0 -3
index a477991..29a8bbf 100644
@@ -111,13 +111,11 @@ axon_ram_make_request(struct request_queue *queue, struct bio *bio)
    unsigned long phys_mem, phys_end;
    void *user_mem;
    struct bio_vec *vec;
-    unsigned int transfered;
    unsigned short idx;
    int rc = 0;
 
    phys_mem = bank->io_addr + (bio->bi_sector << AXON_RAM_SECTOR_SHIFT);
    phys_end = bank->io_addr + bank->size;
-    transfered = 0;
    bio_for_each_segment(vec, bio, idx) {
        if (unlikely(phys_mem + vec->bv_len > phys_end)) {
            bio_io_error(bio);
@@ -132,7 +130,6 @@ axon_ram_make_request(struct request_queue *queue, struct bio *bio)
            memcpy((void *) phys_mem, user_mem, vec->bv_len);
 
        phys_mem += vec->bv_len;
-        transfered += vec->bv_len;
    }
    bio_endio(bio, 0);
 
Signature · 1 line
1.5.5.3