1. 23 7月, 2009 2 次提交
    • J
      cifs: fix sb->s_maxbytes so that it casts properly to a signed value · 03aa3a49
      Jeff Layton 提交于
      This off-by-one bug causes sendfile() to not work properly. When a task
      calls sendfile() on a file on a CIFS filesystem, the syscall returns -1
      and sets errno to EOVERFLOW.
      
      do_sendfile uses s_maxbytes to verify the returned offset of the file.
      The problem there is that this value is cast to a signed value (loff_t).
      When this is done on the s_maxbytes value that cifs uses, it becomes
      negative and the comparisons against it fail.
      
      Even though s_maxbytes is an unsigned value, it seems that it's not OK
      to set it in such a way that it'll end up negative when it's cast to a
      signed value. These casts happen in other codepaths besides sendfile
      too, but the VFS is a little hard to follow in this area and I can't
      be sure if there are other bugs that this will fix.
      
      It's not clear to me why s_maxbytes isn't just declared as loff_t in the
      first place, but either way we still need to fix these values to make
      sendfile work properly. This is also an opportunity to replace the magic
      bit-shift values here with the standard #defines for this.
      
      This fixes the reproducer program I have that does a sendfile and
      will probably also fix the situation where apache is serving from a
      CIFS share.
      Acked-by: NJohannes Weiner <hannes@cmpxchg.org>
      Signed-off-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NSteve French <sfrench@us.ibm.com>
      03aa3a49
    • J
      cifs: disable serverino if server doesn't support it · ce6e7fcd
      Jeff Layton 提交于
      A recent regression when dealing with older servers. This bug was
      introduced when we made serverino the default...
      
      When the server can't provide inode numbers, disable it for the mount.
      Signed-off-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NSteve French <sfrench@us.ibm.com>
      ce6e7fcd
  2. 21 7月, 2009 10 次提交
  3. 19 7月, 2009 2 次提交
    • L
      Merge master.kernel.org:/home/rmk/linux-2.6-arm · a7571a5c
      Linus Torvalds 提交于
      * master.kernel.org:/home/rmk/linux-2.6-arm:
        ARM: Realview & Versatile: Fix i2c_board_info definitions
        [ARM] 5608/1: Updated U300 defconfig
        [ARM] 5606/1: Fix ep93xx watchdog driver headers
        [ARM] 5594/1: Correct U300 VIC init PM setting
        [ARM] 5595/1: ep93xx: missing header in dma-m2p.c
        [ARM] Kirkwood: Correct header define
        [ARM] pxa: fix ULPI_{DIR,NXT,STP} MFP defines
        backlight: fix pwm_bl.c to notify platform code when suspending
        [ARM] pxa: use kzalloc() in pxa_init_gpio_chip()
        [ARM] pxa: correct I2CPWR clock for pxa3xx
        pxamci: correct DMA flow control
        ARM: add support for the EET board, based on the i.MX31 pcm037 module
        pcm037: add MT9T031 camera support
        Armadillo 500 add NAND flash device support (resend).
        ARM MXC: Armadillo 500 add NOR flash device support (resend).
        mx31: remove duplicated #include
      a7571a5c
    • R
      ARM: Realview & Versatile: Fix i2c_board_info definitions · 64e8be6e
      Russell King 提交于
      Fix i2c_board_info definitions - we were defining the 'type' field
      of these structures twice since the first argument of I2C_BOARD_INFO
      sets this field.  Move the second definition into I2C_BOARD_INFO().
      Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
      Acked-by: NJean Delvare <khali@linux-fr.org>
      Acked-by: NBen Dooks <ben-linux@fluff.org>
      64e8be6e
  4. 18 7月, 2009 8 次提交
  5. 17 7月, 2009 18 次提交