2 #include <linux/kernel.h>
12 #if defined(CONFIG_SIBYTE_SWARM) || defined(CONFIG_SIBYTE_LITTLESUR)
14 #define DRV_NAME "pata-swarm"
16 #define SWARM_IDE_SHIFT 5
17 #define SWARM_IDE_BASE 0x1f0
18 #define SWARM_IDE_CTRL 0x3f6
20 static struct resource swarm_pata_resource[] = {
22 .
name =
"Swarm GenBus IDE",
25 .name =
"Swarm GenBus IDE",
28 .name =
"Swarm GenBus IDE",
30 .start = K_INT_GB_IDE,
40 .
name =
"pata_platform",
42 .resource = swarm_pata_resource,
43 .num_resources =
ARRAY_SIZE(swarm_pata_resource),
45 .platform_data = &pata_platform_data,
46 .coherent_dma_mask = ~0,
50 static int __init swarm_pata_init(
void)
74 r = swarm_pata_resource;
75 r[0].
start = offset + (SWARM_IDE_BASE << SWARM_IDE_SHIFT);
76 r[0].
end = offset + ((SWARM_IDE_BASE + 8) << SWARM_IDE_SHIFT) - 1;
77 r[1].
start = offset + (SWARM_IDE_CTRL << SWARM_IDE_SHIFT);
78 r[1].
end = offset + ((SWARM_IDE_CTRL + 1) << SWARM_IDE_SHIFT) - 1;
87 #define sb1250_dev_struct(num) \
88 static struct resource sb1250_res##num = { \
89 .name = "SB1250 MAC " __stringify(num), \
90 .flags = IORESOURCE_MEM, \
91 .start = A_MAC_CHANNEL_BASE(num), \
92 .end = A_MAC_CHANNEL_BASE(num + 1) -1, \
94 static struct platform_device sb1250_dev##num = { \
95 .name = "sb1250-mac", \
97 .resource = &sb1250_res##num, \
113 static int __init sb1250_device_init(
void)