1. 08 Jul, 2011 10 commits
  2. 07 Jul, 2011 21 commits
  3. 06 Jul, 2011 9 commits
    • Dave Chinner's avatar
      xfs: unpin stale inodes directly in IOP_COMMITTED · 1316d4da
      Dave Chinner authored
      When inodes are marked stale in a transaction, they are treated
      specially when the inode log item is being inserted into the AIL.
      It tries to avoid moving the log item forward in the AIL due to a
      race condition with the writing the underlying buffer back to disk.
      The was "fixed" in commit de25c181 ("xfs: avoid moving stale inodes
      in the AIL").
      
      To avoid moving the item forward, we return a LSN smaller than the
      commit_lsn of the completing transaction, thereby trying to trick
      the commit code into not moving the inode forward at all. I'm not
      sure this ever worked as intended - it assumes the inode is already
      in the AIL, but I don't think the returned LSN would have been small
      enough to prevent moving the inode. It appears that the reason it
      worked is that the lower LSN of the inodes meant they were inserted
      into the AIL and flushed before the inode buffer (which was moved to
      the commit_lsn of the transaction).
      
      The big problem is that with delayed logging, the returning of the
      different LSN means insertion takes the slow, non-bulk path.  Worse
      yet is that insertion is to a position -before- the commit_lsn so it
      is doing a AIL traversal on every insertion, and has to walk over
      all the items that have already been inserted into the AIL. It's
      expensive.
      
      To compound the matter further, with delayed logging inodes are
      likely to go from clean to stale in a single checkpoint, which means
      they aren't even in the AIL at all when we come across them at AIL
      insertion time. Hence these were all getting inserted into the AIL
      when they simply do not need to be as inodes marked XFS_ISTALE are
      never written back.
      
      Transactional/recovery integrity is maintained in this case by the
      other items in the unlink transaction that were modified (e.g. the
      AGI btree blocks) and committed in the same checkpoint.
      
      So to fix this, simply unpin the stale inodes directly in
      xfs_inode_item_committed() and return -1 to indicate that the AIL
      insertion code does not need to do any further processing of these
      inodes.
      Signed-off-by: default avatarDave Chinner <dchinner@redhat.com>
      Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
      Signed-off-by: default avatarAlex Elder <aelder@sgi.com>
      1316d4da
    • Andrea Righi's avatar
      Documentation: fix cgroup blkio throttle filenames · 9b61fc4c
      Andrea Righi authored
      All the blkio.throttle.* file names are incorrectly reported without
      ".throttle" in the documentation. Fix it.
      Signed-off-by: default avatarAndrea Righi <andrea@betterlinux.com>
      Signed-off-by: default avatarRandy Dunlap <randy.dunlap@oracle.com>
      Acked-by: default avatarVivek Goyal <vgoyal@redhat.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      9b61fc4c
    • Jesper Juhl's avatar
      Documentation: update CodingStyle memory allocators · 316b3799
      Jesper Juhl authored
      The list of available general purpose memory allocators in
      Documentation/CodingStyle chapter 14 is incomplete. This patch adds
      the missing vzalloc() to the list.
      Signed-off-by: default avatarJesper Juhl <jj@chaosbits.net>
      Signed-off-by: default avatarRandy Dunlap <randy.dunlap@oracle.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      316b3799
    • Randy Dunlap's avatar
      MAINTAINERS: move kernel-doc patches location · 0dcb6d73
      Randy Dunlap authored
      Move location of quilt series for kernel-doc patches.
      Signed-off-by: default avatarRandy Dunlap <rdunlap@xenotime.net>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      0dcb6d73
    • Linus Torvalds's avatar
      Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6 · de3796e7
      Linus Torvalds authored
      * 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-2.6: (46 commits)
        [media] rc: call input_sync after scancode reports
        [media] imon: allow either proto on unknown 0xffdc
        [media] imon: auto-config ffdc 7e device
        [media] saa7134: fix raw IR timeout value
        [media] rc: fix ghost keypresses with certain hw
        [media] [staging] lirc_serial: allocate irq at init time
        [media] lirc_zilog: fix spinning rx thread
        [media] keymaps: fix table for pinnacle pctv hd devices
        [media] ite-cir: 8709 needs to use pnp resource 2
        [media] V4L: mx1-camera: fix uninitialized variable
        [media] omap_vout: Added check in reqbuf & mmap for buf_size allocation
        [media] OMAP_VOUT: Change hardcoded device node number to -1
        [media] OMAP_VOUTLIB: Fix wrong resizer calculation
        [media] uvcvideo: Disable the queue when failing to start
        [media] uvcvideo: Remove buffers from the queues when freeing
        [media] uvcvideo: Ignore entities for terminals with no supported format
        [media] v4l: Don't access media entity after is has been destroyed
        [media] media: omap3isp: fix a potential NULL deref
        [media] media: vb2: fix allocation failure check
        [media] media: vb2: reset queued_count value during queue reinitialization
        ...
      
      Fix up trivial conflict in MAINTAINERS as per Mauro
      de3796e7
    • Davidlohr Bueso's avatar
      FDPIC: Fix memory leak · bcb65a79
      Davidlohr Bueso authored
      The shdr4extnum variable isn't being freed in the cleanup process of
      elf_fdpic_core_dump().
      Signed-off-by: default avatarDavidlohr Bueso <dave@gnu.org>
      Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      bcb65a79
    • Rafael J. Wysocki's avatar
      PM / Hibernate: Fix free_unnecessary_pages() · 4d4cf23c
      Rafael J. Wysocki authored
      There is a bug in free_unnecessary_pages() that causes it to
      attempt to free too many pages in some cases, which triggers the
      BUG_ON() in memory_bm_clear_bit() for copy_bm.  Namely, if
      count_data_pages() is initially greater than alloc_normal, we get
      to_free_normal equal to 0 and "save" greater from 0.  In that case,
      if the sum of "save" and count_highmem_pages() is greater than
      alloc_highmem, we subtract a positive number from to_free_normal.
      Hence, since to_free_normal was 0 before the subtraction and is
      an unsigned int, the result is converted to a huge positive number
      that is used as the number of pages to free.
      
      Fix this bug by checking if to_free_normal is actually greater
      than or equal to the number we're going to subtract from it.
      Signed-off-by: default avatarRafael J. Wysocki <rjw@sisk.pl>
      Reported-and-tested-by: default avatarMatthew Garrett <mjg@redhat.com>
      Cc: stable@kernel.org
      4d4cf23c
    • Ram Pai's avatar
      resource: ability to resize an allocated resource · 23c570a6
      Ram Pai authored
      Provides the ability to resize a resource that is already allocated.
      This functionality is put in place to support reallocation needs of
      pci resources.
      Signed-off-by: default avatarRam Pai <linuxram@us.ibm.com>
      Acked-by: default avatarJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      23c570a6
    • Miklos Szeredi's avatar
      fs: fix lock initialization · a51cb91d
      Miklos Szeredi authored
      locks_alloc_lock() assumed that the allocated struct file_lock is
      already initialized to zero members.  This is only true for the first
      allocation of the structure, after reuse some of the members will have
      random values.
      
      This will for example result in passing random fl_start values to
      userspace in fuse for FL_FLOCK locks, which is an information leak at
      best.
      
      Fix by reinitializing those members which may be non-zero after freeing.
      Signed-off-by: default avatarMiklos Szeredi <mszeredi@suse.cz>
      CC: stable@kernel.org
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      a51cb91d