1. 13 4月, 2016 2 次提交
    • M
      locking/rwsem: Introduce basis for down_write_killable() · d4799608
      Michal Hocko 提交于
      Introduce a generic implementation necessary for down_write_killable().
      
      This is a trivial extension of the already existing down_write() call
      which can be interrupted by SIGKILL.  This patch doesn't provide
      down_write_killable() yet because arches have to provide the necessary
      pieces before.
      
      rwsem_down_write_failed() which is a generic slow path for the
      write lock is extended to take a task state and renamed to
      __rwsem_down_write_failed_common(). The return value is either a valid
      semaphore pointer or ERR_PTR(-EINTR).
      
      rwsem_down_write_failed_killable() is exported as a new way to wait for
      the lock and be killable.
      
      For rwsem-spinlock implementation the current __down_write() it updated
      in a similar way as __rwsem_down_write_failed_common() except it doesn't
      need new exports just visible __down_write_killable().
      
      Architectures which are not using the generic rwsem implementation are
      supposed to provide their __down_write_killable() implementation and
      use rwsem_down_write_failed_killable() for the slow path.
      Signed-off-by: NMichal Hocko <mhocko@suse.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Max Filippov <jcmvbkbc@gmail.com>
      Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de>
      Cc: Signed-off-by: Jason Low <jason.low2@hp.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Tony Luck <tony.luck@intel.com>
      Cc: linux-alpha@vger.kernel.org
      Cc: linux-arch@vger.kernel.org
      Cc: linux-ia64@vger.kernel.org
      Cc: linux-s390@vger.kernel.org
      Cc: linux-sh@vger.kernel.org
      Cc: linux-xtensa@linux-xtensa.org
      Cc: sparclinux@vger.kernel.org
      Link: http://lkml.kernel.org/r/1460041951-22347-7-git-send-email-mhocko@kernel.orgSigned-off-by: NIngo Molnar <mingo@kernel.org>
      d4799608
    • M
      locking/rwsem: Get rid of __down_write_nested() · f8e04d85
      Michal Hocko 提交于
      This is no longer used anywhere and all callers (__down_write()) use
      0 as a subclass. Ditch __down_write_nested() to make the code easier
      to follow.
      
      This shouldn't introduce any functional change.
      Signed-off-by: NMichal Hocko <mhocko@suse.com>
      Acked-by: NDavidlohr Bueso <dave@stgolabs.net>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: David S. Miller <davem@davemloft.net>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Max Filippov <jcmvbkbc@gmail.com>
      Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Signed-off-by: Davidlohr Bueso <dbueso@suse.de>
      Cc: Signed-off-by: Jason Low <jason.low2@hp.com>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Tony Luck <tony.luck@intel.com>
      Cc: linux-alpha@vger.kernel.org
      Cc: linux-arch@vger.kernel.org
      Cc: linux-ia64@vger.kernel.org
      Cc: linux-s390@vger.kernel.org
      Cc: linux-sh@vger.kernel.org
      Cc: linux-xtensa@linux-xtensa.org
      Cc: sparclinux@vger.kernel.org
      Link: http://lkml.kernel.org/r/1460041951-22347-2-git-send-email-mhocko@kernel.orgSigned-off-by: NIngo Molnar <mingo@kernel.org>
      f8e04d85
  2. 18 2月, 2015 1 次提交
  3. 04 2月, 2015 1 次提交
  4. 16 7月, 2014 1 次提交
  5. 06 11月, 2013 1 次提交
  6. 07 5月, 2013 2 次提交
  7. 19 2月, 2013 1 次提交
    • Y
      rwsem-spinlock: Implement writer lock-stealing for better scalability · 41ef8f82
      Yuanhan Liu 提交于
      We (Linux Kernel Performance project) found a regression
      introduced by commit:
      
        5a505085 mm/rmap: Convert the struct anon_vma::mutex to an rwsem
      
      which converted all anon_vma::mutex locks rwsem write locks.
      
      The semantics are the same, but the behavioral difference is
      quite huge in some cases. After investigating it we found the
      root cause: mutexes support lock stealing while rwsems don't.
      
      Here is the link for the detailed regression report:
      
        https://lkml.org/lkml/2013/1/29/84
      
      Ingo suggested adding write lock stealing to rwsems:
      
          "I think we should allow lock-steal between rwsem writers - that
           will not hurt fairness as most rwsem fairness concerns relate to
           reader vs. writer fairness"
      
      And here is the rwsem-spinlock version.
      
      With this patch, we got a double performance increase in one
      test box with following aim7 workfile:
      
          FILESIZE: 1M
          POOLSIZE: 10M
          10 fork_test
      
       /usr/bin/time output w/o patch                       /usr/bin/time_output with patch
       -- Percent of CPU this job got: 369%                 Percent of CPU this job got: 537%
       Voluntary context switches: 640595016                Voluntary context switches: 157915561
      
      We got a 45% increase in CPU usage and saved about 3/4 voluntary context switches.
      Reported-by: NLKP project <lkp@linux.intel.com>
      Suggested-by: NIngo Molnar <mingo@kernel.org>
      Signed-off-by: NYuanhan Liu <yuanhan.liu@linux.intel.com>
      Cc: Alex Shi <alex.shi@intel.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Michel Lespinasse <walken@google.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Anton Blanchard <anton@samba.org>
      Cc: Arjan van de Ven <arjan@linux.intel.com>
      Cc: paul.gortmaker@windriver.com
      Link: http://lkml.kernel.org/r/1359716356-23865-1-git-send-email-yuanhan.liu@linux.intel.comSigned-off-by: NIngo Molnar <mingo@kernel.org>
      41ef8f82
  8. 08 3月, 2012 1 次提交
  9. 13 9月, 2011 1 次提交
  10. 08 4月, 2010 1 次提交
  11. 16 12月, 2009 2 次提交
  12. 09 2月, 2008 1 次提交
  13. 11 10月, 2006 1 次提交
  14. 04 7月, 2006 2 次提交
  15. 01 5月, 2005 1 次提交
  16. 17 4月, 2005 1 次提交
    • L
      Linux-2.6.12-rc2 · 1da177e4
      Linus Torvalds 提交于
      Initial git repository build. I'm not bothering with the full history,
      even though we have it. We can create a separate "historical" git
      archive of that later if we want to, and in the meantime it's about
      3.2GB when imported into git - space that would just make the early
      git days unnecessarily complicated, when we don't have a lot of good
      infrastructure for it.
      
      Let it rip!
      1da177e4