lkml.org 
[lkml]   [1999]   [Dec]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    On Sun, 19 Dec 1999, Linus Torvalds wrote:

    > Anybody willing to fix this up properly? Ben?

    This should do the trick. It's reading my isofs disc at the >4gb mark,
    and uses 32 bit operations for just about everything.

    -ben

    Only in 2.3.34-2/fs/isofs/: .depend
    Only in 2.3.34-2/fs/isofs/: .dir.o.flags
    Only in 2.3.34-2/fs/isofs/: .file.o.flags
    Only in 2.3.34-2/fs/isofs/: .inode.o.flags
    Only in 2.3.34-2/fs/isofs/: .isofs.o.flags
    Only in 2.3.34-2/fs/isofs/: .namei.o.flags
    Only in 2.3.34-2/fs/isofs/: .rock.o.flags
    Only in 2.3.34-2/fs/isofs/: .symlink.o.flags
    Only in 2.3.34-2/fs/isofs/: .util.o.flags
    Only in 2.3.34-2/fs/isofs/: dir.o
    Only in 2.3.34-2/fs/isofs/: file.o
    diff -u clean/2.3.34-2/fs/isofs/inode.c 2.3.34-2/fs/isofs/inode.c
    --- clean/2.3.34-2/fs/isofs/inode.c Fri Nov 12 16:21:09 1999
    +++ 2.3.34-2/fs/isofs/inode.c Mon Dec 20 11:05:10 1999
    @@ -927,7 +927,8 @@
    int isofs_get_block(struct inode *inode, long iblock,
    struct buffer_head *bh_result, int create)
    {
    - off_t b_off, offset, sect_size;
    + unsigned long b_off;
    + unsigned offset, sect_size;
    unsigned int firstext;
    unsigned long nextino;
    int i, err;
    @@ -942,30 +943,21 @@
    if (iblock < 0)
    goto abort_negative;

    - b_off = iblock << ISOFS_BUFFER_BITS(inode);
    + b_off = iblock;

    - /* If we are beyond the end of this file, don't give out any
    - * blocks.
    + /* If we are *way* beyond the end of the file, print a message.
    + * Access beyond the end of the file up to the next page boundary
    + * is normal, however because of the way the page cache works.
    + * In this case, we just return 0 so that we can properly fill
    + * the page with useless information without generating any
    + * I/O errors.
    */
    - if (b_off > inode->i_size) {
    - off_t max_legal_read_offset;
    -
    - /* If we are *way* beyond the end of the file, print a message.
    - * Access beyond the end of the file up to the next page boundary
    - * is normal, however because of the way the page cache works.
    - * In this case, we just return 0 so that we can properly fill
    - * the page with useless information without generating any
    - * I/O errors.
    - */
    - max_legal_read_offset = (inode->i_size + PAGE_SIZE - 1)
    - & ~(PAGE_SIZE - 1);
    - if (b_off >= max_legal_read_offset)
    - goto abort_beyond_end;
    - }
    + if (b_off > ((inode->i_size + PAGE_SIZE - 1) >> ISOFS_BUFFER_BITS(inode)))
    + goto abort_beyond_end;

    offset = 0;
    firstext = inode->u.isofs_i.i_first_extent;
    - sect_size = inode->u.isofs_i.i_section_size;
    + sect_size = inode->u.isofs_i.i_section_size >> ISOFS_BUFFER_BITS(inode);
    nextino = inode->u.isofs_i.i_next_section_ino;

    i = 0;
    @@ -990,8 +982,7 @@
    }

    bh_result->b_dev = inode->i_dev;
    - bh_result->b_blocknr = firstext +
    - ((b_off - offset) >> ISOFS_BUFFER_BITS(inode));
    + bh_result->b_blocknr = firstext + b_off - offset;
    bh_result->b_state |= (1UL << BH_Mapped);
    err = 0;

    Only in 2.3.34-2/fs/isofs/: inode.c.orig
    Only in 2.3.34-2/fs/isofs/: inode.o
    Only in 2.3.34-2/fs/isofs/: isofs.o
    Only in 2.3.34-2/fs/isofs/: namei.o
    Only in 2.3.34-2/fs/isofs/: rock.o
    Only in 2.3.34-2/fs/isofs/: symlink.o
    Only in 2.3.34-2/fs/isofs/: util.o


    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.rutgers.edu
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:55    [W:0.027 / U:121.740 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site