1. 28 10月, 2006 2 次提交
  2. 22 10月, 2006 1 次提交
    • J
      [PATCH] x86-64: Speed up dwarf2 unwinder · 690a973f
      Jan Beulich 提交于
      This changes the dwarf2 unwinder to do a binary search for CIEs
      instead of a linear work. The linker is unfortunately not
      able to build a proper lookup table at link time, instead it creates
      one at runtime as soon as the bootmem allocator is usable (so you'll continue
      using the linear lookup for the first [hopefully] few calls).
      The code should be ready to utilize a build-time created table once
      a fixed linker becomes available.
      Signed-off-by: NJan Beulich <jbeulich@novell.com>
      Signed-off-by: NAndi Kleen <ak@suse.de>
      690a973f
  3. 21 10月, 2006 1 次提交
    • R
      [PATCH] Fix warnings for WARN_ON if CONFIG_BUG is disabled · 8c7c7c9b
      Ralf Baechle 提交于
      In most cases the return value of WARN_ON() is ignored.  If the generic
      definition for the !CONFIG_BUG case is used this will result in a warning:
      
        CC      kernel/sched.o
      In file included from include/linux/bio.h:25,
                       from include/linux/blkdev.h:14,
                       from kernel/sched.c:39:
      include/linux/ioprio.h: In function ‘task_ioprio’:
      include/linux/ioprio.h:50: warning: statement with no effect
      kernel/sched.c: In function ‘context_switch’:
      kernel/sched.c:1834: warning: statement with no effect
      Signed-off-by: NRalf Baechle <ralf@linux-mips.org>
      Cc: Jeremy Fitzhardinge <jeremy@goop.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      8c7c7c9b
  4. 12 10月, 2006 1 次提交
    • N
      [PATCH] sched: likely profiling · beed33a8
      Nick Piggin 提交于
      This likely profiling is pretty fun. I found a few possible problems
      in sched.c.
      
      This patch may be not measurable, but when I did measure long ago,
      nooping (un)likely cost a couple of % on scheduler heavy benchmarks, so
      it all adds up.
      
      Tweak some branch hints:
      
      - the 2nd 64 bits in the bitmask is likely to be populated, because it
        contains the first 28 bits (nearly 3/4) of the normal priorities.
        (ratio of 669669:691 ~= 1000:1).
      
      - it isn't unlikely that context switching switches to another process. it
        might be very rapidly switching to and from the idle process (ratio of
        475815:419004 and 471330:423544). Let the branch predictor decide.
      
      - preempt_enable seems to be very often called in a nested preempt_disable
        or with interrupts disabled (ratio of 3567760:87965 ~= 40:1)
      Signed-off-by: NNick Piggin <npiggin@suse.de>
      Acked-by: NIngo Molnar <mingo@elte.hu>
      Cc: Daniel Walker <dwalker@mvista.com>
      Cc: Hua Zhong <hzhong@gmail.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      beed33a8
  5. 06 10月, 2006 2 次提交
    • J
      [PATCH] Fix typo in "syntax error if percpu macros are incorrectly used" patch · a666ecfb
      Jan Blunck 提交于
      Trivial typo fix in the "syntax error if percpu macros are incorrectly
      used" patch.  I misspelled "identifier" in all places.  D'Oh!
      
      Thanks to Dirk Mueller to point this out.
      Signed-off-by: NJan Blunck <jblunck@suse.de>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      a666ecfb
    • A
      [PATCH] Fix WARN_ON / WARN_ON_ONCE regression · d69a8922
      Andrew Morton 提交于
      Tim and Ananiev report that the recent WARN_ON_ONCE changes cause increased
      cache misses with the tbench workload.  Apparently due to the access to the
      newly-added static variable.
      
      Rearrange the code so that we don't touch that variable unless the warning is
      going to trigger.
      
      Also rework the logic so that the static variable starts out at zero, so we
      can move it into bss.
      
      It would seem logical to mark the static variable as __read_mostly too.  But
      it would be wrong, because that would put it back into the vmlinux image, and
      the kernel will never read from this variable in normal operation anyway.
      Unless the compiler or hardware go and do some prefetching on us?
      
      For some reason this patch shrinks softirq.o text by 40 bytes.
      
      Cc: Tim Chen <tim.c.chen@intel.com>
      Cc: Herbert Xu <herbert@gondor.apana.org.au>
      Cc: "Ananiev, Leonid I" <leonid.i.ananiev@intel.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      d69a8922
  6. 05 10月, 2006 1 次提交
    • D
      IRQ: Maintain regs pointer globally rather than passing to IRQ handlers · 7d12e780
      David Howells 提交于
      Maintain a per-CPU global "struct pt_regs *" variable which can be used instead
      of passing regs around manually through all ~1800 interrupt handlers in the
      Linux kernel.
      
      The regs pointer is used in few places, but it potentially costs both stack
      space and code to pass it around.  On the FRV arch, removing the regs parameter
      from all the genirq function results in a 20% speed up of the IRQ exit path
      (ie: from leaving timer_interrupt() to leaving do_IRQ()).
      
      Where appropriate, an arch may override the generic storage facility and do
      something different with the variable.  On FRV, for instance, the address is
      maintained in GR28 at all times inside the kernel as part of general exception
      handling.
      
      Having looked over the code, it appears that the parameter may be handed down
      through up to twenty or so layers of functions.  Consider a USB character
      device attached to a USB hub, attached to a USB controller that posts its
      interrupts through a cascaded auxiliary interrupt controller.  A character
      device driver may want to pass regs to the sysrq handler through the input
      layer which adds another few layers of parameter passing.
      
      I've build this code with allyesconfig for x86_64 and i386.  I've runtested the
      main part of the code on FRV and i386, though I can't test most of the drivers.
      I've also done partial conversion for powerpc and MIPS - these at least compile
      with minimal configurations.
      
      This will affect all archs.  Mostly the changes should be relatively easy.
      Take do_IRQ(), store the regs pointer at the beginning, saving the old one:
      
      	struct pt_regs *old_regs = set_irq_regs(regs);
      
      And put the old one back at the end:
      
      	set_irq_regs(old_regs);
      
      Don't pass regs through to generic_handle_irq() or __do_IRQ().
      
      In timer_interrupt(), this sort of change will be necessary:
      
      	-	update_process_times(user_mode(regs));
      	-	profile_tick(CPU_PROFILING, regs);
      	+	update_process_times(user_mode(get_irq_regs()));
      	+	profile_tick(CPU_PROFILING);
      
      I'd like to move update_process_times()'s use of get_irq_regs() into itself,
      except that i386, alone of the archs, uses something other than user_mode().
      
      Some notes on the interrupt handling in the drivers:
      
       (*) input_dev() is now gone entirely.  The regs pointer is no longer stored in
           the input_dev struct.
      
       (*) finish_unlinks() in drivers/usb/host/ohci-q.c needs checking.  It does
           something different depending on whether it's been supplied with a regs
           pointer or not.
      
       (*) Various IRQ handler function pointers have been moved to type
           irq_handler_t.
      Signed-Off-By: NDavid Howells <dhowells@redhat.com>
      (cherry picked from 1b16e7ac850969f38b375e511e3fa2f474a33867 commit)
      7d12e780
  7. 04 10月, 2006 1 次提交
  8. 01 10月, 2006 3 次提交
    • Z
      [PATCH] paravirt: remove set pte atomic · a93cb055
      Zachary Amsden 提交于
      Now that ptep_establish has a definition in PAE i386 3-level paging code, the
      only paging model which is insane enough to have multi-word hardware PTEs
      which are not efficient to set atomically, we can remove the ghost of
      set_pte_atomic from other architectures which falesly duplicated it, and
      remove all knowledge of it from the generic pgtable code.
      
      set_pte_atomic is now a private pte operator which is specific to i386
      Signed-off-by: NZachary Amsden <zach@vmware.com>
      Cc: Rusty Russell <rusty@rustcorp.com.au>
      Cc: Jeremy Fitzhardinge <jeremy@xensource.com>
      Cc: Andi Kleen <ak@suse.de>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      a93cb055
    • Z
      [PATCH] paravirt: lazy mmu mode hooks.patch · 6606c3e0
      Zachary Amsden 提交于
      Implement lazy MMU update hooks which are SMP safe for both direct and shadow
      page tables.  The idea is that PTE updates and page invalidations while in
      lazy mode can be batched into a single hypercall.  We use this in VMI for
      shadow page table synchronization, and it is a win.  It also can be used by
      PPC and for direct page tables on Xen.
      
      For SMP, the enter / leave must happen under protection of the page table
      locks for page tables which are being modified.  This is because otherwise,
      you end up with stale state in the batched hypercall, which other CPUs can
      race ahead of.  Doing this under the protection of the locks guarantees the
      synchronization is correct, and also means that spurious faults which are
      generated during this window by remote CPUs are properly handled, as the page
      fault handler must re-check the PTE under protection of the same lock.
      Signed-off-by: NZachary Amsden <zach@vmware.com>
      Signed-off-by: NJeremy Fitzhardinge <jeremy@xensource.com>
      Cc: Rusty Russell <rusty@rustcorp.com.au>
      Cc: Andi Kleen <ak@suse.de>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      6606c3e0
    • Z
      [PATCH] paravirt: pte clear not present · 9888a1ca
      Zachary Amsden 提交于
      Change pte_clear_full to a more appropriately named pte_clear_not_present,
      allowing optimizations when not-present mapping changes need not be reflected
      in the hardware TLB for protected page table modes.  There is also another
      case that can use it in the fremap code.
      Signed-off-by: NZachary Amsden <zach@vmware.com>
      Signed-off-by: NJeremy Fitzhardinge <jeremy@xensource.com>
      Cc: Rusty Russell <rusty@rustcorp.com.au>
      Cc: Andi Kleen <ak@suse.de>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      9888a1ca
  9. 30 9月, 2006 1 次提交
  10. 27 9月, 2006 1 次提交
  11. 26 9月, 2006 4 次提交
  12. 23 9月, 2006 1 次提交
  13. 19 9月, 2006 1 次提交
  14. 13 9月, 2006 1 次提交
  15. 12 9月, 2006 1 次提交
  16. 10 8月, 2006 1 次提交
    • A
      [PATCH] libata: rework legacy handling to remove much of the cruft · 2ec7df04
      Alan Cox 提交于
      Kill host_set->next
      Fix simplex support
      Allow per platform setting of IDE legacy bases
      
      Some of this can be tidied further later on, in particular all the
      legacy port gunge belongs as a PCI quirk/PCI header decode to understand
      the special legacy IDE rules in the PCI spec.
      
      Longer term Jeff also wants to move the request_irq/free_irq out of core
      which will make this even cleaner.
      
      tj: folded in three followup patches - ata_piix-fix, broken-arch-fix
      and fix-new-legacy-handling, and separated per-dev xfermask into
      separate patch preceding this one.  Folded in fixes are...
      
      * ata_piix-fix: fix build failure due to host_set->next removal
      * broken-arch-fix: add missing include/asm-*/libata-portmap.h
      * fix-new-legacy-handling:
      	* In ata_pci_init_legacy_port(), probe_num was incorrectly
                incremented during initialization of the secondary port and
                probe_ent->n_ports was incorrectly fixed to 1.
      
      	* Both legacy ports ended up having the same hard_port_no.
      
      	* When printing port information, both legacy ports printed
      	  the first irq.
      Signed-off-by: NAlan Cox <alan@redhat.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      2ec7df04
  17. 15 7月, 2006 3 次提交
  18. 04 7月, 2006 2 次提交
    • I
      [PATCH] lockdep: better lock debugging · 9a11b49a
      Ingo Molnar 提交于
      Generic lock debugging:
      
       - generalized lock debugging framework. For example, a bug in one lock
         subsystem turns off debugging in all lock subsystems.
      
       - got rid of the caller address passing (__IP__/__IP_DECL__/etc.) from
         the mutex/rtmutex debugging code: it caused way too much prototype
         hackery, and lockdep will give the same information anyway.
      
       - ability to do silent tests
      
       - check lock freeing in vfree too.
      
       - more finegrained debugging options, to allow distributions to
         turn off more expensive debugging features.
      
      There's no separate 'held mutexes' list anymore - but there's a 'held locks'
      stack within lockdep, which unifies deadlock detection across all lock
      classes.  (this is independent of the lockdep validation stuff - lockdep first
      checks whether we are holding a lock already)
      
      Here are the current debugging options:
      
      CONFIG_DEBUG_MUTEXES=y
      CONFIG_DEBUG_LOCK_ALLOC=y
      
      which do:
      
       config DEBUG_MUTEXES
                bool "Mutex debugging, basic checks"
      
       config DEBUG_LOCK_ALLOC
               bool "Detect incorrect freeing of live mutexes"
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      Signed-off-by: NArjan van de Ven <arjan@linux.intel.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      9a11b49a
    • I
      [PATCH] lockdep: add per_cpu_offset() · a875a69f
      Ingo Molnar 提交于
      Add the per_cpu_offset() generic method. (used by the lock validator)
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      Signed-off-by: NArjan van de Ven <arjan@linux.intel.com>
      Cc: Rusty Russell <rusty@rustcorp.com.au>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      a875a69f
  19. 02 7月, 2006 1 次提交
  20. 01 7月, 2006 1 次提交
    • A
      [PATCH] audit syscall classes · b915543b
      Al Viro 提交于
      Allow to tie upper bits of syscall bitmap in audit rules to kernel-defined
      sets of syscalls.  Infrastructure, a couple of classes (with 32bit counterparts
      for biarch targets) and actual tie-in on i386, amd64 and ia64.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      b915543b
  21. 30 6月, 2006 1 次提交
  22. 29 6月, 2006 1 次提交
  23. 28 6月, 2006 1 次提交
  24. 26 6月, 2006 2 次提交
  25. 25 6月, 2006 1 次提交
  26. 23 6月, 2006 1 次提交
  27. 18 6月, 2006 1 次提交
  28. 02 6月, 2006 1 次提交
    • D
      [SPARC64]: Fix D-cache corruption in mremap · 0b0968a3
      David S. Miller 提交于
      If we move a mapping from one virtual address to another,
      and this changes the virtual color of the mapping to those
      pages, we can see corrupt data due to D-cache aliasing.
      
      Check for and deal with this by overriding the move_pte()
      macro.  Set things up so that other platforms can cleanly
      override the move_pte() macro too.
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      0b0968a3
  29. 27 4月, 2006 1 次提交