* Reworked 64bit resource patches
@ 2006-06-13 0:30 Greg KH
2006-06-13 0:31 ` [PATCH 01/16] 64bit resource: C99 changes for struct resource declarations Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:30 UTC (permalink / raw)
To: linux-kernel; +Cc: vgoyal
Currently the -mm tree (and my pci quilt tree) has a series of patches
that enable 64bit resource sizes. It was originally done by Vivek
Goyal, and that work was based on something done by someone else before
that (sorry, can't remember that far back anymore...)
Anyway, here's a rework of that series of patches. It drops the number
of patches from 24 to 16, and enables the tree to build at any step
along the way. It also doesn't change the same lines twice (as the old
series did).
The end result is _identical_ to Vivek's patches, but will now play
nicer when ending up in the main kernel git tree.
If anyone has any comments on these, please let me know.
thanks,
greg k-h
^ permalink raw reply [flat|nested] 34+ messages in thread
* [PATCH 01/16] 64bit resource: C99 changes for struct resource declarations
2006-06-13 0:30 Reworked 64bit resource patches Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 02/16] 64bit resource: fix up printks for resources in sound drivers Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
Based on an original patch from Ralf Baechle <ralf@linux-mips.org> and
Vivek Goyal <vgoyal@in.ibm.com>. This is needed in order to prepare for
changing the size of resources.
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
arch/arm/kernel/setup.c | 42 ++++++++-
arch/mips/au1000/common/pci.c | 16 ++-
arch/mips/cobalt/setup.c | 41 +++++++--
arch/mips/ddb5xxx/ddb5476/setup.c | 37 +++++++-
arch/mips/ite-boards/generic/it8172_setup.c | 74 +++++++++++++---
arch/mips/jmr3927/rbhma3100/setup.c | 59 ++++++++++---
arch/mips/pci/ops-it8172.c | 34 +++----
arch/mips/pci/pci-ddb5074.c | 16 ++-
arch/mips/pci/pci-ddb5476.c | 16 ++-
arch/mips/pci/pci-ddb5477.c | 32 +++----
arch/mips/pci/pci-jmr3927.c | 16 ++-
arch/mips/pci/pci-ocelot.c | 8 +-
arch/mips/pci/pci-yosemite.c | 10 ++
arch/mips/philips/pnx8550/common/pci.c | 16 ++-
arch/mips/philips/pnx8550/common/setup.c | 25 +++++
arch/mips/sni/setup.c | 126 +++++++++++++++++++++++----
arch/mips/tx4938/toshiba_rbtx4938/setup.c | 5 +
17 files changed, 424 insertions(+), 149 deletions(-)
diff --git a/drivers/video/console/vgacon.c b/drivers/video/console/vgacon.c
index d5a04b6..7b2d9b7 100644
--- a/drivers/video/console/vgacon.c
+++ b/drivers/video/console/vgacon.c
@@ -389,7 +389,7 @@ #endif
vga_video_port_val = VGA_CRT_DM;
if ((ORIG_VIDEO_EGA_BX & 0xff) != 0x10) {
static struct resource ega_console_resource =
- { "ega", 0x3B0, 0x3BF };
+ { .name = "ega", .start = 0x3B0, .end = 0x3BF };
vga_video_type = VIDEO_TYPE_EGAM;
vga_vram_end = 0xb8000;
display_desc = "EGA+";
@@ -397,9 +397,9 @@ #endif
&ega_console_resource);
} else {
static struct resource mda1_console_resource =
- { "mda", 0x3B0, 0x3BB };
+ { .name = "mda", .start = 0x3B0, .end = 0x3BB };
static struct resource mda2_console_resource =
- { "mda", 0x3BF, 0x3BF };
+ { .name = "mda", .start = 0x3BF, .end = 0x3BF };
vga_video_type = VIDEO_TYPE_MDA;
vga_vram_end = 0xb2000;
display_desc = "*MDA";
@@ -422,14 +422,14 @@ #endif
if (!ORIG_VIDEO_ISVGA) {
static struct resource ega_console_resource
- = { "ega", 0x3C0, 0x3DF };
+ = { .name = "ega", .start = 0x3C0, .end = 0x3DF };
vga_video_type = VIDEO_TYPE_EGAC;
display_desc = "EGA";
request_resource(&ioport_resource,
&ega_console_resource);
} else {
static struct resource vga_console_resource
- = { "vga+", 0x3C0, 0x3DF };
+ = { .name = "vga+", .start = 0x3C0, .end = 0x3DF };
vga_video_type = VIDEO_TYPE_VGAC;
display_desc = "VGA+";
request_resource(&ioport_resource,
@@ -473,7 +473,7 @@ #endif
}
} else {
static struct resource cga_console_resource =
- { "cga", 0x3D4, 0x3D5 };
+ { .name = "cga", .start = 0x3D4, .end = 0x3D5 };
vga_video_type = VIDEO_TYPE_CGA;
vga_vram_end = 0xba000;
display_desc = "*CGA";
diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c
index 9fc9af8..d694127 100644
--- a/arch/arm/kernel/setup.c
+++ b/arch/arm/kernel/setup.c
@@ -119,9 +119,24 @@ DEFINE_PER_CPU(struct cpuinfo_arm, cpu_d
* Standard memory resources
*/
static struct resource mem_res[] = {
- { "Video RAM", 0, 0, IORESOURCE_MEM },
- { "Kernel text", 0, 0, IORESOURCE_MEM },
- { "Kernel data", 0, 0, IORESOURCE_MEM }
+ {
+ .name = "Video RAM",
+ .start = 0,
+ .end = 0,
+ .flags = IORESOURCE_MEM
+ },
+ {
+ .name = "Kernel text",
+ .start = 0,
+ .end = 0,
+ .flags = IORESOURCE_MEM
+ },
+ {
+ .name = "Kernel data",
+ .start = 0,
+ .end = 0,
+ .flags = IORESOURCE_MEM
+ }
};
#define video_ram mem_res[0]
@@ -129,9 +144,24 @@ #define kernel_code mem_res[1]
#define kernel_data mem_res[2]
static struct resource io_res[] = {
- { "reserved", 0x3bc, 0x3be, IORESOURCE_IO | IORESOURCE_BUSY },
- { "reserved", 0x378, 0x37f, IORESOURCE_IO | IORESOURCE_BUSY },
- { "reserved", 0x278, 0x27f, IORESOURCE_IO | IORESOURCE_BUSY }
+ {
+ .name = "reserved",
+ .start = 0x3bc,
+ .end = 0x3be,
+ .flags = IORESOURCE_IO | IORESOURCE_BUSY
+ },
+ {
+ .name = "reserved",
+ .start = 0x378,
+ .end = 0x37f,
+ .flags = IORESOURCE_IO | IORESOURCE_BUSY
+ },
+ {
+ .name = "reserved",
+ .start = 0x278,
+ .end = 0x27f,
+ .flags = IORESOURCE_IO | IORESOURCE_BUSY
+ }
};
#define lp0 io_res[0]
diff --git a/arch/mips/au1000/common/pci.c b/arch/mips/au1000/common/pci.c
index 4e5a6e1..b1392ab 100644
--- a/arch/mips/au1000/common/pci.c
+++ b/arch/mips/au1000/common/pci.c
@@ -40,17 +40,17 @@ #include <asm/mach-au1x00/au1000.h>
/* TBD */
static struct resource pci_io_resource = {
- "pci IO space",
- (u32)PCI_IO_START,
- (u32)PCI_IO_END,
- IORESOURCE_IO
+ .start = PCI_IO_START,
+ .end = PCI_IO_END,
+ .name = "PCI IO space",
+ .flags = IORESOURCE_IO
};
static struct resource pci_mem_resource = {
- "pci memory space",
- (u32)PCI_MEM_START,
- (u32)PCI_MEM_END,
- IORESOURCE_MEM
+ .start = PCI_MEM_START,
+ .end = PCI_MEM_END,
+ .name = "PCI memory space",
+ .flags = IORESOURCE_MEM
};
extern struct pci_ops au1x_pci_ops;
diff --git a/arch/mips/cobalt/setup.c b/arch/mips/cobalt/setup.c
index 4f9ea12..928431a 100644
--- a/arch/mips/cobalt/setup.c
+++ b/arch/mips/cobalt/setup.c
@@ -68,19 +68,46 @@ static void __init cobalt_timer_setup(st
extern struct pci_ops gt64111_pci_ops;
static struct resource cobalt_mem_resource = {
- "PCI memory", GT64111_MEM_BASE, GT64111_MEM_END, IORESOURCE_MEM
+ .start = GT64111_MEM_BASE,
+ .end = GT64111_MEM_END,
+ .name = "PCI memory",
+ .flags = IORESOURCE_MEM
};
static struct resource cobalt_io_resource = {
- "PCI I/O", 0x1000, 0xffff, IORESOURCE_IO
+ .start = 0x1000,
+ .end = 0xffff,
+ .name = "PCI I/O",
+ .flags = IORESOURCE_IO
};
static struct resource cobalt_io_resources[] = {
- { "dma1", 0x00, 0x1f, IORESOURCE_BUSY },
- { "timer", 0x40, 0x5f, IORESOURCE_BUSY },
- { "keyboard", 0x60, 0x6f, IORESOURCE_BUSY },
- { "dma page reg", 0x80, 0x8f, IORESOURCE_BUSY },
- { "dma2", 0xc0, 0xdf, IORESOURCE_BUSY },
+ {
+ .start = 0x00,
+ .end = 0x1f,
+ .name = "dma1",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x40,
+ .end = 0x5f,
+ .name = "timer",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x60,
+ .end = 0x6f,
+ .name = "keyboard",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x80,
+ .end = 0x8f,
+ .name = "dma page reg",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0xc0,
+ .end = 0xdf,
+ .name = "dma2",
+ .flags = IORESOURCE_BUSY
+ },
};
#define COBALT_IO_RESOURCES (sizeof(cobalt_io_resources)/sizeof(struct resource))
diff --git a/arch/mips/ddb5xxx/ddb5476/setup.c b/arch/mips/ddb5xxx/ddb5476/setup.c
index c902ade..fc8d8bb 100644
--- a/arch/mips/ddb5xxx/ddb5476/setup.c
+++ b/arch/mips/ddb5xxx/ddb5476/setup.c
@@ -109,17 +109,42 @@ static struct {
struct resource dma2;
} ddb5476_ioport = {
{
- "dma1", 0x00, 0x1f, IORESOURCE_BUSY}, {
- "timer", 0x40, 0x5f, IORESOURCE_BUSY}, {
- "rtc", 0x70, 0x7f, IORESOURCE_BUSY}, {
- "dma page reg", 0x80, 0x8f, IORESOURCE_BUSY}, {
- "dma2", 0xc0, 0xdf, IORESOURCE_BUSY}
+ .start = 0x00,
+ .end = 0x1f,
+ .name = "dma1",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x40,
+ .end = 0x5f,
+ .name = "timer",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x70,
+ .end = 0x7f,
+ .name = "rtc",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x80,
+ .end = 0x8f,
+ .name = "dma page reg",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0xc0,
+ .end = 0xdf,
+ .name = "dma2",
+ .flags = IORESOURCE_BUSY
+ }
};
static struct {
struct resource nile4;
} ddb5476_iomem = {
- { "Nile 4", DDB_BASE, DDB_BASE + DDB_SIZE - 1, IORESOURCE_BUSY}
+ {
+ .start = DDB_BASE,
+ .end = DDB_BASE + DDB_SIZE - 1,
+ .name = "Nile 4",
+ .flags = IORESOURCE_BUSY
+ }
};
diff --git a/arch/mips/ite-boards/generic/it8172_setup.c b/arch/mips/ite-boards/generic/it8172_setup.c
index fc73c8d..00844e6 100644
--- a/arch/mips/ite-boards/generic/it8172_setup.c
+++ b/arch/mips/ite-boards/generic/it8172_setup.c
@@ -72,11 +72,29 @@ struct {
struct resource flash;
struct resource boot;
} it8172_resources = {
- { "RAM", 0, 0, IORESOURCE_MEM }, /* to be initted */
- { "PCI Mem", 0x10000000, 0x13FFFFFF, IORESOURCE_MEM },
- { "PCI I/O", 0x14000000, 0x17FFFFFF },
- { "Flash", 0x08000000, 0x0CFFFFFF },
- { "Boot ROM", 0x1FC00000, 0x1FFFFFFF }
+ {
+ .start = 0, /* to be initted */
+ .end = 0,
+ .name = "RAM",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x10000000,
+ .end = 0x13FFFFFF,
+ .name = "PCI Mem",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x14000000,
+ .end = 0x17FFFFFF
+ .name = "PCI I/O",
+ }, {
+ .start = 0x08000000,
+ .end = 0x0CFFFFFF
+ .name = "Flash",
+ }, {
+ .start = 0x1FC00000,
+ .end = 0x1FFFFFFF
+ .name = "Boot ROM",
+ }
};
#else
struct {
@@ -89,14 +107,44 @@ struct {
struct resource flash;
struct resource boot;
} it8172_resources = {
- { "RAM", 0, 0, IORESOURCE_MEM }, /* to be initted */
- { "PCI Mem0", 0x0C000000, 0x0FFFFFFF, IORESOURCE_MEM },
- { "PCI Mem1", 0x10000000, 0x13FFFFFF, IORESOURCE_MEM },
- { "PCI I/O", 0x14000000, 0x17FFFFFF },
- { "PCI Mem2", 0x1A000000, 0x1BFFFFFF, IORESOURCE_MEM },
- { "PCI Mem3", 0x1C000000, 0x1FBFFFFF, IORESOURCE_MEM },
- { "Flash", 0x08000000, 0x0CFFFFFF },
- { "Boot ROM", 0x1FC00000, 0x1FFFFFFF }
+ {
+ .start = 0, /* to be initted */
+ .end = 0,
+ .name = "RAM",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x0C000000,
+ .end = 0x0FFFFFFF,
+ .name = "PCI Mem0",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x10000000,
+ .end = 0x13FFFFFF,
+ .name = "PCI Mem1",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x14000000,
+ .end = 0x17FFFFFF
+ .name = "PCI I/O",
+ }, {
+ .start = 0x1A000000,
+ .end = 0x1BFFFFFF,
+ .name = "PCI Mem2",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x1C000000,
+ .end = 0x1FBFFFFF,
+ .name = "PCI Mem3",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x08000000,
+ .end = 0x0CFFFFFF
+ .name = "Flash",
+ }, {
+ .start = 0x1FC00000,
+ .end = 0x1FFFFFFF
+ .name = "Boot ROM",
+ }
};
#endif
diff --git a/arch/mips/jmr3927/rbhma3100/setup.c b/arch/mips/jmr3927/rbhma3100/setup.c
index 9359cc4..1f13655 100644
--- a/arch/mips/jmr3927/rbhma3100/setup.c
+++ b/arch/mips/jmr3927/rbhma3100/setup.c
@@ -82,17 +82,54 @@ struct {
struct resource sio0;
struct resource sio1;
} jmr3927_resources = {
- { "RAM0", 0, 0x01FFFFFF, IORESOURCE_MEM },
- { "RAM1", 0x02000000, 0x03FFFFFF, IORESOURCE_MEM },
- { "PCIMEM", 0x08000000, 0x07FFFFFF, IORESOURCE_MEM },
- { "IOB", 0x10000000, 0x13FFFFFF },
- { "IOC", 0x14000000, 0x14FFFFFF },
- { "PCIIO", 0x15000000, 0x15FFFFFF },
- { "JMY1394", 0x1D000000, 0x1D3FFFFF },
- { "ROM1", 0x1E000000, 0x1E3FFFFF },
- { "ROM0", 0x1FC00000, 0x1FFFFFFF },
- { "SIO0", 0xFFFEF300, 0xFFFEF3FF },
- { "SIO1", 0xFFFEF400, 0xFFFEF4FF },
+ {
+ .start = 0,
+ .end = 0x01FFFFFF,
+ .name = "RAM0",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x02000000,
+ .end = 0x03FFFFFF,
+ .name = "RAM1",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x08000000,
+ .end = 0x07FFFFFF,
+ .name = "PCIMEM",
+ .flags = IORESOURCE_MEM
+ }, {
+ .start = 0x10000000,
+ .end = 0x13FFFFFF,
+ .name = "IOB"
+ }, {
+ .start = 0x14000000,
+ .end = 0x14FFFFFF,
+ .name = "IOC"
+ }, {
+ .start = 0x15000000,
+ .end = 0x15FFFFFF,
+ .name = "PCIIO"
+ }, {
+ .start = 0x1D000000,
+ .end = 0x1D3FFFFF,
+ .name = "JMY1394"
+ }, {
+ .start = 0x1E000000,
+ .end = 0x1E3FFFFF,
+ .name = "ROM1"
+ }, {
+ .start = 0x1FC00000,
+ .end = 0x1FFFFFFF,
+ .name = "ROM0"
+ }, {
+ .start = 0xFFFEF300,
+ .end = 0xFFFEF3FF,
+ .name = "SIO0"
+ }, {
+ .start = 0xFFFEF400,
+ .end = 0xFFFEF4FF,
+ .name = "SIO1"
+ },
};
/* don't enable - see errata */
diff --git a/arch/mips/pci/ops-it8172.c b/arch/mips/pci/ops-it8172.c
index b7a8b9a..ba83285 100644
--- a/arch/mips/pci/ops-it8172.c
+++ b/arch/mips/pci/ops-it8172.c
@@ -50,30 +50,28 @@ #endif
static struct resource pci_mem_resource_1;
static struct resource pci_io_resource = {
- "io pci IO space",
- 0x14018000,
- 0x17FFFFFF,
- IORESOURCE_IO
+ .start = 0x14018000,
+ .end = 0x17FFFFFF,
+ .name = "io pci IO space",
+ .flags = IORESOURCE_IO
};
static struct resource pci_mem_resource_0 = {
- "ext pci memory space 0/1",
- 0x10101000,
- 0x13FFFFFF,
- IORESOURCE_MEM,
- &pci_mem_resource_0,
- NULL,
- &pci_mem_resource_1
+ .start = 0x10101000,
+ .end = 0x13FFFFFF,
+ .name = "ext pci memory space 0/1",
+ .flags = IORESOURCE_MEM,
+ .parent = &pci_mem_resource_0,
+ .sibling = NULL,
+ .child = &pci_mem_resource_1
};
static struct resource pci_mem_resource_1 = {
- "ext pci memory space 2/3",
- 0x1A000000,
- 0x1FBFFFFF,
- IORESOURCE_MEM,
- &pci_mem_resource_0,
- NULL,
- NULL
+ .start = 0x1A000000,
+ .end = 0x1FBFFFFF,
+ .name = "ext pci memory space 2/3",
+ .flags = IORESOURCE_MEM,
+ .parent = &pci_mem_resource_0
};
extern struct pci_ops it8172_pci_ops;
diff --git a/arch/mips/pci/pci-ddb5074.c b/arch/mips/pci/pci-ddb5074.c
index 73f9cee..b74158d 100644
--- a/arch/mips/pci/pci-ddb5074.c
+++ b/arch/mips/pci/pci-ddb5074.c
@@ -8,17 +8,17 @@ #include <asm/debug.h>
#include <asm/ddb5xxx/ddb5xxx.h>
static struct resource extpci_io_resource = {
- "pci IO space",
- 0x1000, /* leave some room for ISA bus */
- DDB_PCI_IO_SIZE - 1,
- IORESOURCE_IO
+ .start = 0x1000, /* leave some room for ISA bus */
+ .end = DDB_PCI_IO_SIZE - 1,
+ .name = "pci IO space",
+ .flags = IORESOURCE_IO
};
static struct resource extpci_mem_resource = {
- "pci memory space",
- DDB_PCI_MEM_BASE + 0x00100000, /* leave 1 MB for RTC */
- DDB_PCI_MEM_BASE + DDB_PCI_MEM_SIZE - 1,
- IORESOURCE_MEM
+ .start = DDB_PCI_MEM_BASE + 0x00100000, /* leave 1 MB for RTC */
+ .end = DDB_PCI_MEM_BASE + DDB_PCI_MEM_SIZE - 1,
+ .name = "pci memory space",
+ .flags = IORESOURCE_MEM
};
extern struct pci_ops ddb5476_ext_pci_ops;
diff --git a/arch/mips/pci/pci-ddb5476.c b/arch/mips/pci/pci-ddb5476.c
index 90dd495..2f44c0b 100644
--- a/arch/mips/pci/pci-ddb5476.c
+++ b/arch/mips/pci/pci-ddb5476.c
@@ -8,17 +8,17 @@ #include <asm/debug.h>
#include <asm/ddb5xxx/ddb5xxx.h>
static struct resource extpci_io_resource = {
- "pci IO space",
- 0x1000, /* leave some room for ISA bus */
- DDB_PCI_IO_SIZE - 1,
- IORESOURCE_IO
+ .start = 0x1000, /* leave some room for ISA bus */
+ .end = DDB_PCI_IO_SIZE - 1,
+ .name = "pci IO space",
+ .flags = IORESOURCE_IO
};
static struct resource extpci_mem_resource = {
- "pci memory space",
- DDB_PCI_MEM_BASE + 0x00100000, /* leave 1 MB for RTC */
- DDB_PCI_MEM_BASE + DDB_PCI_MEM_SIZE - 1,
- IORESOURCE_MEM
+ .start = DDB_PCI_MEM_BASE + 0x00100000, /* leave 1 MB for RTC */
+ .end = DDB_PCI_MEM_BASE + DDB_PCI_MEM_SIZE - 1,
+ .name = "pci memory space",
+ .flags = IORESOURCE_MEM
};
extern struct pci_ops ddb5476_ext_pci_ops;
diff --git a/arch/mips/pci/pci-ddb5477.c b/arch/mips/pci/pci-ddb5477.c
index 826d653..d071bc3 100644
--- a/arch/mips/pci/pci-ddb5477.c
+++ b/arch/mips/pci/pci-ddb5477.c
@@ -22,31 +22,31 @@ #include <asm/debug.h>
#include <asm/ddb5xxx/ddb5xxx.h>
static struct resource extpci_io_resource = {
- "ext pci IO space",
- DDB_PCI0_IO_BASE - DDB_PCI_IO_BASE + 0x4000,
- DDB_PCI0_IO_BASE - DDB_PCI_IO_BASE + DDB_PCI0_IO_SIZE - 1,
- IORESOURCE_IO
+ .start = DDB_PCI0_IO_BASE - DDB_PCI_IO_BASE + 0x4000,
+ .end = DDB_PCI0_IO_BASE - DDB_PCI_IO_BASE + DDB_PCI0_IO_SIZE - 1,
+ .name = "ext pci IO space",
+ .flags = IORESOURCE_IO
};
static struct resource extpci_mem_resource = {
- "ext pci memory space",
- DDB_PCI0_MEM_BASE + 0x100000,
- DDB_PCI0_MEM_BASE + DDB_PCI0_MEM_SIZE - 1,
- IORESOURCE_MEM
+ .start = DDB_PCI0_MEM_BASE + 0x100000,
+ .end = DDB_PCI0_MEM_BASE + DDB_PCI0_MEM_SIZE - 1,
+ .name = "ext pci memory space",
+ .flags = IORESOURCE_MEM
};
static struct resource iopci_io_resource = {
- "io pci IO space",
- DDB_PCI1_IO_BASE - DDB_PCI_IO_BASE,
- DDB_PCI1_IO_BASE - DDB_PCI_IO_BASE + DDB_PCI1_IO_SIZE - 1,
- IORESOURCE_IO
+ .start = DDB_PCI1_IO_BASE - DDB_PCI_IO_BASE,
+ .end = DDB_PCI1_IO_BASE - DDB_PCI_IO_BASE + DDB_PCI1_IO_SIZE - 1,
+ .name = "io pci IO space",
+ .flags = IORESOURCE_IO
};
static struct resource iopci_mem_resource = {
- "ext pci memory space",
- DDB_PCI1_MEM_BASE,
- DDB_PCI1_MEM_BASE + DDB_PCI1_MEM_SIZE - 1,
- IORESOURCE_MEM
+ .start = DDB_PCI1_MEM_BASE,
+ .end = DDB_PCI1_MEM_BASE + DDB_PCI1_MEM_SIZE - 1,
+ .name = "ext pci memory space",
+ .flags = IORESOURCE_MEM
};
extern struct pci_ops ddb5477_ext_pci_ops;
diff --git a/arch/mips/pci/pci-jmr3927.c b/arch/mips/pci/pci-jmr3927.c
index f02ef6e..cb84f4e 100644
--- a/arch/mips/pci/pci-jmr3927.c
+++ b/arch/mips/pci/pci-jmr3927.c
@@ -35,17 +35,17 @@ #include <asm/jmr3927/jmr3927.h>
#include <asm/debug.h>
struct resource pci_io_resource = {
- "IO MEM",
- 0x1000, /* reserve regacy I/O space */
- 0x1000 + JMR3927_PCIIO_SIZE - 1,
- IORESOURCE_IO
+ .name = "IO MEM",
+ .start = 0x1000, /* reserve regacy I/O space */
+ .end = 0x1000 + JMR3927_PCIIO_SIZE - 1,
+ .flags = IORESOURCE_IO
};
struct resource pci_mem_resource = {
- "PCI MEM",
- JMR3927_PCIMEM,
- JMR3927_PCIMEM + JMR3927_PCIMEM_SIZE - 1,
- IORESOURCE_MEM
+ .name = "PCI MEM",
+ .start = JMR3927_PCIMEM,
+ .end = JMR3927_PCIMEM + JMR3927_PCIMEM_SIZE - 1,
+ .flags = IORESOURCE_MEM
};
extern struct pci_ops jmr3927_pci_ops;
diff --git a/arch/mips/pci/pci-ocelot.c b/arch/mips/pci/pci-ocelot.c
index 3da8a4e..2b9495d 100644
--- a/arch/mips/pci/pci-ocelot.c
+++ b/arch/mips/pci/pci-ocelot.c
@@ -71,13 +71,13 @@ static inline void pci0WriteConfigReg(un
}
static struct resource ocelot_mem_resource = {
- iomem_resource.start = GT_PCI_MEM_BASE;
- iomem_resource.end = GT_PCI_MEM_BASE + GT_PCI_MEM_BASE - 1;
+ start = GT_PCI_MEM_BASE;
+ end = GT_PCI_MEM_BASE + GT_PCI_MEM_BASE - 1;
};
static struct resource ocelot_io_resource = {
- ioport_resource.start = GT_PCI_IO_BASE;
- ioport_resource.end = GT_PCI_IO_BASE + GT_PCI_IO_SIZE - 1;
+ start = GT_PCI_IO_BASE;
+ end = GT_PCI_IO_BASE + GT_PCI_IO_SIZE - 1;
};
static struct pci_controller ocelot_pci_controller = {
diff --git a/arch/mips/pci/pci-yosemite.c b/arch/mips/pci/pci-yosemite.c
index dac9ed4..0357946 100644
--- a/arch/mips/pci/pci-yosemite.c
+++ b/arch/mips/pci/pci-yosemite.c
@@ -14,7 +14,10 @@ #include <asm/titan_dep.h>
extern struct pci_ops titan_pci_ops;
static struct resource py_mem_resource = {
- "Titan PCI MEM", 0xe0000000UL, 0xe3ffffffUL, IORESOURCE_MEM
+ .start = 0xe0000000UL,
+ .end = 0xe3ffffffUL,
+ .name = "Titan PCI MEM",
+ .flags = IORESOURCE_MEM
};
/*
@@ -26,7 +29,10 @@ #define TITAN_IO_SIZE 0x0000ffffUL
#define TITAN_IO_BASE 0xe8000000UL
static struct resource py_io_resource = {
- "Titan IO MEM", 0x00001000UL, TITAN_IO_SIZE - 1, IORESOURCE_IO,
+ .start = 0x00001000UL,
+ .end = TITAN_IO_SIZE - 1,
+ .name = "Titan IO MEM",
+ .flags = IORESOURCE_IO,
};
static struct pci_controller py_controller = {
diff --git a/arch/mips/philips/pnx8550/common/pci.c b/arch/mips/philips/pnx8550/common/pci.c
index baa6905..eee4f3d 100644
--- a/arch/mips/philips/pnx8550/common/pci.c
+++ b/arch/mips/philips/pnx8550/common/pci.c
@@ -27,17 +27,17 @@ #include <glb.h>
#include <nand.h>
static struct resource pci_io_resource = {
- "pci IO space",
- (u32)(PNX8550_PCIIO + 0x1000), /* reserve regacy I/O space */
- (u32)(PNX8550_PCIIO + PNX8550_PCIIO_SIZE),
- IORESOURCE_IO
+ .start = PNX8550_PCIIO + 0x1000, /* reserve regacy I/O space */
+ .end = PNX8550_PCIIO + PNX8550_PCIIO_SIZE,
+ .name = "pci IO space",
+ .flags = IORESOURCE_IO
};
static struct resource pci_mem_resource = {
- "pci memory space",
- (u32)(PNX8550_PCIMEM),
- (u32)(PNX8550_PCIMEM + PNX8550_PCIMEM_SIZE - 1),
- IORESOURCE_MEM
+ .start = PNX8550_PCIMEM,
+ .end = PNX8550_PCIMEM + PNX8550_PCIMEM_SIZE - 1,
+ .name = "pci memory space",
+ .flags = IORESOURCE_MEM
};
extern struct pci_ops pnx8550_pci_ops;
diff --git a/arch/mips/philips/pnx8550/common/setup.c b/arch/mips/philips/pnx8550/common/setup.c
index 0d8a776..2b199f3 100644
--- a/arch/mips/philips/pnx8550/common/setup.c
+++ b/arch/mips/philips/pnx8550/common/setup.c
@@ -58,10 +58,27 @@ extern void prom_printf(char *fmt, ...);
extern char *prom_getcmdline(void);
struct resource standard_io_resources[] = {
- {"dma1", 0x00, 0x1f, IORESOURCE_BUSY},
- {"timer", 0x40, 0x5f, IORESOURCE_BUSY},
- {"dma page reg", 0x80, 0x8f, IORESOURCE_BUSY},
- {"dma2", 0xc0, 0xdf, IORESOURCE_BUSY},
+ {
+ .start = .0x00,
+ .end = 0x1f,
+ .name = "dma1",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x40,
+ .end = 0x5f,
+ .name = "timer",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x80,
+ .end = 0x8f,
+ .name = "dma page reg",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0xc0,
+ .end = 0xdf,
+ .name = "dma2",
+ .flags = IORESOURCE_BUSY
+ },
};
#define STANDARD_IO_RESOURCES (sizeof(standard_io_resources)/sizeof(struct resource))
diff --git a/arch/mips/sni/setup.c b/arch/mips/sni/setup.c
index 01ba6c5..c33cb9d 100644
--- a/arch/mips/sni/setup.c
+++ b/arch/mips/sni/setup.c
@@ -92,20 +92,51 @@ #endif
}
static struct resource sni_io_resource = {
- "PCIMT IO MEM", 0x00001000UL, 0x03bfffffUL, IORESOURCE_IO,
+ .start = 0x00001000UL,
+ .end = 0x03bfffffUL,
+ .name = "PCIMT IO MEM",
+ .flags = IORESOURCE_IO,
};
static struct resource pcimt_io_resources[] = {
- { "dma1", 0x00, 0x1f, IORESOURCE_BUSY },
- { "timer", 0x40, 0x5f, IORESOURCE_BUSY },
- { "keyboard", 0x60, 0x6f, IORESOURCE_BUSY },
- { "dma page reg", 0x80, 0x8f, IORESOURCE_BUSY },
- { "dma2", 0xc0, 0xdf, IORESOURCE_BUSY },
- { "PCI config data", 0xcfc, 0xcff, IORESOURCE_BUSY }
+ {
+ .start = 0x00,
+ .end = 0x1f,
+ .name = "dma1",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x40,
+ .end = 0x5f,
+ .name = "timer",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x60,
+ .end = 0x6f,
+ .name = "keyboard",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x80,
+ .end = 0x8f,
+ .name = "dma page reg",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0xc0,
+ .end = 0xdf,
+ .name = "dma2",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0xcfc,
+ .end = 0xcff,
+ .name = "PCI config data",
+ .flags = IORESOURCE_BUSY
+ }
};
static struct resource sni_mem_resource = {
- "PCIMT PCI MEM", 0x10000000UL, 0xffffffffUL, IORESOURCE_MEM
+ .start = 0x10000000UL,
+ .end = 0xffffffffUL,
+ .name = "PCIMT PCI MEM",
+ .flags = IORESOURCE_MEM
};
/*
@@ -122,19 +153,72 @@ static struct resource sni_mem_resource
* 0xa0000000 - 0xffffffff (1.5GB) PCI/EISA Bus Memory
*/
static struct resource pcimt_mem_resources[] = {
- { "Video RAM area", 0x100a0000, 0x100bffff, IORESOURCE_BUSY },
- { "ISA Reserved", 0x100c0000, 0x100fffff, IORESOURCE_BUSY },
- { "PCI IO", 0x14000000, 0x17bfffff, IORESOURCE_BUSY },
- { "Cache Replacement Area", 0x17c00000, 0x17ffffff, IORESOURCE_BUSY},
- { "PCI INT Acknowledge", 0x1a000000, 0x1a000003, IORESOURCE_BUSY },
- { "Boot PROM", 0x1fc00000, 0x1fc7ffff, IORESOURCE_BUSY},
- { "Diag PROM", 0x1fc80000, 0x1fcfffff, IORESOURCE_BUSY},
- { "X-Bus", 0x1fd00000, 0x1fdfffff, IORESOURCE_BUSY},
- { "BIOS map", 0x1fe00000, 0x1fefffff, IORESOURCE_BUSY},
- { "NVRAM / EEPROM", 0x1ff00000, 0x1ff7ffff, IORESOURCE_BUSY},
- { "ASIC PCI", 0x1fff0000, 0x1fffefff, IORESOURCE_BUSY},
- { "MP Agent", 0x1ffff000, 0x1fffffff, IORESOURCE_BUSY},
- { "Main Memory", 0x20000000, 0x9fffffff, IORESOURCE_BUSY}
+ {
+ .start = 0x100a0000,
+ .end = 0x100bffff,
+ .name = "Video RAM area",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x100c0000,
+ .end = 0x100fffff,
+ .name = "ISA Reserved",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x14000000,
+ .end = 0x17bfffff,
+ .name = "PCI IO",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x17c00000,
+ .end = 0x17ffffff,
+ .name = "Cache Replacement Area",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x1a000000,
+ .end = 0x1a000003,
+ .name = "PCI INT Acknowledge",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x1fc00000,
+ .end = 0x1fc7ffff,
+ .name = "Boot PROM",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x1fc80000,
+ .end = 0x1fcfffff,
+ .name = "Diag PROM",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x1fd00000,
+ .end = 0x1fdfffff,
+ .name = "X-Bus",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x1fe00000,
+ .end = 0x1fefffff,
+ .name = "BIOS map",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x1ff00000,
+ .end = 0x1ff7ffff,
+ .name = "NVRAM / EEPROM",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x1fff0000,
+ .end = 0x1fffefff,
+ .name = "ASIC PCI",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x1ffff000,
+ .end = 0x1fffffff,
+ .name = "MP Agent",
+ .flags = IORESOURCE_BUSY
+ }, {
+ .start = 0x20000000,
+ .end = 0x9fffffff,
+ .name = "Main Memory",
+ .flags = IORESOURCE_BUSY
+ }
};
static void __init sni_resource_init(void)
diff --git a/arch/mips/tx4938/toshiba_rbtx4938/setup.c b/arch/mips/tx4938/toshiba_rbtx4938/setup.c
index 9166cd4..96e833c 100644
--- a/arch/mips/tx4938/toshiba_rbtx4938/setup.c
+++ b/arch/mips/tx4938/toshiba_rbtx4938/setup.c
@@ -664,7 +664,10 @@ static struct resource rbtx4938_fpga_res
static char pcode_str[8];
static struct resource tx4938_reg_resource = {
- pcode_str, TX4938_REG_BASE, TX4938_REG_BASE+TX4938_REG_SIZE, IORESOURCE_MEM
+ .start = TX4938_REG_BASE,
+ .end = TX4938_REG_BASE + TX4938_REG_SIZE,
+ .name = pcode_str,
+ .flags = IORESOURCE_MEM
};
void __init tx4938_board_setup(void)
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 02/16] 64bit resource: fix up printks for resources in sound drivers
2006-06-13 0:31 ` [PATCH 01/16] 64bit resource: C99 changes for struct resource declarations Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
sound/arm/aaci.c | 5 +++--
sound/drivers/mpu401/mpu401.c | 5 +++--
sound/isa/es18xx.c | 3 ++-
sound/isa/gus/interwave.c | 8 ++++----
sound/isa/sb/sb16.c | 3 ++-
sound/oss/forte.c | 5 +++--
sound/pci/bt87x.c | 5 +++--
sound/pci/sonicvibes.c | 4 ++--
sound/ppc/pmac.c | 14 ++++++++------
sound/sparc/cs4231.c | 4 ++--
sound/sparc/dbri.c | 5 +++--
11 files changed, 35 insertions(+), 26 deletions(-)
diff --git a/sound/arm/aaci.c b/sound/arm/aaci.c
index 5f22d70..6b18225 100644
--- a/sound/arm/aaci.c
+++ b/sound/arm/aaci.c
@@ -779,8 +779,9 @@ static struct aaci * __devinit aaci_init
strlcpy(card->driver, DRIVER_NAME, sizeof(card->driver));
strlcpy(card->shortname, "ARM AC'97 Interface", sizeof(card->shortname));
snprintf(card->longname, sizeof(card->longname),
- "%s at 0x%08lx, irq %d",
- card->shortname, dev->res.start, dev->irq[0]);
+ "%s at 0x%016llx, irq %d",
+ card->shortname, (unsigned long long)dev->res.start,
+ dev->irq[0]);
aaci = card->private_data;
mutex_init(&aaci->ac97_sem);
diff --git a/sound/drivers/mpu401/mpu401.c b/sound/drivers/mpu401/mpu401.c
index 77b0600..547aa9e 100644
--- a/sound/drivers/mpu401/mpu401.c
+++ b/sound/drivers/mpu401/mpu401.c
@@ -160,8 +160,9 @@ static int __devinit snd_mpu401_pnp(int
return -ENODEV;
}
if (pnp_port_len(device, 0) < IO_EXTENT) {
- snd_printk(KERN_ERR "PnP port length is %ld, expected %d\n",
- pnp_port_len(device, 0), IO_EXTENT);
+ snd_printk(KERN_ERR "PnP port length is %llu, expected %d\n",
+ (unsigned long long)pnp_port_len(device, 0),
+ IO_EXTENT);
return -ENODEV;
}
port[dev] = pnp_port_start(device, 0);
diff --git a/sound/isa/es18xx.c b/sound/isa/es18xx.c
index e6945db..af60b0b 100644
--- a/sound/isa/es18xx.c
+++ b/sound/isa/es18xx.c
@@ -2088,7 +2088,8 @@ static int __devinit snd_audiodrive_pnp(
kfree(cfg);
return -EAGAIN;
}
- snd_printdd("pnp: port=0x%lx\n", pnp_port_start(acard->devc, 0));
+ snd_printdd("pnp: port=0x%llx\n",
+ (unsigned long long)pnp_port_start(acard->devc, 0));
/* PnP initialization */
pdev = acard->dev;
pnp_init_resource_table(cfg);
diff --git a/sound/isa/gus/interwave.c b/sound/isa/gus/interwave.c
index 4298d33..c6d83b8 100644
--- a/sound/isa/gus/interwave.c
+++ b/sound/isa/gus/interwave.c
@@ -611,10 +611,10 @@ #endif
if (dma2[dev] >= 0)
dma2[dev] = pnp_dma(pdev, 1);
irq[dev] = pnp_irq(pdev, 0);
- snd_printdd("isapnp IW: sb port=0x%lx, gf1 port=0x%lx, codec port=0x%lx\n",
- pnp_port_start(pdev, 0),
- pnp_port_start(pdev, 1),
- pnp_port_start(pdev, 2));
+ snd_printdd("isapnp IW: sb port=0x%llx, gf1 port=0x%llx, codec port=0x%llx\n",
+ (unsigned long long)pnp_port_start(pdev, 0),
+ (unsigned long long)pnp_port_start(pdev, 1),
+ (unsigned long long)pnp_port_start(pdev, 2));
snd_printdd("isapnp IW: dma1=%i, dma2=%i, irq=%i\n", dma1[dev], dma2[dev], irq[dev]);
#ifdef SNDRV_STB
/* Tone Control initialization */
diff --git a/sound/isa/sb/sb16.c b/sound/isa/sb/sb16.c
index 6333f90..05b1b23 100644
--- a/sound/isa/sb/sb16.c
+++ b/sound/isa/sb/sb16.c
@@ -327,7 +327,8 @@ #ifdef SNDRV_SBAWE_EMU8000
goto __wt_error;
}
awe_port[dev] = pnp_port_start(pdev, 0);
- snd_printdd("pnp SB16: wavetable port=0x%lx\n", pnp_port_start(pdev, 0));
+ snd_printdd("pnp SB16: wavetable port=0x%llx\n",
+ (unsigned long long)pnp_port_start(pdev, 0));
} else {
__wt_error:
if (pdev) {
diff --git a/sound/oss/forte.c b/sound/oss/forte.c
index 0294eec..44e5780 100644
--- a/sound/oss/forte.c
+++ b/sound/oss/forte.c
@@ -2035,8 +2035,9 @@ forte_probe (struct pci_dev *pci_dev, co
pci_set_drvdata (pci_dev, chip);
- printk (KERN_INFO PFX "FM801 chip found at 0x%04lX-0x%04lX IRQ %u\n",
- chip->iobase, pci_resource_end (pci_dev, 0), chip->irq);
+ printk (KERN_INFO PFX "FM801 chip found at 0x%04lX-0x%16llX IRQ %u\n",
+ chip->iobase, (unsigned long long)pci_resource_end (pci_dev, 0),
+ chip->irq);
/* Power it up */
if ((ret = forte_chip_init (chip)) == 0)
diff --git a/sound/pci/bt87x.c b/sound/pci/bt87x.c
index 9ee07d4..3bee063 100644
--- a/sound/pci/bt87x.c
+++ b/sound/pci/bt87x.c
@@ -886,8 +886,9 @@ static int __devinit snd_bt87x_probe(str
strcpy(card->driver, "Bt87x");
sprintf(card->shortname, "Brooktree Bt%x", pci->device);
- sprintf(card->longname, "%s at %#lx, irq %i",
- card->shortname, pci_resource_start(pci, 0), chip->irq);
+ sprintf(card->longname, "%s at %#llx, irq %i",
+ card->shortname, (unsigned long long)pci_resource_start(pci, 0),
+ chip->irq);
strcpy(card->mixername, "Bt87x");
err = snd_card_register(card);
diff --git a/sound/pci/sonicvibes.c b/sound/pci/sonicvibes.c
index 91f8bf3..32d1a61 100644
--- a/sound/pci/sonicvibes.c
+++ b/sound/pci/sonicvibes.c
@@ -1441,10 +1441,10 @@ static int __devinit snd_sonic_probe(str
strcpy(card->driver, "SonicVibes");
strcpy(card->shortname, "S3 SonicVibes");
- sprintf(card->longname, "%s rev %i at 0x%lx, irq %i",
+ sprintf(card->longname, "%s rev %i at 0x%llx, irq %i",
card->shortname,
sonic->revision,
- pci_resource_start(pci, 1),
+ (unsigned long long)pci_resource_start(pci, 1),
sonic->irq);
if ((err = snd_sonicvibes_pcm(sonic, 0, NULL)) < 0) {
diff --git a/sound/ppc/pmac.c b/sound/ppc/pmac.c
index f0794ef..7232667 100644
--- a/sound/ppc/pmac.c
+++ b/sound/ppc/pmac.c
@@ -1198,9 +1198,10 @@ int __init snd_pmac_new(struct snd_card
chip->rsrc[i].start + 1,
rnames[i]) == NULL) {
printk(KERN_ERR "snd: can't request rsrc "
- " %d (%s: 0x%08lx:%08lx)\n",
- i, rnames[i], chip->rsrc[i].start,
- chip->rsrc[i].end);
+ " %d (%s: 0x%016llx:%016llx)\n",
+ i, rnames[i],
+ (unsigned long long)chip->rsrc[i].start,
+ (unsigned long long)chip->rsrc[i].end);
err = -ENODEV;
goto __error;
}
@@ -1229,9 +1230,10 @@ int __init snd_pmac_new(struct snd_card
chip->rsrc[i].start + 1,
rnames[i]) == NULL) {
printk(KERN_ERR "snd: can't request rsrc "
- " %d (%s: 0x%08lx:%08lx)\n",
- i, rnames[i], chip->rsrc[i].start,
- chip->rsrc[i].end);
+ " %d (%s: 0x%016llx:%016llx)\n",
+ i, rnames[i],
+ (unsigned long long)chip->rsrc[i].start,
+ (unsigned long long)chip->rsrc[i].end);
err = -ENODEV;
goto __error;
}
diff --git a/sound/sparc/cs4231.c b/sound/sparc/cs4231.c
index 8804f26..e7aa761 100644
--- a/sound/sparc/cs4231.c
+++ b/sound/sparc/cs4231.c
@@ -2038,10 +2038,10 @@ static int __init cs4231_sbus_attach(str
if (err)
return err;
- sprintf(card->longname, "%s at 0x%02lx:0x%08lx, irq %s",
+ sprintf(card->longname, "%s at 0x%02lx:0x%016llx, irq %s",
card->shortname,
rp->flags & 0xffL,
- rp->start,
+ (unsigned long long)rp->start,
__irq_itoa(sdev->irqs[0]));
if ((err = snd_cs4231_sbus_create(card, sdev, dev, &cp)) < 0) {
diff --git a/sound/sparc/dbri.c b/sound/sparc/dbri.c
index 2164b7d..cd305fd 100644
--- a/sound/sparc/dbri.c
+++ b/sound/sparc/dbri.c
@@ -2645,9 +2645,10 @@ static int __init dbri_attach(int prom_n
strcpy(card->driver, "DBRI");
strcpy(card->shortname, "Sun DBRI");
rp = &sdev->resource[0];
- sprintf(card->longname, "%s at 0x%02lx:0x%08lx, irq %s",
+ sprintf(card->longname, "%s at 0x%02lx:0x%016llx, irq %s",
card->shortname,
- rp->flags & 0xffL, rp->start, __irq_itoa(irq.pri));
+ rp->flags & 0xffL, (unsigned long long)rp->start,
+ __irq_itoa(irq.pri));
if ((err = snd_dbri_create(card, sdev, &irq, dev)) < 0) {
snd_card_free(card);
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers
2006-06-13 0:31 ` [PATCH 02/16] 64bit resource: fix up printks for resources in sound drivers Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 04/16] 64bit resource: fix up printks for resources in pci core and hotplug drivers Greg KH
2006-06-13 16:24 ` [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers Jesse Brandeburg
0 siblings, 2 replies; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/net/3c59x.c | 6 ++++--
drivers/net/8139cp.c | 9 +++++----
drivers/net/8139too.c | 6 +++---
drivers/net/e100.c | 4 ++--
drivers/net/skge.c | 4 ++--
drivers/net/sky2.c | 6 +++---
drivers/net/tulip/de2104x.c | 9 +++++----
drivers/net/tulip/tulip_core.c | 6 +++---
drivers/net/typhoon.c | 5 +++--
drivers/net/wan/dscc4.c | 12 ++++++------
drivers/net/wan/pc300_drv.c | 4 ++--
11 files changed, 38 insertions(+), 33 deletions(-)
diff --git a/drivers/net/3c59x.c b/drivers/net/3c59x.c
index 274b013..e5e60d3 100644
--- a/drivers/net/3c59x.c
+++ b/drivers/net/3c59x.c
@@ -1413,8 +1413,10 @@ #endif
}
if (print_info) {
- printk(KERN_INFO "%s: CardBus functions mapped %8.8lx->%p\n",
- print_name, pci_resource_start(pdev, 2),
+ printk(KERN_INFO "%s: CardBus functions mapped "
+ "%16.16llx->%p\n",
+ print_name,
+ (unsigned long long)pci_resource_start(pdev, 2),
vp->cb_fn_base);
}
EL3WINDOW(2);
diff --git a/drivers/net/8139cp.c b/drivers/net/8139cp.c
index 066e22b..e74e20a 100644
--- a/drivers/net/8139cp.c
+++ b/drivers/net/8139cp.c
@@ -1728,8 +1728,8 @@ #endif
}
if (pci_resource_len(pdev, 1) < CP_REGS_SIZE) {
rc = -EIO;
- printk(KERN_ERR PFX "MMIO resource (%lx) too small on pci dev %s\n",
- pci_resource_len(pdev, 1), pci_name(pdev));
+ printk(KERN_ERR PFX "MMIO resource (%llx) too small on pci dev %s\n",
+ (unsigned long long)pci_resource_len(pdev, 1), pci_name(pdev));
goto err_out_res;
}
@@ -1761,8 +1761,9 @@ #endif
regs = ioremap(pciaddr, CP_REGS_SIZE);
if (!regs) {
rc = -EIO;
- printk(KERN_ERR PFX "Cannot map PCI MMIO (%lx@%lx) on pci dev %s\n",
- pci_resource_len(pdev, 1), pciaddr, pci_name(pdev));
+ printk(KERN_ERR PFX "Cannot map PCI MMIO (%llx@%llx) on pci dev %s\n",
+ (unsigned long long)pci_resource_len(pdev, 1),
+ (unsigned long long)pciaddr, pci_name(pdev));
goto err_out_res;
}
dev->base_addr = (unsigned long) regs;
diff --git a/drivers/net/8139too.c b/drivers/net/8139too.c
index feae783..4c3e632 100644
--- a/drivers/net/8139too.c
+++ b/drivers/net/8139too.c
@@ -1341,9 +1341,9 @@ static int rtl8139_open (struct net_devi
netif_start_queue (dev);
if (netif_msg_ifup(tp))
- printk(KERN_DEBUG "%s: rtl8139_open() ioaddr %#lx IRQ %d"
- " GP Pins %2.2x %s-duplex.\n",
- dev->name, pci_resource_start (tp->pci_dev, 1),
+ printk(KERN_DEBUG "%s: rtl8139_open() ioaddr %#llx IRQ %d"
+ " GP Pins %2.2x %s-duplex.\n", dev->name,
+ (unsigned long long)pci_resource_start (tp->pci_dev, 1),
dev->irq, RTL_R8 (MediaStatus),
tp->mii.full_duplex ? "full" : "half");
diff --git a/drivers/net/e100.c b/drivers/net/e100.c
index 31ac001..0c0bd67 100644
--- a/drivers/net/e100.c
+++ b/drivers/net/e100.c
@@ -2678,9 +2678,9 @@ #endif
goto err_out_free;
}
- DPRINTK(PROBE, INFO, "addr 0x%lx, irq %d, "
+ DPRINTK(PROBE, INFO, "addr 0x%llx, irq %d, "
"MAC addr %02X:%02X:%02X:%02X:%02X:%02X\n",
- pci_resource_start(pdev, 0), pdev->irq,
+ (unsigned long long)pci_resource_start(pdev, 0), pdev->irq,
netdev->dev_addr[0], netdev->dev_addr[1], netdev->dev_addr[2],
netdev->dev_addr[3], netdev->dev_addr[4], netdev->dev_addr[5]);
diff --git a/drivers/net/skge.c b/drivers/net/skge.c
index 5ca5a1b..432b3f2 100644
--- a/drivers/net/skge.c
+++ b/drivers/net/skge.c
@@ -3327,8 +3327,8 @@ #endif
if (err)
goto err_out_free_irq;
- printk(KERN_INFO PFX DRV_VERSION " addr 0x%lx irq %d chip %s rev %d\n",
- pci_resource_start(pdev, 0), pdev->irq,
+ printk(KERN_INFO PFX DRV_VERSION " addr 0x%llx irq %d chip %s rev %d\n",
+ (unsigned long long)pci_resource_start(pdev, 0), pdev->irq,
skge_board_name(hw), hw->chip_rev);
if ((dev = skge_devinit(hw, 0, using_dac)) == NULL)
diff --git a/drivers/net/sky2.c b/drivers/net/sky2.c
index 9591096..74b499e 100644
--- a/drivers/net/sky2.c
+++ b/drivers/net/sky2.c
@@ -3302,9 +3302,9 @@ #endif
if (err)
goto err_out_iounmap;
- printk(KERN_INFO PFX "v%s addr 0x%lx irq %d Yukon-%s (0x%x) rev %d\n",
- DRV_VERSION, pci_resource_start(pdev, 0), pdev->irq,
- yukon2_name[hw->chip_id - CHIP_ID_YUKON_XL],
+ printk(KERN_INFO PFX "v%s addr 0x%llx irq %d Yukon-%s (0x%x) rev %d\n",
+ DRV_VERSION, (unsigned long long)pci_resource_start(pdev, 0),
+ pdev->irq, yukon2_name[hw->chip_id - CHIP_ID_YUKON_XL],
hw->chip_id, hw->chip_rev);
dev = sky2_init_netdev(hw, 0, using_dac);
diff --git a/drivers/net/tulip/de2104x.c b/drivers/net/tulip/de2104x.c
index e3dd144..901a42d 100644
--- a/drivers/net/tulip/de2104x.c
+++ b/drivers/net/tulip/de2104x.c
@@ -2007,8 +2007,8 @@ #endif
}
if (pci_resource_len(pdev, 1) < DE_REGS_SIZE) {
rc = -EIO;
- printk(KERN_ERR PFX "MMIO resource (%lx) too small on pci dev %s\n",
- pci_resource_len(pdev, 1), pci_name(pdev));
+ printk(KERN_ERR PFX "MMIO resource (%llx) too small on pci dev %s\n",
+ (unsigned long long)pci_resource_len(pdev, 1), pci_name(pdev));
goto err_out_res;
}
@@ -2016,8 +2016,9 @@ #endif
regs = ioremap_nocache(pciaddr, DE_REGS_SIZE);
if (!regs) {
rc = -EIO;
- printk(KERN_ERR PFX "Cannot map PCI MMIO (%lx@%lx) on pci dev %s\n",
- pci_resource_len(pdev, 1), pciaddr, pci_name(pdev));
+ printk(KERN_ERR PFX "Cannot map PCI MMIO (%llx@%lx) on pci dev %s\n",
+ (unsigned long long)pci_resource_len(pdev, 1),
+ pciaddr, pci_name(pdev));
goto err_out_res;
}
dev->base_addr = (unsigned long) regs;
diff --git a/drivers/net/tulip/tulip_core.c b/drivers/net/tulip/tulip_core.c
index c67c912..b11c614 100644
--- a/drivers/net/tulip/tulip_core.c
+++ b/drivers/net/tulip/tulip_core.c
@@ -1350,10 +1350,10 @@ #endif
SET_MODULE_OWNER(dev);
SET_NETDEV_DEV(dev, &pdev->dev);
if (pci_resource_len (pdev, 0) < tulip_tbl[chip_idx].io_size) {
- printk (KERN_ERR PFX "%s: I/O region (0x%lx@0x%lx) too small, "
+ printk (KERN_ERR PFX "%s: I/O region (0x%llx@0x%llx) too small, "
"aborting\n", pci_name(pdev),
- pci_resource_len (pdev, 0),
- pci_resource_start (pdev, 0));
+ (unsigned long long)pci_resource_len (pdev, 0),
+ (unsigned long long)pci_resource_start (pdev, 0));
goto err_out_free_netdev;
}
diff --git a/drivers/net/typhoon.c b/drivers/net/typhoon.c
index d9258d4..9eced14 100644
--- a/drivers/net/typhoon.c
+++ b/drivers/net/typhoon.c
@@ -2568,9 +2568,10 @@ typhoon_init_one(struct pci_dev *pdev, c
pci_set_drvdata(pdev, dev);
- printk(KERN_INFO "%s: %s at %s 0x%lx, ",
+ printk(KERN_INFO "%s: %s at %s 0x%llx, ",
dev->name, typhoon_card_info[card_id].name,
- use_mmio ? "MMIO" : "IO", pci_resource_start(pdev, use_mmio));
+ use_mmio ? "MMIO" : "IO",
+ (unsigned long long)pci_resource_start(pdev, use_mmio));
for(i = 0; i < 5; i++)
printk("%2.2x:", dev->dev_addr[i]);
printk("%2.2x\n", dev->dev_addr[i]);
diff --git a/drivers/net/wan/dscc4.c b/drivers/net/wan/dscc4.c
index 4505540..04a376e 100644
--- a/drivers/net/wan/dscc4.c
+++ b/drivers/net/wan/dscc4.c
@@ -732,15 +732,15 @@ static int __devinit dscc4_init_one(stru
ioaddr = ioremap(pci_resource_start(pdev, 0),
pci_resource_len(pdev, 0));
if (!ioaddr) {
- printk(KERN_ERR "%s: cannot remap MMIO region %lx @ %lx\n",
- DRV_NAME, pci_resource_len(pdev, 0),
- pci_resource_start(pdev, 0));
+ printk(KERN_ERR "%s: cannot remap MMIO region %llx @ %llx\n",
+ DRV_NAME, (unsigned long long)pci_resource_len(pdev, 0),
+ (unsigned long long)pci_resource_start(pdev, 0));
rc = -EIO;
goto err_free_mmio_regions_2;
}
- printk(KERN_DEBUG "Siemens DSCC4, MMIO at %#lx (regs), %#lx (lbi), IRQ %d\n",
- pci_resource_start(pdev, 0),
- pci_resource_start(pdev, 1), pdev->irq);
+ printk(KERN_DEBUG "Siemens DSCC4, MMIO at %#llx (regs), %#llx (lbi), IRQ %d\n",
+ (unsigned long long)pci_resource_start(pdev, 0),
+ (unsigned long long)pci_resource_start(pdev, 1), pdev->irq);
/* Cf errata DS5 p.2 */
pci_write_config_byte(pdev, PCI_LATENCY_TIMER, 0xf8);
diff --git a/drivers/net/wan/pc300_drv.c b/drivers/net/wan/pc300_drv.c
index a3e65d1..d7897ae 100644
--- a/drivers/net/wan/pc300_drv.c
+++ b/drivers/net/wan/pc300_drv.c
@@ -3445,9 +3445,9 @@ #endif
card = (pc300_t *) kmalloc(sizeof(pc300_t), GFP_KERNEL);
if (card == NULL) {
- printk("PC300 found at RAM 0x%08lx, "
+ printk("PC300 found at RAM 0x%016llx, "
"but could not allocate card structure.\n",
- pci_resource_start(pdev, 3));
+ (unsigned long long)pci_resource_start(pdev, 3));
err = -ENOMEM;
goto err_disable_dev;
}
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 04/16] 64bit resource: fix up printks for resources in pci core and hotplug drivers
2006-06-13 0:31 ` [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 05/16] 64bit resource: fix up printks for resources in mtd drivers Greg KH
2006-06-13 16:24 ` [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers Jesse Brandeburg
1 sibling, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/pci/hotplug/cpcihp_zt5550.c | 9 +++++----
drivers/pci/hotplug/cpqphp_core.c | 10 +++++-----
drivers/pci/hotplug/pciehp_hpc.c | 5 +++--
drivers/pci/hotplug/shpchp_sysfs.c | 18 ++++++++++++------
drivers/pci/pci.c | 6 ++++--
drivers/pci/proc.c | 16 +++++-----------
drivers/pci/setup-bus.c | 6 ++++--
drivers/pci/setup-res.c | 28 +++++++++++++++++-----------
8 files changed, 55 insertions(+), 43 deletions(-)
diff --git a/drivers/pci/hotplug/cpcihp_zt5550.c b/drivers/pci/hotplug/cpcihp_zt5550.c
index f7cb00d..1ec165d 100644
--- a/drivers/pci/hotplug/cpcihp_zt5550.c
+++ b/drivers/pci/hotplug/cpcihp_zt5550.c
@@ -95,8 +95,8 @@ static int zt5550_hc_config(struct pci_d
hc_dev = pdev;
dbg("hc_dev = %p", hc_dev);
- dbg("pci resource start %lx", pci_resource_start(hc_dev, 1));
- dbg("pci resource len %lx", pci_resource_len(hc_dev, 1));
+ dbg("pci resource start %llx", (unsigned long long)pci_resource_start(hc_dev, 1));
+ dbg("pci resource len %llx", (unsigned long long)pci_resource_len(hc_dev, 1));
if(!request_mem_region(pci_resource_start(hc_dev, 1),
pci_resource_len(hc_dev, 1), MY_NAME)) {
@@ -108,8 +108,9 @@ static int zt5550_hc_config(struct pci_d
hc_registers =
ioremap(pci_resource_start(hc_dev, 1), pci_resource_len(hc_dev, 1));
if(!hc_registers) {
- err("cannot remap MMIO region %lx @ %lx",
- pci_resource_len(hc_dev, 1), pci_resource_start(hc_dev, 1));
+ err("cannot remap MMIO region %llx @ %llx",
+ (unsigned long long)pci_resource_len(hc_dev, 1),
+ (unsigned long long)pci_resource_start(hc_dev, 1));
ret = -ENODEV;
goto exit_release_region;
}
diff --git a/drivers/pci/hotplug/cpqphp_core.c b/drivers/pci/hotplug/cpqphp_core.c
index 9bc1deb..f8658d6 100644
--- a/drivers/pci/hotplug/cpqphp_core.c
+++ b/drivers/pci/hotplug/cpqphp_core.c
@@ -1089,8 +1089,8 @@ static int cpqhpc_probe(struct pci_dev *
}
dbg("pdev = %p\n", pdev);
- dbg("pci resource start %lx\n", pci_resource_start(pdev, 0));
- dbg("pci resource len %lx\n", pci_resource_len(pdev, 0));
+ dbg("pci resource start %llx\n", (unsigned long long)pci_resource_start(pdev, 0));
+ dbg("pci resource len %llx\n", (unsigned long long)pci_resource_len(pdev, 0));
if (!request_mem_region(pci_resource_start(pdev, 0),
pci_resource_len(pdev, 0), MY_NAME)) {
@@ -1102,9 +1102,9 @@ static int cpqhpc_probe(struct pci_dev *
ctrl->hpc_reg = ioremap(pci_resource_start(pdev, 0),
pci_resource_len(pdev, 0));
if (!ctrl->hpc_reg) {
- err("cannot remap MMIO region %lx @ %lx\n",
- pci_resource_len(pdev, 0),
- pci_resource_start(pdev, 0));
+ err("cannot remap MMIO region %llx @ %llx\n",
+ (unsigned long long)pci_resource_len(pdev, 0),
+ (unsigned long long)pci_resource_start(pdev, 0));
rc = -ENODEV;
goto err_free_mem_region;
}
diff --git a/drivers/pci/hotplug/pciehp_hpc.c b/drivers/pci/hotplug/pciehp_hpc.c
index 6c14d9e..b9bbf6c 100644
--- a/drivers/pci/hotplug/pciehp_hpc.c
+++ b/drivers/pci/hotplug/pciehp_hpc.c
@@ -1398,8 +1398,9 @@ int pcie_init(struct controller * ctrl,
for ( rc = 0; rc < DEVICE_COUNT_RESOURCE; rc++)
if (pci_resource_len(pdev, rc) > 0)
- dbg("pci resource[%d] start=0x%lx(len=0x%lx)\n", rc,
- pci_resource_start(pdev, rc), pci_resource_len(pdev, rc));
+ dbg("pci resource[%d] start=0x%llx(len=0x%llx)\n", rc,
+ (unsigned long long)pci_resource_start(pdev, rc),
+ (unsigned long long)pci_resource_len(pdev, rc));
info("HPC vendor_id %x device_id %x ss_vid %x ss_did %x\n", pdev->vendor, pdev->device,
pdev->subsystem_vendor, pdev->subsystem_device);
diff --git a/drivers/pci/hotplug/shpchp_sysfs.c b/drivers/pci/hotplug/shpchp_sysfs.c
index f5cfbf2..620e113 100644
--- a/drivers/pci/hotplug/shpchp_sysfs.c
+++ b/drivers/pci/hotplug/shpchp_sysfs.c
@@ -51,8 +51,10 @@ static ssize_t show_ctrl (struct device
res = bus->resource[index];
if (res && (res->flags & IORESOURCE_MEM) &&
!(res->flags & IORESOURCE_PREFETCH)) {
- out += sprintf(out, "start = %8.8lx, length = %8.8lx\n",
- res->start, (res->end - res->start));
+ out += sprintf(out, "start = %8.8llx, "
+ "length = %8.8llx\n",
+ (unsigned long long)res->start,
+ (unsigned long long)(res->end - res->start));
}
}
out += sprintf(out, "Free resources: prefetchable memory\n");
@@ -60,16 +62,20 @@ static ssize_t show_ctrl (struct device
res = bus->resource[index];
if (res && (res->flags & IORESOURCE_MEM) &&
(res->flags & IORESOURCE_PREFETCH)) {
- out += sprintf(out, "start = %8.8lx, length = %8.8lx\n",
- res->start, (res->end - res->start));
+ out += sprintf(out, "start = %8.8llx, "
+ "length = %8.8llx\n",
+ (unsigned long long)res->start,
+ (unsigned long long)(res->end - res->start));
}
}
out += sprintf(out, "Free resources: IO\n");
for (index = 0; index < PCI_BUS_NUM_RESOURCES; index++) {
res = bus->resource[index];
if (res && (res->flags & IORESOURCE_IO)) {
- out += sprintf(out, "start = %8.8lx, length = %8.8lx\n",
- res->start, (res->end - res->start));
+ out += sprintf(out, "start = %8.8llx, "
+ "length = %8.8llx\n",
+ (unsigned long long)res->start,
+ (unsigned long long)(res->end - res->start));
}
}
out += sprintf(out, "Free resources: bus numbers\n");
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
index 1228627..a19b773 100644
--- a/drivers/pci/pci.c
+++ b/drivers/pci/pci.c
@@ -680,10 +680,12 @@ int pci_request_region(struct pci_dev *p
return 0;
err_out:
- printk (KERN_WARNING "PCI: Unable to reserve %s region #%d:%lx@%lx for device %s\n",
+ printk (KERN_WARNING "PCI: Unable to reserve %s region #%d:%llx@%llx "
+ "for device %s\n",
pci_resource_flags(pdev, bar) & IORESOURCE_IO ? "I/O" : "mem",
bar + 1, /* PCI BAR # */
- pci_resource_len(pdev, bar), pci_resource_start(pdev, bar),
+ (unsigned long long)pci_resource_len(pdev, bar),
+ (unsigned long long)pci_resource_start(pdev, bar),
pci_name(pdev));
return -EBUSY;
}
diff --git a/drivers/pci/proc.c b/drivers/pci/proc.c
index 54b2ebc..20dfd77 100644
--- a/drivers/pci/proc.c
+++ b/drivers/pci/proc.c
@@ -302,12 +302,6 @@ #endif /* HAVE_ARCH_PCI_GET_UNMAPPED_ARE
#endif /* HAVE_PCI_MMAP */
};
-#if BITS_PER_LONG == 32
-#define LONG_FORMAT "\t%08lx"
-#else
-#define LONG_FORMAT "\t%16lx"
-#endif
-
/* iterator */
static void *pci_seq_start(struct seq_file *m, loff_t *pos)
{
@@ -358,16 +352,16 @@ static int show_device(struct seq_file *
for (i=0; i<7; i++) {
u64 start, end;
pci_resource_to_user(dev, i, &dev->resource[i], &start, &end);
- seq_printf(m, LONG_FORMAT,
- ((unsigned long)start) |
- (dev->resource[i].flags & PCI_REGION_FLAG_MASK));
+ seq_printf(m, "\t%16llx",
+ (unsigned long long)(start |
+ (dev->resource[i].flags & PCI_REGION_FLAG_MASK)));
}
for (i=0; i<7; i++) {
u64 start, end;
pci_resource_to_user(dev, i, &dev->resource[i], &start, &end);
- seq_printf(m, LONG_FORMAT,
+ seq_printf(m, "\t%16llx",
dev->resource[i].start < dev->resource[i].end ?
- (unsigned long)(end - start) + 1 : 0);
+ (unsigned long long)(end - start) + 1 : 0);
}
seq_putc(m, '\t');
if (drv)
diff --git a/drivers/pci/setup-bus.c b/drivers/pci/setup-bus.c
index 28ce3a7..ddca473 100644
--- a/drivers/pci/setup-bus.c
+++ b/drivers/pci/setup-bus.c
@@ -356,8 +356,10 @@ pbus_size_mem(struct pci_bus *bus, unsig
order = __ffs(align) - 20;
if (order > 11) {
printk(KERN_WARNING "PCI: region %s/%d "
- "too large: %lx-%lx\n",
- pci_name(dev), i, r->start, r->end);
+ "too large: %llx-%llx\n",
+ pci_name(dev), i,
+ (unsigned long long)r->start,
+ (unsigned long long)r->end);
r->flags = 0;
continue;
}
diff --git a/drivers/pci/setup-res.c b/drivers/pci/setup-res.c
index ea9277b..d3e70ca 100644
--- a/drivers/pci/setup-res.c
+++ b/drivers/pci/setup-res.c
@@ -40,8 +40,9 @@ pci_update_resource(struct pci_dev *dev,
pcibios_resource_to_bus(dev, ®ion, res);
- pr_debug(" got res [%lx:%lx] bus [%lx:%lx] flags %lx for "
- "BAR %d of %s\n", res->start, res->end,
+ pr_debug(" got res [%llx:%llx] bus [%lx:%lx] flags %lx for "
+ "BAR %d of %s\n", (unsigned long long)res->start,
+ (unsigned long long)res->end,
region.start, region.end, res->flags, resno, pci_name(dev));
new = region.start | (res->flags & PCI_REGION_FLAG_MASK);
@@ -104,10 +105,12 @@ pci_claim_resource(struct pci_dev *dev,
err = insert_resource(root, res);
if (err) {
- printk(KERN_ERR "PCI: %s region %d of %s %s [%lx:%lx]\n",
- root ? "Address space collision on" :
- "No parent found for",
- resource, dtype, pci_name(dev), res->start, res->end);
+ printk(KERN_ERR "PCI: %s region %d of %s %s [%llx:%llx]\n",
+ root ? "Address space collision on" :
+ "No parent found for",
+ resource, dtype, pci_name(dev),
+ (unsigned long long)res->start,
+ (unsigned long long)res->end);
}
return err;
@@ -145,9 +148,11 @@ int pci_assign_resource(struct pci_dev *
}
if (ret) {
- printk(KERN_ERR "PCI: Failed to allocate %s resource #%d:%lx@%lx for %s\n",
- res->flags & IORESOURCE_IO ? "I/O" : "mem",
- resno, size, res->start, pci_name(dev));
+ printk(KERN_ERR "PCI: Failed to allocate %s resource "
+ "#%d:%llx@%llx for %s\n",
+ res->flags & IORESOURCE_IO ? "I/O" : "mem",
+ resno, (unsigned long long)size,
+ (unsigned long long)res->start, pci_name(dev));
} else if (resno < PCI_BRIDGE_RESOURCES) {
pci_update_resource(dev, res, resno);
}
@@ -173,8 +178,9 @@ pdev_sort_resources(struct pci_dev *dev,
continue;
if (!r_align) {
printk(KERN_WARNING "PCI: Ignore bogus resource %d "
- "[%lx:%lx] of %s\n",
- i, r->start, r->end, pci_name(dev));
+ "[%llx:%llx] of %s\n",
+ i, (unsigned long long)r->start,
+ (unsigned long long)r->end, pci_name(dev));
continue;
}
r_align = (i < PCI_BRIDGE_RESOURCES) ? r_align + 1 : r->start;
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 05/16] 64bit resource: fix up printks for resources in mtd drivers
2006-06-13 0:31 ` [PATCH 04/16] 64bit resource: fix up printks for resources in pci core and hotplug drivers Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 06/16] 64bit resource: fix up printks for resources in ide drivers Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/mtd/devices/pmc551.c | 8 ++++----
drivers/mtd/maps/amd76xrom.c | 5 +++--
drivers/mtd/maps/ichxrom.c | 5 +++--
drivers/mtd/maps/scx200_docflash.c | 5 +++--
drivers/mtd/maps/sun_uflash.c | 10 ++++++----
5 files changed, 19 insertions(+), 14 deletions(-)
diff --git a/drivers/mtd/devices/pmc551.c b/drivers/mtd/devices/pmc551.c
index 666cce1..ce2a233 100644
--- a/drivers/mtd/devices/pmc551.c
+++ b/drivers/mtd/devices/pmc551.c
@@ -551,11 +551,11 @@ #ifdef CONFIG_MTD_PMC551_DEBUG
/*
* Some screen fun
*/
- printk(KERN_DEBUG "pmc551: %d%c (0x%x) of %sprefetchable memory at 0x%lx\n",
+ printk(KERN_DEBUG "pmc551: %d%c (0x%x) of %sprefetchable memory at 0x%llx\n",
(size<1024)?size:(size<1048576)?size>>10:size>>20,
(size<1024)?'B':(size<1048576)?'K':'M',
size, ((dcmd&(0x1<<3)) == 0)?"non-":"",
- (dev->resource[0].start)&PCI_BASE_ADDRESS_MEM_MASK );
+ (unsigned long long)((dev->resource[0].start)&PCI_BASE_ADDRESS_MEM_MASK));
/*
* Check to see the state of the memory
@@ -685,8 +685,8 @@ static int __init init_pmc551(void)
break;
}
- printk(KERN_NOTICE "pmc551: Found PCI V370PDC at 0x%lX\n",
- PCI_Device->resource[0].start);
+ printk(KERN_NOTICE "pmc551: Found PCI V370PDC at 0x%llx\n",
+ (unsigned long long)PCI_Device->resource[0].start);
/*
* The PMC551 device acts VERY weird if you don't init it
diff --git a/drivers/mtd/maps/amd76xrom.c b/drivers/mtd/maps/amd76xrom.c
index c350878..a505870 100644
--- a/drivers/mtd/maps/amd76xrom.c
+++ b/drivers/mtd/maps/amd76xrom.c
@@ -123,9 +123,10 @@ static int __devinit amd76xrom_init_one
window->rsrc.parent = NULL;
printk(KERN_ERR MOD_NAME
" %s(): Unable to register resource"
- " 0x%.08lx-0x%.08lx - kernel bug?\n",
+ " 0x%.16llx-0x%.16llx - kernel bug?\n",
__func__,
- window->rsrc.start, window->rsrc.end);
+ (unsigned long long)window->rsrc.start,
+ (unsigned long long)window->rsrc.end);
}
#if 0
diff --git a/drivers/mtd/maps/ichxrom.c b/drivers/mtd/maps/ichxrom.c
index ea50737..1673279 100644
--- a/drivers/mtd/maps/ichxrom.c
+++ b/drivers/mtd/maps/ichxrom.c
@@ -177,9 +177,10 @@ static int __devinit ichxrom_init_one (s
window->rsrc.parent = NULL;
printk(KERN_DEBUG MOD_NAME
": %s(): Unable to register resource"
- " 0x%.08lx-0x%.08lx - kernel bug?\n",
+ " 0x%.16llx-0x%.16llx - kernel bug?\n",
__func__,
- window->rsrc.start, window->rsrc.end);
+ (unsigned long long)window->rsrc.start,
+ (unsigned long long)window->rsrc.end);
}
/* Map the firmware hub into my address space. */
diff --git a/drivers/mtd/maps/scx200_docflash.c b/drivers/mtd/maps/scx200_docflash.c
index 28b8a57..331a158 100644
--- a/drivers/mtd/maps/scx200_docflash.c
+++ b/drivers/mtd/maps/scx200_docflash.c
@@ -164,8 +164,9 @@ static int __init init_scx200_docflash(v
outl(pmr, scx200_cb_base + SCx200_PMR);
}
- printk(KERN_INFO NAME ": DOCCS mapped at 0x%lx-0x%lx, width %d\n",
- docmem.start, docmem.end, width);
+ printk(KERN_INFO NAME ": DOCCS mapped at 0x%llx-0x%llx, width %d\n",
+ (unsigned long long)docmem.start,
+ (unsigned long long)docmem.end, width);
scx200_docflash_map.size = size;
if (width == 8)
diff --git a/drivers/mtd/maps/sun_uflash.c b/drivers/mtd/maps/sun_uflash.c
index 0758cb1..9ed42d5 100644
--- a/drivers/mtd/maps/sun_uflash.c
+++ b/drivers/mtd/maps/sun_uflash.c
@@ -74,9 +74,10 @@ int uflash_devinit(struct linux_ebus_dev
/* Non-CFI userflash device-- once I find one we
* can work on supporting it.
*/
- printk("%s: unsupported device at 0x%lx (%d regs): " \
+ printk("%s: unsupported device at 0x%llx (%d regs): " \
"email ebrower@usa.net\n",
- UFLASH_DEVNAME, edev->resource[0].start, nregs);
+ UFLASH_DEVNAME,
+ (unsigned long long)edev->resource[0].start, nregs);
return -ENODEV;
}
@@ -132,8 +133,9 @@ static int __init uflash_init(void)
for_each_ebusdev(edev, ebus) {
if (!strcmp(edev->prom_name, UFLASH_OBPNAME)) {
if(0 > prom_getproplen(edev->prom_node, "user")) {
- DEBUG(2, "%s: ignoring device at 0x%lx\n",
- UFLASH_DEVNAME, edev->resource[0].start);
+ DEBUG(2, "%s: ignoring device at 0x%llx\n",
+ UFLASH_DEVNAME,
+ (unsigned long long)edev->resource[0].start);
} else {
uflash_devinit(edev);
}
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 06/16] 64bit resource: fix up printks for resources in ide drivers
2006-06-13 0:31 ` [PATCH 05/16] 64bit resource: fix up printks for resources in mtd drivers Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 07/16] 64bit resource: fix up printks for resources in video drivers Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/ide/pci/aec62xx.c | 3 ++-
drivers/ide/pci/cmd64x.c | 3 ++-
drivers/ide/pci/hpt34x.c | 2 +-
drivers/ide/pci/pdc202xx_new.c | 4 ++--
drivers/ide/pci/pdc202xx_old.c | 4 ++--
5 files changed, 9 insertions(+), 7 deletions(-)
diff --git a/drivers/ide/pci/aec62xx.c b/drivers/ide/pci/aec62xx.c
index c743e68..8d5b872 100644
--- a/drivers/ide/pci/aec62xx.c
+++ b/drivers/ide/pci/aec62xx.c
@@ -254,7 +254,8 @@ static unsigned int __devinit init_chips
if (dev->resource[PCI_ROM_RESOURCE].start) {
pci_write_config_dword(dev, PCI_ROM_ADDRESS, dev->resource[PCI_ROM_RESOURCE].start | PCI_ROM_ADDRESS_ENABLE);
- printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name, dev->resource[PCI_ROM_RESOURCE].start);
+ printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name,
+ (unsigned long)dev->resource[PCI_ROM_RESOURCE].start);
}
if (bus_speed <= 33)
diff --git a/drivers/ide/pci/cmd64x.c b/drivers/ide/pci/cmd64x.c
index 3d9c7af..9828039 100644
--- a/drivers/ide/pci/cmd64x.c
+++ b/drivers/ide/pci/cmd64x.c
@@ -609,7 +609,8 @@ static unsigned int __devinit init_chips
#ifdef __i386__
if (dev->resource[PCI_ROM_RESOURCE].start) {
pci_write_config_dword(dev, PCI_ROM_ADDRESS, dev->resource[PCI_ROM_RESOURCE].start | PCI_ROM_ADDRESS_ENABLE);
- printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name, dev->resource[PCI_ROM_RESOURCE].start);
+ printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name,
+ (unsigned long)dev->resource[PCI_ROM_RESOURCE].start);
}
#endif
diff --git a/drivers/ide/pci/hpt34x.c b/drivers/ide/pci/hpt34x.c
index be334da..7da5502 100644
--- a/drivers/ide/pci/hpt34x.c
+++ b/drivers/ide/pci/hpt34x.c
@@ -176,7 +176,7 @@ static unsigned int __devinit init_chips
pci_write_config_dword(dev, PCI_ROM_ADDRESS,
dev->resource[PCI_ROM_RESOURCE].start | PCI_ROM_ADDRESS_ENABLE);
printk(KERN_INFO "HPT345: ROM enabled at 0x%08lx\n",
- dev->resource[PCI_ROM_RESOURCE].start);
+ (unsigned long)dev->resource[PCI_ROM_RESOURCE].start);
}
pci_write_config_byte(dev, PCI_LATENCY_TIMER, 0xF0);
} else {
diff --git a/drivers/ide/pci/pdc202xx_new.c b/drivers/ide/pci/pdc202xx_new.c
index acd6317..20d5965 100644
--- a/drivers/ide/pci/pdc202xx_new.c
+++ b/drivers/ide/pci/pdc202xx_new.c
@@ -313,8 +313,8 @@ static unsigned int __devinit init_chips
if (dev->resource[PCI_ROM_RESOURCE].start) {
pci_write_config_dword(dev, PCI_ROM_ADDRESS,
dev->resource[PCI_ROM_RESOURCE].start | PCI_ROM_ADDRESS_ENABLE);
- printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n",
- name, dev->resource[PCI_ROM_RESOURCE].start);
+ printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name,
+ (unsigned long)dev->resource[PCI_ROM_RESOURCE].start);
}
#ifdef CONFIG_PPC_PMAC
diff --git a/drivers/ide/pci/pdc202xx_old.c b/drivers/ide/pci/pdc202xx_old.c
index 7ce5bf7..793e530 100644
--- a/drivers/ide/pci/pdc202xx_old.c
+++ b/drivers/ide/pci/pdc202xx_old.c
@@ -580,8 +580,8 @@ static unsigned int __devinit init_chips
if (dev->resource[PCI_ROM_RESOURCE].start) {
pci_write_config_dword(dev, PCI_ROM_ADDRESS,
dev->resource[PCI_ROM_RESOURCE].start | PCI_ROM_ADDRESS_ENABLE);
- printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n",
- name, dev->resource[PCI_ROM_RESOURCE].start);
+ printk(KERN_INFO "%s: ROM enabled at 0x%08lx\n", name,
+ (unsigned long)dev->resource[PCI_ROM_RESOURCE].start);
}
/*
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 07/16] 64bit resource: fix up printks for resources in video drivers
2006-06-13 0:31 ` [PATCH 06/16] 64bit resource: fix up printks for resources in ide drivers Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 08/16] 64bit resource: fix up printks for resources in pcmcia drivers Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/media/video/bt8xx/bttv-driver.c | 10 ++++++----
drivers/media/video/cx88/cx88-alsa.c | 8 ++++----
drivers/media/video/cx88/cx88-core.c | 4 ++--
drivers/media/video/cx88/cx88-mpeg.c | 4 ++--
drivers/media/video/cx88/cx88-video.c | 4 ++--
drivers/media/video/saa7134/saa7134-core.c | 8 ++++----
6 files changed, 20 insertions(+), 18 deletions(-)
diff --git a/drivers/media/video/bt8xx/bttv-driver.c b/drivers/media/video/bt8xx/bttv-driver.c
index 423e954..aa3203a 100644
--- a/drivers/media/video/bt8xx/bttv-driver.c
+++ b/drivers/media/video/bt8xx/bttv-driver.c
@@ -4019,8 +4019,9 @@ static int __devinit bttv_probe(struct p
if (!request_mem_region(pci_resource_start(dev,0),
pci_resource_len(dev,0),
btv->c.name)) {
- printk(KERN_WARNING "bttv%d: can't request iomem (0x%lx).\n",
- btv->c.nr, pci_resource_start(dev,0));
+ printk(KERN_WARNING "bttv%d: can't request iomem (0x%llx).\n",
+ btv->c.nr,
+ (unsigned long long)pci_resource_start(dev,0));
return -EBUSY;
}
pci_set_master(dev);
@@ -4031,8 +4032,9 @@ static int __devinit bttv_probe(struct p
pci_read_config_byte(dev, PCI_LATENCY_TIMER, &lat);
printk(KERN_INFO "bttv%d: Bt%d (rev %d) at %s, ",
bttv_num,btv->id, btv->revision, pci_name(dev));
- printk("irq: %d, latency: %d, mmio: 0x%lx\n",
- btv->c.pci->irq, lat, pci_resource_start(dev,0));
+ printk("irq: %d, latency: %d, mmio: 0x%llx\n",
+ btv->c.pci->irq, lat,
+ (unsigned long long)pci_resource_start(dev,0));
schedule();
btv->bt848_mmio=ioremap(pci_resource_start(dev,0), 0x1000);
diff --git a/drivers/media/video/cx88/cx88-alsa.c b/drivers/media/video/cx88/cx88-alsa.c
index 320b3d9..db2e307 100644
--- a/drivers/media/video/cx88/cx88-alsa.c
+++ b/drivers/media/video/cx88/cx88-alsa.c
@@ -713,9 +713,9 @@ static int __devinit snd_cx88_create(str
pci_read_config_byte(pci, PCI_LATENCY_TIMER, &chip->pci_lat);
dprintk(1,"ALSA %s/%i: found at %s, rev: %d, irq: %d, "
- "latency: %d, mmio: 0x%lx\n", core->name, devno,
+ "latency: %d, mmio: 0x%llx\n", core->name, devno,
pci_name(pci), chip->pci_rev, pci->irq,
- chip->pci_lat,pci_resource_start(pci,0));
+ chip->pci_lat,(unsigned long long)pci_resource_start(pci,0));
chip->irq = pci->irq;
synchronize_irq(chip->irq);
@@ -767,8 +767,8 @@ static int __devinit cx88_audio_initdev(
strcpy (card->driver, "CX88x");
sprintf(card->shortname, "Conexant CX%x", pci->device);
- sprintf(card->longname, "%s at %#lx",
- card->shortname, pci_resource_start(pci, 0));
+ sprintf(card->longname, "%s at %#llx",
+ card->shortname,(unsigned long long)pci_resource_start(pci, 0));
strcpy (card->mixername, "CX88");
dprintk (0, "%s/%i: ALSA support for cx2388x boards\n",
diff --git a/drivers/media/video/cx88/cx88-core.c b/drivers/media/video/cx88/cx88-core.c
index e1092d5..d8ac14b 100644
--- a/drivers/media/video/cx88/cx88-core.c
+++ b/drivers/media/video/cx88/cx88-core.c
@@ -1031,8 +1031,8 @@ static int get_ressources(struct cx88_co
pci_resource_len(pci,0),
core->name))
return 0;
- printk(KERN_ERR "%s: can't get MMIO memory @ 0x%lx\n",
- core->name,pci_resource_start(pci,0));
+ printk(KERN_ERR "%s: can't get MMIO memory @ 0x%llx\n",
+ core->name,(unsigned long long)pci_resource_start(pci,0));
return -EBUSY;
}
diff --git a/drivers/media/video/cx88/cx88-mpeg.c b/drivers/media/video/cx88/cx88-mpeg.c
index 7d16888..c107264 100644
--- a/drivers/media/video/cx88/cx88-mpeg.c
+++ b/drivers/media/video/cx88/cx88-mpeg.c
@@ -386,9 +386,9 @@ int cx8802_init_common(struct cx8802_dev
pci_read_config_byte(dev->pci, PCI_CLASS_REVISION, &dev->pci_rev);
pci_read_config_byte(dev->pci, PCI_LATENCY_TIMER, &dev->pci_lat);
printk(KERN_INFO "%s/2: found at %s, rev: %d, irq: %d, "
- "latency: %d, mmio: 0x%lx\n", dev->core->name,
+ "latency: %d, mmio: 0x%llx\n", dev->core->name,
pci_name(dev->pci), dev->pci_rev, dev->pci->irq,
- dev->pci_lat,pci_resource_start(dev->pci,0));
+ dev->pci_lat,(unsigned long long)pci_resource_start(dev->pci,0));
/* initialize driver struct */
spin_lock_init(&dev->slock);
diff --git a/drivers/media/video/cx88/cx88-video.c b/drivers/media/video/cx88/cx88-video.c
index 694d1d8..095e5ef 100644
--- a/drivers/media/video/cx88/cx88-video.c
+++ b/drivers/media/video/cx88/cx88-video.c
@@ -1849,9 +1849,9 @@ static int __devinit cx8800_initdev(stru
pci_read_config_byte(pci_dev, PCI_CLASS_REVISION, &dev->pci_rev);
pci_read_config_byte(pci_dev, PCI_LATENCY_TIMER, &dev->pci_lat);
printk(KERN_INFO "%s/0: found at %s, rev: %d, irq: %d, "
- "latency: %d, mmio: 0x%lx\n", core->name,
+ "latency: %d, mmio: 0x%llx\n", core->name,
pci_name(pci_dev), dev->pci_rev, pci_dev->irq,
- dev->pci_lat,pci_resource_start(pci_dev,0));
+ dev->pci_lat,(unsigned long long)pci_resource_start(pci_dev,0));
pci_set_master(pci_dev);
if (!pci_dma_supported(pci_dev,0xffffffff)) {
diff --git a/drivers/media/video/saa7134/saa7134-core.c b/drivers/media/video/saa7134/saa7134-core.c
index f0c2111..da3007d 100644
--- a/drivers/media/video/saa7134/saa7134-core.c
+++ b/drivers/media/video/saa7134/saa7134-core.c
@@ -871,9 +871,9 @@ #endif
pci_read_config_byte(pci_dev, PCI_CLASS_REVISION, &dev->pci_rev);
pci_read_config_byte(pci_dev, PCI_LATENCY_TIMER, &dev->pci_lat);
printk(KERN_INFO "%s: found at %s, rev: %d, irq: %d, "
- "latency: %d, mmio: 0x%lx\n", dev->name,
+ "latency: %d, mmio: 0x%llx\n", dev->name,
pci_name(pci_dev), dev->pci_rev, pci_dev->irq,
- dev->pci_lat,pci_resource_start(pci_dev,0));
+ dev->pci_lat,(unsigned long long)pci_resource_start(pci_dev,0));
pci_set_master(pci_dev);
if (!pci_dma_supported(pci_dev, DMA_32BIT_MASK)) {
printk("%s: Oops: no 32bit PCI DMA ???\n",dev->name);
@@ -905,8 +905,8 @@ #endif
pci_resource_len(pci_dev,0),
dev->name)) {
err = -EBUSY;
- printk(KERN_ERR "%s: can't get MMIO memory @ 0x%lx\n",
- dev->name,pci_resource_start(pci_dev,0));
+ printk(KERN_ERR "%s: can't get MMIO memory @ 0x%llx\n",
+ dev->name,(unsigned long long)pci_resource_start(pci_dev,0));
goto fail1;
}
dev->lmmio = ioremap(pci_resource_start(pci_dev,0), 0x1000);
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 08/16] 64bit resource: fix up printks for resources in pcmcia drivers
2006-06-13 0:31 ` [PATCH 07/16] 64bit resource: fix up printks for resources in video drivers Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 09/16] 64bit resource: fix up printks for resources in arch and core code Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/pcmcia/i82365.c | 5 +++--
drivers/pcmcia/pd6729.c | 3 ++-
drivers/pcmcia/rsrc_nonstatic.c | 12 ++++++++----
drivers/pcmcia/tcic.c | 5 +++--
4 files changed, 16 insertions(+), 9 deletions(-)
diff --git a/drivers/pcmcia/i82365.c b/drivers/pcmcia/i82365.c
index a2f05f4..ff51a65 100644
--- a/drivers/pcmcia/i82365.c
+++ b/drivers/pcmcia/i82365.c
@@ -1084,9 +1084,10 @@ static int i365_set_mem_map(u_short sock
u_short base, i;
u_char map;
- debug(1, "SetMemMap(%d, %d, %#2.2x, %d ns, %#lx-%#lx, "
+ debug(1, "SetMemMap(%d, %d, %#2.2x, %d ns, %#llx-%#llx, "
"%#x)\n", sock, mem->map, mem->flags, mem->speed,
- mem->res->start, mem->res->end, mem->card_start);
+ (unsigned long long)mem->res->start,
+ (unsigned long long)mem->res->end, mem->card_start);
map = mem->map;
if ((map > 4) || (mem->card_start > 0x3ffffff) ||
diff --git a/drivers/pcmcia/pd6729.c b/drivers/pcmcia/pd6729.c
index 247ab83..9ee26c1 100644
--- a/drivers/pcmcia/pd6729.c
+++ b/drivers/pcmcia/pd6729.c
@@ -642,7 +642,8 @@ static int __devinit pd6729_pci_probe(st
goto err_out_free_mem;
printk(KERN_INFO "pd6729: Cirrus PD6729 PCI to PCMCIA Bridge "
- "at 0x%lx on irq %d\n", pci_resource_start(dev, 0), dev->irq);
+ "at 0x%llx on irq %d\n",
+ (unsigned long long)pci_resource_start(dev, 0), dev->irq);
/*
* Since we have no memory BARs some firmware may not
* have had PCI_COMMAND_MEMORY enabled, yet the device needs it.
diff --git a/drivers/pcmcia/rsrc_nonstatic.c b/drivers/pcmcia/rsrc_nonstatic.c
index 0f8b157..cc03130 100644
--- a/drivers/pcmcia/rsrc_nonstatic.c
+++ b/drivers/pcmcia/rsrc_nonstatic.c
@@ -808,8 +808,10 @@ #endif
if (res->flags & IORESOURCE_IO) {
if (res == &ioport_resource)
continue;
- printk(KERN_INFO "pcmcia: parent PCI bridge I/O window: 0x%lx - 0x%lx\n",
- res->start, res->end);
+ printk(KERN_INFO "pcmcia: parent PCI bridge I/O "
+ "window: 0x%llx - 0x%llx\n",
+ (unsigned long long)res->start,
+ (unsigned long long)res->end);
if (!adjust_io(s, ADD_MANAGED_RESOURCE, res->start, res->end))
done |= IORESOURCE_IO;
@@ -818,8 +820,10 @@ #endif
if (res->flags & IORESOURCE_MEM) {
if (res == &iomem_resource)
continue;
- printk(KERN_INFO "pcmcia: parent PCI bridge Memory window: 0x%lx - 0x%lx\n",
- res->start, res->end);
+ printk(KERN_INFO "pcmcia: parent PCI bridge Memory "
+ "window: 0x%llx - 0x%llx\n",
+ (unsigned long long)res->start,
+ (unsigned long long)res->end);
if (!adjust_memory(s, ADD_MANAGED_RESOURCE, res->start, res->end))
done |= IORESOURCE_MEM;
}
diff --git a/drivers/pcmcia/tcic.c b/drivers/pcmcia/tcic.c
index 73bad1d..65a6067 100644
--- a/drivers/pcmcia/tcic.c
+++ b/drivers/pcmcia/tcic.c
@@ -756,8 +756,9 @@ static int tcic_set_mem_map(struct pcmci
u_long base, len, mmap;
debug(1, "SetMemMap(%d, %d, %#2.2x, %d ns, "
- "%#lx-%#lx, %#x)\n", psock, mem->map, mem->flags,
- mem->speed, mem->res->start, mem->res->end, mem->card_start);
+ "%#llx-%#llx, %#x)\n", psock, mem->map, mem->flags,
+ mem->speed, (unsigned long long)mem->res->start,
+ (unsigned long long)mem->res->end, mem->card_start);
if ((mem->map > 3) || (mem->card_start > 0x3ffffff) ||
(mem->res->start > 0xffffff) || (mem->res->end > 0xffffff) ||
(mem->res->start > mem->res->end) || (mem->speed > 1000))
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 09/16] 64bit resource: fix up printks for resources in arch and core code
2006-06-13 0:31 ` [PATCH 08/16] 64bit resource: fix up printks for resources in pcmcia drivers Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 10/16] 64bit resource: fix up printks for resources in misc drivers Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
arch/i386/kernel/efi.c | 6 +++--
arch/powerpc/kernel/pci_32.c | 37 +++++++++++++++--------------
arch/powerpc/platforms/83xx/pci.c | 5 ++--
arch/powerpc/platforms/85xx/pci.c | 5 ++--
arch/powerpc/platforms/chrp/pci.c | 4 ++-
arch/powerpc/platforms/maple/pci.c | 5 ++--
arch/powerpc/platforms/powermac/pci.c | 5 ++--
arch/ppc/kernel/pci.c | 42 ++++++++++++++++++++-------------
arch/sparc/kernel/ioport.c | 4 ++-
kernel/resource.c | 10 +++++---
10 files changed, 71 insertions(+), 52 deletions(-)
diff --git a/arch/i386/kernel/efi.c b/arch/i386/kernel/efi.c
index 9202b67..8beb0f0 100644
--- a/arch/i386/kernel/efi.c
+++ b/arch/i386/kernel/efi.c
@@ -601,8 +601,10 @@ efi_initialize_iomem_resources(struct re
res->end = res->start + ((md->num_pages << EFI_PAGE_SHIFT) - 1);
res->flags = IORESOURCE_MEM | IORESOURCE_BUSY;
if (request_resource(&iomem_resource, res) < 0)
- printk(KERN_ERR PFX "Failed to allocate res %s : 0x%lx-0x%lx\n",
- res->name, res->start, res->end);
+ printk(KERN_ERR PFX "Failed to allocate res %s : "
+ "0x%llx-0x%llx\n", res->name,
+ (unsigned long long)res->start,
+ (unsigned long long)res->end);
/*
* We don't know which region contains kernel data so we try
* it repeatedly and let the resource manager test it.
diff --git a/arch/powerpc/kernel/pci_32.c b/arch/powerpc/kernel/pci_32.c
index b129d2e..18886e8 100644
--- a/arch/powerpc/kernel/pci_32.c
+++ b/arch/powerpc/kernel/pci_32.c
@@ -99,7 +99,7 @@ pcibios_fixup_resources(struct pci_dev *
if (!res->flags)
continue;
if (res->end == 0xffffffff) {
- DBG("PCI:%s Resource %d [%08lx-%08lx] is unassigned\n",
+ DBG("PCI:%s Resource %d [%016llx-%016llx] is unassigned\n",
pci_name(dev), i, res->start, res->end);
res->end -= res->start;
res->start = 0;
@@ -117,7 +117,7 @@ pcibios_fixup_resources(struct pci_dev *
res->start += offset;
res->end += offset;
#ifdef DEBUG
- printk("Fixup res %d (%lx) of dev %s: %lx -> %lx\n",
+ printk("Fixup res %d (%lx) of dev %s: %llx -> %llx\n",
i, res->flags, pci_name(dev),
res->start - offset, res->start);
#endif
@@ -183,7 +183,7 @@ void pcibios_align_resource(void *data,
if (size > 0x100) {
printk(KERN_ERR "PCI: I/O Region %s/%d too large"
- " (%ld bytes)\n", pci_name(dev),
+ " (%lld bytes)\n", pci_name(dev),
dev->resource - res, size);
}
@@ -255,8 +255,8 @@ pcibios_allocate_bus_resources(struct li
}
}
- DBG("PCI: bridge rsrc %lx..%lx (%lx), parent %p\n",
- res->start, res->end, res->flags, pr);
+ DBG("PCI: bridge rsrc %llx..%llx (%lx), parent %p\n",
+ res->start, res->end, res->flags, pr);
if (pr) {
if (request_resource(pr, res) == 0)
continue;
@@ -306,7 +306,7 @@ reparent_resources(struct resource *pare
*pp = NULL;
for (p = res->child; p != NULL; p = p->sibling) {
p->parent = res;
- DBG(KERN_INFO "PCI: reparented %s [%lx..%lx] under %s\n",
+ DBG(KERN_INFO "PCI: reparented %s [%llx..%llx] under %s\n",
p->name, p->start, p->end, res->name);
}
return 0;
@@ -362,13 +362,14 @@ pci_relocate_bridge_resource(struct pci_
try = conflict->start - 1;
}
if (request_resource(pr, res)) {
- DBG(KERN_ERR "PCI: huh? couldn't move to %lx..%lx\n",
+ DBG(KERN_ERR "PCI: huh? couldn't move to %llx..%llx\n",
res->start, res->end);
return -1; /* "can't happen" */
}
update_bridge_base(bus, i);
- printk(KERN_INFO "PCI: bridge %d resource %d moved to %lx..%lx\n",
- bus->number, i, res->start, res->end);
+ printk(KERN_INFO "PCI: bridge %d resource %d moved to %llx..%llx\n",
+ bus->number, i, (unsigned long long)res->start,
+ (unsigned long long)res->end);
return 0;
}
@@ -479,14 +480,14 @@ static inline void alloc_resource(struct
{
struct resource *pr, *r = &dev->resource[idx];
- DBG("PCI:%s: Resource %d: %08lx-%08lx (f=%lx)\n",
+ DBG("PCI:%s: Resource %d: %016llx-%016llx (f=%lx)\n",
pci_name(dev), idx, r->start, r->end, r->flags);
pr = pci_find_parent_resource(dev, r);
if (!pr || request_resource(pr, r) < 0) {
printk(KERN_ERR "PCI: Cannot allocate resource region %d"
" of device %s\n", idx, pci_name(dev));
if (pr)
- DBG("PCI: parent is %p: %08lx-%08lx (f=%lx)\n",
+ DBG("PCI: parent is %p: %016llx-%016llx (f=%lx)\n",
pr, pr->start, pr->end, pr->flags);
/* We'll assign a new address later */
r->flags |= IORESOURCE_UNSET;
@@ -956,7 +957,7 @@ pci_process_bridge_OF_ranges(struct pci_
res = &hose->io_resource;
res->flags = IORESOURCE_IO;
res->start = ranges[2];
- DBG("PCI: IO 0x%lx -> 0x%lx\n",
+ DBG("PCI: IO 0x%llx -> 0x%llx\n",
res->start, res->start + size - 1);
break;
case 2: /* memory space */
@@ -978,7 +979,7 @@ pci_process_bridge_OF_ranges(struct pci_
if(ranges[0] & 0x40000000)
res->flags |= IORESOURCE_PREFETCH;
res->start = ranges[na+2];
- DBG("PCI: MEM[%d] 0x%lx -> 0x%lx\n", memno,
+ DBG("PCI: MEM[%d] 0x%llx -> 0x%llx\n", memno,
res->start, res->start + size - 1);
}
break;
@@ -1074,7 +1075,7 @@ do_update_p2p_io_resource(struct pci_bus
DBG("Remapping Bus %d, bridge: %s\n", bus->number, pci_name(bridge));
res.start -= ((unsigned long) hose->io_base_virt - isa_io_base);
res.end -= ((unsigned long) hose->io_base_virt - isa_io_base);
- DBG(" IO window: %08lx-%08lx\n", res.start, res.end);
+ DBG(" IO window: %016llx-%016llx\n", res.start, res.end);
/* Set up the top and bottom of the PCI I/O segment for this bus. */
pci_read_config_dword(bridge, PCI_IO_BASE, &l);
@@ -1222,8 +1223,8 @@ do_fixup_p2p_level(struct pci_bus *bus)
continue;
if ((r->flags & IORESOURCE_IO) == 0)
continue;
- DBG("Trying to allocate from %08lx, size %08lx from parent"
- " res %d: %08lx -> %08lx\n",
+ DBG("Trying to allocate from %016llx, size %016llx from parent"
+ " res %d: %016llx -> %016llx\n",
res->start, res->end, i, r->start, r->end);
if (allocate_resource(r, res, res->end + 1, res->start, max,
@@ -1573,8 +1574,8 @@ static pgprot_t __pci_mmap_set_pgprot(st
else
prot |= _PAGE_GUARDED;
- printk("PCI map for %s:%lx, prot: %lx\n", pci_name(dev), rp->start,
- prot);
+ printk("PCI map for %s:%llx, prot: %lx\n", pci_name(dev),
+ (unsigned long long)rp->start, prot);
return __pgprot(prot);
}
diff --git a/arch/powerpc/platforms/83xx/pci.c b/arch/powerpc/platforms/83xx/pci.c
index 16f7d3b..3baceb0 100644
--- a/arch/powerpc/platforms/83xx/pci.c
+++ b/arch/powerpc/platforms/83xx/pci.c
@@ -91,9 +91,10 @@ int __init add_bridge(struct device_node
mpc83xx_pci2_busno = hose->first_busno;
}
- printk(KERN_INFO "Found MPC83xx PCI host bridge at 0x%08lx. "
+ printk(KERN_INFO "Found MPC83xx PCI host bridge at 0x%016llx. "
"Firmware bus number: %d->%d\n",
- rsrc.start, hose->first_busno, hose->last_busno);
+ (unsigned long long)rsrc.start, hose->first_busno,
+ hose->last_busno);
DBG(" ->Hose at 0x%p, cfg_addr=0x%p,cfg_data=0x%p\n",
hose, hose->cfg_addr, hose->cfg_data);
diff --git a/arch/powerpc/platforms/85xx/pci.c b/arch/powerpc/platforms/85xx/pci.c
index bad2901..48c8849 100644
--- a/arch/powerpc/platforms/85xx/pci.c
+++ b/arch/powerpc/platforms/85xx/pci.c
@@ -79,9 +79,10 @@ int __init add_bridge(struct device_node
mpc85xx_pci2_busno = hose->first_busno;
}
- printk(KERN_INFO "Found MPC85xx PCI host bridge at 0x%08lx. "
+ printk(KERN_INFO "Found MPC85xx PCI host bridge at 0x%016llx. "
"Firmware bus number: %d->%d\n",
- rsrc.start, hose->first_busno, hose->last_busno);
+ (unsigned long long)rsrc.start, hose->first_busno,
+ hose->last_busno);
DBG(" ->Hose at 0x%p, cfg_addr=0x%p,cfg_data=0x%p\n",
hose, hose->cfg_addr, hose->cfg_data);
diff --git a/arch/powerpc/platforms/chrp/pci.c b/arch/powerpc/platforms/chrp/pci.c
index ac22487..53515da 100644
--- a/arch/powerpc/platforms/chrp/pci.c
+++ b/arch/powerpc/platforms/chrp/pci.c
@@ -143,7 +143,7 @@ hydra_init(void)
if (np == NULL || of_address_to_resource(np, 0, &r))
return 0;
Hydra = ioremap(r.start, r.end-r.start);
- printk("Hydra Mac I/O at %lx\n", r.start);
+ printk("Hydra Mac I/O at %llx\n", (unsigned long long)r.start);
printk("Hydra Feature_Control was %x",
in_le32(&Hydra->Feature_Control));
out_le32(&Hydra->Feature_Control, (HYDRA_FC_SCC_CELL_EN |
@@ -267,7 +267,7 @@ chrp_find_bridges(void)
bus_range[0], bus_range[1]);
printk(" controlled by %s", dev->type);
if (!is_longtrail)
- printk(" at %lx", r.start);
+ printk(" at %llx", (unsigned long long)r.start);
printk("\n");
hose = pcibios_alloc_controller();
diff --git a/arch/powerpc/platforms/maple/pci.c b/arch/powerpc/platforms/maple/pci.c
index 85d6c93..ccc0955 100644
--- a/arch/powerpc/platforms/maple/pci.c
+++ b/arch/powerpc/platforms/maple/pci.c
@@ -376,9 +376,10 @@ static void __init maple_fixup_phb_resou
unsigned long offset = (unsigned long)hose->io_base_virt - pci_io_base;
hose->io_resource.start += offset;
hose->io_resource.end += offset;
- printk(KERN_INFO "PCI Host %d, io start: %lx; io end: %lx\n",
+ printk(KERN_INFO "PCI Host %d, io start: %llx; io end: %llx\n",
hose->global_number,
- hose->io_resource.start, hose->io_resource.end);
+ (unsigned long long)hose->io_resource.start,
+ (unsigned long long)hose->io_resource.end);
}
}
diff --git a/arch/powerpc/platforms/powermac/pci.c b/arch/powerpc/platforms/powermac/pci.c
index ea179af..73065ba 100644
--- a/arch/powerpc/platforms/powermac/pci.c
+++ b/arch/powerpc/platforms/powermac/pci.c
@@ -939,9 +939,10 @@ #ifdef CONFIG_PPC32
disp_name = "Chaos";
primary = 0;
}
- printk(KERN_INFO "Found %s PCI host bridge at 0x%08lx. "
+ printk(KERN_INFO "Found %s PCI host bridge at 0x%016llx. "
"Firmware bus number: %d->%d\n",
- disp_name, rsrc.start, hose->first_busno, hose->last_busno);
+ disp_name, (unsigned long long)rsrc.start, hose->first_busno,
+ hose->last_busno);
#endif /* CONFIG_PPC32 */
DBG(" ->Hose at 0x%p, cfg_addr=0x%p,cfg_data=0x%p\n",
diff --git a/arch/ppc/kernel/pci.c b/arch/ppc/kernel/pci.c
index 809673a..3ddc1e0 100644
--- a/arch/ppc/kernel/pci.c
+++ b/arch/ppc/kernel/pci.c
@@ -95,8 +95,10 @@ pcibios_fixup_resources(struct pci_dev *
if (!res->flags)
continue;
if (res->end == 0xffffffff) {
- DBG("PCI:%s Resource %d [%08lx-%08lx] is unassigned\n",
- pci_name(dev), i, res->start, res->end);
+ DBG("PCI:%s Resource %d [%016llx-%016llx] is unassigned\n",
+ pci_name(dev), i,
+ (unsigned long long)res->start,
+ (unsigned long long)res->end);
res->end -= res->start;
res->start = 0;
res->flags |= IORESOURCE_UNSET;
@@ -179,8 +181,8 @@ void pcibios_align_resource(void *data,
if (size > 0x100) {
printk(KERN_ERR "PCI: I/O Region %s/%d too large"
- " (%ld bytes)\n", pci_name(dev),
- dev->resource - res, size);
+ " (%lld bytes)\n", pci_name(dev),
+ dev->resource - res, (unsigned long long)size);
}
if (start & 0x300) {
@@ -251,8 +253,9 @@ pcibios_allocate_bus_resources(struct li
}
}
- DBG("PCI: bridge rsrc %lx..%lx (%lx), parent %p\n",
- res->start, res->end, res->flags, pr);
+ DBG("PCI: bridge rsrc %llx..%llx (%lx), parent %p\n",
+ (unsigned long long)res->start,
+ (unsigned long long)res->end, res->flags, pr);
if (pr) {
if (request_resource(pr, res) == 0)
continue;
@@ -302,8 +305,9 @@ reparent_resources(struct resource *pare
*pp = NULL;
for (p = res->child; p != NULL; p = p->sibling) {
p->parent = res;
- DBG(KERN_INFO "PCI: reparented %s [%lx..%lx] under %s\n",
- p->name, p->start, p->end, res->name);
+ DBG(KERN_INFO "PCI: reparented %s [%llx..%llx] under %s\n",
+ p->name, (unsigned long long)p->start,
+ (unsigned long long)p->end, res->name);
}
return 0;
}
@@ -358,13 +362,15 @@ pci_relocate_bridge_resource(struct pci_
try = conflict->start - 1;
}
if (request_resource(pr, res)) {
- DBG(KERN_ERR "PCI: huh? couldn't move to %lx..%lx\n",
- res->start, res->end);
+ DBG(KERN_ERR "PCI: huh? couldn't move to %llx..%llx\n",
+ (unsigned long long)res->start,
+ (unsigned long long)res->end);
return -1; /* "can't happen" */
}
update_bridge_base(bus, i);
- printk(KERN_INFO "PCI: bridge %d resource %d moved to %lx..%lx\n",
- bus->number, i, res->start, res->end);
+ printk(KERN_INFO "PCI: bridge %d resource %d moved to %llx..%llx\n",
+ bus->number, i, (unsigned long long)res->start,
+ (unsigned long long)res->end);
return 0;
}
@@ -475,15 +481,17 @@ static inline void alloc_resource(struct
{
struct resource *pr, *r = &dev->resource[idx];
- DBG("PCI:%s: Resource %d: %08lx-%08lx (f=%lx)\n",
- pci_name(dev), idx, r->start, r->end, r->flags);
+ DBG("PCI:%s: Resource %d: %016llx-%016llx (f=%lx)\n",
+ pci_name(dev), idx, (unsigned long long)r->start,
+ (unsigned long long)r->end, r->flags);
pr = pci_find_parent_resource(dev, r);
if (!pr || request_resource(pr, r) < 0) {
printk(KERN_ERR "PCI: Cannot allocate resource region %d"
" of device %s\n", idx, pci_name(dev));
if (pr)
- DBG("PCI: parent is %p: %08lx-%08lx (f=%lx)\n",
- pr, pr->start, pr->end, pr->flags);
+ DBG("PCI: parent is %p: %016llx-%016llx (f=%lx)\n",
+ pr, (unsigned long long)pr->start,
+ (unsigned long long)pr->end, pr->flags);
/* We'll assign a new address later */
r->flags |= IORESOURCE_UNSET;
r->end -= r->start;
@@ -952,7 +960,7 @@ static pgprot_t __pci_mmap_set_pgprot(st
else
prot |= _PAGE_GUARDED;
- printk("PCI map for %s:%lx, prot: %lx\n", pci_name(dev), rp->start,
+ printk("PCI map for %s:%llx, prot: %llx\n", pci_name(dev), rp->start,
prot);
return __pgprot(prot);
diff --git a/arch/sparc/kernel/ioport.c b/arch/sparc/kernel/ioport.c
index f9ff297..84e134d 100644
--- a/arch/sparc/kernel/ioport.c
+++ b/arch/sparc/kernel/ioport.c
@@ -690,7 +690,9 @@ _sparc_io_get_info(char *buf, char **sta
if (p + 32 >= e) /* Better than nothing */
break;
if ((nm = r->name) == 0) nm = "???";
- p += sprintf(p, "%08lx-%08lx: %s\n", r->start, r->end, nm);
+ p += sprintf(p, "%016llx-%016llx: %s\n",
+ (unsigned long long)r->start,
+ (unsigned long long)r->end, nm);
}
return p-buf;
diff --git a/kernel/resource.c b/kernel/resource.c
index e3080fc..97a703f 100644
--- a/kernel/resource.c
+++ b/kernel/resource.c
@@ -83,10 +83,10 @@ static int r_show(struct seq_file *m, vo
for (depth = 0, p = r; depth < MAX_IORES_LEVEL; depth++, p = p->parent)
if (p->parent == root)
break;
- seq_printf(m, "%*s%0*lx-%0*lx : %s\n",
+ seq_printf(m, "%*s%0*llx-%0*llx : %s\n",
depth * 2, "",
- width, r->start,
- width, r->end,
+ width, (unsigned long long) r->start,
+ width, (unsigned long long) r->end,
r->name ? r->name : "<BAD>");
return 0;
}
@@ -511,7 +511,9 @@ void __release_region(struct resource *p
write_unlock(&resource_lock);
- printk(KERN_WARNING "Trying to free nonexistent resource <%08lx-%08lx>\n", start, end);
+ printk(KERN_WARNING "Trying to free nonexistent resource "
+ "<%16llx-%16llx>\n", (unsigned long long)start,
+ (unsigned long long) end);
}
EXPORT_SYMBOL(__release_region);
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 10/16] 64bit resource: fix up printks for resources in misc drivers
2006-06-13 0:31 ` [PATCH 09/16] 64bit resource: fix up printks for resources in arch and core code Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 11/16] 64bit resource: introduce resource_size_t for the start and end of struct resource Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
This is needed if we wish to change the size of the resource structures.
Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/amba/bus.c | 5 +++--
drivers/atm/ambassador.c | 3 ++-
drivers/atm/firestream.c | 5 +++--
drivers/block/sx8.c | 5 +++--
drivers/char/applicom.c | 9 ++++++---
drivers/ieee1394/ohci1394.c | 15 ++++++++-------
drivers/infiniband/hw/ipath/ipath_driver.c | 8 ++++----
drivers/infiniband/hw/mthca/mthca_main.c | 5 +++--
drivers/input/serio/ct82c710.c | 6 +++---
drivers/isdn/hisax/telespci.c | 5 +++--
drivers/macintosh/macio_asic.c | 4 ++--
drivers/message/i2o/iop.c | 14 ++++++++------
drivers/mmc/mmci.c | 4 ++--
drivers/scsi/sata_via.c | 8 ++++----
14 files changed, 54 insertions(+), 42 deletions(-)
diff --git a/drivers/amba/bus.c b/drivers/amba/bus.c
index 889855d..9e3e2a6 100644
--- a/drivers/amba/bus.c
+++ b/drivers/amba/bus.c
@@ -180,8 +180,9 @@ static DEVICE_ATTR(name, S_IRUGO, show_#
amba_attr(id, "%08x\n", dev->periphid);
amba_attr(irq0, "%u\n", dev->irq[0]);
amba_attr(irq1, "%u\n", dev->irq[1]);
-amba_attr(resource, "\t%08lx\t%08lx\t%08lx\n",
- dev->res.start, dev->res.end, dev->res.flags);
+amba_attr(resource, "\t%016llx\t%016llx\t%016lx\n",
+ (unsigned long long)dev->res.start, (unsigned long long)dev->res.end,
+ dev->res.flags);
/**
* amba_device_register - register an AMBA device
diff --git a/drivers/atm/ambassador.c b/drivers/atm/ambassador.c
index 4b6bf19..4048681 100644
--- a/drivers/atm/ambassador.c
+++ b/drivers/atm/ambassador.c
@@ -2257,7 +2257,8 @@ static int __devinit amb_probe(struct pc
}
PRINTD (DBG_INFO, "found Madge ATM adapter (amb) at"
- " IO %lx, IRQ %u, MEM %p", pci_resource_start(pci_dev, 1),
+ " IO %llx, IRQ %u, MEM %p",
+ (unsigned long long)pci_resource_start(pci_dev, 1),
irq, bus_to_virt(pci_resource_start(pci_dev, 0)));
// check IO region
diff --git a/drivers/atm/firestream.c b/drivers/atm/firestream.c
index 7f7ec28..be42ce9 100644
--- a/drivers/atm/firestream.c
+++ b/drivers/atm/firestream.c
@@ -1657,9 +1657,10 @@ static int __devinit fs_init (struct fs_
func_enter ();
pci_dev = dev->pci_dev;
- printk (KERN_INFO "found a FireStream %d card, base %08lx, irq%d.\n",
+ printk (KERN_INFO "found a FireStream %d card, base %16llx, irq%d.\n",
IS_FS50(dev)?50:155,
- pci_resource_start(pci_dev, 0), dev->pci_dev->irq);
+ (unsigned long long)pci_resource_start(pci_dev, 0),
+ dev->pci_dev->irq);
if (fs_debug & FS_DEBUG_INIT)
my_hd ((unsigned char *) dev, sizeof (*dev));
diff --git a/drivers/block/sx8.c b/drivers/block/sx8.c
index 2ae08b3..8144ce9 100644
--- a/drivers/block/sx8.c
+++ b/drivers/block/sx8.c
@@ -1694,9 +1694,10 @@ #endif
DPRINTK("waiting for probe_comp\n");
wait_for_completion(&host->probe_comp);
- printk(KERN_INFO "%s: pci %s, ports %d, io %lx, irq %u, major %d\n",
+ printk(KERN_INFO "%s: pci %s, ports %d, io %llx, irq %u, major %d\n",
host->name, pci_name(pdev), (int) CARM_MAX_PORTS,
- pci_resource_start(pdev, 0), pdev->irq, host->major);
+ (unsigned long long)pci_resource_start(pdev, 0),
+ pdev->irq, host->major);
carm_host_id++;
pci_set_drvdata(pdev, host);
diff --git a/drivers/char/applicom.c b/drivers/char/applicom.c
index a370e7a..1f48cce 100644
--- a/drivers/char/applicom.c
+++ b/drivers/char/applicom.c
@@ -215,13 +215,16 @@ int __init applicom_init(void)
RamIO = ioremap(dev->resource[0].start, LEN_RAM_IO);
if (!RamIO) {
- printk(KERN_INFO "ac.o: Failed to ioremap PCI memory space at 0x%lx\n", dev->resource[0].start);
+ printk(KERN_INFO "ac.o: Failed to ioremap PCI memory "
+ "space at 0x%llx\n",
+ (unsigned long long)dev->resource[0].start);
pci_disable_device(dev);
return -EIO;
}
- printk(KERN_INFO "Applicom %s found at mem 0x%lx, irq %d\n",
- applicom_pci_devnames[dev->device-1], dev->resource[0].start,
+ printk(KERN_INFO "Applicom %s found at mem 0x%llx, irq %d\n",
+ applicom_pci_devnames[dev->device-1],
+ (unsigned long long)dev->resource[0].start,
dev->irq);
boardno = ac_register_board(dev->resource[0].start, RamIO,0);
diff --git a/drivers/ieee1394/ohci1394.c b/drivers/ieee1394/ohci1394.c
index 11f1377..744b66c 100644
--- a/drivers/ieee1394/ohci1394.c
+++ b/drivers/ieee1394/ohci1394.c
@@ -592,11 +592,11 @@ #else
sprintf (irq_buf, "%s", __irq_itoa(ohci->dev->irq));
#endif
PRINT(KERN_INFO, "OHCI-1394 %d.%d (PCI): IRQ=[%s] "
- "MMIO=[%lx-%lx] Max Packet=[%d] IR/IT contexts=[%d/%d]",
+ "MMIO=[%llx-%llx] Max Packet=[%d] IR/IT contexts=[%d/%d]",
((((buf) >> 16) & 0xf) + (((buf) >> 20) & 0xf) * 10),
((((buf) >> 4) & 0xf) + ((buf) & 0xf) * 10), irq_buf,
- pci_resource_start(ohci->dev, 0),
- pci_resource_start(ohci->dev, 0) + OHCI1394_REGISTER_SIZE - 1,
+ (unsigned long long)pci_resource_start(ohci->dev, 0),
+ (unsigned long long)pci_resource_start(ohci->dev, 0) + OHCI1394_REGISTER_SIZE - 1,
ohci->max_packet_size,
ohci->nb_iso_rcv_ctx, ohci->nb_iso_xmit_ctx);
@@ -3263,15 +3263,16 @@ #endif
* clearly says it's 2kb, so this shouldn't be a problem. */
ohci_base = pci_resource_start(dev, 0);
if (pci_resource_len(dev, 0) < OHCI1394_REGISTER_SIZE)
- PRINT(KERN_WARNING, "PCI resource length of %lx too small!",
- pci_resource_len(dev, 0));
+ PRINT(KERN_WARNING, "PCI resource length of 0x%llx too small!",
+ (unsigned long long)pci_resource_len(dev, 0));
/* Seems PCMCIA handles this internally. Not sure why. Seems
* pretty bogus to force a driver to special case this. */
#ifndef PCMCIA
if (!request_mem_region (ohci_base, OHCI1394_REGISTER_SIZE, OHCI1394_DRIVER_NAME))
- FAIL(-ENOMEM, "MMIO resource (0x%lx - 0x%lx) unavailable",
- ohci_base, ohci_base + OHCI1394_REGISTER_SIZE);
+ FAIL(-ENOMEM, "MMIO resource (0x%llx - 0x%llx) unavailable",
+ (unsigned long long)ohci_base,
+ (unsigned long long)ohci_base + OHCI1394_REGISTER_SIZE);
#endif
ohci->init_state = OHCI_INIT_HAVE_MEM_REGION;
diff --git a/drivers/infiniband/hw/ipath/ipath_driver.c b/drivers/infiniband/hw/ipath/ipath_driver.c
index dddcdae..e4b897f 100644
--- a/drivers/infiniband/hw/ipath/ipath_driver.c
+++ b/drivers/infiniband/hw/ipath/ipath_driver.c
@@ -460,10 +460,10 @@ static int __devinit ipath_init_one(stru
for (j = 0; j < 6; j++) {
if (!pdev->resource[j].start)
continue;
- ipath_cdbg(VERBOSE, "BAR %d start %lx, end %lx, len %lx\n",
- j, pdev->resource[j].start,
- pdev->resource[j].end,
- pci_resource_len(pdev, j));
+ ipath_cdbg(VERBOSE, "BAR %d start %llx, end %llx, len %llx\n",
+ j, (unsigned long long)pdev->resource[j].start,
+ (unsigned long long)pdev->resource[j].end,
+ (unsigned long long)pci_resource_len(pdev, j));
}
if (!addr) {
diff --git a/drivers/infiniband/hw/mthca/mthca_main.c b/drivers/infiniband/hw/mthca/mthca_main.c
index 9b9ff7b..465fd22 100644
--- a/drivers/infiniband/hw/mthca/mthca_main.c
+++ b/drivers/infiniband/hw/mthca/mthca_main.c
@@ -172,8 +172,9 @@ static int __devinit mthca_dev_lim(struc
if (dev_lim->uar_size > pci_resource_len(mdev->pdev, 2)) {
mthca_err(mdev, "HCA reported UAR size of 0x%x bigger than "
- "PCI resource 2 size of 0x%lx, aborting.\n",
- dev_lim->uar_size, pci_resource_len(mdev->pdev, 2));
+ "PCI resource 2 size of 0x%llx, aborting.\n",
+ dev_lim->uar_size,
+ (unsigned long long)pci_resource_len(mdev->pdev, 2));
return -ENODEV;
}
diff --git a/drivers/input/serio/ct82c710.c b/drivers/input/serio/ct82c710.c
index 096b6a0..1ac739e 100644
--- a/drivers/input/serio/ct82c710.c
+++ b/drivers/input/serio/ct82c710.c
@@ -189,7 +189,7 @@ static int __devinit ct82c710_probe(stru
strlcpy(ct82c710_port->name, "C&T 82c710 mouse port",
sizeof(ct82c710_port->name));
snprintf(ct82c710_port->phys, sizeof(ct82c710_port->phys),
- "isa%04lx/serio0", CT82C710_DATA);
+ "isa%16llx/serio0", (unsigned long long)CT82C710_DATA);
serio_register_port(ct82c710_port);
@@ -241,8 +241,8 @@ static int __init ct82c710_init(void)
serio_register_port(ct82c710_port);
- printk(KERN_INFO "serio: C&T 82c710 mouse port at %#lx irq %d\n",
- CT82C710_DATA, CT82C710_IRQ);
+ printk(KERN_INFO "serio: C&T 82c710 mouse port at %#llx irq %d\n",
+ (unsigned long long)CT82C710_DATA, CT82C710_IRQ);
return 0;
diff --git a/drivers/isdn/hisax/telespci.c b/drivers/isdn/hisax/telespci.c
index e2bb4fd..e82ab22 100644
--- a/drivers/isdn/hisax/telespci.c
+++ b/drivers/isdn/hisax/telespci.c
@@ -311,8 +311,9 @@ #ifdef CONFIG_PCI
}
cs->hw.teles0.membase = ioremap(pci_resource_start(dev_tel, 0),
PAGE_SIZE);
- printk(KERN_INFO "Found: Zoran, base-address: 0x%lx, irq: 0x%x\n",
- pci_resource_start(dev_tel, 0), dev_tel->irq);
+ printk(KERN_INFO "Found: Zoran, base-address: 0x%llx, irq: 0x%x\n",
+ (unsigned long long)pci_resource_start(dev_tel, 0),
+ dev_tel->irq);
} else {
printk(KERN_WARNING "TelesPCI: No PCI card found\n");
return(0);
diff --git a/drivers/macintosh/macio_asic.c b/drivers/macintosh/macio_asic.c
index 431bd37..c687ac7 100644
--- a/drivers/macintosh/macio_asic.c
+++ b/drivers/macintosh/macio_asic.c
@@ -428,10 +428,10 @@ #endif
/* MacIO itself has a different reg, we use it's PCI base */
if (np == chip->of_node) {
- sprintf(dev->ofdev.dev.bus_id, "%1d.%08lx:%.*s",
+ sprintf(dev->ofdev.dev.bus_id, "%1d.%016llx:%.*s",
chip->lbus.index,
#ifdef CONFIG_PCI
- pci_resource_start(chip->lbus.pdev, 0),
+ (unsigned long long)pci_resource_start(chip->lbus.pdev, 0),
#else
0, /* NuBus may want to do something better here */
#endif
diff --git a/drivers/message/i2o/iop.c b/drivers/message/i2o/iop.c
index febbdd4..64cc925 100644
--- a/drivers/message/i2o/iop.c
+++ b/drivers/message/i2o/iop.c
@@ -683,9 +683,10 @@ static int i2o_iop_systab_set(struct i2o
c->mem_alloc = 1;
sb->current_mem_size = 1 + res->end - res->start;
sb->current_mem_base = res->start;
- osm_info("%s: allocated %ld bytes of PCI memory at "
- "0x%08lX.\n", c->name,
- 1 + res->end - res->start, res->start);
+ osm_info("%s: allocated %llu bytes of PCI memory at "
+ "0x%016llX.\n", c->name,
+ (unsigned long long)(1 + res->end - res->start),
+ (unsigned long long)res->start);
}
}
@@ -704,9 +705,10 @@ static int i2o_iop_systab_set(struct i2o
c->io_alloc = 1;
sb->current_io_size = 1 + res->end - res->start;
sb->current_mem_base = res->start;
- osm_info("%s: allocated %ld bytes of PCI I/O at 0x%08lX"
- ".\n", c->name, 1 + res->end - res->start,
- res->start);
+ osm_info("%s: allocated %llu bytes of PCI I/O at "
+ "0x%016llX.\n", c->name,
+ (unsigned long long)(1 + res->end - res->start),
+ (unsigned long long)res->start);
}
}
diff --git a/drivers/mmc/mmci.c b/drivers/mmc/mmci.c
index da8e4d7..8576a65 100644
--- a/drivers/mmc/mmci.c
+++ b/drivers/mmc/mmci.c
@@ -546,9 +546,9 @@ static int mmci_probe(struct amba_device
mmc_add_host(mmc);
- printk(KERN_INFO "%s: MMCI rev %x cfg %02x at 0x%08lx irq %d,%d\n",
+ printk(KERN_INFO "%s: MMCI rev %x cfg %02x at 0x%016llx irq %d,%d\n",
mmc_hostname(mmc), amba_rev(dev), amba_config(dev),
- dev->res.start, dev->irq[0], dev->irq[1]);
+ (unsigned long long)dev->res.start, dev->irq[0], dev->irq[1]);
init_timer(&host->timer);
host->timer.data = (unsigned long)host;
diff --git a/drivers/scsi/sata_via.c b/drivers/scsi/sata_via.c
index 9e7ae4e..11ce2b6 100644
--- a/drivers/scsi/sata_via.c
+++ b/drivers/scsi/sata_via.c
@@ -333,10 +333,10 @@ static int svia_init_one (struct pci_dev
if ((pci_resource_start(pdev, i) == 0) ||
(pci_resource_len(pdev, i) < bar_sizes[i])) {
dev_printk(KERN_ERR, &pdev->dev,
- "invalid PCI BAR %u (sz 0x%lx, val 0x%lx)\n",
- i,
- pci_resource_start(pdev, i),
- pci_resource_len(pdev, i));
+ "invalid PCI BAR %u (sz 0x%llx, val 0x%llx)\n",
+ i,
+ (unsigned long long)pci_resource_start(pdev, i),
+ (unsigned long long)pci_resource_len(pdev, i));
rc = -ENODEV;
goto err_out_regions;
}
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 11/16] 64bit resource: introduce resource_size_t for the start and end of struct resource
2006-06-13 0:31 ` [PATCH 10/16] 64bit resource: fix up printks for resources in misc drivers Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 12/16] 64bit resource: change resource core to use resource_size_t Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
But do not change it from what it currently is (unsigned long)
Based on a patch series originally from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
include/linux/ioport.h | 4 +++-
include/linux/types.h | 2 ++
2 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/include/linux/ioport.h b/include/linux/ioport.h
index cd6bd00..535bd95 100644
--- a/include/linux/ioport.h
+++ b/include/linux/ioport.h
@@ -9,13 +9,15 @@ #ifndef _LINUX_IOPORT_H
#define _LINUX_IOPORT_H
#include <linux/compiler.h>
+#include <linux/types.h>
/*
* Resources are tree-like, allowing
* nesting etc..
*/
struct resource {
+ resource_size_t start;
+ resource_size_t end;
const char *name;
- unsigned long start, end;
unsigned long flags;
struct resource *parent, *sibling, *child;
};
diff --git a/include/linux/types.h b/include/linux/types.h
index 1046c7a..047eb8b 100644
--- a/include/linux/types.h
+++ b/include/linux/types.h
@@ -178,6 +178,8 @@ #endif
#ifdef __KERNEL__
typedef unsigned __bitwise__ gfp_t;
+
+typedef unsigned long resource_size_t;
#endif
struct ustat {
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 12/16] 64bit resource: change resource core to use resource_size_t
2006-06-13 0:31 ` [PATCH 11/16] 64bit resource: introduce resource_size_t for the start and end of struct resource Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 15/16] 64bit resource: change pci core and arch code " Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
Based on a patch series originally from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
arch/sparc/kernel/ioport.c | 4 ++--
include/linux/ioport.h | 23 +++++++++++++----------
kernel/resource.c | 34 ++++++++++++++++++----------------
3 files changed, 33 insertions(+), 28 deletions(-)
diff --git a/arch/sparc/kernel/ioport.c b/arch/sparc/kernel/ioport.c
index 84e134d..571e3fa 100644
--- a/arch/sparc/kernel/ioport.c
+++ b/arch/sparc/kernel/ioport.c
@@ -206,7 +206,7 @@ _sparc_ioremap(struct resource *res, u32
pa &= PAGE_MASK;
sparc_mapiorange(bus, pa, res->start, res->end - res->start + 1);
- return (void __iomem *) (res->start + offset);
+ return (void __iomem *)(unsigned long)(res->start + offset);
}
/*
@@ -279,7 +279,7 @@ void *sbus_alloc_consistent(struct sbus_
res->name = sdev->prom_name;
}
- return (void *)res->start;
+ return (void *)(unsigned long)res->start;
err_noiommu:
release_resource(res);
diff --git a/include/linux/ioport.h b/include/linux/ioport.h
index 535bd95..d489523 100644
--- a/include/linux/ioport.h
+++ b/include/linux/ioport.h
@@ -98,31 +98,34 @@ extern struct resource * ____request_res
extern int release_resource(struct resource *new);
extern __deprecated_for_modules int insert_resource(struct resource *parent, struct resource *new);
extern int allocate_resource(struct resource *root, struct resource *new,
- unsigned long size,
- unsigned long min, unsigned long max,
- unsigned long align,
+ resource_size_t size, resource_size_t min,
+ resource_size_t max, resource_size_t align,
void (*alignf)(void *, struct resource *,
- unsigned long, unsigned long),
+ resource_size_t, resource_size_t),
void *alignf_data);
-int adjust_resource(struct resource *res, unsigned long start,
- unsigned long size);
+int adjust_resource(struct resource *res, resource_size_t start,
+ resource_size_t size);
/* Convenience shorthand with allocation */
#define request_region(start,n,name) __request_region(&ioport_resource, (start), (n), (name))
#define request_mem_region(start,n,name) __request_region(&iomem_resource, (start), (n), (name))
#define rename_region(region, newname) do { (region)->name = (newname); } while (0)
-extern struct resource * __request_region(struct resource *, unsigned long start, unsigned long n, const char *name);
+extern struct resource * __request_region(struct resource *,
+ resource_size_t start,
+ resource_size_t n, const char *name);
/* Compatibility cruft */
#define release_region(start,n) __release_region(&ioport_resource, (start), (n))
#define check_mem_region(start,n) __check_region(&iomem_resource, (start), (n))
#define release_mem_region(start,n) __release_region(&iomem_resource, (start), (n))
-extern int __check_region(struct resource *, unsigned long, unsigned long);
-extern void __release_region(struct resource *, unsigned long, unsigned long);
+extern int __check_region(struct resource *, resource_size_t, resource_size_t);
+extern void __release_region(struct resource *, resource_size_t,
+ resource_size_t);
-static inline int __deprecated check_region(unsigned long s, unsigned long n)
+static inline int __deprecated check_region(resource_size_t s,
+ resource_size_t n)
{
return __check_region(&ioport_resource, s, n);
}
diff --git a/kernel/resource.c b/kernel/resource.c
index 97a703f..ad90a70 100644
--- a/kernel/resource.c
+++ b/kernel/resource.c
@@ -151,8 +151,8 @@ #endif /* CONFIG_PROC_FS */
/* Return the conflict entry if you can't request it */
static struct resource * __request_resource(struct resource *root, struct resource *new)
{
- unsigned long start = new->start;
- unsigned long end = new->end;
+ resource_size_t start = new->start;
+ resource_size_t end = new->end;
struct resource *tmp, **p;
if (end < start)
@@ -236,11 +236,10 @@ EXPORT_SYMBOL(release_resource);
* Find empty slot in the resource tree given range and alignment.
*/
static int find_resource(struct resource *root, struct resource *new,
- unsigned long size,
- unsigned long min, unsigned long max,
- unsigned long align,
+ resource_size_t size, resource_size_t min,
+ resource_size_t max, resource_size_t align,
void (*alignf)(void *, struct resource *,
- unsigned long, unsigned long),
+ resource_size_t, resource_size_t),
void *alignf_data)
{
struct resource *this = root->child;
@@ -282,11 +281,10 @@ static int find_resource(struct resource
* Allocate empty slot in the resource tree given range and alignment.
*/
int allocate_resource(struct resource *root, struct resource *new,
- unsigned long size,
- unsigned long min, unsigned long max,
- unsigned long align,
+ resource_size_t size, resource_size_t min,
+ resource_size_t max, resource_size_t align,
void (*alignf)(void *, struct resource *,
- unsigned long, unsigned long),
+ resource_size_t, resource_size_t),
void *alignf_data)
{
int err;
@@ -378,10 +376,10 @@ EXPORT_SYMBOL(insert_resource);
* arguments. Returns -EBUSY if it can't fit. Existing children of
* the resource are assumed to be immutable.
*/
-int adjust_resource(struct resource *res, unsigned long start, unsigned long size)
+int adjust_resource(struct resource *res, resource_size_t start, resource_size_t size)
{
struct resource *tmp, *parent = res->parent;
- unsigned long end = start + size - 1;
+ resource_size_t end = start + size - 1;
int result = -EBUSY;
write_lock(&resource_lock);
@@ -428,7 +426,9 @@ EXPORT_SYMBOL(adjust_resource);
*
* Release-region releases a matching busy region.
*/
-struct resource * __request_region(struct resource *parent, unsigned long start, unsigned long n, const char *name)
+struct resource * __request_region(struct resource *parent,
+ resource_size_t start, resource_size_t n,
+ const char *name)
{
struct resource *res = kzalloc(sizeof(*res), GFP_KERNEL);
@@ -464,7 +464,8 @@ struct resource * __request_region(struc
EXPORT_SYMBOL(__request_region);
-int __check_region(struct resource *parent, unsigned long start, unsigned long n)
+int __check_region(struct resource *parent, resource_size_t start,
+ resource_size_t n)
{
struct resource * res;
@@ -479,10 +480,11 @@ int __check_region(struct resource *pare
EXPORT_SYMBOL(__check_region);
-void __release_region(struct resource *parent, unsigned long start, unsigned long n)
+void __release_region(struct resource *parent, resource_size_t start,
+ resource_size_t n)
{
struct resource **p;
- unsigned long end;
+ resource_size_t end;
p = &parent->child;
end = start + n - 1;
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 15/16] 64bit resource: change pci core and arch code to use resource_size_t
2006-06-13 0:31 ` [PATCH 12/16] 64bit resource: change resource core to use resource_size_t Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 14/16] 64bit resource: change pnp core " Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
Based on a patch series originally from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
arch/alpha/kernel/pci.c | 4 ++--
arch/arm/kernel/bios32.c | 6 +++---
arch/cris/arch-v32/drivers/pci/bios.c | 4 ++--
arch/frv/mb93090-mb00/pci-frv.c | 4 ++--
arch/i386/pci/i386.c | 4 ++--
arch/ia64/pci/pci.c | 2 +-
arch/m68knommu/kernel/comempci.c | 3 ++-
arch/mips/pci/pci.c | 4 ++--
arch/mips/pmc-sierra/yosemite/ht.c | 4 ++--
arch/parisc/kernel/pci.c | 2 +-
arch/powerpc/kernel/pci_32.c | 22 +++++++++++++++-------
arch/powerpc/kernel/pci_64.c | 4 ++--
arch/ppc/kernel/pci.c | 12 ++++++------
arch/sh/boards/mpc1211/pci.c | 4 ++--
arch/sh/boards/overdrive/galileo.c | 2 +-
arch/sh/drivers/pci/pci.c | 6 +++---
arch/sh64/kernel/pcibios.c | 4 ++--
arch/sparc/kernel/pcic.c | 2 +-
arch/sparc64/kernel/pci.c | 2 +-
arch/v850/kernel/rte_mb_a_pci.c | 2 +-
arch/xtensa/kernel/pci.c | 6 +++---
drivers/pci/bus.c | 10 +++++-----
drivers/pci/pci-sysfs.c | 4 ++--
drivers/pci/pci.h | 6 +++---
drivers/pci/proc.c | 4 ++--
drivers/pci/rom.c | 10 +++++-----
drivers/pci/setup-res.c | 6 +++---
include/asm-arm/mach/pci.h | 2 +-
include/asm-powerpc/pci.h | 2 +-
include/asm-ppc/pci.h | 2 +-
include/linux/pci.h | 13 +++++++------
31 files changed, 86 insertions(+), 76 deletions(-)
diff --git a/arch/alpha/kernel/pci.c b/arch/alpha/kernel/pci.c
index 2a8b364..4ea6711 100644
--- a/arch/alpha/kernel/pci.c
+++ b/arch/alpha/kernel/pci.c
@@ -124,12 +124,12 @@ #define GB (1024*MB)
void
pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
struct pci_dev *dev = data;
struct pci_controller *hose = dev->sysdata;
unsigned long alignto;
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (res->flags & IORESOURCE_IO) {
/* Make sure we start at our min on all hoses */
diff --git a/arch/arm/kernel/bios32.c b/arch/arm/kernel/bios32.c
index de606df..e97dc54 100644
--- a/arch/arm/kernel/bios32.c
+++ b/arch/arm/kernel/bios32.c
@@ -304,7 +304,7 @@ static inline int pdev_bad_for_parity(st
static void __devinit
pdev_fixup_device_resources(struct pci_sys_data *root, struct pci_dev *dev)
{
- unsigned long offset;
+ resource_size_t offset;
int i;
for (i = 0; i < PCI_NUM_RESOURCES; i++) {
@@ -634,9 +634,9 @@ char * __init pcibios_setup(char *str)
* which might be mirrored at 0x0100-0x03ff..
*/
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (res->flags & IORESOURCE_IO && start & 0x300)
start = (start + 0x3ff) & ~0x3ff;
diff --git a/arch/cris/arch-v32/drivers/pci/bios.c b/arch/cris/arch-v32/drivers/pci/bios.c
index 24bc149..1a076df 100644
--- a/arch/cris/arch-v32/drivers/pci/bios.c
+++ b/arch/cris/arch-v32/drivers/pci/bios.c
@@ -45,10 +45,10 @@ int pci_mmap_page_range(struct pci_dev *
void
pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
if (res->flags & IORESOURCE_IO) {
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (start & 0x300) {
start = (start + 0x3ff) & ~0x3ff;
diff --git a/arch/frv/mb93090-mb00/pci-frv.c b/arch/frv/mb93090-mb00/pci-frv.c
index 0a26bf6..4f165c9 100644
--- a/arch/frv/mb93090-mb00/pci-frv.c
+++ b/arch/frv/mb93090-mb00/pci-frv.c
@@ -64,10 +64,10 @@ #endif
*/
void
pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
if (res->flags & IORESOURCE_IO) {
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (start & 0x300) {
start = (start + 0x3ff) & ~0x3ff;
diff --git a/arch/i386/pci/i386.c b/arch/i386/pci/i386.c
index ed2c8c8..d2add37 100644
--- a/arch/i386/pci/i386.c
+++ b/arch/i386/pci/i386.c
@@ -48,10 +48,10 @@ #include "pci.h"
*/
void
pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
if (res->flags & IORESOURCE_IO) {
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (start & 0x300) {
start = (start + 0x3ff) & ~0x3ff;
diff --git a/arch/ia64/pci/pci.c b/arch/ia64/pci/pci.c
index ab829a2..c355638 100644
--- a/arch/ia64/pci/pci.c
+++ b/arch/ia64/pci/pci.c
@@ -568,7 +568,7 @@ pcibios_disable_device (struct pci_dev *
void
pcibios_align_resource (void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
}
diff --git a/arch/m68knommu/kernel/comempci.c b/arch/m68knommu/kernel/comempci.c
index 8670938..db7a0c1 100644
--- a/arch/m68knommu/kernel/comempci.c
+++ b/arch/m68knommu/kernel/comempci.c
@@ -357,7 +357,8 @@ void pcibios_fixup_bus(struct pci_bus *b
/*****************************************************************************/
-void pcibios_align_resource(void *data, struct resource *res, unsigned long size, unsigned long align)
+void pcibios_align_resource(void *data, struct resource *res,
+ resource_size_t size, resource_size_t align)
{
}
diff --git a/arch/mips/pci/pci.c b/arch/mips/pci/pci.c
index 21402ff..20278b9 100644
--- a/arch/mips/pci/pci.c
+++ b/arch/mips/pci/pci.c
@@ -51,11 +51,11 @@ unsigned long PCIBIOS_MIN_MEM = 0;
*/
void
pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
struct pci_dev *dev = data;
struct pci_controller *hose = dev->sysdata;
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (res->flags & IORESOURCE_IO) {
/* Make sure we start at our min on all hoses */
diff --git a/arch/mips/pmc-sierra/yosemite/ht.c b/arch/mips/pmc-sierra/yosemite/ht.c
index 54b65a8..fb523eb 100644
--- a/arch/mips/pmc-sierra/yosemite/ht.c
+++ b/arch/mips/pmc-sierra/yosemite/ht.c
@@ -383,12 +383,12 @@ void pcibios_update_resource(struct pci_
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
struct pci_dev *dev = data;
if (res->flags & IORESOURCE_IO) {
- unsigned long start = res->start;
+ resource_size_t start = res->start;
/* We need to avoid collisions with `mirrored' VGA ports
and other strange ISA hardware, so we always want the
diff --git a/arch/parisc/kernel/pci.c b/arch/parisc/kernel/pci.c
index 79c7db2..7d6967e 100644
--- a/arch/parisc/kernel/pci.c
+++ b/arch/parisc/kernel/pci.c
@@ -289,7 +289,7 @@ #endif
* than res->start.
*/
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long alignment)
+ resource_size_t size, resource_size_t alignment)
{
unsigned long mask, align;
diff --git a/arch/powerpc/kernel/pci_32.c b/arch/powerpc/kernel/pci_32.c
index 18886e8..c78b545 100644
--- a/arch/powerpc/kernel/pci_32.c
+++ b/arch/powerpc/kernel/pci_32.c
@@ -173,18 +173,18 @@ EXPORT_SYMBOL(pcibios_bus_to_resource);
* but we want to try to avoid allocating at 0x2900-0x2bff
* which might have be mirrored at 0x0100-0x03ff..
*/
-void pcibios_align_resource(void *data, struct resource *res, unsigned long size,
- unsigned long align)
+void pcibios_align_resource(void *data, struct resource *res,
+ resource_size_t size, resource_size_t align)
{
struct pci_dev *dev = data;
if (res->flags & IORESOURCE_IO) {
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (size > 0x100) {
printk(KERN_ERR "PCI: I/O Region %s/%d too large"
" (%lld bytes)\n", pci_name(dev),
- dev->resource - res, size);
+ dev->resource - res, (unsigned long long)size);
}
if (start & 0x300) {
@@ -1114,8 +1114,16 @@ check_for_io_childs(struct pci_bus *bus,
int i;
int rc = 0;
-#define push_end(res, size) do { unsigned long __sz = (size) ; \
- res->end = ((res->end + __sz) / (__sz + 1)) * (__sz + 1) + __sz; \
+ /*
+ * Assuming mask is a power of two - 1, push_end
+ * moves res->end to the end of the next
+ * mask-aligned boundary.
+ * e.g. res->end of 0x1fff moves to 0x2fff
+ */
+#define push_end(res, mask) do { \
+ BUG_ON(((mask+1) & mask) != 0); \
+ res->end = -(-res->end & ~(unsigned long)mask); \
+ res->end += mask; \
} while (0)
list_for_each_entry(dev, &bus->devices, bus_list) {
@@ -1756,7 +1764,7 @@ #endif /* CONFIG_PPC_PMAC */
void pci_resource_to_user(const struct pci_dev *dev, int bar,
const struct resource *rsrc,
- u64 *start, u64 *end)
+ resource_size_t *start, resource_size_t *end)
{
struct pci_controller *hose = pci_bus_to_hose(dev->bus->number);
unsigned long offset = 0;
diff --git a/arch/powerpc/kernel/pci_64.c b/arch/powerpc/kernel/pci_64.c
index 4c4449b..0ba0413 100644
--- a/arch/powerpc/kernel/pci_64.c
+++ b/arch/powerpc/kernel/pci_64.c
@@ -146,11 +146,11 @@ #endif
* which might have be mirrored at 0x0100-0x03ff..
*/
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
struct pci_dev *dev = data;
struct pci_controller *hose = pci_bus_to_host(dev->bus);
- unsigned long start = res->start;
+ resource_size_t start = res->start;
unsigned long alignto;
if (res->flags & IORESOURCE_IO) {
diff --git a/arch/ppc/kernel/pci.c b/arch/ppc/kernel/pci.c
index 3ddc1e0..4c836df 100644
--- a/arch/ppc/kernel/pci.c
+++ b/arch/ppc/kernel/pci.c
@@ -171,13 +171,13 @@ EXPORT_SYMBOL(pcibios_bus_to_resource);
* but we want to try to avoid allocating at 0x2900-0x2bff
* which might have be mirrored at 0x0100-0x03ff..
*/
-void pcibios_align_resource(void *data, struct resource *res, unsigned long size,
- unsigned long align)
+void pcibios_align_resource(void *data, struct resource *res,
+ resource_size_t size, resource_size_t align)
{
struct pci_dev *dev = data;
if (res->flags & IORESOURCE_IO) {
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (size > 0x100) {
printk(KERN_ERR "PCI: I/O Region %s/%d too large"
@@ -960,8 +960,8 @@ static pgprot_t __pci_mmap_set_pgprot(st
else
prot |= _PAGE_GUARDED;
- printk("PCI map for %s:%llx, prot: %llx\n", pci_name(dev), rp->start,
- prot);
+ printk("PCI map for %s:%llx, prot: %lx\n", pci_name(dev),
+ (unsigned long long)rp->start, prot);
return __pgprot(prot);
}
@@ -1131,7 +1131,7 @@ long sys_pciconfig_iobase(long which, un
void pci_resource_to_user(const struct pci_dev *dev, int bar,
const struct resource *rsrc,
- u64 *start, u64 *end)
+ resource_size_t *start, resource_size_t *end)
{
struct pci_controller *hose = pci_bus_to_hose(dev->bus->number);
unsigned long offset = 0;
diff --git a/arch/sh/boards/mpc1211/pci.c b/arch/sh/boards/mpc1211/pci.c
index ba3a654..9f7ccd3 100644
--- a/arch/sh/boards/mpc1211/pci.c
+++ b/arch/sh/boards/mpc1211/pci.c
@@ -273,9 +273,9 @@ void __init pcibios_fixup_irqs(void)
}
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (res->flags & IORESOURCE_IO) {
if (start >= 0x10000UL) {
diff --git a/arch/sh/boards/overdrive/galileo.c b/arch/sh/boards/overdrive/galileo.c
index 276fa11..b055809 100644
--- a/arch/sh/boards/overdrive/galileo.c
+++ b/arch/sh/boards/overdrive/galileo.c
@@ -536,7 +536,7 @@ void __init pcibios_fixup_bus(struct pci
}
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size)
+ resource_size_t size)
{
}
diff --git a/arch/sh/drivers/pci/pci.c b/arch/sh/drivers/pci/pci.c
index c166990..3d546ba 100644
--- a/arch/sh/drivers/pci/pci.c
+++ b/arch/sh/drivers/pci/pci.c
@@ -75,7 +75,7 @@ pcibios_update_resource(struct pci_dev *
}
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
__attribute__ ((weak));
/*
@@ -85,10 +85,10 @@ void pcibios_align_resource(void *data,
* modulo 0x400.
*/
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
if (res->flags & IORESOURCE_IO) {
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (start & 0x300) {
start = (start + 0x3ff) & ~0x3ff;
diff --git a/arch/sh64/kernel/pcibios.c b/arch/sh64/kernel/pcibios.c
index 50c61dc..945920b 100644
--- a/arch/sh64/kernel/pcibios.c
+++ b/arch/sh64/kernel/pcibios.c
@@ -69,10 +69,10 @@ pcibios_update_resource(struct pci_dev *
* modulo 0x400.
*/
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
if (res->flags & IORESOURCE_IO) {
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (start & 0x300) {
start = (start + 0x3ff) & ~0x3ff;
diff --git a/arch/sparc/kernel/pcic.c b/arch/sparc/kernel/pcic.c
index 42002b7..f181835 100644
--- a/arch/sparc/kernel/pcic.c
+++ b/arch/sparc/kernel/pcic.c
@@ -859,7 +859,7 @@ char * __init pcibios_setup(char *str)
}
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
}
diff --git a/arch/sparc64/kernel/pci.c b/arch/sparc64/kernel/pci.c
index f97ddeb..3bd582e 100644
--- a/arch/sparc64/kernel/pci.c
+++ b/arch/sparc64/kernel/pci.c
@@ -390,7 +390,7 @@ void pcibios_update_irq(struct pci_dev *
}
void pcibios_align_resource(void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
}
diff --git a/arch/v850/kernel/rte_mb_a_pci.c b/arch/v850/kernel/rte_mb_a_pci.c
index ffbb6d0..3a7c5c9 100644
--- a/arch/v850/kernel/rte_mb_a_pci.c
+++ b/arch/v850/kernel/rte_mb_a_pci.c
@@ -329,7 +329,7 @@ void pcibios_fixup_bus(struct pci_bus *b
void
pcibios_align_resource (void *data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
}
diff --git a/arch/xtensa/kernel/pci.c b/arch/xtensa/kernel/pci.c
index de19501..19373ef 100644
--- a/arch/xtensa/kernel/pci.c
+++ b/arch/xtensa/kernel/pci.c
@@ -71,13 +71,13 @@ static int pci_bus_count;
* which might have be mirrored at 0x0100-0x03ff..
*/
void
-pcibios_align_resource(void *data, struct resource *res, unsigned long size,
- unsigned long align)
+pcibios_align_resource(void *data, struct resource *res, resource_size_t size,
+ resource_size_t align)
{
struct pci_dev *dev = data;
if (res->flags & IORESOURCE_IO) {
- unsigned long start = res->start;
+ resource_size_t start = res->start;
if (size > 0x100) {
printk(KERN_ERR "PCI: I/O Region %s/%d too large"
diff --git a/drivers/pci/bus.c b/drivers/pci/bus.c
index eed67d9..d3ca2f9 100644
--- a/drivers/pci/bus.c
+++ b/drivers/pci/bus.c
@@ -34,11 +34,11 @@ #include "pci.h"
*/
int
pci_bus_alloc_resource(struct pci_bus *bus, struct resource *res,
- unsigned long size, unsigned long align, unsigned long min,
- unsigned int type_mask,
- void (*alignf)(void *, struct resource *,
- unsigned long, unsigned long),
- void *alignf_data)
+ resource_size_t size, resource_size_t align,
+ resource_size_t min, unsigned int type_mask,
+ void (*alignf)(void *, struct resource *, resource_size_t,
+ resource_size_t),
+ void *alignf_data)
{
int i, ret = -ENOMEM;
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
index 56ac2bc..df14c54 100644
--- a/drivers/pci/pci-sysfs.c
+++ b/drivers/pci/pci-sysfs.c
@@ -64,7 +64,7 @@ resource_show(struct device * dev, struc
char * str = buf;
int i;
int max = 7;
- u64 start, end;
+ resource_size_t start, end;
if (pci_dev->subordinate)
max = DEVICE_COUNT_RESOURCE;
@@ -320,7 +320,7 @@ pci_mmap_resource(struct kobject *kobj,
struct device, kobj));
struct resource *res = (struct resource *)attr->private;
enum pci_mmap_state mmap_type;
- u64 start, end;
+ resource_size_t start, end;
int i;
for (i = 0; i < PCI_ROM_RESOURCE; i++)
diff --git a/drivers/pci/pci.h b/drivers/pci/pci.h
index 30630cb..1ea979a 100644
--- a/drivers/pci/pci.h
+++ b/drivers/pci/pci.h
@@ -6,10 +6,10 @@ extern int pci_create_sysfs_dev_files(st
extern void pci_remove_sysfs_dev_files(struct pci_dev *pdev);
extern void pci_cleanup_rom(struct pci_dev *dev);
extern int pci_bus_alloc_resource(struct pci_bus *bus, struct resource *res,
- unsigned long size, unsigned long align,
- unsigned long min, unsigned int type_mask,
+ resource_size_t size, resource_size_t align,
+ resource_size_t min, unsigned int type_mask,
void (*alignf)(void *, struct resource *,
- unsigned long, unsigned long),
+ resource_size_t, resource_size_t),
void *alignf_data);
/* Firmware callbacks */
extern int (*platform_pci_choose_state)(struct pci_dev *dev, pm_message_t state);
diff --git a/drivers/pci/proc.c b/drivers/pci/proc.c
index 20dfd77..99cf333 100644
--- a/drivers/pci/proc.c
+++ b/drivers/pci/proc.c
@@ -350,14 +350,14 @@ static int show_device(struct seq_file *
dev->irq);
/* Here should be 7 and not PCI_NUM_RESOURCES as we need to preserve compatibility */
for (i=0; i<7; i++) {
- u64 start, end;
+ resource_size_t start, end;
pci_resource_to_user(dev, i, &dev->resource[i], &start, &end);
seq_printf(m, "\t%16llx",
(unsigned long long)(start |
(dev->resource[i].flags & PCI_REGION_FLAG_MASK)));
}
for (i=0; i<7; i++) {
- u64 start, end;
+ resource_size_t start, end;
pci_resource_to_user(dev, i, &dev->resource[i], &start, &end);
seq_printf(m, "\t%16llx",
dev->resource[i].start < dev->resource[i].end ?
diff --git a/drivers/pci/rom.c b/drivers/pci/rom.c
index 598a115..cbb69cf 100644
--- a/drivers/pci/rom.c
+++ b/drivers/pci/rom.c
@@ -80,8 +80,8 @@ void __iomem *pci_map_rom(struct pci_dev
} else {
if (res->flags & IORESOURCE_ROM_COPY) {
*size = pci_resource_len(pdev, PCI_ROM_RESOURCE);
- return (void __iomem *)pci_resource_start(pdev,
- PCI_ROM_RESOURCE);
+ return (void __iomem *)(unsigned long)
+ pci_resource_start(pdev, PCI_ROM_RESOURCE);
} else {
/* assign the ROM an address if it doesn't have one */
if (res->parent == NULL &&
@@ -170,11 +170,11 @@ void __iomem *pci_map_rom_copy(struct pc
return rom;
res->end = res->start + *size;
- memcpy_fromio((void*)res->start, rom, *size);
+ memcpy_fromio((void*)(unsigned long)res->start, rom, *size);
pci_unmap_rom(pdev, rom);
res->flags |= IORESOURCE_ROM_COPY;
- return (void __iomem *)res->start;
+ return (void __iomem *)(unsigned long)res->start;
}
/**
@@ -227,7 +227,7 @@ void pci_cleanup_rom(struct pci_dev *pde
{
struct resource *res = &pdev->resource[PCI_ROM_RESOURCE];
if (res->flags & IORESOURCE_ROM_COPY) {
- kfree((void*)res->start);
+ kfree((void*)(unsigned long)res->start);
res->flags &= ~IORESOURCE_ROM_COPY;
res->start = 0;
res->end = 0;
diff --git a/drivers/pci/setup-res.c b/drivers/pci/setup-res.c
index d3e70ca..7b1e893 100644
--- a/drivers/pci/setup-res.c
+++ b/drivers/pci/setup-res.c
@@ -121,7 +121,7 @@ int pci_assign_resource(struct pci_dev *
{
struct pci_bus *bus = dev->bus;
struct resource *res = dev->resource + resno;
- unsigned long size, min, align;
+ resource_size_t size, min, align;
int ret;
size = res->end - res->start + 1;
@@ -169,7 +169,7 @@ pdev_sort_resources(struct pci_dev *dev,
for (i = 0; i < PCI_NUM_RESOURCES; i++) {
struct resource *r;
struct resource_list *list, *tmp;
- unsigned long r_align;
+ resource_size_t r_align;
r = &dev->resource[i];
r_align = r->end - r->start;
@@ -185,7 +185,7 @@ pdev_sort_resources(struct pci_dev *dev,
}
r_align = (i < PCI_BRIDGE_RESOURCES) ? r_align + 1 : r->start;
for (list = head; ; list = list->next) {
- unsigned long align = 0;
+ resource_size_t align = 0;
struct resource_list *ln = list->next;
int idx;
diff --git a/include/asm-arm/mach/pci.h b/include/asm-arm/mach/pci.h
index 25d540e..923e0ca 100644
--- a/include/asm-arm/mach/pci.h
+++ b/include/asm-arm/mach/pci.h
@@ -28,7 +28,7 @@ struct hw_pci {
struct pci_sys_data {
struct list_head node;
int busnr; /* primary bus number */
- unsigned long mem_offset; /* bus->cpu memory mapping offset */
+ u64 mem_offset; /* bus->cpu memory mapping offset */
unsigned long io_offset; /* bus->cpu IO mapping offset */
struct pci_bus *bus; /* PCI bus */
struct resource *resource[3]; /* Primary PCI bus resources */
diff --git a/include/asm-powerpc/pci.h b/include/asm-powerpc/pci.h
index 5d2c9e6..46afd29 100644
--- a/include/asm-powerpc/pci.h
+++ b/include/asm-powerpc/pci.h
@@ -242,7 +242,7 @@ #if defined(CONFIG_PPC_MULTIPLATFORM) ||
#define HAVE_ARCH_PCI_RESOURCE_TO_USER
extern void pci_resource_to_user(const struct pci_dev *dev, int bar,
const struct resource *rsrc,
- u64 *start, u64 *end);
+ resource_size_t *start, resource_size_t *end);
#endif /* CONFIG_PPC_MULTIPLATFORM || CONFIG_PPC32 */
#endif /* __KERNEL__ */
diff --git a/include/asm-ppc/pci.h b/include/asm-ppc/pci.h
index 61434ed..11ffaaa 100644
--- a/include/asm-ppc/pci.h
+++ b/include/asm-ppc/pci.h
@@ -133,7 +133,7 @@ extern pgprot_t pci_phys_mem_access_prot
#define HAVE_ARCH_PCI_RESOURCE_TO_USER
extern void pci_resource_to_user(const struct pci_dev *dev, int bar,
const struct resource *rsrc,
- u64 *start, u64 *end);
+ resource_size_t *start, resource_size_t *end);
#endif /* __KERNEL__ */
diff --git a/include/linux/pci.h b/include/linux/pci.h
index 3a6a4e3..ad1943f 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -402,8 +402,8 @@ int pcibios_enable_device(struct pci_dev
char *pcibios_setup (char *str);
/* Used only when drivers/pci/setup.c is used */
-void pcibios_align_resource(void *, struct resource *,
- unsigned long, unsigned long);
+void pcibios_align_resource(void *, struct resource *, resource_size_t,
+ resource_size_t);
void pcibios_update_irq(struct pci_dev *, int irq);
/* Generic PCI functions used internally */
@@ -528,10 +528,10 @@ void pci_release_region(struct pci_dev *
/* drivers/pci/bus.c */
int pci_bus_alloc_resource(struct pci_bus *bus, struct resource *res,
- unsigned long size, unsigned long align,
- unsigned long min, unsigned int type_mask,
+ resource_size_t size, resource_size_t align,
+ resource_size_t min, unsigned int type_mask,
void (*alignf)(void *, struct resource *,
- unsigned long, unsigned long),
+ resource_size_t, resource_size_t),
void *alignf_data);
void pci_enable_bridges(struct pci_bus *bus);
@@ -725,7 +725,8 @@ static inline char *pci_name(struct pci_
*/
#ifndef HAVE_ARCH_PCI_RESOURCE_TO_USER
static inline void pci_resource_to_user(const struct pci_dev *dev, int bar,
- const struct resource *rsrc, u64 *start, u64 *end)
+ const struct resource *rsrc, resource_size_t *start,
+ resource_size_t *end)
{
*start = rsrc->start;
*end = rsrc->end;
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 14/16] 64bit resource: change pnp core to use resource_size_t
2006-06-13 0:31 ` [PATCH 15/16] 64bit resource: change pci core and arch code " Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 15/16] 64bit Resource: convert a few remaining drivers to use resource_size_t where needed Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
Based on a patch series originally from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/pnp/interface.c | 8 ++++----
drivers/pnp/manager.c | 15 ++++++++++-----
drivers/pnp/resource.c | 8 ++++----
include/linux/pnp.h | 7 +++++--
4 files changed, 23 insertions(+), 15 deletions(-)
diff --git a/drivers/pnp/interface.c b/drivers/pnp/interface.c
index a2d8ce7..3163e3d 100644
--- a/drivers/pnp/interface.c
+++ b/drivers/pnp/interface.c
@@ -264,7 +264,7 @@ static ssize_t pnp_show_current_resource
if (pnp_port_flags(dev, i) & IORESOURCE_DISABLED)
pnp_printf(buffer," disabled\n");
else
- pnp_printf(buffer," 0x%lx-0x%lx\n",
+ pnp_printf(buffer," 0x%llx-0x%llx\n",
pnp_port_start(dev, i),
pnp_port_end(dev, i));
}
@@ -275,7 +275,7 @@ static ssize_t pnp_show_current_resource
if (pnp_mem_flags(dev, i) & IORESOURCE_DISABLED)
pnp_printf(buffer," disabled\n");
else
- pnp_printf(buffer," 0x%lx-0x%lx\n",
+ pnp_printf(buffer," 0x%llx-0x%llx\n",
pnp_mem_start(dev, i),
pnp_mem_end(dev, i));
}
@@ -286,7 +286,7 @@ static ssize_t pnp_show_current_resource
if (pnp_irq_flags(dev, i) & IORESOURCE_DISABLED)
pnp_printf(buffer," disabled\n");
else
- pnp_printf(buffer," %ld\n",
+ pnp_printf(buffer," %lld\n",
pnp_irq(dev, i));
}
}
@@ -296,7 +296,7 @@ static ssize_t pnp_show_current_resource
if (pnp_dma_flags(dev, i) & IORESOURCE_DISABLED)
pnp_printf(buffer," disabled\n");
else
- pnp_printf(buffer," %ld\n",
+ pnp_printf(buffer," %lld\n",
pnp_dma(dev, i));
}
}
diff --git a/drivers/pnp/manager.c b/drivers/pnp/manager.c
index 6fff109..1d7a5b8 100644
--- a/drivers/pnp/manager.c
+++ b/drivers/pnp/manager.c
@@ -20,7 +20,8 @@ DECLARE_MUTEX(pnp_res_mutex);
static int pnp_assign_port(struct pnp_dev *dev, struct pnp_port *rule, int idx)
{
- unsigned long *start, *end, *flags;
+ resource_size_t *start, *end;
+ unsigned long *flags;
if (!dev || !rule)
return -EINVAL;
@@ -63,7 +64,8 @@ static int pnp_assign_port(struct pnp_de
static int pnp_assign_mem(struct pnp_dev *dev, struct pnp_mem *rule, int idx)
{
- unsigned long *start, *end, *flags;
+ resource_size_t *start, *end;
+ unsigned long *flags;
if (!dev || !rule)
return -EINVAL;
@@ -116,7 +118,8 @@ static int pnp_assign_mem(struct pnp_dev
static int pnp_assign_irq(struct pnp_dev * dev, struct pnp_irq *rule, int idx)
{
- unsigned long *start, *end, *flags;
+ resource_size_t *start, *end;
+ unsigned long *flags;
int i;
/* IRQ priority: this table is good for i386 */
@@ -168,7 +171,8 @@ static int pnp_assign_irq(struct pnp_dev
static int pnp_assign_dma(struct pnp_dev *dev, struct pnp_dma *rule, int idx)
{
- unsigned long *start, *end, *flags;
+ resource_size_t *start, *end;
+ unsigned long *flags;
int i;
/* DMA priority: this table is good for i386 */
@@ -582,7 +586,8 @@ int pnp_disable_dev(struct pnp_dev *dev)
* @size: size of region
*
*/
-void pnp_resource_change(struct resource *resource, unsigned long start, unsigned long size)
+void pnp_resource_change(struct resource *resource, resource_size_t start,
+ resource_size_t size)
{
if (resource == NULL)
return;
diff --git a/drivers/pnp/resource.c b/drivers/pnp/resource.c
index 6ded527..7bb892f 100644
--- a/drivers/pnp/resource.c
+++ b/drivers/pnp/resource.c
@@ -241,7 +241,7 @@ int pnp_check_port(struct pnp_dev * dev,
{
int tmp;
struct pnp_dev *tdev;
- unsigned long *port, *end, *tport, *tend;
+ resource_size_t *port, *end, *tport, *tend;
port = &dev->res.port_resource[idx].start;
end = &dev->res.port_resource[idx].end;
@@ -297,7 +297,7 @@ int pnp_check_mem(struct pnp_dev * dev,
{
int tmp;
struct pnp_dev *tdev;
- unsigned long *addr, *end, *taddr, *tend;
+ resource_size_t *addr, *end, *taddr, *tend;
addr = &dev->res.mem_resource[idx].start;
end = &dev->res.mem_resource[idx].end;
@@ -358,7 +358,7 @@ int pnp_check_irq(struct pnp_dev * dev,
{
int tmp;
struct pnp_dev *tdev;
- unsigned long * irq = &dev->res.irq_resource[idx].start;
+ resource_size_t * irq = &dev->res.irq_resource[idx].start;
/* if the resource doesn't exist, don't complain about it */
if (cannot_compare(dev->res.irq_resource[idx].flags))
@@ -423,7 +423,7 @@ int pnp_check_dma(struct pnp_dev * dev,
#ifndef CONFIG_IA64
int tmp;
struct pnp_dev *tdev;
- unsigned long * dma = &dev->res.dma_resource[idx].start;
+ resource_size_t * dma = &dev->res.dma_resource[idx].start;
/* if the resource doesn't exist, don't complain about it */
if (cannot_compare(dev->res.dma_resource[idx].flags))
diff --git a/include/linux/pnp.h b/include/linux/pnp.h
index 93b0959..ab8a8dd 100644
--- a/include/linux/pnp.h
+++ b/include/linux/pnp.h
@@ -389,7 +389,8 @@ int pnp_start_dev(struct pnp_dev *dev);
int pnp_stop_dev(struct pnp_dev *dev);
int pnp_activate_dev(struct pnp_dev *dev);
int pnp_disable_dev(struct pnp_dev *dev);
-void pnp_resource_change(struct resource *resource, unsigned long start, unsigned long size);
+void pnp_resource_change(struct resource *resource, resource_size_t start,
+ resource_size_t size);
/* protocol helpers */
int pnp_is_active(struct pnp_dev * dev);
@@ -434,7 +435,9 @@ static inline int pnp_start_dev(struct p
static inline int pnp_stop_dev(struct pnp_dev *dev) { return -ENODEV; }
static inline int pnp_activate_dev(struct pnp_dev *dev) { return -ENODEV; }
static inline int pnp_disable_dev(struct pnp_dev *dev) { return -ENODEV; }
-static inline void pnp_resource_change(struct resource *resource, unsigned long start, unsigned long size) { }
+static inline void pnp_resource_change(struct resource *resource,
+ resource_size_t start,
+ resource_size_t size) { }
/* protocol helpers */
static inline int pnp_is_active(struct pnp_dev * dev) { return 0; }
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 15/16] 64bit Resource: convert a few remaining drivers to use resource_size_t where needed
2006-06-13 0:31 ` [PATCH 14/16] 64bit resource: change pnp core " Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-13 0:31 ` [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
Based on a patch series originally from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
drivers/ieee1394/ohci1394.c | 2 +-
drivers/isdn/hisax/hfc_pci.c | 2 +-
drivers/net/8139cp.c | 2 +-
drivers/pcmcia/rsrc_nonstatic.c | 14 +++++++-------
drivers/serial/8250_pci.c | 4 ++--
drivers/usb/host/sl811-hcd.c | 10 +++++++---
6 files changed, 19 insertions(+), 15 deletions(-)
diff --git a/drivers/ieee1394/ohci1394.c b/drivers/ieee1394/ohci1394.c
index 744b66c..4ebc530 100644
--- a/drivers/ieee1394/ohci1394.c
+++ b/drivers/ieee1394/ohci1394.c
@@ -3210,7 +3210,7 @@ static int __devinit ohci1394_pci_probe(
{
struct hpsb_host *host;
struct ti_ohci *ohci; /* shortcut to currently handled device */
- unsigned long ohci_base;
+ resource_size_t ohci_base;
if (pci_enable_device(dev))
FAIL(-ENXIO, "Failed to enable OHCI hardware");
diff --git a/drivers/isdn/hisax/hfc_pci.c b/drivers/isdn/hisax/hfc_pci.c
index 91d25ac..3622720 100644
--- a/drivers/isdn/hisax/hfc_pci.c
+++ b/drivers/isdn/hisax/hfc_pci.c
@@ -1688,7 +1688,7 @@ #ifdef CONFIG_PCI
printk(KERN_WARNING "HFC-PCI: No IRQ for PCI card found\n");
return (0);
}
- cs->hw.hfcpci.pci_io = (char *) dev_hfcpci->resource[ 1].start;
+ cs->hw.hfcpci.pci_io = (char *)(unsigned long)dev_hfcpci->resource[1].start;
printk(KERN_INFO "HiSax: HFC-PCI card manufacturer: %s card name: %s\n", id_list[i].vendor_name, id_list[i].card_name);
} else {
printk(KERN_WARNING "HFC-PCI: No PCI card found\n");
diff --git a/drivers/net/8139cp.c b/drivers/net/8139cp.c
index e74e20a..1eaf0a4 100644
--- a/drivers/net/8139cp.c
+++ b/drivers/net/8139cp.c
@@ -1668,7 +1668,7 @@ static int cp_init_one (struct pci_dev *
struct cp_private *cp;
int rc;
void __iomem *regs;
- long pciaddr;
+ resource_size_t pciaddr;
unsigned int addr_len, i, pci_using_dac;
u8 pci_rev;
diff --git a/drivers/pcmcia/rsrc_nonstatic.c b/drivers/pcmcia/rsrc_nonstatic.c
index cc03130..c3176b1 100644
--- a/drivers/pcmcia/rsrc_nonstatic.c
+++ b/drivers/pcmcia/rsrc_nonstatic.c
@@ -72,7 +72,7 @@ #define MEM_PROBE_HIGH (1 << 1)
======================================================================*/
static struct resource *
-make_resource(unsigned long b, unsigned long n, int flags, char *name)
+make_resource(resource_size_t b, resource_size_t n, int flags, char *name)
{
struct resource *res = kzalloc(sizeof(*res), GFP_KERNEL);
@@ -86,8 +86,8 @@ make_resource(unsigned long b, unsigned
}
static struct resource *
-claim_region(struct pcmcia_socket *s, unsigned long base, unsigned long size,
- int type, char *name)
+claim_region(struct pcmcia_socket *s, resource_size_t base,
+ resource_size_t size, int type, char *name)
{
struct resource *res, *parent;
@@ -519,10 +519,10 @@ struct pcmcia_align_data {
static void
pcmcia_common_align(void *align_data, struct resource *res,
- unsigned long size, unsigned long align)
+ resource_size_t size, resource_size_t align)
{
struct pcmcia_align_data *data = align_data;
- unsigned long start;
+ resource_size_t start;
/*
* Ensure that we have the correct start address
*/
@@ -533,8 +533,8 @@ pcmcia_common_align(void *align_data, st
}
static void
-pcmcia_align(void *align_data, struct resource *res,
- unsigned long size, unsigned long align)
+pcmcia_align(void *align_data, struct resource *res, resource_size_t size,
+ resource_size_t align)
{
struct pcmcia_align_data *data = align_data;
struct resource_map *m;
diff --git a/drivers/serial/8250_pci.c b/drivers/serial/8250_pci.c
index 94886c0..864ef85 100644
--- a/drivers/serial/8250_pci.c
+++ b/drivers/serial/8250_pci.c
@@ -594,8 +594,8 @@ pci_default_setup(struct serial_private
else
offset += idx * board->uart_offset;
- maxnr = (pci_resource_len(priv->dev, bar) - board->first_offset) /
- (8 << board->reg_shift);
+ maxnr = (pci_resource_len(priv->dev, bar) - board->first_offset) >>
+ (board->reg_shift + 3);
if (board->flags & FL_REGION_SZ_CAP && idx >= maxnr)
return 1;
diff --git a/drivers/usb/host/sl811-hcd.c b/drivers/usb/host/sl811-hcd.c
index a923430..658f570 100644
--- a/drivers/usb/host/sl811-hcd.c
+++ b/drivers/usb/host/sl811-hcd.c
@@ -1684,9 +1684,13 @@ sl811h_probe(struct platform_device *dev
if (!addr || !data)
return -ENODEV;
ioaddr = 1;
-
- addr_reg = (void __iomem *) addr->start;
- data_reg = (void __iomem *) data->start;
+ /*
+ * NOTE: 64-bit resource->start is getting truncated
+ * to avoid compiler warning, assuming that ->start
+ * is always 32-bit for this case
+ */
+ addr_reg = (void __iomem *) (unsigned long) addr->start;
+ data_reg = (void __iomem *) (unsigned long) data->start;
} else {
addr_reg = ioremap(addr->start, 1);
if (addr_reg == NULL) {
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-13 0:31 ` [PATCH 15/16] 64bit Resource: convert a few remaining drivers to use resource_size_t where needed Greg KH
@ 2006-06-13 0:31 ` Greg KH
2006-06-14 12:20 ` Geert Uytterhoeven
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-13 0:31 UTC (permalink / raw)
To: linux-kernel; +Cc: Greg Kroah-Hartman
From: Greg Kroah-Hartman <gregkh@suse.de>
Introduce the Kconfig entry and actually switch to a 64bit value, if
wanted, for resource_size_t.
Based on a patch series originally from Vivek Goyal <vgoyal@in.ibm.com>
Cc: Vivek Goyal <vgoyal@in.ibm.com>
Cc: Andrew Morton <akpm@osdl.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
---
arch/arm/Kconfig | 7 +++++++
arch/arm26/Kconfig | 7 +++++++
arch/cris/Kconfig | 7 +++++++
arch/frv/Kconfig | 7 +++++++
arch/i386/Kconfig | 7 +++++++
arch/m32r/Kconfig | 7 +++++++
arch/m68k/Kconfig | 7 +++++++
arch/m68knommu/Kconfig | 7 +++++++
arch/mips/Kconfig | 8 ++++++++
arch/parisc/Kconfig | 8 ++++++++
arch/powerpc/Kconfig | 8 ++++++++
arch/ppc/Kconfig | 7 +++++++
arch/s390/Kconfig | 8 ++++++++
arch/sh/Kconfig | 7 +++++++
arch/sparc/Kconfig | 7 +++++++
arch/v850/Kconfig | 7 +++++++
arch/xtensa/Kconfig | 7 +++++++
include/linux/types.h | 7 ++++++-
kernel/resource.c | 11 ++++++++++-
19 files changed, 139 insertions(+), 2 deletions(-)
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 08b7cc9..9248a69 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -518,6 +518,13 @@ config NODES_SHIFT
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
config LEDS
bool "Timer and CPU usage LEDs"
depends on ARCH_CDB89712 || ARCH_CO285 || ARCH_EBSA110 || \
diff --git a/arch/arm26/Kconfig b/arch/arm26/Kconfig
index cf4ebf4..919f745 100644
--- a/arch/arm26/Kconfig
+++ b/arch/arm26/Kconfig
@@ -187,6 +187,13 @@ config CMDLINE
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
endmenu
source "net/Kconfig"
diff --git a/arch/cris/Kconfig b/arch/cris/Kconfig
index 856b665..91c0d3a 100644
--- a/arch/cris/Kconfig
+++ b/arch/cris/Kconfig
@@ -80,6 +80,13 @@ config PREEMPT
source mm/Kconfig
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
endmenu
menu "Hardware setup"
diff --git a/arch/frv/Kconfig b/arch/frv/Kconfig
index 95a3892..f929b05 100644
--- a/arch/frv/Kconfig
+++ b/arch/frv/Kconfig
@@ -80,6 +80,13 @@ config HIGHPTE
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
choice
prompt "uClinux kernel load address"
depends on !MMU
diff --git a/arch/i386/Kconfig b/arch/i386/Kconfig
index 8dfa305..34542cb 100644
--- a/arch/i386/Kconfig
+++ b/arch/i386/Kconfig
@@ -754,6 +754,13 @@ config PHYSICAL_START
Don't change this unless you know what you are doing.
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL && !X86_PAE
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
config HOTPLUG_CPU
bool "Support for hot-pluggable CPUs (EXPERIMENTAL)"
depends on SMP && HOTPLUG && EXPERIMENTAL && !X86_VOYAGER
diff --git a/arch/m32r/Kconfig b/arch/m32r/Kconfig
index 41fd490..24d6a1d 100644
--- a/arch/m32r/Kconfig
+++ b/arch/m32r/Kconfig
@@ -188,6 +188,13 @@ config ARCH_DISCONTIGMEM_ENABLE
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
config IRAM_START
hex "Internal memory start address (hex)"
default "00f00000" if !CHIP_M32104
diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
index 805b81f..22dcaa5 100644
--- a/arch/m68k/Kconfig
+++ b/arch/m68k/Kconfig
@@ -368,6 +368,13 @@ config 060_WRITETHROUGH
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
endmenu
menu "General setup"
diff --git a/arch/m68knommu/Kconfig b/arch/m68knommu/Kconfig
index 3cde682..e71fbe7 100644
--- a/arch/m68knommu/Kconfig
+++ b/arch/m68knommu/Kconfig
@@ -605,6 +605,13 @@ endchoice
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
endmenu
config ISA_DMA_API
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
index e8ff09f..cf5defc 100644
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
@@ -1653,6 +1653,14 @@ config NR_CPUS
source "kernel/Kconfig.preempt"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ depends on 32BIT
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
config RTC_DS1742
bool "DS1742 BRAM/RTC support"
depends on TOSHIBA_JMR3927 || TOSHIBA_RBTX4927
diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig
index 910fb3a..591b49b 100644
--- a/arch/parisc/Kconfig
+++ b/arch/parisc/Kconfig
@@ -217,6 +217,14 @@ source "kernel/Kconfig.preempt"
source "kernel/Kconfig.hz"
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ depends on !64BIT
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
config COMPAT
def_bool y
depends on 64BIT
diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
index 6729c98..9444dfa 100644
--- a/arch/powerpc/Kconfig
+++ b/arch/powerpc/Kconfig
@@ -626,6 +626,14 @@ config CRASH_DUMP
Don't change this unless you know what you are doing.
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ depends on PPC32
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
config EMBEDDEDBOOT
bool
depends on 8xx || 8260
diff --git a/arch/ppc/Kconfig b/arch/ppc/Kconfig
index e9a8f5d..c174d05 100644
--- a/arch/ppc/Kconfig
+++ b/arch/ppc/Kconfig
@@ -953,6 +953,13 @@ source kernel/Kconfig.hz
source kernel/Kconfig.preempt
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
source "fs/Kconfig.binfmt"
config PREP_RESIDUAL
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
index 01c5c08..785b2f6 100644
--- a/arch/s390/Kconfig
+++ b/arch/s390/Kconfig
@@ -218,6 +218,14 @@ config WARN_STACK_SIZE
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ depends on !64BIT
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
comment "I/O subsystem configuration"
config MACHCHK_WARNING
diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig
index 2bcecf4..dc1decb 100644
--- a/arch/sh/Kconfig
+++ b/arch/sh/Kconfig
@@ -532,6 +532,13 @@ config NODES_SHIFT
default "1"
depends on NEED_MULTIPLE_NODES
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
endmenu
menu "Boot options"
diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig
index 9431e96..cd3cca3 100644
--- a/arch/sparc/Kconfig
+++ b/arch/sparc/Kconfig
@@ -67,6 +67,13 @@ config SPARC32
maintains both the SPARC32 and SPARC64 ports; its web page is
available at <http://www.ultralinux.org/>.
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
# Global things across all Sun machines.
config ISA
bool
diff --git a/arch/v850/Kconfig b/arch/v850/Kconfig
index 37ec644..9aab649 100644
--- a/arch/v850/Kconfig
+++ b/arch/v850/Kconfig
@@ -235,6 +235,13 @@ menu "Processor type and features"
source "mm/Kconfig"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
endmenu
diff --git a/arch/xtensa/Kconfig b/arch/xtensa/Kconfig
index dbeb350..46ede7f 100644
--- a/arch/xtensa/Kconfig
+++ b/arch/xtensa/Kconfig
@@ -99,6 +99,13 @@ config MATH_EMULATION
config HIGHMEM
bool "High memory support"
+config RESOURCES_32BIT
+ bool "32 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on EXPERIMENTAL
+ help
+ By default resources are 64 bit. This option allows memory and IO
+ resources to be 32 bit to optimize code size.
+
endmenu
menu "Platform options"
diff --git a/include/linux/types.h b/include/linux/types.h
index 047eb8b..27835d5 100644
--- a/include/linux/types.h
+++ b/include/linux/types.h
@@ -179,9 +179,14 @@ #endif
#ifdef __KERNEL__
typedef unsigned __bitwise__ gfp_t;
-typedef unsigned long resource_size_t;
+#ifdef CONFIG_RESOURCES_32BIT
+typedef __u32 resource_size_t;
+#else
+typedef __u64 resource_size_t;
#endif
+#endif /* __KERNEL__ */
+
struct ustat {
__kernel_daddr_t f_tfree;
__kernel_ino_t f_tinode;
diff --git a/kernel/resource.c b/kernel/resource.c
index ad90a70..09b85c4 100644
--- a/kernel/resource.c
+++ b/kernel/resource.c
@@ -23,7 +23,11 @@ #include <asm/io.h>
struct resource ioport_resource = {
.name = "PCI IO",
- .start = 0x0000,
+#ifdef CONFIG_RESOURCES_32BIT
+ .start = 0x0000UL,
+#else
+ .start = 0x0000ULL,
+#endif
.end = IO_SPACE_LIMIT,
.flags = IORESOURCE_IO,
};
@@ -32,8 +36,13 @@ EXPORT_SYMBOL(ioport_resource);
struct resource iomem_resource = {
.name = "PCI mem",
+#ifdef CONFIG_RESOURCES_32BIT
.start = 0UL,
.end = ~0UL,
+#else
+ .start = 0ULL,
+ .end = ~0ULL,
+#endif
.flags = IORESOURCE_MEM,
};
--
1.4.0
^ permalink raw reply related [flat|nested] 34+ messages in thread
* Re: [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers
2006-06-13 0:31 ` [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers Greg KH
2006-06-13 0:31 ` [PATCH 04/16] 64bit resource: fix up printks for resources in pci core and hotplug drivers Greg KH
@ 2006-06-13 16:24 ` Jesse Brandeburg
2006-06-13 16:30 ` Greg KH
1 sibling, 1 reply; 34+ messages in thread
From: Jesse Brandeburg @ 2006-06-13 16:24 UTC (permalink / raw)
To: Greg KH; +Cc: linux-kernel, Greg Kroah-Hartman, NetDEV list
First, added netdev,
On 6/12/06, Greg KH <greg@kroah.com> wrote:
> From: Greg Kroah-Hartman <gregkh@suse.de>
>
> This is needed if we wish to change the size of the resource structures.
>
> Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
>
> Cc: Vivek Goyal <vgoyal@in.ibm.com>
> Cc: Andrew Morton <akpm@osdl.org>
> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
> ---
> drivers/net/3c59x.c | 6 ++++--
> drivers/net/8139cp.c | 9 +++++----
> drivers/net/8139too.c | 6 +++---
> drivers/net/e100.c | 4 ++--
> drivers/net/skge.c | 4 ++--
> drivers/net/sky2.c | 6 +++---
> drivers/net/tulip/de2104x.c | 9 +++++----
> drivers/net/tulip/tulip_core.c | 6 +++---
> drivers/net/typhoon.c | 5 +++--
> drivers/net/wan/dscc4.c | 12 ++++++------
> drivers/net/wan/pc300_drv.c | 4 ++--
> 11 files changed, 38 insertions(+), 33 deletions(-)
>
> diff --git a/drivers/net/e100.c b/drivers/net/e100.c
> index 31ac001..0c0bd67 100644
> --- a/drivers/net/e100.c
> +++ b/drivers/net/e100.c
> @@ -2678,9 +2678,9 @@ #endif
> goto err_out_free;
> }
>
> - DPRINTK(PROBE, INFO, "addr 0x%lx, irq %d, "
> + DPRINTK(PROBE, INFO, "addr 0x%llx, irq %d, "
> "MAC addr %02X:%02X:%02X:%02X:%02X:%02X\n",
> - pci_resource_start(pdev, 0), pdev->irq,
> + (unsigned long long)pci_resource_start(pdev, 0), pdev->irq,
> netdev->dev_addr[0], netdev->dev_addr[1], netdev->dev_addr[2],
> netdev->dev_addr[3], netdev->dev_addr[4], netdev->dev_addr[5]);
color me confused, but why is this change necessary for e100? e100
can not support 64 bit BARs, so it seems to me to make little sense to
cast to unsigned long long. e100 is 32 bit the whole way through.
Jesse
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers
2006-06-13 16:24 ` [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers Jesse Brandeburg
@ 2006-06-13 16:30 ` Greg KH
0 siblings, 0 replies; 34+ messages in thread
From: Greg KH @ 2006-06-13 16:30 UTC (permalink / raw)
To: Jesse Brandeburg; +Cc: Greg KH, linux-kernel, NetDEV list
On Tue, Jun 13, 2006 at 09:24:55AM -0700, Jesse Brandeburg wrote:
> First, added netdev,
>
> On 6/12/06, Greg KH <greg@kroah.com> wrote:
> >From: Greg Kroah-Hartman <gregkh@suse.de>
> >
> >This is needed if we wish to change the size of the resource structures.
> >
> >Based on an original patch from Vivek Goyal <vgoyal@in.ibm.com>
> >
> >Cc: Vivek Goyal <vgoyal@in.ibm.com>
> >Cc: Andrew Morton <akpm@osdl.org>
> >Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
> >---
> > drivers/net/3c59x.c | 6 ++++--
> > drivers/net/8139cp.c | 9 +++++----
> > drivers/net/8139too.c | 6 +++---
> > drivers/net/e100.c | 4 ++--
> > drivers/net/skge.c | 4 ++--
> > drivers/net/sky2.c | 6 +++---
> > drivers/net/tulip/de2104x.c | 9 +++++----
> > drivers/net/tulip/tulip_core.c | 6 +++---
> > drivers/net/typhoon.c | 5 +++--
> > drivers/net/wan/dscc4.c | 12 ++++++------
> > drivers/net/wan/pc300_drv.c | 4 ++--
> > 11 files changed, 38 insertions(+), 33 deletions(-)
> >
> >diff --git a/drivers/net/e100.c b/drivers/net/e100.c
> >index 31ac001..0c0bd67 100644
> >--- a/drivers/net/e100.c
> >+++ b/drivers/net/e100.c
> >@@ -2678,9 +2678,9 @@ #endif
> > goto err_out_free;
> > }
> >
> >- DPRINTK(PROBE, INFO, "addr 0x%lx, irq %d, "
> >+ DPRINTK(PROBE, INFO, "addr 0x%llx, irq %d, "
> > "MAC addr %02X:%02X:%02X:%02X:%02X:%02X\n",
> >- pci_resource_start(pdev, 0), pdev->irq,
> >+ (unsigned long long)pci_resource_start(pdev, 0), pdev->irq,
> > netdev->dev_addr[0], netdev->dev_addr[1],
> > netdev->dev_addr[2],
> > netdev->dev_addr[3], netdev->dev_addr[4],
> > netdev->dev_addr[5]);
>
> color me confused, but why is this change necessary for e100? e100
> can not support 64 bit BARs, so it seems to me to make little sense to
> cast to unsigned long long. e100 is 32 bit the whole way through.
Because the result of pci_resource_start() just became either u32 or u64
depending on a config option, and so, to keep everything sane, we just
always cast it to unsigned long long, which makes everyone happy.
Hope this helps,
greg k-h
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-13 0:31 ` [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes Greg KH
@ 2006-06-14 12:20 ` Geert Uytterhoeven
2006-06-14 23:35 ` Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Geert Uytterhoeven @ 2006-06-14 12:20 UTC (permalink / raw)
To: Greg KH; +Cc: Linux Kernel Development, Greg Kroah-Hartman
On Mon, 12 Jun 2006, Greg KH wrote:
> From: Greg Kroah-Hartman <gregkh@suse.de>
>
> Introduce the Kconfig entry and actually switch to a 64bit value, if
> wanted, for resource_size_t.
> diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
> index 805b81f..22dcaa5 100644
> --- a/arch/m68k/Kconfig
> +++ b/arch/m68k/Kconfig
> @@ -368,6 +368,13 @@ config 060_WRITETHROUGH
>
> source "mm/Kconfig"
>
> +config RESOURCES_32BIT
> + bool "32 bit Memory and IO resources (EXPERIMENTAL)"
> + depends on EXPERIMENTAL
> + help
> + By default resources are 64 bit. This option allows memory and IO
> + resources to be 32 bit to optimize code size.
> +
> endmenu
Why is the default 64 bit? Because 32 bit became experimental?
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-14 12:20 ` Geert Uytterhoeven
@ 2006-06-14 23:35 ` Greg KH
2006-06-15 4:28 ` Vivek Goyal
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-14 23:35 UTC (permalink / raw)
To: Geert Uytterhoeven, vgoyal; +Cc: Linux Kernel Development, Greg Kroah-Hartman
On Wed, Jun 14, 2006 at 02:20:06PM +0200, Geert Uytterhoeven wrote:
> On Mon, 12 Jun 2006, Greg KH wrote:
> > From: Greg Kroah-Hartman <gregkh@suse.de>
> >
> > Introduce the Kconfig entry and actually switch to a 64bit value, if
> > wanted, for resource_size_t.
>
> > diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
> > index 805b81f..22dcaa5 100644
> > --- a/arch/m68k/Kconfig
> > +++ b/arch/m68k/Kconfig
> > @@ -368,6 +368,13 @@ config 060_WRITETHROUGH
> >
> > source "mm/Kconfig"
> >
> > +config RESOURCES_32BIT
> > + bool "32 bit Memory and IO resources (EXPERIMENTAL)"
> > + depends on EXPERIMENTAL
> > + help
> > + By default resources are 64 bit. This option allows memory and IO
> > + resources to be 32 bit to optimize code size.
> > +
> > endmenu
>
> Why is the default 64 bit? Because 32 bit became experimental?
That's a really good question. Vivek, why did you change it to be this
way? In thinking about it some more, this should be a 64bit option
instead.
thanks,
greg k-h
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-14 23:35 ` Greg KH
@ 2006-06-15 4:28 ` Vivek Goyal
2006-06-15 11:47 ` Geert Uytterhoeven
0 siblings, 1 reply; 34+ messages in thread
From: Vivek Goyal @ 2006-06-15 4:28 UTC (permalink / raw)
To: Greg KH; +Cc: Geert Uytterhoeven, Linux Kernel Development, Greg Kroah-Hartman
On Wed, Jun 14, 2006 at 04:35:07PM -0700, Greg KH wrote:
> On Wed, Jun 14, 2006 at 02:20:06PM +0200, Geert Uytterhoeven wrote:
> > On Mon, 12 Jun 2006, Greg KH wrote:
> > > From: Greg Kroah-Hartman <gregkh@suse.de>
> > >
> > > Introduce the Kconfig entry and actually switch to a 64bit value, if
> > > wanted, for resource_size_t.
> >
> > > diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
> > > index 805b81f..22dcaa5 100644
> > > --- a/arch/m68k/Kconfig
> > > +++ b/arch/m68k/Kconfig
> > > @@ -368,6 +368,13 @@ config 060_WRITETHROUGH
> > >
> > > source "mm/Kconfig"
> > >
> > > +config RESOURCES_32BIT
> > > + bool "32 bit Memory and IO resources (EXPERIMENTAL)"
> > > + depends on EXPERIMENTAL
> > > + help
> > > + By default resources are 64 bit. This option allows memory and IO
> > > + resources to be 32 bit to optimize code size.
> > > +
> > > endmenu
> >
> > Why is the default 64 bit? Because 32 bit became experimental?
>
> That's a really good question. Vivek, why did you change it to be this
> way? In thinking about it some more, this should be a 64bit option
> instead.
>
I thought 64bit is more inclusive. Works both for 32bit and 64bit BARs.
Also exports memory more than 4G through /proc/iomem without selecting
an additional option in config file. The flip side is that it introduces
little memory overhead. I thought most of the users should be ok with this
increased memory usage and those who are particular, they can choose
RESOURCES_32BIT.
Thanks
Vivek
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-15 4:28 ` Vivek Goyal
@ 2006-06-15 11:47 ` Geert Uytterhoeven
2006-06-15 15:56 ` Vivek Goyal
0 siblings, 1 reply; 34+ messages in thread
From: Geert Uytterhoeven @ 2006-06-15 11:47 UTC (permalink / raw)
To: Vivek Goyal; +Cc: Greg KH, Linux Kernel Development, Greg Kroah-Hartman
On Thu, 15 Jun 2006, Vivek Goyal wrote:
> On Wed, Jun 14, 2006 at 04:35:07PM -0700, Greg KH wrote:
> > On Wed, Jun 14, 2006 at 02:20:06PM +0200, Geert Uytterhoeven wrote:
> > > On Mon, 12 Jun 2006, Greg KH wrote:
> > > > From: Greg Kroah-Hartman <gregkh@suse.de>
> > > >
> > > > Introduce the Kconfig entry and actually switch to a 64bit value, if
> > > > wanted, for resource_size_t.
> > >
> > > > diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
> > > > index 805b81f..22dcaa5 100644
> > > > --- a/arch/m68k/Kconfig
> > > > +++ b/arch/m68k/Kconfig
> > > > @@ -368,6 +368,13 @@ config 060_WRITETHROUGH
> > > >
> > > > source "mm/Kconfig"
> > > >
> > > > +config RESOURCES_32BIT
> > > > + bool "32 bit Memory and IO resources (EXPERIMENTAL)"
> > > > + depends on EXPERIMENTAL
> > > > + help
> > > > + By default resources are 64 bit. This option allows memory and IO
> > > > + resources to be 32 bit to optimize code size.
> > > > +
> > > > endmenu
> > >
> > > Why is the default 64 bit? Because 32 bit became experimental?
> >
> > That's a really good question. Vivek, why did you change it to be this
> > way? In thinking about it some more, this should be a 64bit option
> > instead.
> >
>
> I thought 64bit is more inclusive. Works both for 32bit and 64bit BARs.
>From a PCI viewpoint? Not all machines have PCI.
> Also exports memory more than 4G through /proc/iomem without selecting
> an additional option in config file. The flip side is that it introduces
> little memory overhead. I thought most of the users should be ok with this
> increased memory usage and those who are particular, they can choose
> RESOURCES_32BIT.
Not all 32 bit platforms support more than 4 GiB of memory, so it's of no use
to waste memory on 64 bit resources.
I'd prefer to have an option to explicitly enable 64 bit resources (and make 32
bit resources non-experimental ;-).
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-15 11:47 ` Geert Uytterhoeven
@ 2006-06-15 15:56 ` Vivek Goyal
2006-06-16 1:35 ` Greg KH
0 siblings, 1 reply; 34+ messages in thread
From: Vivek Goyal @ 2006-06-15 15:56 UTC (permalink / raw)
To: Geert Uytterhoeven; +Cc: Greg KH, Linux Kernel Development, Greg Kroah-Hartman
On Thu, Jun 15, 2006 at 01:47:43PM +0200, Geert Uytterhoeven wrote:
> On Thu, 15 Jun 2006, Vivek Goyal wrote:
> > On Wed, Jun 14, 2006 at 04:35:07PM -0700, Greg KH wrote:
> > > On Wed, Jun 14, 2006 at 02:20:06PM +0200, Geert Uytterhoeven wrote:
> > > > On Mon, 12 Jun 2006, Greg KH wrote:
> > > > > From: Greg Kroah-Hartman <gregkh@suse.de>
> > > > >
> > > > > Introduce the Kconfig entry and actually switch to a 64bit value, if
> > > > > wanted, for resource_size_t.
> > > >
> > > > > diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
> > > > > index 805b81f..22dcaa5 100644
> > > > > --- a/arch/m68k/Kconfig
> > > > > +++ b/arch/m68k/Kconfig
> > > > > @@ -368,6 +368,13 @@ config 060_WRITETHROUGH
> > > > >
> > > > > source "mm/Kconfig"
> > > > >
> > > > > +config RESOURCES_32BIT
> > > > > + bool "32 bit Memory and IO resources (EXPERIMENTAL)"
> > > > > + depends on EXPERIMENTAL
> > > > > + help
> > > > > + By default resources are 64 bit. This option allows memory and IO
> > > > > + resources to be 32 bit to optimize code size.
> > > > > +
> > > > > endmenu
> > > >
> > > > Why is the default 64 bit? Because 32 bit became experimental?
> > >
> > > That's a really good question. Vivek, why did you change it to be this
> > > way? In thinking about it some more, this should be a 64bit option
> > > instead.
> > >
> >
> > I thought 64bit is more inclusive. Works both for 32bit and 64bit BARs.
>
> >From a PCI viewpoint? Not all machines have PCI.
>
> > Also exports memory more than 4G through /proc/iomem without selecting
> > an additional option in config file. The flip side is that it introduces
> > little memory overhead. I thought most of the users should be ok with this
> > increased memory usage and those who are particular, they can choose
> > RESOURCES_32BIT.
>
> Not all 32 bit platforms support more than 4 GiB of memory, so it's of no use
> to waste memory on 64 bit resources.
>
Hmm.. That makes sense. I will rework the patch.
Thanks
Vivek
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-15 15:56 ` Vivek Goyal
@ 2006-06-16 1:35 ` Greg KH
2006-06-16 20:16 ` Vivek Goyal
0 siblings, 1 reply; 34+ messages in thread
From: Greg KH @ 2006-06-16 1:35 UTC (permalink / raw)
To: Vivek Goyal
Cc: Geert Uytterhoeven, Linux Kernel Development, Greg Kroah-Hartman
On Thu, Jun 15, 2006 at 11:56:43AM -0400, Vivek Goyal wrote:
> On Thu, Jun 15, 2006 at 01:47:43PM +0200, Geert Uytterhoeven wrote:
> > On Thu, 15 Jun 2006, Vivek Goyal wrote:
> > > On Wed, Jun 14, 2006 at 04:35:07PM -0700, Greg KH wrote:
> > > > On Wed, Jun 14, 2006 at 02:20:06PM +0200, Geert Uytterhoeven wrote:
> > > > > On Mon, 12 Jun 2006, Greg KH wrote:
> > > > > > From: Greg Kroah-Hartman <gregkh@suse.de>
> > > > > >
> > > > > > Introduce the Kconfig entry and actually switch to a 64bit value, if
> > > > > > wanted, for resource_size_t.
> > > > >
> > > > > > diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
> > > > > > index 805b81f..22dcaa5 100644
> > > > > > --- a/arch/m68k/Kconfig
> > > > > > +++ b/arch/m68k/Kconfig
> > > > > > @@ -368,6 +368,13 @@ config 060_WRITETHROUGH
> > > > > >
> > > > > > source "mm/Kconfig"
> > > > > >
> > > > > > +config RESOURCES_32BIT
> > > > > > + bool "32 bit Memory and IO resources (EXPERIMENTAL)"
> > > > > > + depends on EXPERIMENTAL
> > > > > > + help
> > > > > > + By default resources are 64 bit. This option allows memory and IO
> > > > > > + resources to be 32 bit to optimize code size.
> > > > > > +
> > > > > > endmenu
> > > > >
> > > > > Why is the default 64 bit? Because 32 bit became experimental?
> > > >
> > > > That's a really good question. Vivek, why did you change it to be this
> > > > way? In thinking about it some more, this should be a 64bit option
> > > > instead.
> > > >
> > >
> > > I thought 64bit is more inclusive. Works both for 32bit and 64bit BARs.
> >
> > >From a PCI viewpoint? Not all machines have PCI.
> >
> > > Also exports memory more than 4G through /proc/iomem without selecting
> > > an additional option in config file. The flip side is that it introduces
> > > little memory overhead. I thought most of the users should be ok with this
> > > increased memory usage and those who are particular, they can choose
> > > RESOURCES_32BIT.
> >
> > Not all 32 bit platforms support more than 4 GiB of memory, so it's of no use
> > to waste memory on 64 bit resources.
> >
>
> Hmm.. That makes sense. I will rework the patch.
Thanks, just rework the last one.
And it looks like you can add just one entry to mm/Kconfig instead of
touching every arch's Kconfig file.
thanks,
greg k-h
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-16 1:35 ` Greg KH
@ 2006-06-16 20:16 ` Vivek Goyal
2006-06-17 14:34 ` Geert Uytterhoeven
0 siblings, 1 reply; 34+ messages in thread
From: Vivek Goyal @ 2006-06-16 20:16 UTC (permalink / raw)
To: Greg KH; +Cc: Geert Uytterhoeven, Linux Kernel Development, Greg Kroah-Hartman
On Thu, Jun 15, 2006 at 06:35:43PM -0700, Greg KH wrote:
> On Thu, Jun 15, 2006 at 11:56:43AM -0400, Vivek Goyal wrote:
> > On Thu, Jun 15, 2006 at 01:47:43PM +0200, Geert Uytterhoeven wrote:
> > > On Thu, 15 Jun 2006, Vivek Goyal wrote:
> > > > On Wed, Jun 14, 2006 at 04:35:07PM -0700, Greg KH wrote:
> > > > > On Wed, Jun 14, 2006 at 02:20:06PM +0200, Geert Uytterhoeven wrote:
> > > > > > On Mon, 12 Jun 2006, Greg KH wrote:
> > > > > > > From: Greg Kroah-Hartman <gregkh@suse.de>
> > > > > > >
> > > > > > > Introduce the Kconfig entry and actually switch to a 64bit value, if
> > > > > > > wanted, for resource_size_t.
> > > > > >
> > > > > > > diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
> > > > > > > index 805b81f..22dcaa5 100644
> > > > > > > --- a/arch/m68k/Kconfig
> > > > > > > +++ b/arch/m68k/Kconfig
> > > > > > > @@ -368,6 +368,13 @@ config 060_WRITETHROUGH
> > > > > > >
> > > > > > > source "mm/Kconfig"
> > > > > > >
> > > > > > > +config RESOURCES_32BIT
> > > > > > > + bool "32 bit Memory and IO resources (EXPERIMENTAL)"
> > > > > > > + depends on EXPERIMENTAL
> > > > > > > + help
> > > > > > > + By default resources are 64 bit. This option allows memory and IO
> > > > > > > + resources to be 32 bit to optimize code size.
> > > > > > > +
> > > > > > > endmenu
> > > > > >
> > > > > > Why is the default 64 bit? Because 32 bit became experimental?
> > > > >
> > > > > That's a really good question. Vivek, why did you change it to be this
> > > > > way? In thinking about it some more, this should be a 64bit option
> > > > > instead.
> > > > >
> > > >
> > > > I thought 64bit is more inclusive. Works both for 32bit and 64bit BARs.
> > >
> > > >From a PCI viewpoint? Not all machines have PCI.
> > >
> > > > Also exports memory more than 4G through /proc/iomem without selecting
> > > > an additional option in config file. The flip side is that it introduces
> > > > little memory overhead. I thought most of the users should be ok with this
> > > > increased memory usage and those who are particular, they can choose
> > > > RESOURCES_32BIT.
> > >
> > > Not all 32 bit platforms support more than 4 GiB of memory, so it's of no use
> > > to waste memory on 64 bit resources.
> > >
> >
> > Hmm.. That makes sense. I will rework the patch.
>
> Thanks, just rework the last one.
>
> And it looks like you can add just one entry to mm/Kconfig instead of
> touching every arch's Kconfig file.
Greg, Please find attached the reworked-patch. I have gotten rid of
CONFIG_RESOURCES_32BIT and instead introduced CONFIG_RESOURCES_64BIT in
arch intenepndent file mm/Kconfig.
This patch assumes that 64bit kernels will define CONFIG_64BIT. All the
architectures seems to be adhering to this but can't find CONFIG_64BIT for
sh64. Don't know much about this arch.
o Introuces CONFIG_RESOURCES_64BIT Kconfig option.
o This option is available only for 32bit platforms/kernels (!CONFIG_64BIT),
as for 64bit kernels, resources have to be 64 bits and they already
are.
Signed-off-by: Vivek Goyal <vgoyal@in.ibm.com>
---
linux-2.6.17-rc6-1M-vivek/arch/i386/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/include/linux/types.h | 7 ++++++-
linux-2.6.17-rc6-1M-vivek/mm/Kconfig | 7 +++++++
3 files changed, 14 insertions(+), 1 deletion(-)
diff -puN mm/Kconfig~64bit-resources-modify-kconfig-options mm/Kconfig
--- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-16 14:40:15.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-16 14:51:31.000000000 -0400
@@ -145,3 +145,10 @@ config MIGRATION
while the virtual addresses are not changed. This is useful for
example on NUMA systems to put pages nearer to the processors accessing
the page.
+
+config RESOURCES_64BIT
+ bool "64 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on (EXPERIMENTAL && !64BIT)
+ default n
+ help
+ This option allows memory and IO resources to be 64 bit.
diff -puN include/linux/types.h~64bit-resources-modify-kconfig-options include/linux/types.h
--- linux-2.6.17-rc6-1M/include/linux/types.h~64bit-resources-modify-kconfig-options 2006-06-16 14:40:15.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/include/linux/types.h 2006-06-16 14:49:28.000000000 -0400
@@ -179,7 +179,12 @@ typedef __u64 __bitwise __be64;
#ifdef __KERNEL__
typedef unsigned __bitwise__ gfp_t;
-typedef unsigned long resource_size_t;
+#if defined(CONFIG_RESOURCES_64BIT) || defined(CONFIG_64BIT)
+typedef u64 resource_size_t;
+#else
+typedef u32 resource_size_t;
+#endif
+
#endif
struct ustat {
diff -puN arch/i386/Kconfig~64bit-resources-modify-kconfig-options arch/i386/Kconfig
--- linux-2.6.17-rc6-1M/arch/i386/Kconfig~64bit-resources-modify-kconfig-options 2006-06-16 14:40:15.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/i386/Kconfig 2006-06-16 14:40:15.000000000 -0400
@@ -511,6 +511,7 @@ config X86_PAE
bool
depends on HIGHMEM64G
default y
+ select RESOURCES_64BIT
# Common NUMA Features
config NUMA
_
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-16 20:16 ` Vivek Goyal
@ 2006-06-17 14:34 ` Geert Uytterhoeven
2006-06-18 18:05 ` Vivek Goyal
0 siblings, 1 reply; 34+ messages in thread
From: Geert Uytterhoeven @ 2006-06-17 14:34 UTC (permalink / raw)
To: Vivek Goyal; +Cc: Greg KH, Linux Kernel Development, Greg Kroah-Hartman
On Fri, 16 Jun 2006, Vivek Goyal wrote:
> On Thu, Jun 15, 2006 at 06:35:43PM -0700, Greg KH wrote:
> > On Thu, Jun 15, 2006 at 11:56:43AM -0400, Vivek Goyal wrote:
> > > On Thu, Jun 15, 2006 at 01:47:43PM +0200, Geert Uytterhoeven wrote:
> > > > On Thu, 15 Jun 2006, Vivek Goyal wrote:
> > > > > On Wed, Jun 14, 2006 at 04:35:07PM -0700, Greg KH wrote:
> > > > > > On Wed, Jun 14, 2006 at 02:20:06PM +0200, Geert Uytterhoeven wrote:
> > > > > > > On Mon, 12 Jun 2006, Greg KH wrote:
> > > > > > > > From: Greg Kroah-Hartman <gregkh@suse.de>
> > > > > > > >
> > > > > > > > Introduce the Kconfig entry and actually switch to a 64bit value, if
> > > > > > > > wanted, for resource_size_t.
> > > > > > >
> > > > > > > > diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
> > > > > > > > index 805b81f..22dcaa5 100644
> > > > > > > > --- a/arch/m68k/Kconfig
> > > > > > > > +++ b/arch/m68k/Kconfig
> > > > > > > > @@ -368,6 +368,13 @@ config 060_WRITETHROUGH
> > > > > > > >
> > > > > > > > source "mm/Kconfig"
> > > > > > > >
> > > > > > > > +config RESOURCES_32BIT
> > > > > > > > + bool "32 bit Memory and IO resources (EXPERIMENTAL)"
> > > > > > > > + depends on EXPERIMENTAL
> > > > > > > > + help
> > > > > > > > + By default resources are 64 bit. This option allows memory and IO
> > > > > > > > + resources to be 32 bit to optimize code size.
> > > > > > > > +
> > > > > > > > endmenu
> > > > > > >
> > > > > > > Why is the default 64 bit? Because 32 bit became experimental?
> > > > > >
> > > > > > That's a really good question. Vivek, why did you change it to be this
> > > > > > way? In thinking about it some more, this should be a 64bit option
> > > > > > instead.
> > > > > >
> > > > >
> > > > > I thought 64bit is more inclusive. Works both for 32bit and 64bit BARs.
> > > >
> > > > >From a PCI viewpoint? Not all machines have PCI.
> > > >
> > > > > Also exports memory more than 4G through /proc/iomem without selecting
> > > > > an additional option in config file. The flip side is that it introduces
> > > > > little memory overhead. I thought most of the users should be ok with this
> > > > > increased memory usage and those who are particular, they can choose
> > > > > RESOURCES_32BIT.
> > > >
> > > > Not all 32 bit platforms support more than 4 GiB of memory, so it's of no use
> > > > to waste memory on 64 bit resources.
> > > >
> > >
> > > Hmm.. That makes sense. I will rework the patch.
> >
> > Thanks, just rework the last one.
> >
> > And it looks like you can add just one entry to mm/Kconfig instead of
> > touching every arch's Kconfig file.
>
> Greg, Please find attached the reworked-patch. I have gotten rid of
> CONFIG_RESOURCES_32BIT and instead introduced CONFIG_RESOURCES_64BIT in
> arch intenepndent file mm/Kconfig.
Thanks!
> o Introuces CONFIG_RESOURCES_64BIT Kconfig option.
>
> o This option is available only for 32bit platforms/kernels (!CONFIG_64BIT),
> as for 64bit kernels, resources have to be 64 bits and they already
> are.
> diff -puN mm/Kconfig~64bit-resources-modify-kconfig-options mm/Kconfig
> --- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-16 14:40:15.000000000 -0400
> +++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-16 14:51:31.000000000 -0400
> @@ -145,3 +145,10 @@ config MIGRATION
> while the virtual addresses are not changed. This is useful for
> example on NUMA systems to put pages nearer to the processors accessing
> the page.
> +
> +config RESOURCES_64BIT
> + bool "64 bit Memory and IO resources (EXPERIMENTAL)"
> + depends on (EXPERIMENTAL && !64BIT)
> + default n
> + help
> + This option allows memory and IO resources to be 64 bit.
> diff -puN include/linux/types.h~64bit-resources-modify-kconfig-options include/linux/types.h
> --- linux-2.6.17-rc6-1M/include/linux/types.h~64bit-resources-modify-kconfig-options 2006-06-16 14:40:15.000000000 -0400
> +++ linux-2.6.17-rc6-1M-vivek/include/linux/types.h 2006-06-16 14:49:28.000000000 -0400
> @@ -179,7 +179,12 @@ typedef __u64 __bitwise __be64;
> #ifdef __KERNEL__
> typedef unsigned __bitwise__ gfp_t;
>
> -typedef unsigned long resource_size_t;
> +#if defined(CONFIG_RESOURCES_64BIT) || defined(CONFIG_64BIT)
If you'd set CONFIG_RESOURCES_64BIT in Kconfig if CONFIG_64BIT, you don't need
the `|| defined(CONFIG_64BIT)'.
IMHO it looks a bit confusing that resources are 64 bit on 64 bit platforms,
while CONFIG_RESOURCES_64BIT is not set.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-17 14:34 ` Geert Uytterhoeven
@ 2006-06-18 18:05 ` Vivek Goyal
2006-06-19 8:05 ` Geert Uytterhoeven
0 siblings, 1 reply; 34+ messages in thread
From: Vivek Goyal @ 2006-06-18 18:05 UTC (permalink / raw)
To: Geert Uytterhoeven; +Cc: Greg KH, Linux Kernel Development, Greg Kroah-Hartman
On Sat, Jun 17, 2006 at 04:34:41PM +0200, Geert Uytterhoeven wrote:
> > diff -puN mm/Kconfig~64bit-resources-modify-kconfig-options mm/Kconfig
> > --- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-16 14:40:15.000000000 -0400
> > +++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-16 14:51:31.000000000 -0400
> > @@ -145,3 +145,10 @@ config MIGRATION
> > while the virtual addresses are not changed. This is useful for
> > example on NUMA systems to put pages nearer to the processors accessing
> > the page.
> > +
> > +config RESOURCES_64BIT
> > + bool "64 bit Memory and IO resources (EXPERIMENTAL)"
> > + depends on (EXPERIMENTAL && !64BIT)
> > + default n
> > + help
> > + This option allows memory and IO resources to be 64 bit.
> > diff -puN include/linux/types.h~64bit-resources-modify-kconfig-options include/linux/types.h
> > --- linux-2.6.17-rc6-1M/include/linux/types.h~64bit-resources-modify-kconfig-options 2006-06-16 14:40:15.000000000 -0400
> > +++ linux-2.6.17-rc6-1M-vivek/include/linux/types.h 2006-06-16 14:49:28.000000000 -0400
> > @@ -179,7 +179,12 @@ typedef __u64 __bitwise __be64;
> > #ifdef __KERNEL__
> > typedef unsigned __bitwise__ gfp_t;
> >
> > -typedef unsigned long resource_size_t;
> > +#if defined(CONFIG_RESOURCES_64BIT) || defined(CONFIG_64BIT)
>
> If you'd set CONFIG_RESOURCES_64BIT in Kconfig if CONFIG_64BIT, you don't need
> the `|| defined(CONFIG_64BIT)'.
>
> IMHO it looks a bit confusing that resources are 64 bit on 64 bit platforms,
> while CONFIG_RESOURCES_64BIT is not set.
>
Ok. Here is another take. I have used "select" in arch dependent files to
select CONFIG_RESOURCES_64BIT forcibly if 64BIT is set. Please suggest if
there is an arch independent way to do that.
There is a small issue though. On 64bit kernels RESOURCES_64BIT should not
be exprimental as rosources are already 64bit. "select" will make sure
that RESOURCES_64BIT is set but following line will be visible to user on
64bit platforms and user might be confused about "EXPERIMENTAL" keyword.
"64 bit Memory and IO resources (EXPERIMENTAL)"
At the same time this key word is required on 32bit platforms so that user
knows that this is something new and experimental.
Please suggest if there is a way to handle this situation. Ideally I would
like to set RESOURCES_64BIT on 64bit platforms without prompting anything
to user.
o Introuces CONFIG_RESOURCES_64BIT Kconfig option.
Signed-off-by: Vivek Goyal <vgoyal@in.ibm.com>
---
linux-2.6.17-rc6-1M-vivek/arch/alpha/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/arch/i386/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/arch/ia64/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/arch/mips/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/arch/parisc/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/arch/powerpc/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/arch/s390/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/arch/sparc64/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/arch/x86_64/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/include/linux/types.h | 7 ++++++-
linux-2.6.17-rc6-1M-vivek/mm/Kconfig | 9 +++++++++
11 files changed, 24 insertions(+), 1 deletion(-)
diff -puN include/linux/types.h~64bit-resources-modify-kconfig-options include/linux/types.h
--- linux-2.6.17-rc6-1M/include/linux/types.h~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/include/linux/types.h 2006-06-18 13:35:13.000000000 -0400
@@ -179,7 +179,12 @@ typedef __u64 __bitwise __be64;
#ifdef __KERNEL__
typedef unsigned __bitwise__ gfp_t;
-typedef unsigned long resource_size_t;
+#ifdef CONFIG_RESOURCES_64BIT
+typedef u64 resource_size_t;
+#else
+typedef u32 resource_size_t;
+#endif
+
#endif
struct ustat {
diff -puN mm/Kconfig~64bit-resources-modify-kconfig-options mm/Kconfig
--- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -145,3 +145,12 @@ config MIGRATION
while the virtual addresses are not changed. This is useful for
example on NUMA systems to put pages nearer to the processors accessing
the page.
+
+config RESOURCES_64BIT
+ bool "64 bit Memory and IO resources (EXPERIMENTAL)"
+ depends on (EXPERIMENTAL && !64BIT) || 64BIT
+ default y if 64BIT
+ help
+ This option allows memory and IO resources to be 64 bit.
+
+
diff -puN arch/alpha/Kconfig~64bit-resources-modify-kconfig-options arch/alpha/Kconfig
--- linux-2.6.17-rc6-1M/arch/alpha/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/alpha/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -13,6 +13,7 @@ config ALPHA
config 64BIT
def_bool y
+ select RESOURCES_64BIT
config MMU
bool
diff -puN arch/i386/Kconfig~64bit-resources-modify-kconfig-options arch/i386/Kconfig
--- linux-2.6.17-rc6-1M/arch/i386/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/i386/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -511,6 +511,7 @@ config X86_PAE
bool
depends on HIGHMEM64G
default y
+ select RESOURCES_64BIT
# Common NUMA Features
config NUMA
diff -puN arch/ia64/Kconfig~64bit-resources-modify-kconfig-options arch/ia64/Kconfig
--- linux-2.6.17-rc6-1M/arch/ia64/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/ia64/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -21,6 +21,7 @@ config IA64
config 64BIT
bool
default y
+ select RESOURCES_64BIT
config MMU
bool
diff -puN arch/mips/Kconfig~64bit-resources-modify-kconfig-options arch/mips/Kconfig
--- linux-2.6.17-rc6-1M/arch/mips/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/mips/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -1382,6 +1382,7 @@ config 32BIT
config 64BIT
bool "64-bit kernel"
depends on CPU_SUPPORTS_64BIT_KERNEL && SYS_SUPPORTS_64BIT_KERNEL
+ select RESOURCES_64BIT
help
Select this option if you want to build a 64-bit kernel.
diff -puN arch/parisc/Kconfig~64bit-resources-modify-kconfig-options arch/parisc/Kconfig
--- linux-2.6.17-rc6-1M/arch/parisc/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/parisc/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -128,6 +128,7 @@ config PREFETCH
config 64BIT
bool "64-bit kernel"
depends on PA8X00
+ select RESOURCES_64BIT
help
Enable this if you want to support 64bit kernel on PA-RISC platform.
diff -puN arch/powerpc/Kconfig~64bit-resources-modify-kconfig-options arch/powerpc/Kconfig
--- linux-2.6.17-rc6-1M/arch/powerpc/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/powerpc/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -18,6 +18,7 @@ config PPC32
config 64BIT
bool
default y if PPC64
+ select RESOURCES_64BIT
config PPC_MERGE
def_bool y
diff -puN arch/s390/Kconfig~64bit-resources-modify-kconfig-options arch/s390/Kconfig
--- linux-2.6.17-rc6-1M/arch/s390/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/s390/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -39,6 +39,7 @@ comment "Processor type and features"
config 64BIT
bool "64 bit kernel"
+ select RESOURCES_64BIT
help
Select this option if you have a 64 bit IBM zSeries machine
and want to use the 64 bit addressing mode.
diff -puN arch/sparc64/Kconfig~64bit-resources-modify-kconfig-options arch/sparc64/Kconfig
--- linux-2.6.17-rc6-1M/arch/sparc64/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/sparc64/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -21,6 +21,7 @@ config SPARC64
config 64BIT
def_bool y
+ select RESOURCES_64BIT
config MMU
bool
diff -puN arch/x86_64/Kconfig~64bit-resources-modify-kconfig-options arch/x86_64/Kconfig
--- linux-2.6.17-rc6-1M/arch/x86_64/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/x86_64/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -19,6 +19,7 @@ config X86_64
config 64BIT
def_bool y
+ select RESOURCES_64BIT
config X86
bool
_
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-18 18:05 ` Vivek Goyal
@ 2006-06-19 8:05 ` Geert Uytterhoeven
2006-06-19 10:17 ` Roman Zippel
0 siblings, 1 reply; 34+ messages in thread
From: Geert Uytterhoeven @ 2006-06-19 8:05 UTC (permalink / raw)
To: Vivek Goyal, Roman Zippel
Cc: Greg KH, Linux Kernel Development, Greg Kroah-Hartman
On Sun, 18 Jun 2006, Vivek Goyal wrote:
> On Sat, Jun 17, 2006 at 04:34:41PM +0200, Geert Uytterhoeven wrote:
> > > diff -puN mm/Kconfig~64bit-resources-modify-kconfig-options mm/Kconfig
> > > --- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-16 14:40:15.000000000 -0400
> > > +++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-16 14:51:31.000000000 -0400
> > > @@ -145,3 +145,10 @@ config MIGRATION
> > > while the virtual addresses are not changed. This is useful for
> > > example on NUMA systems to put pages nearer to the processors accessing
> > > the page.
> > > +
> > > +config RESOURCES_64BIT
> > > + bool "64 bit Memory and IO resources (EXPERIMENTAL)"
> > > + depends on (EXPERIMENTAL && !64BIT)
> > > + default n
> > > + help
> > > + This option allows memory and IO resources to be 64 bit.
> > > diff -puN include/linux/types.h~64bit-resources-modify-kconfig-options include/linux/types.h
> > > --- linux-2.6.17-rc6-1M/include/linux/types.h~64bit-resources-modify-kconfig-options 2006-06-16 14:40:15.000000000 -0400
> > > +++ linux-2.6.17-rc6-1M-vivek/include/linux/types.h 2006-06-16 14:49:28.000000000 -0400
> > > @@ -179,7 +179,12 @@ typedef __u64 __bitwise __be64;
> > > #ifdef __KERNEL__
> > > typedef unsigned __bitwise__ gfp_t;
> > >
> > > -typedef unsigned long resource_size_t;
> > > +#if defined(CONFIG_RESOURCES_64BIT) || defined(CONFIG_64BIT)
> >
> > If you'd set CONFIG_RESOURCES_64BIT in Kconfig if CONFIG_64BIT, you don't need
> > the `|| defined(CONFIG_64BIT)'.
> >
> > IMHO it looks a bit confusing that resources are 64 bit on 64 bit platforms,
> > while CONFIG_RESOURCES_64BIT is not set.
> >
>
> Ok. Here is another take. I have used "select" in arch dependent files to
> select CONFIG_RESOURCES_64BIT forcibly if 64BIT is set. Please suggest if
> there is an arch independent way to do that.
I don't think you need to explicitly select it, since
> --- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
> +++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-18 13:35:13.000000000 -0400
> @@ -145,3 +145,12 @@ config MIGRATION
> while the virtual addresses are not changed. This is useful for
> example on NUMA systems to put pages nearer to the processors accessing
> the page.
> +
> +config RESOURCES_64BIT
> + bool "64 bit Memory and IO resources (EXPERIMENTAL)"
> + depends on (EXPERIMENTAL && !64BIT) || 64BIT
> + default y if 64BIT
it defaults to y if 64BIT. Roman?
> There is a small issue though. On 64bit kernels RESOURCES_64BIT should not
> be exprimental as rosources are already 64bit. "select" will make sure
> that RESOURCES_64BIT is set but following line will be visible to user on
> 64bit platforms and user might be confused about "EXPERIMENTAL" keyword.
>
> "64 bit Memory and IO resources (EXPERIMENTAL)"
>
> At the same time this key word is required on 32bit platforms so that user
> knows that this is something new and experimental.
`EXPERIMENTAL on 32 bit'?
> Please suggest if there is a way to handle this situation. Ideally I would
> like to set RESOURCES_64BIT on 64bit platforms without prompting anything
> to user.
Yes, that's what you want. Roman?
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-19 8:05 ` Geert Uytterhoeven
@ 2006-06-19 10:17 ` Roman Zippel
2006-06-19 11:08 ` Geert Uytterhoeven
2006-06-19 13:57 ` Vivek Goyal
0 siblings, 2 replies; 34+ messages in thread
From: Roman Zippel @ 2006-06-19 10:17 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Vivek Goyal, Greg KH, Linux Kernel Development,
Greg Kroah-Hartman
Hi,
On Mon, 19 Jun 2006, Geert Uytterhoeven wrote:
> > --- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
> > +++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-18 13:35:13.000000000 -0400
> > @@ -145,3 +145,12 @@ config MIGRATION
> > while the virtual addresses are not changed. This is useful for
> > example on NUMA systems to put pages nearer to the processors accessing
> > the page.
> > +
> > +config RESOURCES_64BIT
> > + bool "64 bit Memory and IO resources (EXPERIMENTAL)"
> > + depends on (EXPERIMENTAL && !64BIT) || 64BIT
> > + default y if 64BIT
>
> it defaults to y if 64BIT. Roman?
This should do it:
config RESOURCES_64BIT
bool "64 bit Memory and IO resources (EXPERIMENTAL)" if !64BIT && EXPERIMENTAL
default 64BIT
bye, Roman
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-19 10:17 ` Roman Zippel
@ 2006-06-19 11:08 ` Geert Uytterhoeven
2006-06-19 11:34 ` Roman Zippel
2006-06-19 13:57 ` Vivek Goyal
1 sibling, 1 reply; 34+ messages in thread
From: Geert Uytterhoeven @ 2006-06-19 11:08 UTC (permalink / raw)
To: Roman Zippel
Cc: Vivek Goyal, Greg KH, Linux Kernel Development,
Greg Kroah-Hartman
On Mon, 19 Jun 2006, Roman Zippel wrote:
> On Mon, 19 Jun 2006, Geert Uytterhoeven wrote:
>
> > > --- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
> > > +++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-18 13:35:13.000000000 -0400
> > > @@ -145,3 +145,12 @@ config MIGRATION
> > > while the virtual addresses are not changed. This is useful for
> > > example on NUMA systems to put pages nearer to the processors accessing
> > > the page.
> > > +
> > > +config RESOURCES_64BIT
> > > + bool "64 bit Memory and IO resources (EXPERIMENTAL)"
> > > + depends on (EXPERIMENTAL && !64BIT) || 64BIT
> > > + default y if 64BIT
> >
> > it defaults to y if 64BIT. Roman?
>
> This should do it:
>
> config RESOURCES_64BIT
> bool "64 bit Memory and IO resources (EXPERIMENTAL)" if !64BIT && EXPERIMENTAL
> default 64BIT
^
Missing `y if'?
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-19 11:08 ` Geert Uytterhoeven
@ 2006-06-19 11:34 ` Roman Zippel
2006-06-19 11:45 ` Geert Uytterhoeven
0 siblings, 1 reply; 34+ messages in thread
From: Roman Zippel @ 2006-06-19 11:34 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Vivek Goyal, Greg KH, Linux Kernel Development,
Greg Kroah-Hartman
Hi,
On Mon, 19 Jun 2006, Geert Uytterhoeven wrote:
> > config RESOURCES_64BIT
> > bool "64 bit Memory and IO resources (EXPERIMENTAL)" if !64BIT && EXPERIMENTAL
> > default 64BIT
> ^
> Missing `y if'?
Not really. :)
A default accepts normal expressions for boolean/tristate. Most of the
time an if is not needed for a default, it only really makes a difference
if you have multiple defaults, where the condition controls which one is
active.
bye, Roman
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-19 11:34 ` Roman Zippel
@ 2006-06-19 11:45 ` Geert Uytterhoeven
0 siblings, 0 replies; 34+ messages in thread
From: Geert Uytterhoeven @ 2006-06-19 11:45 UTC (permalink / raw)
To: Roman Zippel
Cc: Vivek Goyal, Greg KH, Linux Kernel Development,
Greg Kroah-Hartman
On Mon, 19 Jun 2006, Roman Zippel wrote:
> On Mon, 19 Jun 2006, Geert Uytterhoeven wrote:
> > > config RESOURCES_64BIT
> > > bool "64 bit Memory and IO resources (EXPERIMENTAL)" if !64BIT && EXPERIMENTAL
> > > default 64BIT
> > ^
> > Missing `y if'?
>
> Not really. :)
>
> A default accepts normal expressions for boolean/tristate. Most of the
> time an if is not needed for a default, it only really makes a difference
> if you have multiple defaults, where the condition controls which one is
> active.
IC, of course.
So the default value of CONFIG_RESOURCES_64BIT is the same as the value of
CONFIG_64BIT, which is indeed what we want.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 34+ messages in thread
* Re: [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes
2006-06-19 10:17 ` Roman Zippel
2006-06-19 11:08 ` Geert Uytterhoeven
@ 2006-06-19 13:57 ` Vivek Goyal
1 sibling, 0 replies; 34+ messages in thread
From: Vivek Goyal @ 2006-06-19 13:57 UTC (permalink / raw)
To: Roman Zippel
Cc: Geert Uytterhoeven, Greg KH, Linux Kernel Development,
Greg Kroah-Hartman
On Mon, Jun 19, 2006 at 12:17:12PM +0200, Roman Zippel wrote:
> Hi,
>
> On Mon, 19 Jun 2006, Geert Uytterhoeven wrote:
>
> > > --- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
> > > +++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-18 13:35:13.000000000 -0400
> > > @@ -145,3 +145,12 @@ config MIGRATION
> > > while the virtual addresses are not changed. This is useful for
> > > example on NUMA systems to put pages nearer to the processors accessing
> > > the page.
> > > +
> > > +config RESOURCES_64BIT
> > > + bool "64 bit Memory and IO resources (EXPERIMENTAL)"
> > > + depends on (EXPERIMENTAL && !64BIT) || 64BIT
> > > + default y if 64BIT
> >
> > it defaults to y if 64BIT. Roman?
>
> This should do it:
>
> config RESOURCES_64BIT
> bool "64 bit Memory and IO resources (EXPERIMENTAL)" if !64BIT && EXPERIMENTAL
> default 64BIT
>
Wow. That works. Thanks. I am attaching the patch. Hope this one is final :-)
Greg, can you please pick the patch.
Thanks
Vivek
o Introuces CONFIG_RESOURCES_64BIT Kconfig option.
Signed-off-by: Roman Zippel <zippel@linux-m68k.org>
Signed-off-by: Vivek Goyal <vgoyal@in.ibm.com>
---
linux-2.6.17-rc6-1M-vivek/arch/i386/Kconfig | 1 +
linux-2.6.17-rc6-1M-vivek/include/linux/types.h | 7 ++++++-
linux-2.6.17-rc6-1M-vivek/mm/Kconfig | 6 ++++++
3 files changed, 13 insertions(+), 1 deletion(-)
diff -puN include/linux/types.h~64bit-resources-modify-kconfig-options include/linux/types.h
--- linux-2.6.17-rc6-1M/include/linux/types.h~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/include/linux/types.h 2006-06-18 13:35:13.000000000 -0400
@@ -179,7 +179,12 @@ typedef __u64 __bitwise __be64;
#ifdef __KERNEL__
typedef unsigned __bitwise__ gfp_t;
-typedef unsigned long resource_size_t;
+#ifdef CONFIG_RESOURCES_64BIT
+typedef u64 resource_size_t;
+#else
+typedef u32 resource_size_t;
+#endif
+
#endif
struct ustat {
diff -puN mm/Kconfig~64bit-resources-modify-kconfig-options mm/Kconfig
--- linux-2.6.17-rc6-1M/mm/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/mm/Kconfig 2006-06-19 09:48:41.000000000 -0400
@@ -145,3 +145,9 @@ config MIGRATION
while the virtual addresses are not changed. This is useful for
example on NUMA systems to put pages nearer to the processors accessing
the page.
+
+config RESOURCES_64BIT
+ bool "64 bit Memory and IO resources (EXPERIMENTAL)" if (!64BIT && EXPERIMENTAL)
+ default 64BIT
+ help
+ This option allows memory and IO resources to be 64 bit.
diff -puN arch/i386/Kconfig~64bit-resources-modify-kconfig-options arch/i386/Kconfig
--- linux-2.6.17-rc6-1M/arch/i386/Kconfig~64bit-resources-modify-kconfig-options 2006-06-18 13:35:13.000000000 -0400
+++ linux-2.6.17-rc6-1M-vivek/arch/i386/Kconfig 2006-06-18 13:35:13.000000000 -0400
@@ -511,6 +511,7 @@ config X86_PAE
bool
depends on HIGHMEM64G
default y
+ select RESOURCES_64BIT
# Common NUMA Features
config NUMA
_
^ permalink raw reply [flat|nested] 34+ messages in thread
end of thread, other threads:[~2006-06-19 13:57 UTC | newest]
Thread overview: 34+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-06-13 0:30 Reworked 64bit resource patches Greg KH
2006-06-13 0:31 ` [PATCH 01/16] 64bit resource: C99 changes for struct resource declarations Greg KH
2006-06-13 0:31 ` [PATCH 02/16] 64bit resource: fix up printks for resources in sound drivers Greg KH
2006-06-13 0:31 ` [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers Greg KH
2006-06-13 0:31 ` [PATCH 04/16] 64bit resource: fix up printks for resources in pci core and hotplug drivers Greg KH
2006-06-13 0:31 ` [PATCH 05/16] 64bit resource: fix up printks for resources in mtd drivers Greg KH
2006-06-13 0:31 ` [PATCH 06/16] 64bit resource: fix up printks for resources in ide drivers Greg KH
2006-06-13 0:31 ` [PATCH 07/16] 64bit resource: fix up printks for resources in video drivers Greg KH
2006-06-13 0:31 ` [PATCH 08/16] 64bit resource: fix up printks for resources in pcmcia drivers Greg KH
2006-06-13 0:31 ` [PATCH 09/16] 64bit resource: fix up printks for resources in arch and core code Greg KH
2006-06-13 0:31 ` [PATCH 10/16] 64bit resource: fix up printks for resources in misc drivers Greg KH
2006-06-13 0:31 ` [PATCH 11/16] 64bit resource: introduce resource_size_t for the start and end of struct resource Greg KH
2006-06-13 0:31 ` [PATCH 12/16] 64bit resource: change resource core to use resource_size_t Greg KH
2006-06-13 0:31 ` [PATCH 15/16] 64bit resource: change pci core and arch code " Greg KH
2006-06-13 0:31 ` [PATCH 14/16] 64bit resource: change pnp core " Greg KH
2006-06-13 0:31 ` [PATCH 15/16] 64bit Resource: convert a few remaining drivers to use resource_size_t where needed Greg KH
2006-06-13 0:31 ` [PATCH 16/16] 64bit Resource: finally enable 64bit resource sizes Greg KH
2006-06-14 12:20 ` Geert Uytterhoeven
2006-06-14 23:35 ` Greg KH
2006-06-15 4:28 ` Vivek Goyal
2006-06-15 11:47 ` Geert Uytterhoeven
2006-06-15 15:56 ` Vivek Goyal
2006-06-16 1:35 ` Greg KH
2006-06-16 20:16 ` Vivek Goyal
2006-06-17 14:34 ` Geert Uytterhoeven
2006-06-18 18:05 ` Vivek Goyal
2006-06-19 8:05 ` Geert Uytterhoeven
2006-06-19 10:17 ` Roman Zippel
2006-06-19 11:08 ` Geert Uytterhoeven
2006-06-19 11:34 ` Roman Zippel
2006-06-19 11:45 ` Geert Uytterhoeven
2006-06-19 13:57 ` Vivek Goyal
2006-06-13 16:24 ` [PATCH 03/16] 64bit resource: fix up printks for resources in networks drivers Jesse Brandeburg
2006-06-13 16:30 ` Greg KH
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox