1. 23 1月, 2011 1 次提交
    • B
      genirq: Add IRQ affinity notifiers · cd7eab44
      Ben Hutchings 提交于
      When initiating I/O on a multiqueue and multi-IRQ device, we may want
      to select a queue for which the response will be handled on the same
      or a nearby CPU.  This requires a reverse-map of IRQ affinity.  Add a
      notification mechanism to support this.
      
      This is based closely on work by Thomas Gleixner <tglx@linutronix.de>.
      Signed-off-by: NBen Hutchings <bhutchings@solarflare.com>
      Cc: linux-net-drivers@solarflare.com
      Cc: Tom Herbert <therbert@google.com>
      Cc: David Miller <davem@davemloft.net>
      LKML-Reference: <1295470904.11126.84.camel@bwh-desktop>
      Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
      cd7eab44
  2. 21 1月, 2011 1 次提交
  3. 14 1月, 2011 1 次提交
    • E
      irq: use per_cpu kstat_irqs · 6c9ae009
      Eric Dumazet 提交于
      Use modern per_cpu API to increment {soft|hard}irq counters, and use
      per_cpu allocation for (struct irq_desc)->kstats_irq instead of an array.
      
      This gives better SMP/NUMA locality and saves few instructions per irq.
      
      With small nr_cpuids values (8 for example), kstats_irq was a small array
      (less than L1_CACHE_BYTES), potentially source of false sharing.
      
      In the !CONFIG_SPARSE_IRQ case, remove the huge, NUMA/cache unfriendly
      kstat_irqs_all[NR_IRQS][NR_CPUS] array.
      
      Note: we still populate kstats_irq for all possible irqs in
      early_irq_init().  We probably could use on-demand allocations.  (Code
      included in alloc_descs()).  Problem is not all IRQS are used with a prior
      alloc_descs() call.
      
      kstat_irqs_this_cpu() is not used anymore, remove it.
      Signed-off-by: NEric Dumazet <eric.dumazet@gmail.com>
      Reviewed-by: NChristoph Lameter <cl@linux.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Andi Kleen <andi@firstfloor.org>
      Cc: Tejun Heo <tj@kernel.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      6c9ae009
  4. 07 1月, 2011 1 次提交
  5. 01 12月, 2010 1 次提交
  6. 28 10月, 2010 1 次提交
    • K
      /proc/stat: fix scalability of irq sum of all cpu · 478735e3
      KAMEZAWA Hiroyuki 提交于
      In /proc/stat, the number of per-IRQ event is shown by making a sum each
      irq's events on all cpus.  But we can make use of kstat_irqs().
      
      kstat_irqs() do the same calculation, If !CONFIG_GENERIC_HARDIRQ,
      it's not a big cost. (Both of the number of cpus and irqs are small.)
      
      If a system is very big and CONFIG_GENERIC_HARDIRQ, it does
      
      	for_each_irq()
      		for_each_cpu()
      			- look up a radix tree
      			- read desc->irq_stat[cpu]
      This seems not efficient. This patch adds kstat_irqs() for
      CONFIG_GENRIC_HARDIRQ and change the calculation as
      
      	for_each_irq()
      		look up radix tree
      		for_each_cpu()
      			- read desc->irq_stat[cpu]
      
      This reduces cost.
      
      A test on (4096cpusp, 256 nodes, 4592 irqs) host (by Jack Steiner)
      
      %time cat /proc/stat > /dev/null
      
      Before Patch:	 2.459 sec
      After Patch :	  .561 sec
      
      [akpm@linux-foundation.org: unexport kstat_irqs, coding-style tweaks]
      [akpm@linux-foundation.org: fix unused variable 'per_irq_sum']
      Signed-off-by: NKAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
      Tested-by: NJack Steiner <steiner@sgi.com>
      Acked-by: NJack Steiner <steiner@sgi.com>
      Cc: Yinghai Lu <yinghai@kernel.org>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      478735e3
  7. 23 10月, 2010 1 次提交
  8. 22 10月, 2010 1 次提交
  9. 13 10月, 2010 1 次提交
  10. 12 10月, 2010 18 次提交
  11. 04 10月, 2010 13 次提交