1. 14 10月, 2006 1 次提交
  2. 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
  3. 27 9月, 2006 1 次提交
  4. 17 8月, 2006 1 次提交
  5. 13 7月, 2006 1 次提交
  6. 10 7月, 2006 1 次提交
  7. 03 7月, 2006 1 次提交
  8. 01 7月, 2006 1 次提交
  9. 30 6月, 2006 1 次提交
  10. 28 6月, 2006 1 次提交
    • B
      ACPI: ACPICA 20060623 · 967440e3
      Bob Moore 提交于
      Implemented a new acpi_spinlock type for the OSL lock
      interfaces.  This allows the type to be customized to
      the host OS for improved efficiency (since a spinlock is
      usually a very small object.)
      
      Implemented support for "ignored" bits in the ACPI
      registers.  According to the ACPI specification, these
      bits should be preserved when writing the registers via
      a read/modify/write cycle. There are 3 bits preserved
      in this manner: PM1_CONTROL[0] (SCI_EN), PM1_CONTROL[9],
      and PM1_STATUS[11].
      http://bugzilla.kernel.org/show_bug.cgi?id=3691
      
      Implemented the initial deployment of new OSL mutex
      interfaces.  Since some host operating systems have
      separate mutex and semaphore objects, this feature was
      requested. The base code now uses mutexes (and the new
      mutex interfaces) wherever a binary semaphore was used
      previously. However, for the current release, the mutex
      interfaces are defined as macros to map them to the
      existing semaphore interfaces.
      
      Fixed several problems with the support for the control
      method SyncLevel parameter. The SyncLevel now works
      according to the ACPI specification and in concert with the
      Mutex SyncLevel parameter, since the current SyncLevel is
      a property of the executing thread. Mutual exclusion for
      control methods is now implemented with a mutex instead
      of a semaphore.
      
      Fixed three instances of the use of the C shift operator
      in the bitfield support code (exfldio.c) to avoid the use
      of a shift value larger than the target data width. The
      behavior of C compilers is undefined in this case and can
      cause unpredictable results, and therefore the case must
      be detected and avoided.  (Fiodor Suietov)
      
      Added an info message whenever an SSDT or OEM table
      is loaded dynamically via the Load() or LoadTable()
      ASL operators. This should improve debugging capability
      since it will show exactly what tables have been loaded
      (beyond the tables present in the RSDT/XSDT.)
      Signed-off-by: NBob Moore <robert.moore@intel.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      967440e3
  11. 27 6月, 2006 4 次提交
  12. 14 6月, 2006 4 次提交
    • B
      ACPI: ACPICA 20060608 · 4c90ece2
      Bob Moore 提交于
      Converted the locking mutex used for the ACPI hardware
      to a spinlock. This change should eliminate all problems
      caused by attempting to acquire a semaphore at interrupt
      level, and it means that all ACPICA external interfaces
      that directly access the ACPI hardware can be safely
      called from interrupt level.
      
      Fixed a regression introduced in 20060526 where the ACPI
      device initialization could be prematurely aborted with
      an AE_NOT_FOUND if a device did not have an optional
      _INI method.
      
      Fixed an IndexField issue where a write to the Data
      Register should be limited in size to the AccessSize
      (width) of the IndexField itself. (BZ 433, Fiodor Suietov)
      
      Fixed problem reports (Valery Podrezov) integrated: - Allow
      store of ThermalZone objects to Debug object.
      http://bugzilla.kernel.org/show_bug.cgi?id=5369
      http://bugzilla.kernel.org/show_bug.cgi?id=5370
      
      Fixed problem reports (Fiodor Suietov) integrated: -
      acpi_get_table_header() doesn't handle multiple instances
      correctly (BZ 364)
      
      Removed four global mutexes that were obsolete and were
      no longer being used.
      Signed-off-by: NBob Moore <robert.moore@intel.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      4c90ece2
    • A
      ACPI: execute Notify() handlers on new thread · b8d35192
      Alexey Starikovskiy 提交于
      http://bugzilla.kernel.org/show_bug.cgi?id=5534
      
      Thanks to Peter Wainwright for isolating the issue.
      Thanks to Andi Kleen and Bob Moore for feedback.
      Thanks to Richard Mace and others for testing.
      Updates by Konstantin Karasyov.
      Signed-off-by: NKonstantin Karasyov <konstantin.a.karasyov@intel.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      b8d35192
    • B
      ACPI: ACPICA 20060421 · b229cf92
      Bob Moore 提交于
      Removed a device initialization optimization introduced in
      20051216 where the _STA method was not run unless an _INI
      was also present for the same device. This optimization
      could cause problems because it could allow _INI methods
      to be run within a not-present device subtree (If a
      not-present device had no _INI, _STA would not be run,
      the not-present status would not be discovered, and the
      children of the device would be incorrectly traversed.)
      
      Implemented a new _STA optimization where namespace
      subtrees that do not contain _INI are identified and
      ignored during device initialization. Selectively running
      _STA can significantly improve boot time on large machines
      (with assistance from Len Brown.)
      
      Implemented support for the device initialization case
      where the returned _STA flags indicate a device not-present
      but functioning. In this case, _INI is not run, but the
      device children are examined for presence, as per the
      ACPI specification.
      
      Implemented an additional change to the IndexField support
      in order to conform to MS behavior. The value written to
      the Index Register is not simply a byte offset, it is a
      byte offset in units of the access width of the parent
      Index Field. (Fiodor Suietov)
      
      Defined and deployed a new OSL interface,
      acpi_os_validate_address().  This interface is called during
      the creation of all AML operation regions, and allows
      the host OS to exert control over what addresses it will
      allow the AML code to access. Operation Regions whose
      addresses are disallowed will cause a runtime exception
      when they are actually accessed (will not affect or abort
      table loading.)
      
      Defined and deployed a new OSL interface,
      acpi_os_validate_interface().  This interface allows the host OS
      to match the various "optional" interface/behavior strings
      for the _OSI predefined control method as appropriate
      (with assistance from Bjorn Helgaas.)
      
      Restructured and corrected various problems in the
      exception handling code paths within DsCallControlMethod
      and DsTerminateControlMethod in dsmethod (with assistance
      from Takayoshi Kochi.)
      
      Modified the Linux source converter to ignore quoted string
      literals while converting identifiers from mixed to lower
      case. This will correct problems with the disassembler
      and other areas where such strings must not be modified.
      
      The ACPI_FUNCTION_* macros no longer require quotes around
      the function name. This allows the Linux source converter
      to convert the names, now that the converter ignores
      quoted strings.
      Signed-off-by: NBob Moore <robert.moore@intel.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      b229cf92
    • B
      [ACPI] ACPICA 20060317 · 61686124
      Bob Moore 提交于
      Implemented the use of a cache object for all internal
      namespace nodes. Since there are about 1000 static nodes
      in a typical system, this will decrease memory use for
      cache implementations that minimize per-allocation overhead
      (such as a slab allocator.)
      
      Removed the reference count mechanism for internal
      namespace nodes, since it was deemed unnecessary. This
      reduces the size of each namespace node by about 5%-10%
      on all platforms. Nodes are now 20 bytes for the 32-bit
      case, and 32 bytes for the 64-bit case.
      
      Optimized several internal data structures to reduce
      object size on 64-bit platforms by packing data within
      the 64-bit alignment. This includes the frequently used
      ACPI_OPERAND_OBJECT, of which there can be ~1000 static
      instances corresponding to the namespace objects.
      
      Added two new strings for the predefined _OSI method:
      "Windows 2001.1 SP1" and "Windows 2006".
      
      Split the allocation tracking mechanism out to a separate
      file, from utalloc.c to uttrack.c. This mechanism appears
      to be only useful for application-level code. Kernels may
      wish to not include uttrack.c in distributions.
      
      Removed all remnants of the obsolete ACPI_REPORT_* macros
      and the associated code. (These macros have been replaced
      by the ACPI_ERROR and ACPI_WARNING macros.)
      Signed-off-by: NBob Moore <robert.moore@intel.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      61686124
  13. 01 4月, 2006 1 次提交
  14. 27 3月, 2006 2 次提交
  15. 31 1月, 2006 1 次提交
    • B
      [ACPI] ACPICA 20060127 · b8e4d893
      Bob Moore 提交于
      Implemented support in the Resource Manager to allow
      unresolved namestring references within resource package
      objects for the _PRT method. This support is in addition
      to the previously implemented unresolved reference
      support within the AML parser. If the interpreter slack
      mode is enabled (true on Linux unless acpi=strict),
      these unresolved references will be passed through
      to the caller as a NULL package entry.
      http://bugzilla.kernel.org/show_bug.cgi?id=5741
      
      Implemented and deployed new macros and functions for
      error and warning messages across the subsystem. These
      macros are simpler and generate less code than their
      predecessors. The new macros ACPI_ERROR, ACPI_EXCEPTION,
      ACPI_WARNING, and ACPI_INFO replace the ACPI_REPORT_*
      macros.
      
      Implemented the acpi_cpu_flags type to simplify host OS
      integration of the Acquire/Release Lock OSL interfaces.
      Suggested by Steven Rostedt and Andrew Morton.
      
      Fixed a problem where Alias ASL operators are sometimes
      not correctly resolved. causing AE_AML_INTERNAL
      http://bugzilla.kernel.org/show_bug.cgi?id=5189
      http://bugzilla.kernel.org/show_bug.cgi?id=5674
      
      Fixed several problems with the implementation of the
      ConcatenateResTemplate ASL operator. As per the ACPI
      specification, zero length buffers are now treated as a
      single EndTag. One-length buffers always cause a fatal
      exception. Non-zero length buffers that do not end with
      a full 2-byte EndTag cause a fatal exception.
      
      Fixed a possible structure overwrite in the
      AcpiGetObjectInfo external interface. (With assistance
      from Thomas Renninger)
      Signed-off-by: NBob Moore <robert.moore@intel.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      b8e4d893
  16. 09 1月, 2006 1 次提交
  17. 04 1月, 2006 1 次提交
  18. 28 12月, 2005 1 次提交
  19. 10 12月, 2005 1 次提交
    • B
      [ACPI] ACPICA 20051021 · 0897831b
      Bob Moore 提交于
      Implemented support for the EM64T and other x86_64
      processors. This essentially entails recognizing
      that these processors support non-aligned memory
      transfers. Previously, all 64-bit processors were assumed
      to lack hardware support for non-aligned transfers.
      
      Completed conversion of the Resource Manager to nearly
      full table-driven operation. Specifically, the resource
      conversion code (convert AML to internal format and the
      reverse) and the debug code to dump internal resource
      descriptors are fully table-driven, reducing code and data
      size and improving maintainability.
      
      The OSL interfaces for Acquire and Release Lock now use a
      64-bit flag word on 64-bit processors instead of a fixed
      32-bit word. (Alexey Starikovskiy)
      
      Implemented support within the resource conversion code
      for the Type-Specific byte within the various ACPI 3.0
      *WordSpace macros.
      
      Fixed some issues within the resource conversion code for
      the type-specific flags for both Memory and I/O address
      resource descriptors. For Memory, implemented support
      for the MTP and TTP flags. For I/O, split the TRS and TTP
      flags into two separate fields.
      Signed-off-by: NBob Moore <robert.moore@intel.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      0897831b
  20. 07 11月, 2005 1 次提交
  21. 03 9月, 2005 1 次提交
  22. 26 8月, 2005 1 次提交
  23. 16 8月, 2005 1 次提交
  24. 05 8月, 2005 1 次提交
  25. 04 8月, 2005 1 次提交
  26. 14 7月, 2005 1 次提交
    • R
      ACPICA 20050617-0624 from Bob Moore <robert.moore@intel.com> · 73459f73
      Robert Moore 提交于
      ACPICA 20050617:
      
      Moved the object cache operations into the OS interface
      layer (OSL) to allow the host OS to handle these operations
      if desired (for example, the Linux OSL will invoke the
      slab allocator).  This support is optional; the compile
      time define ACPI_USE_LOCAL_CACHE may be used to utilize
      the original cache code in the ACPI CA core.  The new OSL
      interfaces are shown below.  See utalloc.c for an example
      implementation, and acpiosxf.h for the exact interface
      definitions.  Thanks to Alexey Starikovskiy.
      	acpi_os_create_cache
      	acpi_os_delete_cache
      	acpi_os_purge_cache
      	acpi_os_acquire_object
      	acpi_os_release_object
      
      Modified the interfaces to acpi_os_acquire_lock and
      acpi_os_release_lock to return and restore a flags
      parameter.  This fits better with many OS lock models.
      Note: the current execution state (interrupt handler
      or not) is no longer passed to these interfaces.  If
      necessary, the OSL must determine this state by itself, a
      simple and fast operation.  Thanks to Alexey Starikovskiy.
      
      Fixed a problem in the ACPI table handling where a valid
      XSDT was assumed present if the revision of the RSDP
      was 2 or greater.  According to the ACPI specification,
      the XSDT is optional in all cases, and the table manager
      therefore now checks for both an RSDP >=2 and a valid
      XSDT pointer.  Otherwise, the RSDT pointer is used.
      Some ACPI 2.0 compliant BIOSs contain only the RSDT.
      
      Fixed an interpreter problem with the Mid() operator in the
      case of an input string where the resulting output string
      is of zero length.  It now correctly returns a valid,
      null terminated string object instead of a string object
      with a null pointer.
      
      Fixed a problem with the control method argument handling
      to allow a store to an Arg object that already contains an
      object of type Device.  The Device object is now correctly
      overwritten.  Previously, an error was returned.
      
      ACPICA 20050624:
      
      Modified the new OSL cache interfaces to use ACPI_CACHE_T
      as the type for the host-defined cache object.  This allows
      the OSL implementation to define and type this object in
      any manner desired, simplifying the OSL implementation.
      For example, ACPI_CACHE_T is defined as kmem_cache_t for
      Linux, and should be defined in the OS-specific header
      file for other operating systems as required.
      
      Changed the interface to AcpiOsAcquireObject to directly
      return the requested object as the function return (instead
      of ACPI_STATUS.) This change was made for performance
      reasons, since this is the purpose of the interface in the
      first place.  acpi_os_acquire_object is now similar to the
      acpi_os_allocate interface.  Thanks to Alexey Starikovskiy.
      
      Modified the initialization sequence in
      acpi_initialize_subsystem to call the OSL interface
      acpi_osl_initialize first, before any local initialization.
      This change was required because the global initialization
      now calls OSL interfaces.
      
      Restructured the code base to split some files because
      of size and/or because the code logically belonged in a
      separate file.  New files are listed below.
      
        utilities/utcache.c	/* Local cache interfaces */
        utilities/utmutex.c	/* Local mutex support */
        utilities/utstate.c	/* State object support */
        parser/psloop.c	/* Main AML parse loop */
      Signed-off-by: NLen Brown <len.brown@intel.com>
      73459f73
  27. 12 7月, 2005 1 次提交
  28. 17 4月, 2005 1 次提交
    • L
      Linux-2.6.12-rc2 · 1da177e4
      Linus Torvalds 提交于
      Initial git repository build. I'm not bothering with the full history,
      even though we have it. We can create a separate "historical" git
      archive of that later if we want to, and in the meantime it's about
      3.2GB when imported into git - space that would just make the early
      git days unnecessarily complicated, when we don't have a lot of good
      infrastructure for it.
      
      Let it rip!
      1da177e4