> v10: make the x86 32 bit support sparse_irq too.> also make remove irqbalance in kernel for 32 bit> and make 32 bit support per_cpu vector. so start merging or io_apic_xx.c> > 01-03 is some fix for current tree> 04: is revert for one patch hide in sched/ and tip/master> > based on tip/master> > to do:> merge io_apic_xx.c

ok, i've created a new tip/irq/sparseirq topic branch for this.

Could you please send future updates against:

git-checkout tip/master git-merge tip/irq/sparseirq

Not yet integrated into tip/master, i've still got some other backlog.

A couple of observations about the general structure of the sparse irqs code:

- the new APIs should probably live in mm/bootmem.c not in init/main.c, and in bootmem.h. Also, it should be outlined clearly why this new API is needed as a wrapper ontop of existing bootmem mechanisms.

- the #ifdef complications, while fine for migration, should be eliminated. Could we introduce some compatible form for the definition/allocation APIs that work even if an architecture still uses a flat irq array? That would remove most of the uglinesses.

- some of the irq < 16 checks in x86 look a bit ugly, can we do anything about them?

- i think as a final-ish commit we should just remove the dyn-array define and make all architectures use this facility. You converted most of them - how many are still missing? Sparse-irq is more intrusive so that should probably stay a Kconfig knob.

- there was one aspect of NR_IRQS that was nice and useful: it acted as a sanity check against BIOS bugs and driver bugs that pass in some irrealistically high irq number. Now we'll just try to allocate some really high IRQ and accept it. I _think_ there should be a single, simple 'absolute maximum IRQ number' define which should set the maximum possible IRQ number. Lets call it NR_IRQS_MAX or so, and set it to NR_CPUS*NR_IO_APICS*224 or so?

- i'm a bit worried about linecount increase in general:

247 files changed, 3671 insertions(+), 2052 deletions(-)

could we work on reducing that somewhat? The new infrastructure bits in mm/* and kernel/irq/* will be unavoidable, what we should concentrate on is to make usage of the new facility just as straightforward, easy and compact as the old irq_desc[] usages.

A worst-case example is drivers/char/random.c: the CONFIG_HAVE_SPARSE_IRQ and CONFIG_HAVE_DYN_ARRAY #ifdef jungle is not acceptable. I think the best way out is to convert the whole kernel to the new facilities (as safely as possible, without breaking other architectures), and making sure that the end result is easy to understand and intuitive.

so i dont mind the current code as long as the extra complications are temporary during a safe conversion - but we should work on eliminating all those complications before thinking about upstream merging.

Ingo

-------------------->the irq/sparseirq git tree can be picked up from:

Jaswinder Singh (27): x86: Introducing asm/syscalls.h x86: process_32.c declare cpu_number before they get used x86: signal_XX.c declare do_notify_resume before they get used x86: time_XX.c declare functions before they get used x86: setup.c declare saved_video_mode before they get used x86: e820.c declare pci_mem_start before they get used x86: pci-dma.c declare iommu_bio_merge before they get used x86: pci-nommu.c declare nommu_dma_ops before they get used x86: i387.c declare dump_fpu() before they get used x86: ptrace.c declare functions before they get used x86: proc.c declare cpuinfo_op before they get used x86: common.c declare idle_regs before they get used x86: mtrr/main.c declare range_state as static x86: apic_XX.c declare functions before they get used x86: vm86_32.c declare functions before they get used x86: mm/init_XX.c declare functions before they get used x86: mm/fault.c declare do_page_fault before they get used x86: mm/ioremap.c declare early_ioremap_debug and early_ioremap_nested as static x86: mm/pageattr.c declare arch_report_meminfo before they get used x86: mm/pgtable_32.c declare set_pmd_pfn before they get used x86: mach-default/setup.c declare no_broadcast before they get used x86_64: Declare new_utsname in asm-x86/syscalls.h X86_32: declare pt_regs_access as unsigned long X86_SMP: smp.c declare functions before they get used X86_SMP: smpboot.c declare idle_thread_array and smp_b_stepping as static X86_SMP: ipi.c declare functions before they get used X86_SMP: tlb_XX.c declare smp_invalidate_interrupt before they get used