Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=436d1bc7fe6e78e37fe5f5022ea4d5c133d825eb
Commit:     436d1bc7fe6e78e37fe5f5022ea4d5c133d825eb
Parent:     671756162cfb0b3ccbb6a0047baa3010885561a2
Author:     Christian Borntraeger <[EMAIL PROTECTED]>
AuthorDate: Tue Dec 4 16:09:03 2007 +0100
Committer:  Martin Schwidefsky <[EMAIL PROTECTED]>
CommitDate: Tue Dec 4 16:09:57 2007 +0100

    [S390] dcssblk: prevent early access without own make_request function
    
    When loading a dcss segment with the dcssblk driver, sometimes the
    following kind of message appears:
    
    bio too big device dcssblk0 (8 > 0)
    Buffer I/O error on device dcssblk0, logical block 172016
    ..
    
    The fix is to move the disk registration after setting the
    make_request function, to avoid calls into generic_make_request
    for dcssblock without having the make_request function set up
    properly.
    
    Cc: Gerald Schaefer <[EMAIL PROTECTED]>
    Signed-off-by: Christian Borntraeger <[EMAIL PROTECTED]>
    Signed-off-by: Martin Schwidefsky <[EMAIL PROTECTED]>
---
 drivers/s390/block/dcssblk.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/s390/block/dcssblk.c b/drivers/s390/block/dcssblk.c
index 5e083d1..15a5789 100644
--- a/drivers/s390/block/dcssblk.c
+++ b/drivers/s390/block/dcssblk.c
@@ -472,11 +472,11 @@ dcssblk_add_store(struct device *dev, struct 
device_attribute *attr, const char
        if (rc)
                goto unregister_dev;
 
-       add_disk(dev_info->gd);
-
        blk_queue_make_request(dev_info->dcssblk_queue, dcssblk_make_request);
        blk_queue_hardsect_size(dev_info->dcssblk_queue, 4096);
 
+       add_disk(dev_info->gd);
+
        switch (dev_info->segment_type) {
                case SEG_TYPE_SR:
                case SEG_TYPE_ER:
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to