1. 02 Sep, 2008 18 commits
  2. 01 Sep, 2008 6 commits
    • J. Bruce Fields's avatar
      nfsd: fix buffer overrun decoding NFSv4 acl · 91b80969
      J. Bruce Fields authored
      The array we kmalloc() here is not large enough.
      
      Thanks to Johann Dahm and David Richter for bug report and testing.
      Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
      Cc: David Richter <richterd@citi.umich.edu>
      Tested-by: default avatarJohann Dahm <jdahm@umich.edu>
      91b80969
    • Cyrill Gorcunov's avatar
      sunrpc: fix possible overrun on read of /proc/sys/sunrpc/transports · 27df6f25
      Cyrill Gorcunov authored
      Vegard Nossum reported
      ----------------------
      > I noticed that something weird is going on with /proc/sys/sunrpc/transports.
      > This file is generated in net/sunrpc/sysctl.c, function proc_do_xprt(). When
      > I "cat" this file, I get the expected output:
      >    $ cat /proc/sys/sunrpc/transports
      >    tcp 1048576
      >    udp 32768
      
      > But I think that it does not check the length of the buffer supplied by
      > userspace to read(). With my original program, I found that the stack was
      > being overwritten by the characters above, even when the length given to
      > read() was just 1.
      
      David Wagner added (among other things) that copy_to_user could be
      probably used here.
      
      Ingo Oeser suggested to use simple_read_from_buffer() here.
      
      The conclusion is that proc_do_xprt doesn't check for userside buffer
      size indeed so fix this by using Ingo's suggestion.
      Reported-by: default avatarVegard Nossum <vegard.nossum@gmail.com>
      Signed-off-by: default avatarCyrill Gorcunov <gorcunov@gmail.com>
      CC: Ingo Oeser <ioe-lkml@rameria.de>
      Cc: Neil Brown <neilb@suse.de>
      Cc: Chuck Lever <chuck.lever@oracle.com>
      Cc: Greg Banks <gnb@sgi.com>
      Cc: Tom Tucker <tom@opengridcomputing.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
      27df6f25
    • Andy Adamson's avatar
      nfsd: fix compound state allocation error handling · c228c24b
      Andy Adamson authored
      Move the cstate_alloc call so that if it fails, the response is setup to
      encode the NFS error. The out label now means that the
      nfsd4_compound_state has not been allocated.
      Signed-off-by: default avatarAndy Adamson <andros@netapp.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
      c228c24b
    • Tejun Heo's avatar
      block: restore original behavior of /proc/partition when there's no partition · ddef43a8
      Tejun Heo authored
      /proc/partitions didn't use to write out the header if there was no
      partition.  However, recent commit 66c64afe changed the behavior.
      This is nothing major but there's no reason to change user visible
      behavior without a good rationale.  Restore the original behavior.
      
      Note that 2.6.28 has clean up changes scheduled which will replace
      this rather hacky implementation.
      Signed-off-by: default avatarTejun Heo <tj@kernel.org>
      Cc: Greg KH <greg@kroah.com>
      Cc: Kay Sievers <kay.sievers@vrfy.org>
      Signed-off-by: default avatarJens Axboe <jens.axboe@oracle.com>
      ddef43a8
    • NeilBrown's avatar
      Fix problem with waiting while holding rcu read lock in md/bitmap.c · b2d2c4ce
      NeilBrown authored
      A recent patch to protect the rdev list with rcu locking leaves us
      with a problem because we can sleep on memalloc while holding the
      rcu lock.
      
      The rcu lock is only needed while walking the linked list as
      uninteresting devices (failed or spares) can be removed at any time.
      
      So only take the rcu lock while actually walking the linked list.
      Take a refcount on the rdev during the time when we drop the lock
      and do the memalloc to start IO.
      When we return to the locked code, all the interesting devices
      on the list will not have moved, so we can simply use
      list_for_each_continue_rcu to pick up where we left off.
      Signed-off-by: default avatarNeilBrown <neilb@suse.de>
      b2d2c4ce
    • NeilBrown's avatar
      Remove invalidate_partition call from do_md_stop. · 271f5a9b
      NeilBrown authored
      When stopping an md array, or just switching to read-only, we
      currently call invalidate_partition while holding the mddev lock.
      The main reason for this is probably to ensure all dirty buffers
      are flushed (invalidate_partition calls fsync_bdev).
      
      However if any dirty buffers are found, it will almost certainly cause
      a deadlock as starting writeout will require an update to the
      superblock, and performing that updates requires taking the mddev
      lock - which is already held.
      
      This deadlock can be demonstrated by running "reboot -f -n" with
      a root filesystem on md/raid, and some dirty buffers in memory.
      
      All other calls to stop an array should already happen after a flush.
      The normal sequence is to stop using the array (e.g. umount) which
      will cause __blkdev_put to call sync_blockdev.  Then open the
      array and issue the STOP_ARRAY ioctl while the buffers are all still
      clean.
      
      So this invalidate_partition is normally a no-op, except for one case
      where it will cause a deadlock.
      
      So remove it.
      
      This patch possibly addresses the regression recored in
         http://bugzilla.kernel.org/show_bug.cgi?id=11460
      and
         http://bugzilla.kernel.org/show_bug.cgi?id=11452
      
      though it isn't yet clear how it ever worked.
      Signed-off-by: default avatarNeilBrown <neilb@suse.de>
      271f5a9b
  3. 31 Aug, 2008 1 commit
  4. 30 Aug, 2008 2 commits
  5. 29 Aug, 2008 6 commits
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6 · 00aeb429
      Linus Torvalds authored
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6:
        ALSA: oxygen: fix distorted output on AK4396-based cards
        Revert "ALSA: hda - Added model selection for iMac 24""
      00aeb429
    • Andi Kleen's avatar
      Don't trigger softlockup detector on network fs blocked tasks · 316d9679
      Andi Kleen authored
      Pulling the ethernet cable on a 2.6.27-rc system with NFS mounts
      currently leads to an ongoing flood of soft lockup detector backtraces
      for all tasks blocked on the NFS mounts when the hickup takes
      longer than 120s.
      
      I don't think NFS problems should be all that noisy.
      
      Luckily there's a reasonably easy way to distingush this case.
      
      Don't report task softlockup warnings for tasks in TASK_KILLABLE
      state, which is used by the network file systems.
      
      I believe this patch is a 2.6.27 candidate.
      Signed-off-by: default avatarAndi Kleen <ak@linux.intel.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      316d9679
    • Linus Torvalds's avatar
      Revert "x86: fix HPET regression in 2.6.26 versus 2.6.25, check hpet against BAR, v3" · b4609472
      Linus Torvalds authored
      This reverts commit a2bd7274.
      
      It wasn't really right to begin with (there's a better fix for the
      problem with e820 reservations clashing with PCI BAR's pending), but it
      also actually causes more regressions, so it should be reverted even
      before the better fix is finalized.
      
      Rafael reports that this commit broke AHCI detection, and thus causes
      the kernel to not boot on his quad core test box.
      Reported-and-bisected-by: default avatarRafael J. Wysocki <rjw@sisk.pl>
      Cc: Yinghai Lu <yhlu.kernel@gmail.com>
      Cc: David Witbrodt <dawitbro@sbcglobal.net>
      Cc: Ingo Molnar <mingo@elte.hu>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      b4609472
    • Clemens Ladisch's avatar
      ALSA: oxygen: fix distorted output on AK4396-based cards · df91bc23
      Clemens Ladisch authored
      When changing the sample rate, the CMI8788's master clock output becomes
      unstable for a short time.  The AK4396 needs the master clock to do SPI
      writes, so writing to an AK4396 control register directly after a sample
      rate change will garble the value.  In our case, this leads to the DACs
      being misconfigured to I2S sample format, which results in a wrong
      output level and horrible distortions on samples louder than -6 dB.
      
      To fix this, we need to wait until the new master clock signal has
      become stable before doing SPI writes.
      Signed-off-by: default avatarClemens Ladisch <clemens@ladisch.de>
      Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
      df91bc23
    • FUJITA Tomonori's avatar
      remove blk_register_filter and blk_unregister_filter in gendisk · bb23b431
      FUJITA Tomonori authored
      This patch remove blk_register_filter and blk_unregister_filter in
      gendisk, and adds them to sd.c, sr.c. and ide-cd.c
      
      The commit abf54393 moved cmdfilter
      from gendisk to request_queue. It turned out that in some subsystems
      multiple gendisks share a single request_queue. So we get:
      
      Using physmap partition information
      Creating 3 MTD partitions on "physmap-flash":
      0x00000000-0x01c00000 : "User FS"
      0x01c00000-0x01c40000 : "booter"
      kobject (8511c410): tried to init an initialized object, something is seriously wrong.
      Call Trace:
      [<8036644c>] dump_stack+0x8/0x34
      [<8021f050>] kobject_init+0x50/0xcc
      [<8021fa18>] kobject_init_and_add+0x24/0x58
      [<8021d20c>] blk_register_filter+0x4c/0x64
      [<8021c194>] add_disk+0x78/0xe0
      [<8027d14c>] add_mtd_blktrans_dev+0x254/0x278
      [<8027c8f0>] blktrans_notify_add+0x40/0x78
      [<80279c00>] add_mtd_device+0xd0/0x150
      [<8027b090>] add_mtd_partitions+0x568/0x5d8
      [<80285458>] physmap_flash_probe+0x2ac/0x334
      [<802644f8>] driver_probe_device+0x12c/0x244
      [<8026465c>] __driver_attach+0x4c/0x84
      [<80263c64>] bus_for_each_dev+0x58/0xac
      [<802633ec>] bus_add_driver+0xc4/0x24c
      [<802648e0>] driver_register+0xcc/0x184
      [<80100460>] _stext+0x60/0x1bc
      
      In the long term, we need to fix such subsystems but we need a quick
      fix now. This patch add the command filter support to only sd and sr
      though it might be useful for other SG_IO users (such as cciss).
      Signed-off-by: default avatarFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
      Reported-by: default avatarManuel Lauss <mano@roarinelk.homelinux.net>
      Signed-off-by: default avatarJens Axboe <jens.axboe@oracle.com>
      bb23b431
    • David S. Miller's avatar
      sparc: Fix resource flags for PCI children in OF device tree. · e3c71a32
      David S. Miller authored
      When a device is under an EBUS or ISA bus, the resource flags
      don't get set properly.
      
      Fix this by re-evaluating the resource flags at each level of
      bus as we apply ranges on the way to the root.  And let PCI
      override any existing flags setting, but don't let the
      default flags calculator make such overrides.
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e3c71a32
  6. 28 Aug, 2008 7 commits