1. 25 5月, 2010 1 次提交
  2. 29 4月, 2010 1 次提交
  3. 23 4月, 2010 1 次提交
  4. 09 4月, 2010 1 次提交
  5. 04 4月, 2010 1 次提交
  6. 30 3月, 2010 1 次提交
    • T
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking... · 5a0e3ad6
      Tejun Heo 提交于
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
      
      percpu.h is included by sched.h and module.h and thus ends up being
      included when building most .c files.  percpu.h includes slab.h which
      in turn includes gfp.h making everything defined by the two files
      universally available and complicating inclusion dependencies.
      
      percpu.h -> slab.h dependency is about to be removed.  Prepare for
      this change by updating users of gfp and slab facilities include those
      headers directly instead of assuming availability.  As this conversion
      needs to touch large number of source files, the following script is
      used as the basis of conversion.
      
        http://userweb.kernel.org/~tj/misc/slabh-sweep.py
      
      The script does the followings.
      
      * Scan files for gfp and slab usages and update includes such that
        only the necessary includes are there.  ie. if only gfp is used,
        gfp.h, if slab is used, slab.h.
      
      * When the script inserts a new include, it looks at the include
        blocks and try to put the new include such that its order conforms
        to its surrounding.  It's put in the include block which contains
        core kernel includes, in the same order that the rest are ordered -
        alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
        doesn't seem to be any matching order.
      
      * If the script can't find a place to put a new include (mostly
        because the file doesn't have fitting include block), it prints out
        an error message indicating which .h file needs to be added to the
        file.
      
      The conversion was done in the following steps.
      
      1. The initial automatic conversion of all .c files updated slightly
         over 4000 files, deleting around 700 includes and adding ~480 gfp.h
         and ~3000 slab.h inclusions.  The script emitted errors for ~400
         files.
      
      2. Each error was manually checked.  Some didn't need the inclusion,
         some needed manual addition while adding it to implementation .h or
         embedding .c file was more appropriate for others.  This step added
         inclusions to around 150 files.
      
      3. The script was run again and the output was compared to the edits
         from #2 to make sure no file was left behind.
      
      4. Several build tests were done and a couple of problems were fixed.
         e.g. lib/decompress_*.c used malloc/free() wrappers around slab
         APIs requiring slab.h to be added manually.
      
      5. The script was run on all .h files but without automatically
         editing them as sprinkling gfp.h and slab.h inclusions around .h
         files could easily lead to inclusion dependency hell.  Most gfp.h
         inclusion directives were ignored as stuff from gfp.h was usually
         wildly available and often used in preprocessor macros.  Each
         slab.h inclusion directive was examined and added manually as
         necessary.
      
      6. percpu.h was updated not to include slab.h.
      
      7. Build test were done on the following configurations and failures
         were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
         distributed build env didn't work with gcov compiles) and a few
         more options had to be turned off depending on archs to make things
         build (like ipr on powerpc/64 which failed due to missing writeq).
      
         * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
         * powerpc and powerpc64 SMP allmodconfig
         * sparc and sparc64 SMP allmodconfig
         * ia64 SMP allmodconfig
         * s390 SMP allmodconfig
         * alpha SMP allmodconfig
         * um on x86_64 SMP allmodconfig
      
      8. percpu.h modifications were reverted so that it could be applied as
         a separate patch and serve as bisection point.
      
      Given the fact that I had only a couple of failures from tests on step
      6, I'm fairly confident about the coverage of this conversion patch.
      If there is a breakage, it's likely to be something in one of the arch
      headers which should be easily discoverable easily on most builds of
      the specific arch.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Guess-its-ok-by: NChristoph Lameter <cl@linux-foundation.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
      5a0e3ad6
  7. 26 3月, 2010 2 次提交
  8. 24 2月, 2010 2 次提交
  9. 20 2月, 2010 2 次提交
    • T
      x86: Add pci_init_irq to x86_init · ab3b3793
      Thomas Gleixner 提交于
      Moorestown wants to reuse pcibios_init_irq but needs to provide its
      own implementation of pci_enable_irq. After we distangled the init we
      can move the init_irq call to x86_init and remove the pci_enable_irq
      != NULL check in pcibios_init_irq. pci_enable_irq is compile time
      initialized to pirq_enable_irq and the special cases which override it
      (visws and acpi) set the x86_init function pointer to noop. That
      allows MSRT to override pci_enable_irq and otherwise run
      pcibios_init_irq unmodified.
      Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
      LKML-Reference: <43F901BD926A4E43B106BF17856F07559FB80CFF@orsmsx508.amr.corp.intel.com>
      Acked-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NJacob Pan <jacob.jun.pan@intel.com>
      Signed-off-by: NH. Peter Anvin <hpa@zytor.com>
      ab3b3793
    • T
      x86: Move pci init function to x86_init · b72d0db9
      Thomas Gleixner 提交于
      The PCI initialization in pci_subsys_init() is a mess. pci_numaq_init,
      pci_acpi_init, pci_visws_init and pci_legacy_init are called and each
      implementation checks and eventually modifies the global variable
      pcibios_scanned.
      
      x86_init functions allow us to do this more elegant. The pci.init
      function pointer is preset to pci_legacy_init. numaq, acpi and visws
      can modify the pointer in their early setup functions. The functions
      return 0 when they did the full initialization including bus scan. A
      non zero return value indicates that pci_legacy_init needs to be
      called either because the selected function failed or wants the
      generic bus scan in pci_legacy_init to happen (e.g. visws).
      Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
      LKML-Reference: <43F901BD926A4E43B106BF17856F07559FB80CFE@orsmsx508.amr.corp.intel.com>
      Acked-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NJacob Pan <jacob.jun.pan@intel.com>
      Signed-off-by: NH. Peter Anvin <hpa@zytor.com>
      b72d0db9
  10. 07 11月, 2009 1 次提交
  11. 05 11月, 2009 5 次提交
  12. 01 7月, 2009 2 次提交
  13. 25 6月, 2009 1 次提交
  14. 17 6月, 2009 1 次提交
    • G
      x86/ACPI: Correct maximum allowed _CRS returned resources and warn if exceeded · f9cde5ff
      Gary Hade 提交于
      Issue a warning if _CRS returns too many resource descriptors to be
      accommodated by the fixed size resource array instances.  If there is no
      transparent bridge on the root bus "too many" is the
      PCI_BUS_NUM_RESOURCES size of the resource array.  Otherwise, the last 3
      slots of the resource array must be excluded making the maximum
      (PCI_BUS_NUM_RESOURCES - 3).
      
      The current code:
       - is silent when _CRS returns too many resource descriptors and
       - incorrectly allows use of the last 3 slots of the resource array
         for a root bus with a transparent bridge
      Signed-off-by: NGary Hade <garyhade@us.ibm.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      f9cde5ff
  15. 12 6月, 2009 1 次提交
  16. 08 1月, 2009 2 次提交
  17. 30 12月, 2008 1 次提交
  18. 24 7月, 2008 1 次提交
    • M
      x86: PIC, L-APIC and I/O APIC debug information · 32f71aff
      Maciej W. Rozycki 提交于
       Dump all the PIC, local APIC and I/O APIC information at the
      fs_initcall() level, which is after ACPI (if used) has initialised PCI
      information, making the point of invocation consistent across MP-table and
      ACPI platforms.  Remove explicit calls to print_IO_APIC() from elsewhere.
      Make the interface of all the functions involved consistent between 32-bit
      and 64-bit versions and make them all static by default by the means of a
      New-and-Improved(TM) __apicdebuginit() macro.
      
       Note that like print_IO_APIC() all these only output anything if
      "apic=debug" has been passed to the kernel through the command line.
      Signed-off-by: NMaciej W. Rozycki <macro@linux-mips.org>
      Cc: Chuck Ebbert <cebbert@redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      32f71aff
  19. 17 7月, 2008 1 次提交
  20. 16 7月, 2008 1 次提交
    • A
      x86/PCI: ACPI based PCI gap calculation · 809d9a8f
      Alok Kataria 提交于
      Using ACPI to find free address space allows us to find a gap for the
      unallocated PCI resources or MMIO resources for hotplug devices within
      the BIOS allowed PCI regions.
      
      It works by evaluating the _CRS object under PCI0 looking for producer
      resources.  Then searches the e820 memory space for a gap within these
      producer resources.
      Signed-off-by: NAlok N Kataria <akataria@vmware.com>
      Cc: Andi Kleen <ak@linux.intel.com>
      Cc: Len Brown <lenb@kernel.org>
      Cc: Ingo Molnar <mingo@elte.hu>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      809d9a8f
  21. 09 7月, 2008 1 次提交
    • R
      x86/pci: removing subsys_initcall ordering dependencies · 8dd779b1
      Robert Richter 提交于
      So far subsys_initcalls has been executed in this order depending on
      the object order in the Makefile:
      
      arch/x86/pci/visws.c:subsys_initcall(pcibios_init);
      arch/x86/pci/numa.c:subsys_initcall(pci_numa_init);
      arch/x86/pci/acpi.c:subsys_initcall(pci_acpi_init);
      arch/x86/pci/legacy.c:subsys_initcall(pci_legacy_init);
      arch/x86/pci/irq.c:subsys_initcall(pcibios_irq_init);
      arch/x86/pci/common.c:subsys_initcall(pcibios_init);
      
      This patch removes the ordering dependency. There is now only one
      subsys_initcall function that contains subsystem initialization code
      with a defined order.
      Signed-off-by: NRobert Richter <robert.richter@amd.com>
      Acked-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      8dd779b1
  22. 08 7月, 2008 3 次提交
  23. 06 5月, 2008 1 次提交
  24. 27 4月, 2008 1 次提交
    • Y
      x86: get mp_bus_to_node early · 871d5f8d
      Yinghai Lu 提交于
      Currently, on an amd k8 system with multi ht chains, the numa_node of
      pci devices under /sys/devices/pci0000:80/* is always 0, even if that
      chain is on node 1 or 2 or 3.
      
      Workaround: pcibus_to_node(bus) is used when we want to get the node that
      pci_device is on.
      
      In struct device, we already have numa_node member, and we could use
      dev_to_node()/set_dev_node() to get and set numa_node in the device.
      set_dev_node is called in pci_device_add() with pcibus_to_node(bus),
      and pcibus_to_node uses bus->sysdata for nodeid.
      
      The problem is when pci_add_device is called, bus->sysdata is not assigned
      correct nodeid yet. The result is that numa_node will always be 0.
      
      pcibios_scan_root and pci_scan_root could take sysdata. So we need to get
      mp_bus_to_node mapping before these two are called, and thus
      get_mp_bus_to_node could get correct node for sysdata in root bus.
      
      In scanning of the root bus, all child busses will take parent bus sysdata.
      So all pci_device->dev.numa_node will be assigned correctly and automatically.
      
      Later we could use dev_to_node(&pci_dev->dev) to get numa_node, and we
      could also could make other bus specific device get the correct numa_node
      too.
      
      This is an updated version of pci_sysdata and Jeff's pci_domain patch.
      
      [ mingo@elte.hu: build fix ]
      Signed-off-by: NYinghai Lu <yinghai.lu@sun.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
      871d5f8d
  25. 21 4月, 2008 2 次提交
  26. 16 4月, 2008 1 次提交
  27. 17 11月, 2007 2 次提交
    • Y
      x86: check boundary in count setup resource · 3d9befd2
      Yinghai Lu 提交于
      need to check info->res_num less than PCI_BUS_NUM_RESOURCES, so
      info->bus->resource[info->res_num] = res will not beyond of bus resource
      array when acpi returns too many resource entries.
      Signed-off-by: NYinghai Lu <yinghai.lu@sun.com>
      Cc: Greg Kroah-Hartman <gregkh@suse.de>
      Cc: Gary Hade <gary.hade@us.ibm.com>
      Cc: Len Brown <lenb@kernel.org>
      Cc: Ingo Molnar <mingo@elte.hu>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NThomas Gleixner <tglx@linutronix.de>
      3d9befd2
    • A
      x86: acpi_pciprobe_dmi_table[] must be __devinitdata · 55b8d50c
      Adrian Bunk 提交于
      This patch fixes the following section mismatches with CONFIG_HOTPLUG=n:
      
      <--  snip  -->
      
      ...
      WARNING: vmlinux.o(.data+0x23640): Section mismatch: reference to .init.text.20:can_skip_ioresource_align (between 'acpi_pciprobe_dmi_table' and 'pcibios_irq_mask')
      WARNING: vmlinux.o(.data+0x2366c): Section mismatch: reference to .init.text.20:can_skip_ioresource_align (between 'acpi_pciprobe_dmi_table' and 'pcibios_irq_mask')
      WARNING: vmlinux.o(.data+0x23698): Section mismatch: reference to .init.text.20:can_skip_ioresource_align (between 'acpi_pciprobe_dmi_table' and 'pcibios_irq_mask')
      ...
      
      <--  snip  -->
      Signed-off-by: NAdrian Bunk <bunk@kernel.org>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      55b8d50c