1. 15 3月, 2010 1 次提交
  2. 05 11月, 2009 2 次提交
  3. 11 10月, 2008 2 次提交
  4. 02 8月, 2008 1 次提交
  5. 17 7月, 2008 5 次提交
    • B
      PNP: convert resource options to single linked list · 1f32ca31
      Bjorn Helgaas 提交于
      ISAPNP, PNPBIOS, and ACPI describe the "possible resource settings" of
      a device, i.e., the possibilities an OS bus driver has when it assigns
      I/O port, MMIO, and other resources to the device.
      
      PNP used to maintain this "possible resource setting" information in
      one independent option structure and a list of dependent option
      structures for each device.  Each of these option structures had lists
      of I/O, memory, IRQ, and DMA resources, for example:
      
        dev
          independent options
            ind-io0  -> ind-io1  ...
            ind-mem0 -> ind-mem1 ...
            ...
          dependent option set 0
            dep0-io0  -> dep0-io1  ...
            dep0-mem0 -> dep0-mem1 ...
            ...
          dependent option set 1
            dep1-io0  -> dep1-io1  ...
            dep1-mem0 -> dep1-mem1 ...
            ...
          ...
      
      This data structure was designed for ISAPNP, where the OS configures
      device resource settings by writing directly to configuration
      registers.  The OS can write the registers in arbitrary order much
      like it writes PCI BARs.
      
      However, for PNPBIOS and ACPI devices, the OS uses firmware interfaces
      that perform device configuration, and it is important to pass the
      desired settings to those interfaces in the correct order.  The OS
      learns the correct order by using firmware interfaces that return the
      "current resource settings" and "possible resource settings," but the
      option structures above doesn't store the ordering information.
      
      This patch replaces the independent and dependent lists with a single
      list of options.  For example, a device might have possible resource
      settings like this:
      
        dev
          options
            ind-io0 -> dep0-io0 -> dep1->io0 -> ind-io1 ...
      
      All the possible settings are in the same list, in the order they
      come from the firmware "possible resource settings" list.  Each entry
      is tagged with an independent/dependent flag.  Dependent entries also
      have a "set number" and an optional priority value.  All dependent
      entries must be assigned from the same set.  For example, the OS can
      use all the entries from dependent set 0, or all the entries from
      dependent set 1, but it cannot mix entries from set 0 with entries
      from set 1.
      
      Prior to this patch PNP didn't keep track of the order of this list,
      and it assigned all independent options first, then all dependent
      ones.  Using the example above, that resulted in a "desired
      configuration" list like this:
      
        ind->io0 -> ind->io1 -> depN-io0 ...
      
      instead of the list the firmware expects, which looks like this:
      
        ind->io0 -> depN-io0 -> ind-io1 ...
      Signed-off-by: NBjorn Helgaas <bjorn.helgaas@hp.com>
      Signed-off-by: NAndi Kleen <ak@linux.intel.com>
      Acked-by: NRene Herman <rene.herman@gmail.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      1f32ca31
    • B
      PNP: in debug resource dump, make empty list obvious · 819beac3
      Bjorn Helgaas 提交于
      If the resource list is empty, say that explicitly.  Previously,
      it was confusing because often the heading was followed by zero
      resource lines, then some "add resource" lines from auto-assignment,
      so the "add" lines looked like current resources.
      Signed-off-by: NBjorn Helgaas <bjorn.helgaas@hp.com>
      Signed-off-by: NAndi Kleen <ak@linux.intel.com>
      Acked-by: NRene Herman <rene.herman@gmail.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      819beac3
    • B
      PNP: replace pnp_resource_table with dynamically allocated resources · aee3ad81
      Bjorn Helgaas 提交于
      PNP used to have a fixed-size pnp_resource_table for tracking the
      resources used by a device.  This table often overflowed, so we've
      had to increase the table size, which wastes memory because most
      devices have very few resources.
      
      This patch replaces the table with a linked list of resources where
      the entries are allocated on demand.
      
      This removes messages like these:
      
          pnpacpi: exceeded the max number of IO resources
          00:01: too many I/O port resources
      
      References:
      
          http://bugzilla.kernel.org/show_bug.cgi?id=9535
          http://bugzilla.kernel.org/show_bug.cgi?id=9740
          http://lkml.org/lkml/2007/11/30/110
      
      This patch also changes the way PNP uses the IORESOURCE_UNSET,
      IORESOURCE_AUTO, and IORESOURCE_DISABLED flags.
      
      Prior to this patch, the pnp_resource_table entries used the flags
      like this:
      
          IORESOURCE_UNSET
      	This table entry is unused and available for use.  When this flag
      	is set, we shouldn't look at anything else in the resource structure.
      	This flag is set when a resource table entry is initialized.
      
          IORESOURCE_AUTO
      	This resource was assigned automatically by pnp_assign_{io,mem,etc}().
      
      	This flag is set when a resource table entry is initialized and
      	cleared whenever we discover a resource setting by reading an ISAPNP
      	config register, parsing a PNPBIOS resource data stream, parsing an
      	ACPI _CRS list, or interpreting a sysfs "set" command.
      
      	Resources marked IORESOURCE_AUTO are reinitialized and marked as
      	IORESOURCE_UNSET by pnp_clean_resource_table() in these cases:
      
      	    - before we attempt to assign resources automatically,
      	    - if we fail to assign resources automatically,
      	    - after disabling a device
      
          IORESOURCE_DISABLED
      	Set by pnp_assign_{io,mem,etc}() when automatic assignment fails.
      	Also set by PNPBIOS and PNPACPI for:
      
      	    - invalid IRQs or GSI registration failures
      	    - invalid DMA channels
      	    - I/O ports above 0x10000
      	    - mem ranges with negative length
      
      After this patch, there is no pnp_resource_table, and the resource list
      entries use the flags like this:
      
          IORESOURCE_UNSET
      	This flag is no longer used in PNP.  Instead of keeping
      	IORESOURCE_UNSET entries in the resource list, we remove
      	entries from the list and free them.
      
          IORESOURCE_AUTO
      	No change in meaning: it still means the resource was assigned
      	automatically by pnp_assign_{port,mem,etc}(), but these functions
      	now set the bit explicitly.
      
      	We still "clean" a device's resource list in the same places,
      	but rather than reinitializing IORESOURCE_AUTO entries, we
      	just remove them from the list.
      
      	Note that IORESOURCE_AUTO entries are always at the end of the
      	list, so removing them doesn't reorder other list entries.
      	This is because non-IORESOURCE_AUTO entries are added by the
      	ISAPNP, PNPBIOS, or PNPACPI "get resources" methods and by the
      	sysfs "set" command.  In each of these cases, we completely free
      	the resource list first.
      
          IORESOURCE_DISABLED
      	In addition to the cases where we used to set this flag, ISAPNP now
      	adds an IORESOURCE_DISABLED resource when it reads a configuration
      	register with a "disabled" value.
      Signed-off-by: NBjorn Helgaas <bjorn.helgaas@hp.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      Signed-off-by: NAndi Kleen <ak@linux.intel.com>
      aee3ad81
    • B
      PNP: add pnp_resource_type_name() helper function · 9fdee4e0
      Bjorn Helgaas 提交于
      This patch adds a "pnp_resource_type_name(struct resource *)" that
      returns the string resource type.  This will be used by the sysfs
      "show resources" function and the debug resource dump function.
      Signed-off-by: NBjorn Helgaas <bjorn.helgaas@hp.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      Signed-off-by: NAndi Kleen <ak@linux.intel.com>
      9fdee4e0
    • B
      PNP: add detail to debug resource dump · b897f46c
      Bjorn Helgaas 提交于
      In the debug resource dump, decode the flags and indicate when
      a resource is disabled or has been automatically assigned.
      Signed-off-by: NBjorn Helgaas <bjorn.helgaas@hp.com>
      Signed-off-by: NLen Brown <len.brown@intel.com>
      Signed-off-by: NAndi Kleen <ak@linux.intel.com>
      b897f46c
  6. 15 5月, 2008 1 次提交
  7. 29 4月, 2008 3 次提交
  8. 27 7月, 2007 2 次提交
  9. 01 7月, 2006 1 次提交
  10. 08 9月, 2005 1 次提交
  11. 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