projects
/
platform
/
kernel
/
kernel-mfld-blackbay.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5e18cfd
)
loop: don't increment p->offset with (size_t) -EINVAL
author
Roel Kluin
<roel.kluin@gmail.com>
Thu, 5 Mar 2009 07:03:53 +0000
(08:03 +0100)
committer
Jens Axboe
<jens.axboe@oracle.com>
Thu, 5 Mar 2009 11:04:57 +0000
(12:04 +0100)
Upon a 'transfer error block' size is set to -EINVAL, but this becomes positive
since size is unsigned: p->offset still gets incremented.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
drivers/block/loop.c
patch
|
blob
|
history
diff --git
a/drivers/block/loop.c
b/drivers/block/loop.c
index
edbaac6
..
bf03455
100644
(file)
--- a/
drivers/block/loop.c
+++ b/
drivers/block/loop.c
@@
-392,8
+392,7
@@
lo_splice_actor(struct pipe_inode_info *pipe, struct pipe_buffer *buf,
struct loop_device *lo = p->lo;
struct page *page = buf->page;
sector_t IV;
- size_t size;
- int ret;
+ int size, ret;
ret = buf->ops->confirm(pipe, buf);
if (unlikely(ret))