diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-14 23:29:21 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-14 23:29:21 -0400 |
commit | a3d3203e4bb40f253b1541e310dc0f9305be7c84 (patch) | |
tree | ac0d74a607493053da92244a6763e503c5904f4f /drivers/pnp/resource.c | |
parent | f937331b3f92cb2f67bc81baa1b8cc5198c439e5 (diff) | |
parent | ec28dcc6b4c00b78ad269ad5b85ebd5c2d504825 (diff) |
Merge branch 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6
* 'release' of git://git.kernel.org/pub/scm/linux/kernel/git/lenb/linux-acpi-2.6: (34 commits)
ACPI: processor: push file static MADT pointer into internal map_madt_entry()
ACPI: processor: refactor internal map_lsapic_id()
ACPI: processor: refactor internal map_x2apic_id()
ACPI: processor: refactor internal map_lapic_id()
ACPI: processor: driver doesn't need to evaluate _PDC
ACPI: processor: remove early _PDC optin quirks
ACPI: processor: add internal processor_physically_present()
ACPI: processor: move acpi_get_cpuid into processor_core.c
ACPI: processor: export acpi_get_cpuid()
ACPI: processor: mv processor_pdc.c processor_core.c
ACPI: processor: mv processor_core.c processor_driver.c
ACPI: plan to delete "acpi=ht" boot option
ACPI: remove "acpi=ht" DMI blacklist
PNPACPI: add bus number support
PNPACPI: add window support
resource: add window support
resource: add bus number support
resource: expand IORESOURCE_TYPE_BITS to make room for bus resource type
acpiphp: Execute ACPI _REG method for hotadded devices
ACPI video: Be more liberal in validating _BQC behaviour
...
Diffstat (limited to 'drivers/pnp/resource.c')
-rw-r--r-- | drivers/pnp/resource.c | 27 |
1 files changed, 26 insertions, 1 deletions
diff --git a/drivers/pnp/resource.c b/drivers/pnp/resource.c index 64d0596bafb5..5b277dbaacde 100644 --- a/drivers/pnp/resource.c +++ b/drivers/pnp/resource.c | |||
@@ -470,7 +470,8 @@ int pnp_check_dma(struct pnp_dev *dev, struct resource *res) | |||
470 | unsigned long pnp_resource_type(struct resource *res) | 470 | unsigned long pnp_resource_type(struct resource *res) |
471 | { | 471 | { |
472 | return res->flags & (IORESOURCE_IO | IORESOURCE_MEM | | 472 | return res->flags & (IORESOURCE_IO | IORESOURCE_MEM | |
473 | IORESOURCE_IRQ | IORESOURCE_DMA); | 473 | IORESOURCE_IRQ | IORESOURCE_DMA | |
474 | IORESOURCE_BUS); | ||
474 | } | 475 | } |
475 | 476 | ||
476 | struct resource *pnp_get_resource(struct pnp_dev *dev, | 477 | struct resource *pnp_get_resource(struct pnp_dev *dev, |
@@ -590,6 +591,30 @@ struct pnp_resource *pnp_add_mem_resource(struct pnp_dev *dev, | |||
590 | return pnp_res; | 591 | return pnp_res; |
591 | } | 592 | } |
592 | 593 | ||
594 | struct pnp_resource *pnp_add_bus_resource(struct pnp_dev *dev, | ||
595 | resource_size_t start, | ||
596 | resource_size_t end) | ||
597 | { | ||
598 | struct pnp_resource *pnp_res; | ||
599 | struct resource *res; | ||
600 | |||
601 | pnp_res = pnp_new_resource(dev); | ||
602 | if (!pnp_res) { | ||
603 | dev_err(&dev->dev, "can't add resource for BUS %#llx-%#llx\n", | ||
604 | (unsigned long long) start, | ||
605 | (unsigned long long) end); | ||
606 | return NULL; | ||
607 | } | ||
608 | |||
609 | res = &pnp_res->res; | ||
610 | res->flags = IORESOURCE_BUS; | ||
611 | res->start = start; | ||
612 | res->end = end; | ||
613 | |||
614 | pnp_dbg(&dev->dev, " add %pr\n", res); | ||
615 | return pnp_res; | ||
616 | } | ||
617 | |||
593 | /* | 618 | /* |
594 | * Determine whether the specified resource is a possible configuration | 619 | * Determine whether the specified resource is a possible configuration |
595 | * for this device. | 620 | * for this device. |