1. 07 12月, 2006 16 次提交
  2. 05 12月, 2006 1 次提交
  3. 04 12月, 2006 2 次提交
  4. 03 12月, 2006 1 次提交
  5. 02 12月, 2006 2 次提交
  6. 14 11月, 2006 3 次提交
    • A
      [PATCH] x86-64: Fix race in exit_idle · 9446868b
      Andi Kleen 提交于
      When another interrupt happens in exit_idle the exit idle notifier
      could be called an incorrect number of times.
      
      Add a test_and_clear_bit_pda and use it handle the bit
      atomically against interrupts to avoid this.
      
      Pointed out by Stephane Eranian
      Signed-off-by: NAndi Kleen <ak@suse.de>
      9446868b
    • A
      [PATCH] x86-64: Fix vgetcpu when CONFIG_HOTPLUG_CPU is disabled · 8c131af1
      Andi Kleen 提交于
      The vgetcpu per CPU initialization previously relied on CPU hotplug
      events for all CPUs to initialize the per CPU state. That only
      worked only on kernels with CONFIG_HOTPLUG_CPU enabled.  On the
      others some CPUs didn't get their state initialized properly
      and vgetcpu wouldn't work.
      
      Change the initialization sequence to instead run in a normal
      initcall (which runs after the normal CPU bootup) and initialize
      all running CPUs there. Later hotplug CPUs are still handled
      with an hotplug notifier.
      
      This actually simplifies the code somewhat.
      Signed-off-by: NAndi Kleen <ak@suse.de>
      8c131af1
    • A
      [PATCH] x86: Add acpi_user_timer_override option for Asus boards · fa18f477
      Andi Kleen 提交于
      Timer overrides are normally disabled on Nvidia board because
      they are commonly wrong, except on new ones with HPET support.
      Unfortunately there are quite some Asus boards around that
      don't have HPET, but need a timer override.
      
      We don't know yet how to handle this transparently,
      but at least add a command line option to force the timer override
      and let them boot.
      
      Cc: len.brown@intel.com
      Signed-off-by: NAndi Kleen <ak@suse.de>
      fa18f477
  7. 09 11月, 2006 1 次提交
    • L
      x86-64: clean up io-apic accesses · 6c0ffb9d
      Linus Torvalds 提交于
      This is just commit 130fe05d ported to
      x86-64, for all the same reasons.  It cleans up the IO-APIC accesses in
      order to then fix the ordering issues.
      
      We move the accessor functions (that were only used by io_apic.c) out of
      a header file, and use proper memory-mapped accesses rather than making
      up our own "volatile" pointers.
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      6c0ffb9d
  8. 25 10月, 2006 1 次提交
    • E
      [PATCH] x86-64: Only look at per_cpu data for online cpus. · 70a0a535
      Eric W. Biederman 提交于
      When I generalized __assign_irq_vector I failed to pay attention
      to what happens when you access a per cpu data structure for
      a cpu that is not online.   It is an undefined case making any
      code that does it have undefined behavior as well.
      
      The code still needs to be able to allocate a vector across cpus
      that are not online to properly handle combinations like lowest
      priority interrupt delivery and cpu_hotplug.  Not that we can do
      that today but the infrastructure shouldn't prevent it.
      
      So this patch updates the places where we touch per cpu data
      to only touch online cpus, it makes cpu vector allocation
      an atomic operation with respect to cpu hotplug, and it updates
      the cpu start code to properly initialize vector_irq so we
      don't have inconsistencies.
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: NAndi Kleen <ak@suse.de>
      70a0a535
  9. 22 10月, 2006 2 次提交
    • A
      [PATCH] x86-64: Revert timer routing behaviour back to 2.6.16 state · e70ea8c0
      Andi Kleen 提交于
      By default route the 8254 over the 8259 and only disable
      it on ATI boards where this causes double timer interrupts.
      
      This should unbreak some Nvidia boards where the timer doesn't
      seem to tick of it isn't enabled in the 8259. At least one
      VIA board also seemed to have a little trouble with the disabled
      8259.
      
      For 2.6.20 we'll try both dynamically without black listing, but I think
      for .19 this is the safer approach because it has been already well tested
      in earlier kernels. This also makes the x86-64 behaviour the same
      as i386.
      
      Command line options can change all this of course.
      Signed-off-by: NAndi Kleen <ak@suse.de>
      e70ea8c0
    • B
      [PATCH] x86-64: x86_64 add NX mask for PTE entry · 7a71cef7
      bibo,mao 提交于
          If function change_page_attr_addr calls revert_page to revert
      to original pte value, mk_pte_phys does not mask NX bit. If NX bit
      is set on no NX hardware supported x86_64 machine, there is will
      be RSVD type page fault and system will crash. This patch adds NX
      mask bit for PTE entry.
      Signed-off-by: Nbibo,mao <bibo.mao@intel.com>
      Signed-off-by: NAndi Kleen <ak@suse.de>
      7a71cef7
  10. 14 10月, 2006 1 次提交
  11. 12 10月, 2006 1 次提交
  12. 09 10月, 2006 2 次提交
    • E
      [PATCH] x86_64 irq: Allocate a vector across all cpus for genapic_flat. · c7111c13
      Eric W. Biederman 提交于
      The problem we can't take advantage of lowest priority delivery mode if
      the vectors are allocated for only one cpu at a time.  Nor can we work
      around hardware that assumes lowest priority delivery mode is always
      used with several cpus.
      
      So this patch introduces the concept of a vector_allocation_domain.  A
      set of cpus that will receive an irq on the same vector.  Currently the
      code for implementing this is placed in the genapic structure so we can
      vary this depending on how we are using the io_apics.
      
      This allows us to restore the previous behaviour of genapic_flat without
      removing the benefits of having separate vector allocation for large
      machines.
      
      This should also fix the problem report where a hyperthreaded cpu was
      receving the irq on the wrong hyperthread when in logical delivery mode
      because the previous behaviour is restored.
      
      This patch properly records our allocation of the first 16 irqs to the
      first 16 available vectors on all cpus.  This should be fine but it may
      run into problems with multiple interrupts at the same interrupt level.
      Except for some badly maintained comments in the code and the behaviour
      of the interrupt allocator I have no real understanding of that problem.
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Acked-by: NMuli Ben-Yehuda <muli@il.ibm.com>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      c7111c13
    • E
      [PATCH] i386/x86_64: Remove global IO_APIC_VECTOR · b940d22d
      Eric W. Biederman 提交于
      Which vector an irq is assigned to now varies dynamically and is
      not needed outside of io_apic.c.  So remove the possibility
      of accessing the information outside of io_apic.c and remove
      the silly macro that makes looking for users of irq_vector
      difficult.
      
      The fact this compiles ensures there aren't any more pieces
      of the old CONFIG_PCI_MSI weirdness that I failed to remove.
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      b940d22d
  13. 06 10月, 2006 1 次提交
  14. 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
  15. 04 10月, 2006 5 次提交
    • E
      [PATCH] msi: refactor and move the msi irq_chip into the arch code · 3b7d1921
      Eric W. Biederman 提交于
      It turns out msi_ops was simply not enough to abstract the architecture
      specific details of msi.  So I have moved the resposibility of constructing
      the struct irq_chip to the architectures, and have two architecture specific
      functions arch_setup_msi_irq, and arch_teardown_msi_irq.
      
      For simple architectures those functions can do all of the work.  For
      architectures with platform dependencies they can call into the appropriate
      platform code.
      
      With this msi.c is finally free of assuming you have an apic, and this
      actually takes less code.
      
      The helpers for the architecture specific code are declared in the linux/msi.h
      to keep them separate from the msi functions used by drivers in linux/pci.h
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Tony Luck <tony.luck@intel.com>
      Cc: Andi Kleen <ak@suse.de>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Greg KH <greg@kroah.com>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      3b7d1921
    • E
      [PATCH] Initial generic hypertransport interrupt support · 8b955b0d
      Eric W. Biederman 提交于
      This patch implements two functions ht_create_irq and ht_destroy_irq for
      use by drivers.  Several other functions are implemented as helpers for
      arch specific irq_chip handlers.
      
      The driver for the card I tested this on isn't yet ready to be merged.
      However this code is and hypertransport irqs are in use in a few other
      places in the kernel.  Not that any of this will get merged before 2.6.19
      
      Because the ipath-ht400 is slightly out of spec this code will need to be
      generalized to work there.
      
      I think all of the powerpc uses are for a plain interrupt controller in a
      chipset so support for native hypertransport devices is a little less
      interesting.
      
      However I think this is a half way decent model on how to separate arch
      specific and generic helper code, and I think this is a functional model of
      how to get the architecture dependencies out of the msi code.
      
      [akpm@osdl.org: Kconfig fix]
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Cc: Greg KH <greg@kroah.com>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      8b955b0d
    • E
      [PATCH] genirq: x86_64 irq: Kill irq compression · cd1182f5
      Eric W. Biederman 提交于
      With more irqs in the system we don't need this.
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Rajesh Shah <rajesh.shah@intel.com>
      Cc: Andi Kleen <ak@muc.de>
      Cc: "Protasevich, Natalie" <Natalie.Protasevich@UNISYS.com>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      cd1182f5
    • E
      [PATCH] genirq: x86_64 irq: make vector_irq per cpu · 550f2299
      Eric W. Biederman 提交于
      This refactors the irq handling code to make the vectors a per cpu resource so
      the same vector number can be simultaneously used on multiple cpus for
      different irqs.
      
      This should make systems that were hitting limits on the total number of irqs
      much more livable.
      
      [akpm@osdl.org: build fix]
      [akpm@osdl.org: __target_IO_APIC_irq is unneeded on UP]
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Rajesh Shah <rajesh.shah@intel.com>
      Cc: Andi Kleen <ak@muc.de>
      Cc: "Protasevich, Natalie" <Natalie.Protasevich@UNISYS.com>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      550f2299
    • E
      [PATCH] genirq: x86_64 irq: Make the external irq handlers report their vector, not the irq number · e500f574
      Eric W. Biederman 提交于
      This is a small pessimization but it paves the way for making this information
      per cpu.  Which allows the the maximum number of IRQS to become NR_CPUS*224.
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Rajesh Shah <rajesh.shah@intel.com>
      Cc: Andi Kleen <ak@muc.de>
      Cc: "Protasevich, Natalie" <Natalie.Protasevich@UNISYS.com>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      e500f574