27 Oct, 2008

2 commits

  • In commit f337b9c58332bdecde965b436e47ea4c94d30da0 ("epoll: drop
    unnecessary test") Thomas found that there is an unnecessary (always
    true) test in ep_send_events(). The callback never inserts into
    ->rdllink while the send loop is performed, and also does the
    ~EP_PRIVATE_BITS test. Given we're holding the mutex during this time,
    the conditions tested inside the loop are always true.

    HOWEVER.

    The test "!ep_is_linked(&epi->rdllink)" wasn't there because we insert
    into ->rdllink, but because the send-events loop might terminate before
    the whole list is scanned (-EFAULT).

    In such cases, when the loop terminates early, and when a (leftover)
    file received an event while we're performing the lockless loop, we need
    such test to avoid to double insert the epoll items. The list_splice()
    done a few steps below, will correctly re-insert the ones that were left
    on "txlist".

    This should fix the kenrel.org bugzilla entry 11831.

    Signed-off-by: Davide Libenzi
    Signed-off-by: Linus Torvalds

    Davide Libenzi
     
  • Some userland apps seem to pass in a "0" for the seconds, and several
    seconds worth of usecs to select(). The old kernels accepted this just
    fine, so the new kernels must too.

    However, due to the upscaling of the microseconds to nanoseconds we had
    some cases where we got math overflow, and depending on the GCC version
    (due to inlining decisions) that actually resulted in an -EINVAL return.

    This patch fixes this by adding the excess microseconds to the seconds
    field.

    Also with thanks to Marcin Slusarz for spotting some implementation bugs
    in the diagnostics patches.

    Reported-by: Carlos R. Mafra
    Signed-off-by: Arjan van de Ven
    Signed-off-by: Linus Torvalds

    Arjan van de Ven
     

26 Oct, 2008

2 commits

  • Fix a regression caused by commit d0156417, "ext4: fix ext4_dx_readdir
    hash collision handling", where deleting files in a large directory
    (requiring more than one getdents system call), results in some
    filenames being returned twice. This was caused by a failure to
    update info->curr_hash and info->curr_minor_hash, so that if the
    directory had gotten modified since the last getdents() system call
    (as would be the case if the user is running "rm -r" or "git clean"),
    a directory entry would get returned twice to the userspace.

    Signed-off-by: "Theodore Ts'o"

    This patch fixes the bug reported by Markus Trippelsdorf at:
    http://bugzilla.kernel.org/show_bug.cgi?id=11844

    Signed-off-by: "Theodore Ts'o"
    Tested-by: Markus Trippelsdorf

    Theodore Ts'o
     
  • Fix a regression caused by commit 6a897cf4, "ext3: fix ext3_dx_readdir
    hash collision handling", where deleting files in a large directory
    (requiring more than one getdents system call), results in some
    filenames being returned twice. This was caused by a failure to
    update info->curr_hash and info->curr_minor_hash, so that if the
    directory had gotten modified since the last getdents() system call
    (as would be the case if the user is running "rm -r" or "git clean"),
    a directory entry would get returned twice to the userspace.

    This patch fixes the bug reported by Markus Trippelsdorf at:
    http://bugzilla.kernel.org/show_bug.cgi?id=11844

    Signed-off-by: "Theodore Ts'o"
    Tested-by: Markus Trippelsdorf

    Theodore Ts'o
     

24 Oct, 2008

9 commits

  • * 'proc' of git://git.kernel.org/pub/scm/linux/kernel/git/adobriyan/proc: (35 commits)
    proc: remove fs/proc/proc_misc.c
    proc: move /proc/vmcore creation to fs/proc/vmcore.c
    proc: move pagecount stuff to fs/proc/page.c
    proc: move all /proc/kcore stuff to fs/proc/kcore.c
    proc: move /proc/schedstat boilerplate to kernel/sched_stats.h
    proc: move /proc/modules boilerplate to kernel/module.c
    proc: move /proc/diskstats boilerplate to block/genhd.c
    proc: move /proc/zoneinfo boilerplate to mm/vmstat.c
    proc: move /proc/vmstat boilerplate to mm/vmstat.c
    proc: move /proc/pagetypeinfo boilerplate to mm/vmstat.c
    proc: move /proc/buddyinfo boilerplate to mm/vmstat.c
    proc: move /proc/vmallocinfo to mm/vmalloc.c
    proc: move /proc/slabinfo boilerplate to mm/slub.c, mm/slab.c
    proc: move /proc/slab_allocators boilerplate to mm/slab.c
    proc: move /proc/interrupts boilerplate code to fs/proc/interrupts.c
    proc: move /proc/stat to fs/proc/stat.c
    proc: move rest of /proc/partitions code to block/genhd.c
    proc: move /proc/cpuinfo code to fs/proc/cpuinfo.c
    proc: move /proc/devices code to fs/proc/devices.c
    proc: move rest of /proc/locks to fs/locks.c
    ...

    Linus Torvalds
     
  • Signed-off-by: Christoph Hellwig
    [ All users removed in "switch all filesystems over to d_obtain_alias",
    aka commit 440037287c5ebb07033ab927ca16bb68c291d309 ]
    Signed-off-by: Linus Torvalds

    Christoph Hellwig
     
  • This one was due to a merge error: we added a use of nd.path in commit
    2d7c820e56ce83b23daee9eb5343730fb309418e ("ext3: add checks for errors
    from jbd"), and concurrently we got rid of 'nd' and used a naked 'path'
    in commit 8264613def2e5c4f12bc3167713090fd172e6055 ("[PATCH] switch
    quota_on-related stuff to kern_path()").

    That all merged cleanly, but it didn't actually _work_. This should fix
    it.

    Signed-off-by: Linus Torvalds

    Linus Torvalds
     
  • …inux/kernel/git/tip/linux-2.6-tip

    * 'v28-range-hrtimers-for-linus-v2' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (37 commits)
    hrtimers: add missing docbook comments to struct hrtimer
    hrtimers: simplify hrtimer_peek_ahead_timers()
    hrtimers: fix docbook comments
    DECLARE_PER_CPU needs linux/percpu.h
    hrtimers: fix typo
    rangetimers: fix the bug reported by Ingo for real
    rangetimer: fix BUG_ON reported by Ingo
    rangetimer: fix x86 build failure for the !HRTIMERS case
    select: fix alpha OSF wrapper
    select: fix alpha OSF wrapper
    hrtimer: peek at the timer queue just before going idle
    hrtimer: make the futex() system call use the per process slack value
    hrtimer: make the nanosleep() syscall use the per process slack
    hrtimer: fix signed/unsigned bug in slack estimator
    hrtimer: show the timer ranges in /proc/timer_list
    hrtimer: incorporate feedback from Peter Zijlstra
    hrtimer: add a hrtimer_start_range() function
    hrtimer: another build fix
    hrtimer: fix build bug found by Ingo
    hrtimer: make select() and poll() use the hrtimer range feature
    ...

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/sfrench/cifs-2.6:
    cifs: handle the TCP_Server_Info->tsk field more carefully
    cifs: fix unlinking of rename target when server doesn't support open file renames
    [CIFS] improve setlease handling
    [CIFS] fix saving of resume key before CIFSFindNext
    cifs: make cifs_rename handle -EACCES errors
    [CIFS] fix build error
    [CIFS] undo changes in cifs_rename_pending_delete if it errors out
    cifs: track DeletePending flag in cifsInodeInfo
    cifs: don't use CREATE_DELETE_ON_CLOSE in cifs_rename_pending_delete
    [CIFS] eliminate usage of kthread_stop for cifsd
    [CIFS] Add nodfs mount option

    Linus Torvalds
     
  • * git://git.kernel.org/pub/scm/linux/kernel/git/viro/bdev: (66 commits)
    [PATCH] kill the rest of struct file propagation in block ioctls
    [PATCH] get rid of struct file use in blkdev_ioctl() BLKBSZSET
    [PATCH] get rid of blkdev_locked_ioctl()
    [PATCH] get rid of blkdev_driver_ioctl()
    [PATCH] sanitize blkdev_get() and friends
    [PATCH] remember mode of reiserfs journal
    [PATCH] propagate mode through swsusp_close()
    [PATCH] propagate mode through open_bdev_excl/close_bdev_excl
    [PATCH] pass fmode_t to blkdev_put()
    [PATCH] kill the unused bsize on the send side of /dev/loop
    [PATCH] trim file propagation in block/compat_ioctl.c
    [PATCH] end of methods switch: remove the old ones
    [PATCH] switch sr
    [PATCH] switch sd
    [PATCH] switch ide-scsi
    [PATCH] switch tape_block
    [PATCH] switch dcssblk
    [PATCH] switch dasd
    [PATCH] switch mtd_blkdevs
    [PATCH] switch mmc
    ...

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6: (46 commits)
    [PATCH] fs: add a sanity check in d_free
    [PATCH] i_version: remount support
    [patch] vfs: make security_inode_setattr() calling consistent
    [patch 1/3] FS_MBCACHE: don't needlessly make it built-in
    [PATCH] move executable checking into ->permission()
    [PATCH] fs/dcache.c: update comment of d_validate()
    [RFC PATCH] touch_mnt_namespace when the mount flags change
    [PATCH] reiserfs: add missing llseek method
    [PATCH] fix ->llseek for more directories
    [PATCH vfs-2.6 6/6] vfs: add LOOKUP_RENAME_TARGET intent
    [PATCH vfs-2.6 5/6] vfs: remove LOOKUP_PARENT from non LOOKUP_PARENT lookup
    [PATCH vfs-2.6 4/6] vfs: remove unnecessary fsnotify_d_instantiate()
    [PATCH vfs-2.6 3/6] vfs: add __d_instantiate() helper
    [PATCH vfs-2.6 2/6] vfs: add d_ancestor()
    [PATCH vfs-2.6 1/6] vfs: replace parent == dentry->d_parent by IS_ROOT()
    [PATCH] get rid of on-stack dentry in udf
    [PATCH 2/2] anondev: switch to IDA
    [PATCH 1/2] anondev: init IDR statically
    [JFFS2] Use d_splice_alias() not d_add() in jffs2_lookup()
    [PATCH] Optimise NFS readdir hack slightly.
    ...

    Linus Torvalds
     
  • * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ericvh/v9fs:
    9p: fix sparse warnings
    9p: rdma: RDMA Transport Support for 9P
    9p: fix format warning
    9p: fix debug build error

    Linus Torvalds
     
  • * 'for-2.6.28' of git://linux-nfs.org/~bfields/linux:
    nfsd: clean up expkey_parse error cases
    nfsd: Drop reference in expkey_parse error cases
    nfsd: Fix memory leak in nfsd_getxattr
    NFSD: Fix BUG during NFSD shutdown processing

    Linus Torvalds
     

23 Oct, 2008

27 commits