aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-03-14 23:29:21 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2010-03-14 23:29:21 -0400
commita3d3203e4bb40f253b1541e310dc0f9305be7c84 (patch)
treeac0d74a607493053da92244a6763e503c5904f4f /lib
parentf937331b3f92cb2f67bc81baa1b8cc5198c439e5 (diff)
parentec28dcc6b4c00b78ad269ad5b85ebd5c2d504825 (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 'lib')
-rw-r--r--lib/vsprintf.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/lib/vsprintf.c b/lib/vsprintf.c
index 0d461c7c14db..24112e5a5780 100644
--- a/lib/vsprintf.c
+++ b/lib/vsprintf.c
@@ -609,6 +609,12 @@ static char *resource_string(char *buf, char *end, struct resource *res,
609 .precision = -1, 609 .precision = -1,
610 .flags = SPECIAL | SMALL | ZEROPAD, 610 .flags = SPECIAL | SMALL | ZEROPAD,
611 }; 611 };
612 static const struct printf_spec bus_spec = {
613 .base = 16,
614 .field_width = 2,
615 .precision = -1,
616 .flags = SMALL | ZEROPAD,
617 };
612 static const struct printf_spec dec_spec = { 618 static const struct printf_spec dec_spec = {
613 .base = 10, 619 .base = 10,
614 .precision = -1, 620 .precision = -1,
@@ -629,7 +635,7 @@ static char *resource_string(char *buf, char *end, struct resource *res,
629 * 64-bit res (sizeof==8): 20 chars in dec, 18 in hex ("0x" + 16) */ 635 * 64-bit res (sizeof==8): 20 chars in dec, 18 in hex ("0x" + 16) */
630#define RSRC_BUF_SIZE ((2 * sizeof(resource_size_t)) + 4) 636#define RSRC_BUF_SIZE ((2 * sizeof(resource_size_t)) + 4)
631#define FLAG_BUF_SIZE (2 * sizeof(res->flags)) 637#define FLAG_BUF_SIZE (2 * sizeof(res->flags))
632#define DECODED_BUF_SIZE sizeof("[mem - 64bit pref disabled]") 638#define DECODED_BUF_SIZE sizeof("[mem - 64bit pref window disabled]")
633#define RAW_BUF_SIZE sizeof("[mem - flags 0x]") 639#define RAW_BUF_SIZE sizeof("[mem - flags 0x]")
634 char sym[max(2*RSRC_BUF_SIZE + DECODED_BUF_SIZE, 640 char sym[max(2*RSRC_BUF_SIZE + DECODED_BUF_SIZE,
635 2*RSRC_BUF_SIZE + FLAG_BUF_SIZE + RAW_BUF_SIZE)]; 641 2*RSRC_BUF_SIZE + FLAG_BUF_SIZE + RAW_BUF_SIZE)];
@@ -651,6 +657,9 @@ static char *resource_string(char *buf, char *end, struct resource *res,
651 } else if (res->flags & IORESOURCE_DMA) { 657 } else if (res->flags & IORESOURCE_DMA) {
652 p = string(p, pend, "dma ", str_spec); 658 p = string(p, pend, "dma ", str_spec);
653 specp = &dec_spec; 659 specp = &dec_spec;
660 } else if (res->flags & IORESOURCE_BUS) {
661 p = string(p, pend, "bus ", str_spec);
662 specp = &bus_spec;
654 } else { 663 } else {
655 p = string(p, pend, "??? ", str_spec); 664 p = string(p, pend, "??? ", str_spec);
656 specp = &mem_spec; 665 specp = &mem_spec;
@@ -666,6 +675,8 @@ static char *resource_string(char *buf, char *end, struct resource *res,
666 p = string(p, pend, " 64bit", str_spec); 675 p = string(p, pend, " 64bit", str_spec);
667 if (res->flags & IORESOURCE_PREFETCH) 676 if (res->flags & IORESOURCE_PREFETCH)
668 p = string(p, pend, " pref", str_spec); 677 p = string(p, pend, " pref", str_spec);
678 if (res->flags & IORESOURCE_WINDOW)
679 p = string(p, pend, " window", str_spec);
669 if (res->flags & IORESOURCE_DISABLED) 680 if (res->flags & IORESOURCE_DISABLED)
670 p = string(p, pend, " disabled", str_spec); 681 p = string(p, pend, " disabled", str_spec);
671 } else { 682 } else {