Commit f495a8bf authored by Jon Loeliger's avatar Jon Loeliger Committed by Paul Mackerras

[PATCH] powerpc: Remove sections use from ppc

Here is a new patch that removes all notion of the pmac, prep,
chrp and openfirmware initialization sections, and then unifies
the sections.h files without those __pmac, etc, sections identifiers
cluttering things up.
Signed-off-by: default avatarJon Loeliger <jdl@freescale.com>
Signed-off-by: default avatarKumar Gala <kumar.gala@freescale.com>
Signed-off-by: default avatarPaul Mackerras <paulus@samba.org>
parent 7da8f860
...@@ -644,7 +644,7 @@ pcibios_alloc_controller(void) ...@@ -644,7 +644,7 @@ pcibios_alloc_controller(void)
/* /*
* Functions below are used on OpenFirmware machines. * Functions below are used on OpenFirmware machines.
*/ */
static void __openfirmware static void
make_one_node_map(struct device_node* node, u8 pci_bus) make_one_node_map(struct device_node* node, u8 pci_bus)
{ {
int *bus_range; int *bus_range;
...@@ -678,7 +678,7 @@ make_one_node_map(struct device_node* node, u8 pci_bus) ...@@ -678,7 +678,7 @@ make_one_node_map(struct device_node* node, u8 pci_bus)
} }
} }
void __openfirmware void
pcibios_make_OF_bus_map(void) pcibios_make_OF_bus_map(void)
{ {
int i; int i;
...@@ -720,7 +720,7 @@ pcibios_make_OF_bus_map(void) ...@@ -720,7 +720,7 @@ pcibios_make_OF_bus_map(void)
typedef int (*pci_OF_scan_iterator)(struct device_node* node, void* data); typedef int (*pci_OF_scan_iterator)(struct device_node* node, void* data);
static struct device_node* __openfirmware static struct device_node*
scan_OF_pci_childs(struct device_node* node, pci_OF_scan_iterator filter, void* data) scan_OF_pci_childs(struct device_node* node, pci_OF_scan_iterator filter, void* data)
{ {
struct device_node* sub_node; struct device_node* sub_node;
...@@ -761,7 +761,7 @@ scan_OF_pci_childs_iterator(struct device_node* node, void* data) ...@@ -761,7 +761,7 @@ scan_OF_pci_childs_iterator(struct device_node* node, void* data)
return 0; return 0;
} }
static struct device_node* __openfirmware static struct device_node*
scan_OF_childs_for_device(struct device_node* node, u8 bus, u8 dev_fn) scan_OF_childs_for_device(struct device_node* node, u8 bus, u8 dev_fn)
{ {
u8 filter_data[2] = {bus, dev_fn}; u8 filter_data[2] = {bus, dev_fn};
...@@ -842,7 +842,7 @@ pci_find_hose_for_OF_device(struct device_node* node) ...@@ -842,7 +842,7 @@ pci_find_hose_for_OF_device(struct device_node* node)
return NULL; return NULL;
} }
static int __openfirmware static int
find_OF_pci_device_filter(struct device_node* node, void* data) find_OF_pci_device_filter(struct device_node* node, void* data)
{ {
return ((void *)node == data); return ((void *)node == data);
......
...@@ -339,7 +339,7 @@ early_init(int r3, int r4, int r5) ...@@ -339,7 +339,7 @@ early_init(int r3, int r4, int r5)
* Assume here that all clock rates are the same in a * Assume here that all clock rates are the same in a
* smp system. -- Cort * smp system. -- Cort
*/ */
int __openfirmware int
of_show_percpuinfo(struct seq_file *m, int i) of_show_percpuinfo(struct seq_file *m, int i)
{ {
struct device_node *cpu_node; struct device_node *cpu_node;
......
...@@ -29,7 +29,7 @@ void __iomem *gg2_pci_config_base; ...@@ -29,7 +29,7 @@ void __iomem *gg2_pci_config_base;
* limit the bus number to 3 bits * limit the bus number to 3 bits
*/ */
int __chrp gg2_read_config(struct pci_bus *bus, unsigned int devfn, int off, int gg2_read_config(struct pci_bus *bus, unsigned int devfn, int off,
int len, u32 *val) int len, u32 *val)
{ {
volatile void __iomem *cfg_data; volatile void __iomem *cfg_data;
...@@ -56,7 +56,7 @@ int __chrp gg2_read_config(struct pci_bus *bus, unsigned int devfn, int off, ...@@ -56,7 +56,7 @@ int __chrp gg2_read_config(struct pci_bus *bus, unsigned int devfn, int off,
return PCIBIOS_SUCCESSFUL; return PCIBIOS_SUCCESSFUL;
} }
int __chrp gg2_write_config(struct pci_bus *bus, unsigned int devfn, int off, int gg2_write_config(struct pci_bus *bus, unsigned int devfn, int off,
int len, u32 val) int len, u32 val)
{ {
volatile void __iomem *cfg_data; volatile void __iomem *cfg_data;
...@@ -92,7 +92,7 @@ static struct pci_ops gg2_pci_ops = ...@@ -92,7 +92,7 @@ static struct pci_ops gg2_pci_ops =
/* /*
* Access functions for PCI config space using RTAS calls. * Access functions for PCI config space using RTAS calls.
*/ */
int __chrp int
rtas_read_config(struct pci_bus *bus, unsigned int devfn, int offset, rtas_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 *val) int len, u32 *val)
{ {
...@@ -108,7 +108,7 @@ rtas_read_config(struct pci_bus *bus, unsigned int devfn, int offset, ...@@ -108,7 +108,7 @@ rtas_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
return rval? PCIBIOS_DEVICE_NOT_FOUND: PCIBIOS_SUCCESSFUL; return rval? PCIBIOS_DEVICE_NOT_FOUND: PCIBIOS_SUCCESSFUL;
} }
int __chrp int
rtas_write_config(struct pci_bus *bus, unsigned int devfn, int offset, rtas_write_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 val) int len, u32 val)
{ {
......
...@@ -105,7 +105,7 @@ static const char *gg2_cachemodes[4] = { ...@@ -105,7 +105,7 @@ static const char *gg2_cachemodes[4] = {
"Disabled", "Write-Through", "Copy-Back", "Transparent Mode" "Disabled", "Write-Through", "Copy-Back", "Transparent Mode"
}; };
int __chrp int
chrp_show_cpuinfo(struct seq_file *m) chrp_show_cpuinfo(struct seq_file *m)
{ {
int i, sdramen; int i, sdramen;
...@@ -303,7 +303,7 @@ void __init chrp_setup_arch(void) ...@@ -303,7 +303,7 @@ void __init chrp_setup_arch(void)
pci_create_OF_bus_map(); pci_create_OF_bus_map();
} }
void __chrp void
chrp_event_scan(void) chrp_event_scan(void)
{ {
unsigned char log[1024]; unsigned char log[1024];
...@@ -314,7 +314,7 @@ chrp_event_scan(void) ...@@ -314,7 +314,7 @@ chrp_event_scan(void)
ppc_md.heartbeat_count = ppc_md.heartbeat_reset; ppc_md.heartbeat_count = ppc_md.heartbeat_reset;
} }
void __chrp void
chrp_restart(char *cmd) chrp_restart(char *cmd)
{ {
printk("RTAS system-reboot returned %d\n", printk("RTAS system-reboot returned %d\n",
...@@ -322,7 +322,7 @@ chrp_restart(char *cmd) ...@@ -322,7 +322,7 @@ chrp_restart(char *cmd)
for (;;); for (;;);
} }
void __chrp void
chrp_power_off(void) chrp_power_off(void)
{ {
/* allow power on only with power button press */ /* allow power on only with power button press */
...@@ -331,13 +331,13 @@ chrp_power_off(void) ...@@ -331,13 +331,13 @@ chrp_power_off(void)
for (;;); for (;;);
} }
void __chrp void
chrp_halt(void) chrp_halt(void)
{ {
chrp_power_off(); chrp_power_off();
} }
u_int __chrp u_int
chrp_irq_canonicalize(u_int irq) chrp_irq_canonicalize(u_int irq)
{ {
if (irq == 2) if (irq == 2)
...@@ -572,7 +572,7 @@ chrp_init(unsigned long r3, unsigned long r4, unsigned long r5, ...@@ -572,7 +572,7 @@ chrp_init(unsigned long r3, unsigned long r4, unsigned long r5,
if (ppc_md.progress) ppc_md.progress("Linux/PPC "UTS_RELEASE"\n", 0x0); if (ppc_md.progress) ppc_md.progress("Linux/PPC "UTS_RELEASE"\n", 0x0);
} }
void __chrp void
rtas_display_progress(char *s, unsigned short hex) rtas_display_progress(char *s, unsigned short hex)
{ {
int width; int width;
...@@ -599,7 +599,7 @@ rtas_display_progress(char *s, unsigned short hex) ...@@ -599,7 +599,7 @@ rtas_display_progress(char *s, unsigned short hex)
call_rtas( "display-character", 1, 1, NULL, ' ' ); call_rtas( "display-character", 1, 1, NULL, ' ' );
} }
void __chrp void
rtas_indicator_progress(char *s, unsigned short hex) rtas_indicator_progress(char *s, unsigned short hex)
{ {
call_rtas("set-indicator", 3, 1, NULL, 6, 0, hex); call_rtas("set-indicator", 3, 1, NULL, 6, 0, hex);
......
...@@ -88,7 +88,7 @@ smp_chrp_take_timebase(void) ...@@ -88,7 +88,7 @@ smp_chrp_take_timebase(void)
} }
/* CHRP with openpic */ /* CHRP with openpic */
struct smp_ops_t chrp_smp_ops __chrpdata = { struct smp_ops_t chrp_smp_ops = {
.message_pass = smp_openpic_message_pass, .message_pass = smp_openpic_message_pass,
.probe = smp_chrp_probe, .probe = smp_chrp_probe,
.kick_cpu = smp_chrp_kick_cpu, .kick_cpu = smp_chrp_kick_cpu,
......
...@@ -52,7 +52,7 @@ long __init chrp_time_init(void) ...@@ -52,7 +52,7 @@ long __init chrp_time_init(void)
return 0; return 0;
} }
int __chrp chrp_cmos_clock_read(int addr) int chrp_cmos_clock_read(int addr)
{ {
if (nvram_as1 != 0) if (nvram_as1 != 0)
outb(addr>>8, nvram_as1); outb(addr>>8, nvram_as1);
...@@ -60,7 +60,7 @@ int __chrp chrp_cmos_clock_read(int addr) ...@@ -60,7 +60,7 @@ int __chrp chrp_cmos_clock_read(int addr)
return (inb(nvram_data)); return (inb(nvram_data));
} }
void __chrp chrp_cmos_clock_write(unsigned long val, int addr) void chrp_cmos_clock_write(unsigned long val, int addr)
{ {
if (nvram_as1 != 0) if (nvram_as1 != 0)
outb(addr>>8, nvram_as1); outb(addr>>8, nvram_as1);
...@@ -72,7 +72,7 @@ void __chrp chrp_cmos_clock_write(unsigned long val, int addr) ...@@ -72,7 +72,7 @@ void __chrp chrp_cmos_clock_write(unsigned long val, int addr)
/* /*
* Set the hardware clock. -- Cort * Set the hardware clock. -- Cort
*/ */
int __chrp chrp_set_rtc_time(unsigned long nowtime) int chrp_set_rtc_time(unsigned long nowtime)
{ {
unsigned char save_control, save_freq_select; unsigned char save_control, save_freq_select;
struct rtc_time tm; struct rtc_time tm;
...@@ -118,7 +118,7 @@ int __chrp chrp_set_rtc_time(unsigned long nowtime) ...@@ -118,7 +118,7 @@ int __chrp chrp_set_rtc_time(unsigned long nowtime)
return 0; return 0;
} }
unsigned long __chrp chrp_get_rtc_time(void) unsigned long chrp_get_rtc_time(void)
{ {
unsigned int year, mon, day, hour, min, sec; unsigned int year, mon, day, hour, min, sec;
int uip, i; int uip, i;
......
...@@ -37,7 +37,7 @@ static int backlight_req_enable = -1; ...@@ -37,7 +37,7 @@ static int backlight_req_enable = -1;
static void backlight_callback(void *); static void backlight_callback(void *);
static DECLARE_WORK(backlight_work, backlight_callback, NULL); static DECLARE_WORK(backlight_work, backlight_callback, NULL);
void __pmac register_backlight_controller(struct backlight_controller *ctrler, void register_backlight_controller(struct backlight_controller *ctrler,
void *data, char *type) void *data, char *type)
{ {
struct device_node* bk_node; struct device_node* bk_node;
...@@ -99,7 +99,7 @@ void __pmac register_backlight_controller(struct backlight_controller *ctrler, ...@@ -99,7 +99,7 @@ void __pmac register_backlight_controller(struct backlight_controller *ctrler,
} }
EXPORT_SYMBOL(register_backlight_controller); EXPORT_SYMBOL(register_backlight_controller);
void __pmac unregister_backlight_controller(struct backlight_controller void unregister_backlight_controller(struct backlight_controller
*ctrler, void *data) *ctrler, void *data)
{ {
/* We keep the current backlight level (for now) */ /* We keep the current backlight level (for now) */
...@@ -108,7 +108,7 @@ void __pmac unregister_backlight_controller(struct backlight_controller ...@@ -108,7 +108,7 @@ void __pmac unregister_backlight_controller(struct backlight_controller
} }
EXPORT_SYMBOL(unregister_backlight_controller); EXPORT_SYMBOL(unregister_backlight_controller);
static int __pmac __set_backlight_enable(int enable) static int __set_backlight_enable(int enable)
{ {
int rc; int rc;
...@@ -122,7 +122,7 @@ static int __pmac __set_backlight_enable(int enable) ...@@ -122,7 +122,7 @@ static int __pmac __set_backlight_enable(int enable)
release_console_sem(); release_console_sem();
return rc; return rc;
} }
int __pmac set_backlight_enable(int enable) int set_backlight_enable(int enable)
{ {
if (!backlighter) if (!backlighter)
return -ENODEV; return -ENODEV;
...@@ -133,7 +133,7 @@ int __pmac set_backlight_enable(int enable) ...@@ -133,7 +133,7 @@ int __pmac set_backlight_enable(int enable)
EXPORT_SYMBOL(set_backlight_enable); EXPORT_SYMBOL(set_backlight_enable);
int __pmac get_backlight_enable(void) int get_backlight_enable(void)
{ {
if (!backlighter) if (!backlighter)
return -ENODEV; return -ENODEV;
...@@ -141,7 +141,7 @@ int __pmac get_backlight_enable(void) ...@@ -141,7 +141,7 @@ int __pmac get_backlight_enable(void)
} }
EXPORT_SYMBOL(get_backlight_enable); EXPORT_SYMBOL(get_backlight_enable);
static int __pmac __set_backlight_level(int level) static int __set_backlight_level(int level)
{ {
int rc = 0; int rc = 0;
...@@ -165,7 +165,7 @@ static int __pmac __set_backlight_level(int level) ...@@ -165,7 +165,7 @@ static int __pmac __set_backlight_level(int level)
} }
return rc; return rc;
} }
int __pmac set_backlight_level(int level) int set_backlight_level(int level)
{ {
if (!backlighter) if (!backlighter)
return -ENODEV; return -ENODEV;
...@@ -176,7 +176,7 @@ int __pmac set_backlight_level(int level) ...@@ -176,7 +176,7 @@ int __pmac set_backlight_level(int level)
EXPORT_SYMBOL(set_backlight_level); EXPORT_SYMBOL(set_backlight_level);
int __pmac get_backlight_level(void) int get_backlight_level(void)
{ {
if (!backlighter) if (!backlighter)
return -ENODEV; return -ENODEV;
......
...@@ -136,7 +136,7 @@ static inline void debug_calc_bogomips(void) ...@@ -136,7 +136,7 @@ static inline void debug_calc_bogomips(void)
/* Switch CPU speed under 750FX CPU control /* Switch CPU speed under 750FX CPU control
*/ */
static int __pmac cpu_750fx_cpu_speed(int low_speed) static int cpu_750fx_cpu_speed(int low_speed)
{ {
u32 hid2; u32 hid2;
...@@ -172,7 +172,7 @@ static int __pmac cpu_750fx_cpu_speed(int low_speed) ...@@ -172,7 +172,7 @@ static int __pmac cpu_750fx_cpu_speed(int low_speed)
return 0; return 0;
} }
static unsigned int __pmac cpu_750fx_get_cpu_speed(void) static unsigned int cpu_750fx_get_cpu_speed(void)
{ {
if (mfspr(SPRN_HID1) & HID1_PS) if (mfspr(SPRN_HID1) & HID1_PS)
return low_freq; return low_freq;
...@@ -181,7 +181,7 @@ static unsigned int __pmac cpu_750fx_get_cpu_speed(void) ...@@ -181,7 +181,7 @@ static unsigned int __pmac cpu_750fx_get_cpu_speed(void)
} }
/* Switch CPU speed using DFS */ /* Switch CPU speed using DFS */
static int __pmac dfs_set_cpu_speed(int low_speed) static int dfs_set_cpu_speed(int low_speed)
{ {
if (low_speed == 0) { if (low_speed == 0) {
/* ramping up, set voltage first */ /* ramping up, set voltage first */
...@@ -205,7 +205,7 @@ static int __pmac dfs_set_cpu_speed(int low_speed) ...@@ -205,7 +205,7 @@ static int __pmac dfs_set_cpu_speed(int low_speed)
return 0; return 0;
} }
static unsigned int __pmac dfs_get_cpu_speed(void) static unsigned int dfs_get_cpu_speed(void)
{ {
if (mfspr(SPRN_HID1) & HID1_DFS) if (mfspr(SPRN_HID1) & HID1_DFS)
return low_freq; return low_freq;
...@@ -216,7 +216,7 @@ static unsigned int __pmac dfs_get_cpu_speed(void) ...@@ -216,7 +216,7 @@ static unsigned int __pmac dfs_get_cpu_speed(void)
/* Switch CPU speed using slewing GPIOs /* Switch CPU speed using slewing GPIOs
*/ */
static int __pmac gpios_set_cpu_speed(int low_speed) static int gpios_set_cpu_speed(int low_speed)
{ {
int gpio, timeout = 0; int gpio, timeout = 0;
...@@ -258,7 +258,7 @@ static int __pmac gpios_set_cpu_speed(int low_speed) ...@@ -258,7 +258,7 @@ static int __pmac gpios_set_cpu_speed(int low_speed)
/* Switch CPU speed under PMU control /* Switch CPU speed under PMU control
*/ */
static int __pmac pmu_set_cpu_speed(int low_speed) static int pmu_set_cpu_speed(int low_speed)
{ {
struct adb_request req; struct adb_request req;
unsigned long save_l2cr; unsigned long save_l2cr;
...@@ -354,7 +354,7 @@ static int __pmac pmu_set_cpu_speed(int low_speed) ...@@ -354,7 +354,7 @@ static int __pmac pmu_set_cpu_speed(int low_speed)
return 0; return 0;
} }
static int __pmac do_set_cpu_speed(int speed_mode, int notify) static int do_set_cpu_speed(int speed_mode, int notify)
{ {
struct cpufreq_freqs freqs; struct cpufreq_freqs freqs;
unsigned long l3cr; unsigned long l3cr;
...@@ -391,17 +391,17 @@ static int __pmac do_set_cpu_speed(int speed_mode, int notify) ...@@ -391,17 +391,17 @@ static int __pmac do_set_cpu_speed(int speed_mode, int notify)
return 0; return 0;
} }
static unsigned int __pmac pmac_cpufreq_get_speed(unsigned int cpu) static unsigned int pmac_cpufreq_get_speed(unsigned int cpu)
{ {
return cur_freq; return cur_freq;
} }
static int __pmac pmac_cpufreq_verify(struct cpufreq_policy *policy) static int pmac_cpufreq_verify(struct cpufreq_policy *policy)
{ {
return cpufreq_frequency_table_verify(policy, pmac_cpu_freqs); return cpufreq_frequency_table_verify(policy, pmac_cpu_freqs);
} }
static int __pmac pmac_cpufreq_target( struct cpufreq_policy *policy, static int pmac_cpufreq_target( struct cpufreq_policy *policy,
unsigned int target_freq, unsigned int target_freq,
unsigned int relation) unsigned int relation)
{ {
...@@ -414,13 +414,13 @@ static int __pmac pmac_cpufreq_target( struct cpufreq_policy *policy, ...@@ -414,13 +414,13 @@ static int __pmac pmac_cpufreq_target( struct cpufreq_policy *policy,
return do_set_cpu_speed(newstate, 1); return do_set_cpu_speed(newstate, 1);
} }
unsigned int __pmac pmac_get_one_cpufreq(int i) unsigned int pmac_get_one_cpufreq(int i)
{ {
/* Supports only one CPU for now */ /* Supports only one CPU for now */
return (i == 0) ? cur_freq : 0; return (i == 0) ? cur_freq : 0;
} }
static int __pmac pmac_cpufreq_cpu_init(struct cpufreq_policy *policy) static int pmac_cpufreq_cpu_init(struct cpufreq_policy *policy)
{ {
if (policy->cpu != 0) if (policy->cpu != 0)
return -ENODEV; return -ENODEV;
...@@ -433,7 +433,7 @@ static int __pmac pmac_cpufreq_cpu_init(struct cpufreq_policy *policy) ...@@ -433,7 +433,7 @@ static int __pmac pmac_cpufreq_cpu_init(struct cpufreq_policy *policy)
return cpufreq_frequency_table_cpuinfo(policy, pmac_cpu_freqs); return cpufreq_frequency_table_cpuinfo(policy, pmac_cpu_freqs);
} }
static u32 __pmac read_gpio(struct device_node *np) static u32 read_gpio(struct device_node *np)
{ {
u32 *reg = (u32 *)get_property(np, "reg", NULL); u32 *reg = (u32 *)get_property(np, "reg", NULL);
u32 offset; u32 offset;
...@@ -452,7 +452,7 @@ static u32 __pmac read_gpio(struct device_node *np) ...@@ -452,7 +452,7 @@ static u32 __pmac read_gpio(struct device_node *np)
return offset; return offset;
} }
static int __pmac pmac_cpufreq_suspend(struct cpufreq_policy *policy, pm_message_t pmsg) static int pmac_cpufreq_suspend(struct cpufreq_policy *policy, pm_message_t pmsg)
{ {
/* Ok, this could be made a bit smarter, but let's be robust for now. We /* Ok, this could be made a bit smarter, but let's be robust for now. We
* always force a speed change to high speed before sleep, to make sure * always force a speed change to high speed before sleep, to make sure
...@@ -468,7 +468,7 @@ static int __pmac pmac_cpufreq_suspend(struct cpufreq_policy *policy, pm_message ...@@ -468,7 +468,7 @@ static int __pmac pmac_cpufreq_suspend(struct cpufreq_policy *policy, pm_message
return 0; return 0;
} }
static int __pmac pmac_cpufreq_resume(struct cpufreq_policy *policy) static int pmac_cpufreq_resume(struct cpufreq_policy *policy)
{ {
/* If we resume, first check if we have a get() function */ /* If we resume, first check if we have a get() function */
if (get_speed_proc) if (get_speed_proc)
...@@ -501,7 +501,7 @@ static struct cpufreq_driver pmac_cpufreq_driver = { ...@@ -501,7 +501,7 @@ static struct cpufreq_driver pmac_cpufreq_driver = {
}; };
static int __pmac pmac_cpufreq_init_MacRISC3(struct device_node *cpunode) static int pmac_cpufreq_init_MacRISC3(struct device_node *cpunode)
{ {
struct device_node *volt_gpio_np = of_find_node_by_name(NULL, struct device_node *volt_gpio_np = of_find_node_by_name(NULL,
"voltage-gpio"); "voltage-gpio");
...@@ -593,7 +593,7 @@ static int __pmac pmac_cpufreq_init_MacRISC3(struct device_node *cpunode) ...@@ -593,7 +593,7 @@ static int __pmac pmac_cpufreq_init_MacRISC3(struct device_node *cpunode)
return 0; return 0;
} }
static int __pmac pmac_cpufreq_init_7447A(struct device_node *cpunode) static int pmac_cpufreq_init_7447A(struct device_node *cpunode)
{ {
struct device_node *volt_gpio_np; struct device_node *volt_gpio_np;
...@@ -620,7 +620,7 @@ static int __pmac pmac_cpufreq_init_7447A(struct device_node *cpunode) ...@@ -620,7 +620,7 @@ static int __pmac pmac_cpufreq_init_7447A(struct device_node *cpunode)
return 0; return 0;
} }
static int __pmac pmac_cpufreq_init_750FX(struct device_node *cpunode) static int pmac_cpufreq_init_750FX(struct device_node *cpunode)
{ {
struct device_node *volt_gpio_np; struct device_node *volt_gpio_np;
u32 pvr, *value; u32 pvr, *value;
......
...@@ -63,7 +63,7 @@ extern struct device_node *k2_skiplist[2]; ...@@ -63,7 +63,7 @@ extern struct device_node *k2_skiplist[2];
* We use a single global lock to protect accesses. Each driver has * We use a single global lock to protect accesses. Each driver has
* to take care of its own locking * to take care of its own locking
*/ */
static DEFINE_SPINLOCK(feature_lock __pmacdata); static DEFINE_SPINLOCK(feature_lock);
#define LOCK(flags) spin_lock_irqsave(&feature_lock, flags); #define LOCK(flags) spin_lock_irqsave(&feature_lock, flags);
#define UNLOCK(flags) spin_unlock_irqrestore(&feature_lock, flags); #define UNLOCK(flags) spin_unlock_irqrestore(&feature_lock, flags);
...@@ -72,9 +72,9 @@ static DEFINE_SPINLOCK(feature_lock __pmacdata); ...@@ -72,9 +72,9 @@ static DEFINE_SPINLOCK(feature_lock __pmacdata);
/* /*
* Instance of some macio stuffs * Instance of some macio stuffs
*/ */
struct macio_chip macio_chips[MAX_MACIO_CHIPS] __pmacdata; struct macio_chip macio_chips[MAX_MACIO_CHIPS];
struct macio_chip* __pmac macio_find(struct device_node* child, int type) struct macio_chip* macio_find(struct device_node* child, int type)
{ {
while(child) { while(child) {
int i; int i;
...@@ -89,7 +89,7 @@ struct macio_chip* __pmac macio_find(struct device_node* child, int type) ...@@ -89,7 +89,7 @@ struct macio_chip* __pmac macio_find(struct device_node* child, int type)
} }
EXPORT_SYMBOL_GPL(macio_find); EXPORT_SYMBOL_GPL(macio_find);
static const char* macio_names[] __pmacdata = static const char* macio_names[] =
{ {
"Unknown", "Unknown",
"Grand Central", "Grand Central",
...@@ -116,10 +116,10 @@ static const char* macio_names[] __pmacdata = ...@@ -116,10 +116,10 @@ static const char* macio_names[] __pmacdata =
#define UN_BIS(r,v) (UN_OUT((r), UN_IN(r) | (v))) #define UN_BIS(r,v) (UN_OUT((r), UN_IN(r) | (v)))
#define UN_BIC(r,v) (UN_OUT((r), UN_IN(r) & ~(v))) #define UN_BIC(r,v) (UN_OUT((r), UN_IN(r) & ~(v)))
static struct device_node* uninorth_node __pmacdata; static struct device_node* uninorth_node;
static u32 __iomem * uninorth_base __pmacdata; static u32 __iomem * uninorth_base;
static u32 uninorth_rev __pmacdata; static u32 uninorth_rev;
static int uninorth_u3 __pmacdata; static int uninorth_u3;
static void __iomem *u3_ht; static void __iomem *u3_ht;
/* /*
...@@ -142,13 +142,13 @@ struct pmac_mb_def ...@@ -142,13 +142,13 @@ struct pmac_mb_def
struct feature_table_entry* features; struct feature_table_entry* features;
unsigned long board_flags; unsigned long board_flags;
}; };
static struct pmac_mb_def pmac_mb __pmacdata; static struct pmac_mb_def pmac_mb;
/* /*
* Here are the chip specific feature functions * Here are the chip specific feature functions
*/ */
static inline int __pmac static inline int
simple_feature_tweak(struct device_node* node, int type, int reg, u32 mask, int value) simple_feature_tweak(struct device_node* node, int type, int reg, u32 mask, int value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -170,7 +170,7 @@ simple_feature_tweak(struct device_node* node, int type, int reg, u32 mask, int ...@@ -170,7 +170,7 @@ simple_feature_tweak(struct device_node* node, int type, int reg, u32 mask, int
#ifndef CONFIG_POWER4 #ifndef CONFIG_POWER4
static long __pmac static long
ohare_htw_scc_enable(struct device_node* node, long param, long value) ohare_htw_scc_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -263,21 +263,21 @@ ohare_htw_scc_enable(struct device_node* node, long param, long value) ...@@ -263,21 +263,21 @@ ohare_htw_scc_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
ohare_floppy_enable(struct device_node* node, long param, long value) ohare_floppy_enable(struct device_node* node, long param, long value)
{ {
return simple_feature_tweak(node, macio_ohare, return simple_feature_tweak(node, macio_ohare,
OHARE_FCR, OH_FLOPPY_ENABLE, value); OHARE_FCR, OH_FLOPPY_ENABLE, value);
} }
static long __pmac static long
ohare_mesh_enable(struct device_node* node, long param, long value) ohare_mesh_enable(struct device_node* node, long param, long value)
{ {
return simple_feature_tweak(node, macio_ohare, return simple_feature_tweak(node, macio_ohare,
OHARE_FCR, OH_MESH_ENABLE, value); OHARE_FCR, OH_MESH_ENABLE, value);
} }
static long __pmac static long
ohare_ide_enable(struct device_node* node, long param, long value) ohare_ide_enable(struct device_node* node, long param, long value)
{ {
switch(param) { switch(param) {
...@@ -298,7 +298,7 @@ ohare_ide_enable(struct device_node* node, long param, long value) ...@@ -298,7 +298,7 @@ ohare_ide_enable(struct device_node* node, long param, long value)
} }
} }
static long __pmac static long
ohare_ide_reset(struct device_node* node, long param, long value) ohare_ide_reset(struct device_node* node, long param, long value)
{ {
switch(param) { switch(param) {
...@@ -313,7 +313,7 @@ ohare_ide_reset(struct device_node* node, long param, long value) ...@@ -313,7 +313,7 @@ ohare_ide_reset(struct device_node* node, long param, long value)
} }
} }
static long __pmac static long
ohare_sleep_state(struct device_node* node, long param, long value) ohare_sleep_state(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio = &macio_chips[0]; struct macio_chip* macio = &macio_chips[0];
...@@ -329,7 +329,7 @@ ohare_sleep_state(struct device_node* node, long param, long value) ...@@ -329,7 +329,7 @@ ohare_sleep_state(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
heathrow_modem_enable(struct device_node* node, long param, long value) heathrow_modem_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -373,7 +373,7 @@ heathrow_modem_enable(struct device_node* node, long param, long value) ...@@ -373,7 +373,7 @@ heathrow_modem_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
heathrow_floppy_enable(struct device_node* node, long param, long value) heathrow_floppy_enable(struct device_node* node, long param, long value)
{ {
return simple_feature_tweak(node, macio_unknown, return simple_feature_tweak(node, macio_unknown,
...@@ -382,7 +382,7 @@ heathrow_floppy_enable(struct device_node* node, long param, long value) ...@@ -382,7 +382,7 @@ heathrow_floppy_enable(struct device_node* node, long param, long value)
value); value);
} }
static long __pmac static long
heathrow_mesh_enable(struct device_node* node, long param, long value) heathrow_mesh_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -411,7 +411,7 @@ heathrow_mesh_enable(struct device_node* node, long param, long value) ...@@ -411,7 +411,7 @@ heathrow_mesh_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
heathrow_ide_enable(struct device_node* node, long param, long value) heathrow_ide_enable(struct device_node* node, long param, long value)
{ {
switch(param) { switch(param) {
...@@ -426,7 +426,7 @@ heathrow_ide_enable(struct device_node* node, long param, long value) ...@@ -426,7 +426,7 @@ heathrow_ide_enable(struct device_node* node, long param, long value)
} }
} }
static long __pmac static long
heathrow_ide_reset(struct device_node* node, long param, long value) heathrow_ide_reset(struct device_node* node, long param, long value)
{ {
switch(param) { switch(param) {
...@@ -441,7 +441,7 @@ heathrow_ide_reset(struct device_node* node, long param, long value) ...@@ -441,7 +441,7 @@ heathrow_ide_reset(struct device_node* node, long param, long value)
} }
} }
static long __pmac static long
heathrow_bmac_enable(struct device_node* node, long param, long value) heathrow_bmac_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -470,7 +470,7 @@ heathrow_bmac_enable(struct device_node* node, long param, long value) ...@@ -470,7 +470,7 @@ heathrow_bmac_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
heathrow_sound_enable(struct device_node* node, long param, long value) heathrow_sound_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -501,16 +501,16 @@ heathrow_sound_enable(struct device_node* node, long param, long value) ...@@ -501,16 +501,16 @@ heathrow_sound_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static u32 save_fcr[6] __pmacdata; static u32 save_fcr[6];
static u32 save_mbcr __pmacdata; static u32 save_mbcr;
static u32 save_gpio_levels[2] __pmacdata; static u32 save_gpio_levels[2];
static u8 save_gpio_extint[KEYLARGO_GPIO_EXTINT_CNT] __pmacdata; static u8 save_gpio_extint[KEYLARGO_GPIO_EXTINT_CNT];
static u8 save_gpio_normal[KEYLARGO_GPIO_CNT] __pmacdata; static u8 save_gpio_normal[KEYLARGO_GPIO_CNT];
static u32 save_unin_clock_ctl __pmacdata; static u32 save_unin_clock_ctl;
static struct dbdma_regs save_dbdma[13] __pmacdata; static struct dbdma_regs save_dbdma[13];
static struct dbdma_regs save_alt_dbdma[13] __pmacdata; static struct dbdma_regs save_alt_dbdma[13];
static void __pmac static void
dbdma_save(struct macio_chip* macio, struct dbdma_regs* save) dbdma_save(struct macio_chip* macio, struct dbdma_regs* save)
{ {
int i; int i;
...@@ -527,7 +527,7 @@ dbdma_save(struct macio_chip* macio, struct dbdma_regs* save) ...@@ -527,7 +527,7 @@ dbdma_save(struct macio_chip* macio, struct dbdma_regs* save)
} }
} }
static void __pmac static void
dbdma_restore(struct macio_chip* macio, struct dbdma_regs* save) dbdma_restore(struct macio_chip* macio, struct dbdma_regs* save)
{ {
int i; int i;
...@@ -547,7 +547,7 @@ dbdma_restore(struct macio_chip* macio, struct dbdma_regs* save) ...@@ -547,7 +547,7 @@ dbdma_restore(struct macio_chip* macio, struct dbdma_regs* save)
} }
} }
static void __pmac static void
heathrow_sleep(struct macio_chip* macio, int secondary) heathrow_sleep(struct macio_chip* macio, int secondary)
{ {
if (secondary) { if (secondary) {
...@@ -580,7 +580,7 @@ heathrow_sleep(struct macio_chip* macio, int secondary) ...@@ -580,7 +580,7 @@ heathrow_sleep(struct macio_chip* macio, int secondary)
(void)MACIO_IN32(HEATHROW_FCR); (void)MACIO_IN32(HEATHROW_FCR);
} }
static void __pmac static void
heathrow_wakeup(struct macio_chip* macio, int secondary) heathrow_wakeup(struct macio_chip* macio, int secondary)
{ {
if (secondary) { if (secondary) {
...@@ -605,7 +605,7 @@ heathrow_wakeup(struct macio_chip* macio, int secondary) ...@@ -605,7 +605,7 @@ heathrow_wakeup(struct macio_chip* macio, int secondary)
} }
} }
static long __pmac static long
heathrow_sleep_state(struct device_node* node, long param, long value) heathrow_sleep_state(struct device_node* node, long param, long value)
{ {
if ((pmac_mb.board_flags & PMAC_MB_CAN_SLEEP) == 0) if ((pmac_mb.board_flags & PMAC_MB_CAN_SLEEP) == 0)
...@@ -622,7 +622,7 @@ heathrow_sleep_state(struct device_node* node, long param, long value) ...@@ -622,7 +622,7 @@ heathrow_sleep_state(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
core99_scc_enable(struct device_node* node, long param, long value) core99_scc_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -723,7 +723,7 @@ core99_scc_enable(struct device_node* node, long param, long value) ...@@ -723,7 +723,7 @@ core99_scc_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
core99_modem_enable(struct device_node* node, long param, long value) core99_modem_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -775,7 +775,7 @@ core99_modem_enable(struct device_node* node, long param, long value) ...@@ -775,7 +775,7 @@ core99_modem_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
pangea_modem_enable(struct device_node* node, long param, long value) pangea_modem_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -830,7 +830,7 @@ pangea_modem_enable(struct device_node* node, long param, long value) ...@@ -830,7 +830,7 @@ pangea_modem_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
core99_ata100_enable(struct device_node* node, long value) core99_ata100_enable(struct device_node* node, long value)
{ {
unsigned long flags; unsigned long flags;
...@@ -860,7 +860,7 @@ core99_ata100_enable(struct device_node* node, long value) ...@@ -860,7 +860,7 @@ core99_ata100_enable(struct device_node* node, long value)
return 0; return 0;
} }
static long __pmac static long
core99_ide_enable(struct device_node* node, long param, long value) core99_ide_enable(struct device_node* node, long param, long value)
{ {
/* Bus ID 0 to 2 are KeyLargo based IDE, busID 3 is U2 /* Bus ID 0 to 2 are KeyLargo based IDE, busID 3 is U2
...@@ -883,7 +883,7 @@ core99_ide_enable(struct device_node* node, long param, long value) ...@@ -883,7 +883,7 @@ core99_ide_enable(struct device_node* node, long param, long value)
} }
} }
static long __pmac static long
core99_ide_reset(struct device_node* node, long param, long value) core99_ide_reset(struct device_node* node, long param, long value)
{ {
switch(param) { switch(param) {
...@@ -901,7 +901,7 @@ core99_ide_reset(struct device_node* node, long param, long value) ...@@ -901,7 +901,7 @@ core99_ide_reset(struct device_node* node, long param, long value)
} }
} }
static long __pmac static long
core99_gmac_enable(struct device_node* node, long param, long value) core99_gmac_enable(struct device_node* node, long param, long value)
{ {
unsigned long flags; unsigned long flags;
...@@ -918,7 +918,7 @@ core99_gmac_enable(struct device_node* node, long param, long value) ...@@ -918,7 +918,7 @@ core99_gmac_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
core99_gmac_phy_reset(struct device_node* node, long param, long value) core99_gmac_phy_reset(struct device_node* node, long param, long value)
{ {
unsigned long flags; unsigned long flags;
...@@ -943,7 +943,7 @@ core99_gmac_phy_reset(struct device_node* node, long param, long value) ...@@ -943,7 +943,7 @@ core99_gmac_phy_reset(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
core99_sound_chip_enable(struct device_node* node, long param, long value) core99_sound_chip_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -973,7 +973,7 @@ core99_sound_chip_enable(struct device_node* node, long param, long value) ...@@ -973,7 +973,7 @@ core99_sound_chip_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
core99_airport_enable(struct device_node* node, long param, long value) core99_airport_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -1060,7 +1060,7 @@ core99_airport_enable(struct device_node* node, long param, long value) ...@@ -1060,7 +1060,7 @@ core99_airport_enable(struct device_node* node, long param, long value)
} }
#ifdef CONFIG_SMP #ifdef CONFIG_SMP
static long __pmac static long
core99_reset_cpu(struct device_node* node, long param, long value) core99_reset_cpu(struct device_node* node, long param, long value)
{ {
unsigned int reset_io = 0; unsigned int reset_io = 0;
...@@ -1104,7 +1104,7 @@ core99_reset_cpu(struct device_node* node, long param, long value) ...@@ -1104,7 +1104,7 @@ core99_reset_cpu(struct device_node* node, long param, long value)
} }
#endif /* CONFIG_SMP */ #endif /* CONFIG_SMP */
static long __pmac static long
core99_usb_enable(struct device_node* node, long param, long value) core99_usb_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -1257,7 +1257,7 @@ core99_usb_enable(struct device_node* node, long param, long value) ...@@ -1257,7 +1257,7 @@ core99_usb_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
core99_firewire_enable(struct device_node* node, long param, long value) core99_firewire_enable(struct device_node* node, long param, long value)
{ {
unsigned long flags; unsigned long flags;
...@@ -1284,7 +1284,7 @@ core99_firewire_enable(struct device_node* node, long param, long value) ...@@ -1284,7 +1284,7 @@ core99_firewire_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
core99_firewire_cable_power(struct device_node* node, long param, long value) core99_firewire_cable_power(struct device_node* node, long param, long value)
{ {
unsigned long flags; unsigned long flags;
...@@ -1315,7 +1315,7 @@ core99_firewire_cable_power(struct device_node* node, long param, long value) ...@@ -1315,7 +1315,7 @@ core99_firewire_cable_power(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
intrepid_aack_delay_enable(struct device_node* node, long param, long value) intrepid_aack_delay_enable(struct device_node* node, long param, long value)
{ {
unsigned long flags; unsigned long flags;
...@@ -1336,7 +1336,7 @@ intrepid_aack_delay_enable(struct device_node* node, long param, long value) ...@@ -1336,7 +1336,7 @@ intrepid_aack_delay_enable(struct device_node* node, long param, long value)
#endif /* CONFIG_POWER4 */ #endif /* CONFIG_POWER4 */
static long __pmac static long
core99_read_gpio(struct device_node* node, long param, long value) core99_read_gpio(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio = &macio_chips[0]; struct macio_chip* macio = &macio_chips[0];
...@@ -1345,7 +1345,7 @@ core99_read_gpio(struct device_node* node, long param, long value) ...@@ -1345,7 +1345,7 @@ core99_read_gpio(struct device_node* node, long param, long value)
} }
static long __pmac static long
core99_write_gpio(struct device_node* node, long param, long value) core99_write_gpio(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio = &macio_chips[0]; struct macio_chip* macio = &macio_chips[0];
...@@ -1356,7 +1356,7 @@ core99_write_gpio(struct device_node* node, long param, long value) ...@@ -1356,7 +1356,7 @@ core99_write_gpio(struct device_node* node, long param, long value)
#ifdef CONFIG_POWER4 #ifdef CONFIG_POWER4
static long __pmac static long
g5_gmac_enable(struct device_node* node, long param, long value) g5_gmac_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio = &macio_chips[0]; struct macio_chip* macio = &macio_chips[0];
...@@ -1380,7 +1380,7 @@ g5_gmac_enable(struct device_node* node, long param, long value) ...@@ -1380,7 +1380,7 @@ g5_gmac_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
g5_fw_enable(struct device_node* node, long param, long value) g5_fw_enable(struct device_node* node, long param, long value)
{ {
struct macio_chip* macio = &macio_chips[0]; struct macio_chip* macio = &macio_chips[0];
...@@ -1403,7 +1403,7 @@ g5_fw_enable(struct device_node* node, long param, long value) ...@@ -1403,7 +1403,7 @@ g5_fw_enable(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
g5_mpic_enable(struct device_node* node, long param, long value) g5_mpic_enable(struct device_node* node, long param, long value)
{ {
unsigned long flags; unsigned long flags;
...@@ -1419,7 +1419,7 @@ g5_mpic_enable(struct device_node* node, long param, long value) ...@@ -1419,7 +1419,7 @@ g5_mpic_enable(struct device_node* node, long param, long value)
} }
#ifdef CONFIG_SMP #ifdef CONFIG_SMP
static long __pmac static long
g5_reset_cpu(struct device_node* node, long param, long value) g5_reset_cpu(struct device_node* node, long param, long value)
{ {
unsigned int reset_io = 0; unsigned int reset_io = 0;
...@@ -1465,7 +1465,7 @@ g5_reset_cpu(struct device_node* node, long param, long value) ...@@ -1465,7 +1465,7 @@ g5_reset_cpu(struct device_node* node, long param, long value)
* This takes the second CPU off the bus on dual CPU machines * This takes the second CPU off the bus on dual CPU machines
* running UP * running UP
*/ */
void __pmac g5_phy_disable_cpu1(void) void g5_phy_disable_cpu1(void)
{ {
UN_OUT(U3_API_PHY_CONFIG_1, 0); UN_OUT(U3_API_PHY_CONFIG_1, 0);
} }
...@@ -1474,7 +1474,7 @@ void __pmac g5_phy_disable_cpu1(void) ...@@ -1474,7 +1474,7 @@ void __pmac g5_phy_disable_cpu1(void)
#ifndef CONFIG_POWER4 #ifndef CONFIG_POWER4
static void __pmac static void
keylargo_shutdown(struct macio_chip* macio, int sleep_mode) keylargo_shutdown(struct macio_chip* macio, int sleep_mode)
{ {
u32 temp; u32 temp;
...@@ -1528,7 +1528,7 @@ keylargo_shutdown(struct macio_chip* macio, int sleep_mode) ...@@ -1528,7 +1528,7 @@ keylargo_shutdown(struct macio_chip* macio, int sleep_mode)
(void)MACIO_IN32(KEYLARGO_FCR0); mdelay(1); (void)MACIO_IN32(KEYLARGO_FCR0); mdelay(1);
} }
static void __pmac static void
pangea_shutdown(struct macio_chip* macio, int sleep_mode) pangea_shutdown(struct macio_chip* macio, int sleep_mode)
{ {
u32 temp; u32 temp;
...@@ -1562,7 +1562,7 @@ pangea_shutdown(struct macio_chip* macio, int sleep_mode) ...@@ -1562,7 +1562,7 @@ pangea_shutdown(struct macio_chip* macio, int sleep_mode)
(void)MACIO_IN32(KEYLARGO_FCR0); mdelay(1); (void)MACIO_IN32(KEYLARGO_FCR0); mdelay(1);
} }
static void __pmac static void
intrepid_shutdown(struct macio_chip* macio, int sleep_mode) intrepid_shutdown(struct macio_chip* macio, int sleep_mode)
{ {
u32 temp; u32 temp;
...@@ -1591,7 +1591,7 @@ intrepid_shutdown(struct macio_chip* macio, int sleep_mode) ...@@ -1591,7 +1591,7 @@ intrepid_shutdown(struct macio_chip* macio, int sleep_mode)
} }
void __pmac pmac_tweak_clock_spreading(int enable) void pmac_tweak_clock_spreading(int enable)
{ {
struct macio_chip* macio = &macio_chips[0]; struct macio_chip* macio = &macio_chips[0];
...@@ -1698,7 +1698,7 @@ void __pmac pmac_tweak_clock_spreading(int enable) ...@@ -1698,7 +1698,7 @@ void __pmac pmac_tweak_clock_spreading(int enable)
} }
static int __pmac static int
core99_sleep(void) core99_sleep(void)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -1791,7 +1791,7 @@ core99_sleep(void) ...@@ -1791,7 +1791,7 @@ core99_sleep(void)
return 0; return 0;
} }
static int __pmac static int
core99_wake_up(void) core99_wake_up(void)
{ {
struct macio_chip* macio; struct macio_chip* macio;
...@@ -1854,7 +1854,7 @@ core99_wake_up(void) ...@@ -1854,7 +1854,7 @@ core99_wake_up(void)
return 0; return 0;
} }
static long __pmac static long
core99_sleep_state(struct device_node* node, long param, long value) core99_sleep_state(struct device_node* node, long param, long value)
{ {
/* Param == 1 means to enter the "fake sleep" mode that is /* Param == 1 means to enter the "fake sleep" mode that is
...@@ -1884,7 +1884,7 @@ core99_sleep_state(struct device_node* node, long param, long value) ...@@ -1884,7 +1884,7 @@ core99_sleep_state(struct device_node* node, long param, long value)
#endif /* CONFIG_POWER4 */ #endif /* CONFIG_POWER4 */
static long __pmac static long
generic_dev_can_wake(struct device_node* node, long param, long value) generic_dev_can_wake(struct device_node* node, long param, long value)
{ {
/* Todo: eventually check we are really dealing with on-board /* Todo: eventually check we are really dealing with on-board
...@@ -1896,7 +1896,7 @@ generic_dev_can_wake(struct device_node* node, long param, long value) ...@@ -1896,7 +1896,7 @@ generic_dev_can_wake(struct device_node* node, long param, long value)
return 0; return 0;
} }
static long __pmac static long
generic_get_mb_info(struct device_node* node, long param, long value) generic_get_mb_info(struct device_node* node, long param, long value)
{ {
switch(param) { switch(param) {
...@@ -1919,7 +1919,7 @@ generic_get_mb_info(struct device_node* node, long param, long value) ...@@ -1919,7 +1919,7 @@ generic_get_mb_info(struct device_node* node, long param, long value)
/* Used on any machine /* Used on any machine
*/ */
static struct feature_table_entry any_features[] __pmacdata = { static struct feature_table_entry any_features[] = {
{ PMAC_FTR_GET_MB_INFO, generic_get_mb_info }, { PMAC_FTR_GET_MB_INFO, generic_get_mb_info },
{ PMAC_FTR_DEVICE_CAN_WAKE, generic_dev_can_wake }, { PMAC_FTR_DEVICE_CAN_WAKE, generic_dev_can_wake },
{ 0, NULL } { 0, NULL }
...@@ -1931,7 +1931,7 @@ static struct feature_table_entry any_features[] __pmacdata = { ...@@ -1931,7 +1931,7 @@ static struct feature_table_entry any_features[] __pmacdata = {
* 2400,3400 and 3500 series powerbooks. Some older desktops seem * 2400,3400 and 3500 series powerbooks. Some older desktops seem
* to have issues with turning on/off those asic cells * to have issues with turning on/off those asic cells
*/ */
static struct feature_table_entry ohare_features[] __pmacdata = { static struct feature_table_entry ohare_features[] = {
{ PMAC_FTR_SCC_ENABLE, ohare_htw_scc_enable }, { PMAC_FTR_SCC_ENABLE, ohare_htw_scc_enable },
{ PMAC_FTR_SWIM3_ENABLE, ohare_floppy_enable }, { PMAC_FTR_SWIM3_ENABLE, ohare_floppy_enable },
{ PMAC_FTR_MESH_ENABLE, ohare_mesh_enable }, { PMAC_FTR_MESH_ENABLE, ohare_mesh_enable },
...@@ -1945,7 +1945,7 @@ static struct feature_table_entry ohare_features[] __pmacdata = { ...@@ -1945,7 +1945,7 @@ static struct feature_table_entry ohare_features[] __pmacdata = {
* Separated as some features couldn't be properly tested * Separated as some features couldn't be properly tested
* and the serial port control bits appear to confuse it. * and the serial port control bits appear to confuse it.
*/ */
static struct feature_table_entry heathrow_desktop_features[] __pmacdata = { static struct feature_table_entry heathrow_desktop_features[] = {
{ PMAC_FTR_SWIM3_ENABLE, heathrow_floppy_enable }, { PMAC_FTR_SWIM3_ENABLE, heathrow_floppy_enable },
{ PMAC_FTR_MESH_ENABLE, heathrow_mesh_enable }, { PMAC_FTR_MESH_ENABLE, heathrow_mesh_enable },
{ PMAC_FTR_IDE_ENABLE, heathrow_ide_enable }, { PMAC_FTR_IDE_ENABLE, heathrow_ide_enable },
...@@ -1957,7 +1957,7 @@ static struct feature_table_entry heathrow_desktop_features[] __pmacdata = { ...@@ -1957,7 +1957,7 @@ static struct feature_table_entry heathrow_desktop_features[] __pmacdata = {
/* Heathrow based laptop, that is the Wallstreet and mainstreet /* Heathrow based laptop, that is the Wallstreet and mainstreet
* powerbooks. * powerbooks.
*/ */
static struct feature_table_entry heathrow_laptop_features[] __pmacdata = { static struct feature_table_entry heathrow_laptop_features[] = {
{ PMAC_FTR_SCC_ENABLE, ohare_htw_scc_enable }, { PMAC_FTR_SCC_ENABLE, ohare_htw_scc_enable },
{ PMAC_FTR_MODEM_ENABLE, heathrow_modem_enable }, { PMAC_FTR_MODEM_ENABLE, heathrow_modem_enable },
{ PMAC_FTR_SWIM3_ENABLE, heathrow_floppy_enable }, { PMAC_FTR_SWIM3_ENABLE, heathrow_floppy_enable },
...@@ -1973,7 +1973,7 @@ static struct feature_table_entry heathrow_laptop_features[] __pmacdata = { ...@@ -1973,7 +1973,7 @@ static struct feature_table_entry heathrow_laptop_features[] __pmacdata = {
/* Paddington based machines /* Paddington based machines
* The lombard (101) powerbook, first iMac models, B&W G3 and Yikes G4. * The lombard (101) powerbook, first iMac models, B&W G3 and Yikes G4.
*/ */
static struct feature_table_entry paddington_features[] __pmacdata = { static struct feature_table_entry paddington_features[] = {
{ PMAC_FTR_SCC_ENABLE, ohare_htw_scc_enable }, { PMAC_FTR_SCC_ENABLE, ohare_htw_scc_enable },
{ PMAC_FTR_MODEM_ENABLE, heathrow_modem_enable }, { PMAC_FTR_MODEM_ENABLE, heathrow_modem_enable },
{ PMAC_FTR_SWIM3_ENABLE, heathrow_floppy_enable }, { PMAC_FTR_SWIM3_ENABLE, heathrow_floppy_enable },
...@@ -1991,7 +1991,7 @@ static struct feature_table_entry paddington_features[] __pmacdata = { ...@@ -1991,7 +1991,7 @@ static struct feature_table_entry paddington_features[] __pmacdata = {
* chipset. The pangea chipset is the "combo" UniNorth/KeyLargo * chipset. The pangea chipset is the "combo" UniNorth/KeyLargo
* used on iBook2 & iMac "flow power". * used on iBook2 & iMac "flow power".
*/ */
static struct feature_table_entry core99_features[] __pmacdata = { static struct feature_table_entry core99_features[] = {
{ PMAC_FTR_SCC_ENABLE, core99_scc_enable }, { PMAC_FTR_SCC_ENABLE, core99_scc_enable },
{ PMAC_FTR_MODEM_ENABLE, core99_modem_enable }, { PMAC_FTR_MODEM_ENABLE, core99_modem_enable },
{ PMAC_FTR_IDE_ENABLE, core99_ide_enable }, { PMAC_FTR_IDE_ENABLE, core99_ide_enable },
...@@ -2014,7 +2014,7 @@ static struct feature_table_entry core99_features[] __pmacdata = { ...@@ -2014,7 +2014,7 @@ static struct feature_table_entry core99_features[] __pmacdata = {
/* RackMac /* RackMac
*/ */
static struct feature_table_entry rackmac_features[] __pmacdata = { static struct feature_table_entry rackmac_features[] = {
{ PMAC_FTR_SCC_ENABLE, core99_scc_enable }, { PMAC_FTR_SCC_ENABLE, core99_scc_enable },
{ PMAC_FTR_IDE_ENABLE, core99_ide_enable }, { PMAC_FTR_IDE_ENABLE, core99_ide_enable },
{ PMAC_FTR_IDE_RESET, core99_ide_reset }, { PMAC_FTR_IDE_RESET, core99_ide_reset },
...@@ -2034,7 +2034,7 @@ static struct feature_table_entry rackmac_features[] __pmacdata = { ...@@ -2034,7 +2034,7 @@ static struct feature_table_entry rackmac_features[] __pmacdata = {
/* Pangea features /* Pangea features
*/ */
static struct feature_table_entry pangea_features[] __pmacdata = { static struct feature_table_entry pangea_features[] = {
{ PMAC_FTR_SCC_ENABLE, core99_scc_enable }, { PMAC_FTR_SCC_ENABLE, core99_scc_enable },
{ PMAC_FTR_MODEM_ENABLE, pangea_modem_enable }, { PMAC_FTR_MODEM_ENABLE, pangea_modem_enable },
{ PMAC_FTR_IDE_ENABLE, core99_ide_enable }, { PMAC_FTR_IDE_ENABLE, core99_ide_enable },
...@@ -2054,7 +2054,7 @@ static struct feature_table_entry pangea_features[] __pmacdata = { ...@@ -2054,7 +2054,7 @@ static struct feature_table_entry pangea_features[] __pmacdata = {
/* Intrepid features /* Intrepid features
*/ */
static struct feature_table_entry intrepid_features[] __pmacdata = { static struct feature_table_entry intrepid_features[] = {
{ PMAC_FTR_SCC_ENABLE, core99_scc_enable }, { PMAC_FTR_SCC_ENABLE, core99_scc_enable },
{ PMAC_FTR_MODEM_ENABLE, pangea_modem_enable }, { PMAC_FTR_MODEM_ENABLE, pangea_modem_enable },
{ PMAC_FTR_IDE_ENABLE, core99_ide_enable }, { PMAC_FTR_IDE_ENABLE, core99_ide_enable },
...@@ -2077,7 +2077,7 @@ static struct feature_table_entry intrepid_features[] __pmacdata = { ...@@ -2077,7 +2077,7 @@ static struct feature_table_entry intrepid_features[] __pmacdata = {
/* G5 features /* G5 features
*/ */
static struct feature_table_entry g5_features[] __pmacdata = { static struct feature_table_entry g5_features[] = {
{ PMAC_FTR_GMAC_ENABLE, g5_gmac_enable }, { PMAC_FTR_GMAC_ENABLE, g5_gmac_enable },
{ PMAC_FTR_1394_ENABLE, g5_fw_enable }, { PMAC_FTR_1394_ENABLE, g5_fw_enable },
{ PMAC_FTR_ENABLE_MPIC, g5_mpic_enable }, { PMAC_FTR_ENABLE_MPIC, g5_mpic_enable },
...@@ -2091,7 +2091,7 @@ static struct feature_table_entry g5_features[] __pmacdata = { ...@@ -2091,7 +2091,7 @@ static struct feature_table_entry g5_features[] __pmacdata = {
#endif /* CONFIG_POWER4 */ #endif /* CONFIG_POWER4 */
static struct pmac_mb_def pmac_mb_defs[] __pmacdata = { static struct pmac_mb_def pmac_mb_defs[] = {
#ifndef CONFIG_POWER4 #ifndef CONFIG_POWER4
/* /*
* Desktops * Desktops
...@@ -2352,7 +2352,7 @@ static struct pmac_mb_def pmac_mb_defs[] __pmacdata = { ...@@ -2352,7 +2352,7 @@ static struct pmac_mb_def pmac_mb_defs[] __pmacdata = {
/* /*
* The toplevel feature_call callback * The toplevel feature_call callback
*/ */
long __pmac long
pmac_do_feature_call(unsigned int selector, ...) pmac_do_feature_call(unsigned int selector, ...)
{ {
struct device_node* node; struct device_node* node;
...@@ -2935,8 +2935,8 @@ void __init pmac_check_ht_link(void) ...@@ -2935,8 +2935,8 @@ void __init pmac_check_ht_link(void)
* Early video resume hook * Early video resume hook
*/ */
static void (*pmac_early_vresume_proc)(void *data) __pmacdata; static void (*pmac_early_vresume_proc)(void *data);
static void *pmac_early_vresume_data __pmacdata; static void *pmac_early_vresume_data;
void pmac_set_early_video_resume(void (*proc)(void *data), void *data) void pmac_set_early_video_resume(void (*proc)(void *data), void *data)
{ {
...@@ -2949,7 +2949,7 @@ void pmac_set_early_video_resume(void (*proc)(void *data), void *data) ...@@ -2949,7 +2949,7 @@ void pmac_set_early_video_resume(void (*proc)(void *data), void *data)
} }
EXPORT_SYMBOL(pmac_set_early_video_resume); EXPORT_SYMBOL(pmac_set_early_video_resume);
void __pmac pmac_call_early_video_resume(void) void pmac_call_early_video_resume(void)
{ {
if (pmac_early_vresume_proc) if (pmac_early_vresume_proc)
pmac_early_vresume_proc(pmac_early_vresume_data); pmac_early_vresume_proc(pmac_early_vresume_data);
...@@ -2959,11 +2959,11 @@ void __pmac pmac_call_early_video_resume(void) ...@@ -2959,11 +2959,11 @@ void __pmac pmac_call_early_video_resume(void)
* AGP related suspend/resume code * AGP related suspend/resume code
*/ */
static struct pci_dev *pmac_agp_bridge __pmacdata; static struct pci_dev *pmac_agp_bridge;
static int (*pmac_agp_suspend)(struct pci_dev *bridge) __pmacdata; static int (*pmac_agp_suspend)(struct pci_dev *bridge);
static int (*pmac_agp_resume)(struct pci_dev *bridge) __pmacdata; static int (*pmac_agp_resume)(struct pci_dev *bridge);
void __pmac pmac_register_agp_pm(struct pci_dev *bridge, void pmac_register_agp_pm(struct pci_dev *bridge,
int (*suspend)(struct pci_dev *bridge), int (*suspend)(struct pci_dev *bridge),
int (*resume)(struct pci_dev *bridge)) int (*resume)(struct pci_dev *bridge))
{ {
...@@ -2980,7 +2980,7 @@ void __pmac pmac_register_agp_pm(struct pci_dev *bridge, ...@@ -2980,7 +2980,7 @@ void __pmac pmac_register_agp_pm(struct pci_dev *bridge,
} }
EXPORT_SYMBOL(pmac_register_agp_pm); EXPORT_SYMBOL(pmac_register_agp_pm);
void __pmac pmac_suspend_agp_for_card(struct pci_dev *dev) void pmac_suspend_agp_for_card(struct pci_dev *dev)
{ {
if (pmac_agp_bridge == NULL || pmac_agp_suspend == NULL) if (pmac_agp_bridge == NULL || pmac_agp_suspend == NULL)
return; return;
...@@ -2990,7 +2990,7 @@ void __pmac pmac_suspend_agp_for_card(struct pci_dev *dev) ...@@ -2990,7 +2990,7 @@ void __pmac pmac_suspend_agp_for_card(struct pci_dev *dev)
} }
EXPORT_SYMBOL(pmac_suspend_agp_for_card); EXPORT_SYMBOL(pmac_suspend_agp_for_card);
void __pmac pmac_resume_agp_for_card(struct pci_dev *dev) void pmac_resume_agp_for_card(struct pci_dev *dev)
{ {
if (pmac_agp_bridge == NULL || pmac_agp_resume == NULL) if (pmac_agp_bridge == NULL || pmac_agp_resume == NULL)
return; return;
......
...@@ -88,17 +88,17 @@ extern int system_running; ...@@ -88,17 +88,17 @@ extern int system_running;
static int (*core99_write_bank)(int bank, u8* datas); static int (*core99_write_bank)(int bank, u8* datas);
static int (*core99_erase_bank)(int bank); static int (*core99_erase_bank)(int bank);
static char *nvram_image __pmacdata; static char *nvram_image;
static unsigned char __pmac core99_nvram_read_byte(int addr) static unsigned char core99_nvram_read_byte(int addr)
{ {
if (nvram_image == NULL) if (nvram_image == NULL)
return 0xff; return 0xff;
return nvram_image[addr]; return nvram_image[addr];
} }
static void __pmac core99_nvram_write_byte(int addr, unsigned char val) static void core99_nvram_write_byte(int addr, unsigned char val)
{ {
if (nvram_image == NULL) if (nvram_image == NULL)
return; return;
...@@ -106,18 +106,18 @@ static void __pmac core99_nvram_write_byte(int addr, unsigned char val) ...@@ -106,18 +106,18 @@ static void __pmac core99_nvram_write_byte(int addr, unsigned char val)
} }
static unsigned char __openfirmware direct_nvram_read_byte(int addr) static unsigned char direct_nvram_read_byte(int addr)
{ {
return in_8(&nvram_data[(addr & (NVRAM_SIZE - 1)) * nvram_mult]); return in_8(&nvram_data[(addr & (NVRAM_SIZE - 1)) * nvram_mult]);
} }
static void __openfirmware direct_nvram_write_byte(int addr, unsigned char val) static void direct_nvram_write_byte(int addr, unsigned char val)
{ {
out_8(&nvram_data[(addr & (NVRAM_SIZE - 1)) * nvram_mult], val); out_8(&nvram_data[(addr & (NVRAM_SIZE - 1)) * nvram_mult], val);
} }
static unsigned char __pmac indirect_nvram_read_byte(int addr) static unsigned char indirect_nvram_read_byte(int addr)
{ {
unsigned char val; unsigned char val;
unsigned long flags; unsigned long flags;
...@@ -130,7 +130,7 @@ static unsigned char __pmac indirect_nvram_read_byte(int addr) ...@@ -130,7 +130,7 @@ static unsigned char __pmac indirect_nvram_read_byte(int addr)
return val; return val;
} }
static void __pmac indirect_nvram_write_byte(int addr, unsigned char val) static void indirect_nvram_write_byte(int addr, unsigned char val)
{ {
unsigned long flags; unsigned long flags;
...@@ -143,13 +143,13 @@ static void __pmac indirect_nvram_write_byte(int addr, unsigned char val) ...@@ -143,13 +143,13 @@ static void __pmac indirect_nvram_write_byte(int addr, unsigned char val)
#ifdef CONFIG_ADB_PMU #ifdef CONFIG_ADB_PMU
static void __pmac pmu_nvram_complete(struct adb_request *req) static void pmu_nvram_complete(struct adb_request *req)
{ {
if (req->arg) if (req->arg)
complete((struct completion *)req->arg); complete((struct completion *)req->arg);
} }
static unsigned char __pmac pmu_nvram_read_byte(int addr) static unsigned char pmu_nvram_read_byte(int addr)
{ {
struct adb_request req; struct adb_request req;
DECLARE_COMPLETION(req_complete); DECLARE_COMPLETION(req_complete);
...@@ -165,7 +165,7 @@ static unsigned char __pmac pmu_nvram_read_byte(int addr) ...@@ -165,7 +165,7 @@ static unsigned char __pmac pmu_nvram_read_byte(int addr)
return req.reply[0]; return req.reply[0];
} }
static void __pmac pmu_nvram_write_byte(int addr, unsigned char val) static void pmu_nvram_write_byte(int addr, unsigned char val)
{ {
struct adb_request req; struct adb_request req;
DECLARE_COMPLETION(req_complete); DECLARE_COMPLETION(req_complete);
...@@ -183,7 +183,7 @@ static void __pmac pmu_nvram_write_byte(int addr, unsigned char val) ...@@ -183,7 +183,7 @@ static void __pmac pmu_nvram_write_byte(int addr, unsigned char val)
#endif /* CONFIG_ADB_PMU */ #endif /* CONFIG_ADB_PMU */
static u8 __pmac chrp_checksum(struct chrp_header* hdr) static u8 chrp_checksum(struct chrp_header* hdr)
{ {
u8 *ptr; u8 *ptr;
u16 sum = hdr->signature; u16 sum = hdr->signature;
...@@ -194,7 +194,7 @@ static u8 __pmac chrp_checksum(struct chrp_header* hdr) ...@@ -194,7 +194,7 @@ static u8 __pmac chrp_checksum(struct chrp_header* hdr)
return sum; return sum;
} }
static u32 __pmac core99_calc_adler(u8 *buffer) static u32 core99_calc_adler(u8 *buffer)
{ {
int cnt; int cnt;
u32 low, high; u32 low, high;
...@@ -216,7 +216,7 @@ static u32 __pmac core99_calc_adler(u8 *buffer) ...@@ -216,7 +216,7 @@ static u32 __pmac core99_calc_adler(u8 *buffer)
return (high << 16) | low; return (high << 16) | low;
} }
static u32 __pmac core99_check(u8* datas) static u32 core99_check(u8* datas)
{ {
struct core99_header* hdr99 = (struct core99_header*)datas; struct core99_header* hdr99 = (struct core99_header*)datas;
...@@ -235,7 +235,7 @@ static u32 __pmac core99_check(u8* datas) ...@@ -235,7 +235,7 @@ static u32 __pmac core99_check(u8* datas)
return hdr99->generation; return hdr99->generation;
} }
static int __pmac sm_erase_bank(int bank) static int sm_erase_bank(int bank)
{ {
int stat, i; int stat, i;
unsigned long timeout; unsigned long timeout;
...@@ -267,7 +267,7 @@ static int __pmac sm_erase_bank(int bank) ...@@ -267,7 +267,7 @@ static int __pmac sm_erase_bank(int bank)
return 0; return 0;
} }
static int __pmac sm_write_bank(int bank, u8* datas) static int sm_write_bank(int bank, u8* datas)
{ {
int i, stat = 0; int i, stat = 0;
unsigned long timeout; unsigned long timeout;
...@@ -302,7 +302,7 @@ static int __pmac sm_write_bank(int bank, u8* datas) ...@@ -302,7 +302,7 @@ static int __pmac sm_write_bank(int bank, u8* datas)
return 0; return 0;
} }
static int __pmac amd_erase_bank(int bank) static int amd_erase_bank(int bank)
{ {
int i, stat = 0; int i, stat = 0;
unsigned long timeout; unsigned long timeout;
...@@ -349,7 +349,7 @@ static int __pmac amd_erase_bank(int bank) ...@@ -349,7 +349,7 @@ static int __pmac amd_erase_bank(int bank)
return 0; return 0;
} }
static int __pmac amd_write_bank(int bank, u8* datas) static int amd_write_bank(int bank, u8* datas)
{ {
int i, stat = 0; int i, stat = 0;
unsigned long timeout; unsigned long timeout;
...@@ -430,7 +430,7 @@ static void __init lookup_partitions(void) ...@@ -430,7 +430,7 @@ static void __init lookup_partitions(void)
DBG("nvram: NR partition at 0x%x\n", nvram_partitions[pmac_nvram_NR]); DBG("nvram: NR partition at 0x%x\n", nvram_partitions[pmac_nvram_NR]);
} }
static void __pmac core99_nvram_sync(void) static void core99_nvram_sync(void)
{ {
struct core99_header* hdr99; struct core99_header* hdr99;
unsigned long flags; unsigned long flags;
...@@ -554,12 +554,12 @@ void __init pmac_nvram_init(void) ...@@ -554,12 +554,12 @@ void __init pmac_nvram_init(void)
lookup_partitions(); lookup_partitions();
} }
int __pmac pmac_get_partition(int partition) int pmac_get_partition(int partition)
{ {
return nvram_partitions[partition]; return nvram_partitions[partition];
} }
u8 __pmac pmac_xpram_read(int xpaddr) u8 pmac_xpram_read(int xpaddr)
{ {
int offset = nvram_partitions[pmac_nvram_XPRAM]; int offset = nvram_partitions[pmac_nvram_XPRAM];
...@@ -569,7 +569,7 @@ u8 __pmac pmac_xpram_read(int xpaddr) ...@@ -569,7 +569,7 @@ u8 __pmac pmac_xpram_read(int xpaddr)
return ppc_md.nvram_read_val(xpaddr + offset); return ppc_md.nvram_read_val(xpaddr + offset);
} }
void __pmac pmac_xpram_write(int xpaddr, u8 data) void pmac_xpram_write(int xpaddr, u8 data)
{ {
int offset = nvram_partitions[pmac_nvram_XPRAM]; int offset = nvram_partitions[pmac_nvram_XPRAM];
......
...@@ -141,7 +141,7 @@ fixup_bus_range(struct device_node *bridge) ...@@ -141,7 +141,7 @@ fixup_bus_range(struct device_node *bridge)
|(((unsigned long)(off)) & 0xFCUL) \ |(((unsigned long)(off)) & 0xFCUL) \
|1UL) |1UL)
static void volatile __iomem * __pmac static void volatile __iomem *
macrisc_cfg_access(struct pci_controller* hose, u8 bus, u8 dev_fn, u8 offset) macrisc_cfg_access(struct pci_controller* hose, u8 bus, u8 dev_fn, u8 offset)
{ {
unsigned int caddr; unsigned int caddr;
...@@ -162,7 +162,7 @@ macrisc_cfg_access(struct pci_controller* hose, u8 bus, u8 dev_fn, u8 offset) ...@@ -162,7 +162,7 @@ macrisc_cfg_access(struct pci_controller* hose, u8 bus, u8 dev_fn, u8 offset)
return hose->cfg_data + offset; return hose->cfg_data + offset;
} }
static int __pmac static int
macrisc_read_config(struct pci_bus *bus, unsigned int devfn, int offset, macrisc_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 *val) int len, u32 *val)
{ {
...@@ -190,7 +190,7 @@ macrisc_read_config(struct pci_bus *bus, unsigned int devfn, int offset, ...@@ -190,7 +190,7 @@ macrisc_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
return PCIBIOS_SUCCESSFUL; return PCIBIOS_SUCCESSFUL;
} }
static int __pmac static int
macrisc_write_config(struct pci_bus *bus, unsigned int devfn, int offset, macrisc_write_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 val) int len, u32 val)
{ {
...@@ -230,7 +230,7 @@ static struct pci_ops macrisc_pci_ops = ...@@ -230,7 +230,7 @@ static struct pci_ops macrisc_pci_ops =
/* /*
* Verifiy that a specific (bus, dev_fn) exists on chaos * Verifiy that a specific (bus, dev_fn) exists on chaos
*/ */
static int __pmac static int
chaos_validate_dev(struct pci_bus *bus, int devfn, int offset) chaos_validate_dev(struct pci_bus *bus, int devfn, int offset)
{ {
struct device_node *np; struct device_node *np;
...@@ -252,7 +252,7 @@ chaos_validate_dev(struct pci_bus *bus, int devfn, int offset) ...@@ -252,7 +252,7 @@ chaos_validate_dev(struct pci_bus *bus, int devfn, int offset)
return PCIBIOS_SUCCESSFUL; return PCIBIOS_SUCCESSFUL;
} }
static int __pmac static int
chaos_read_config(struct pci_bus *bus, unsigned int devfn, int offset, chaos_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 *val) int len, u32 *val)
{ {
...@@ -264,7 +264,7 @@ chaos_read_config(struct pci_bus *bus, unsigned int devfn, int offset, ...@@ -264,7 +264,7 @@ chaos_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
return macrisc_read_config(bus, devfn, offset, len, val); return macrisc_read_config(bus, devfn, offset, len, val);
} }
static int __pmac static int
chaos_write_config(struct pci_bus *bus, unsigned int devfn, int offset, chaos_write_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 val) int len, u32 val)
{ {
...@@ -294,7 +294,7 @@ static struct pci_ops chaos_pci_ops = ...@@ -294,7 +294,7 @@ static struct pci_ops chaos_pci_ops =
+ (((unsigned long)bus) << 16) \ + (((unsigned long)bus) << 16) \
+ 0x01000000UL) + 0x01000000UL)
static void volatile __iomem * __pmac static void volatile __iomem *
u3_ht_cfg_access(struct pci_controller* hose, u8 bus, u8 devfn, u8 offset) u3_ht_cfg_access(struct pci_controller* hose, u8 bus, u8 devfn, u8 offset)
{ {
if (bus == hose->first_busno) { if (bus == hose->first_busno) {
...@@ -307,7 +307,7 @@ u3_ht_cfg_access(struct pci_controller* hose, u8 bus, u8 devfn, u8 offset) ...@@ -307,7 +307,7 @@ u3_ht_cfg_access(struct pci_controller* hose, u8 bus, u8 devfn, u8 offset)
return hose->cfg_data + U3_HT_CFA1(bus, devfn, offset); return hose->cfg_data + U3_HT_CFA1(bus, devfn, offset);
} }
static int __pmac static int
u3_ht_read_config(struct pci_bus *bus, unsigned int devfn, int offset, u3_ht_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 *val) int len, u32 *val)
{ {
...@@ -357,7 +357,7 @@ u3_ht_read_config(struct pci_bus *bus, unsigned int devfn, int offset, ...@@ -357,7 +357,7 @@ u3_ht_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
return PCIBIOS_SUCCESSFUL; return PCIBIOS_SUCCESSFUL;
} }
static int __pmac static int
u3_ht_write_config(struct pci_bus *bus, unsigned int devfn, int offset, u3_ht_write_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 val) int len, u32 val)
{ {
...@@ -899,7 +899,7 @@ pmac_pcibios_fixup(void) ...@@ -899,7 +899,7 @@ pmac_pcibios_fixup(void)
pcibios_fixup_OF_interrupts(); pcibios_fixup_OF_interrupts();
} }
int __pmac int
pmac_pci_enable_device_hook(struct pci_dev *dev, int initial) pmac_pci_enable_device_hook(struct pci_dev *dev, int initial)
{ {
struct device_node* node; struct device_node* node;
...@@ -1096,7 +1096,7 @@ DECLARE_PCI_FIXUP_FINAL(PCI_ANY_ID, PCI_ANY_ID, pmac_pci_fixup_pciata); ...@@ -1096,7 +1096,7 @@ DECLARE_PCI_FIXUP_FINAL(PCI_ANY_ID, PCI_ANY_ID, pmac_pci_fixup_pciata);
* Disable second function on K2-SATA, it's broken * Disable second function on K2-SATA, it's broken
* and disable IO BARs on first one * and disable IO BARs on first one
*/ */
void __pmac pmac_pci_fixup_k2_sata(struct pci_dev* dev) void pmac_pci_fixup_k2_sata(struct pci_dev* dev)
{ {
int i; int i;
u16 cmd; u16 cmd;
......
...@@ -53,7 +53,7 @@ struct pmac_irq_hw { ...@@ -53,7 +53,7 @@ struct pmac_irq_hw {
}; };
/* Default addresses */ /* Default addresses */
static volatile struct pmac_irq_hw *pmac_irq_hw[4] __pmacdata = { static volatile struct pmac_irq_hw *pmac_irq_hw[4] = {
(struct pmac_irq_hw *) 0xf3000020, (struct pmac_irq_hw *) 0xf3000020,
(struct pmac_irq_hw *) 0xf3000010, (struct pmac_irq_hw *) 0xf3000010,
(struct pmac_irq_hw *) 0xf4000020, (struct pmac_irq_hw *) 0xf4000020,
...@@ -64,22 +64,22 @@ static volatile struct pmac_irq_hw *pmac_irq_hw[4] __pmacdata = { ...@@ -64,22 +64,22 @@ static volatile struct pmac_irq_hw *pmac_irq_hw[4] __pmacdata = {
#define OHARE_LEVEL_MASK 0x1ff00000 #define OHARE_LEVEL_MASK 0x1ff00000
#define HEATHROW_LEVEL_MASK 0x1ff00000 #define HEATHROW_LEVEL_MASK 0x1ff00000
static int max_irqs __pmacdata; static int max_irqs;
static int max_real_irqs __pmacdata; static int max_real_irqs;
static u32 level_mask[4] __pmacdata; static u32 level_mask[4];
static DEFINE_SPINLOCK(pmac_pic_lock __pmacdata); static DEFINE_SPINLOCK(pmac_pic_lock);
#define GATWICK_IRQ_POOL_SIZE 10 #define GATWICK_IRQ_POOL_SIZE 10
static struct interrupt_info gatwick_int_pool[GATWICK_IRQ_POOL_SIZE] __pmacdata; static struct interrupt_info gatwick_int_pool[GATWICK_IRQ_POOL_SIZE];
/* /*
* Mark an irq as "lost". This is only used on the pmac * Mark an irq as "lost". This is only used on the pmac
* since it can lose interrupts (see pmac_set_irq_mask). * since it can lose interrupts (see pmac_set_irq_mask).
* -- Cort * -- Cort
*/ */
void __pmac void
__set_lost(unsigned long irq_nr, int nokick) __set_lost(unsigned long irq_nr, int nokick)
{ {
if (!test_and_set_bit(irq_nr, ppc_lost_interrupts)) { if (!test_and_set_bit(irq_nr, ppc_lost_interrupts)) {
...@@ -89,7 +89,7 @@ __set_lost(unsigned long irq_nr, int nokick) ...@@ -89,7 +89,7 @@ __set_lost(unsigned long irq_nr, int nokick)
} }
} }
static void __pmac static void
pmac_mask_and_ack_irq(unsigned int irq_nr) pmac_mask_and_ack_irq(unsigned int irq_nr)
{ {
unsigned long bit = 1UL << (irq_nr & 0x1f); unsigned long bit = 1UL << (irq_nr & 0x1f);
...@@ -114,7 +114,7 @@ pmac_mask_and_ack_irq(unsigned int irq_nr) ...@@ -114,7 +114,7 @@ pmac_mask_and_ack_irq(unsigned int irq_nr)
spin_unlock_irqrestore(&pmac_pic_lock, flags); spin_unlock_irqrestore(&pmac_pic_lock, flags);
} }
static void __pmac pmac_set_irq_mask(unsigned int irq_nr, int nokicklost) static void pmac_set_irq_mask(unsigned int irq_nr, int nokicklost)
{ {
unsigned long bit = 1UL << (irq_nr & 0x1f); unsigned long bit = 1UL << (irq_nr & 0x1f);
int i = irq_nr >> 5; int i = irq_nr >> 5;
...@@ -147,7 +147,7 @@ static void __pmac pmac_set_irq_mask(unsigned int irq_nr, int nokicklost) ...@@ -147,7 +147,7 @@ static void __pmac pmac_set_irq_mask(unsigned int irq_nr, int nokicklost)
/* When an irq gets requested for the first client, if it's an /* When an irq gets requested for the first client, if it's an
* edge interrupt, we clear any previous one on the controller * edge interrupt, we clear any previous one on the controller
*/ */
static unsigned int __pmac pmac_startup_irq(unsigned int irq_nr) static unsigned int pmac_startup_irq(unsigned int irq_nr)
{ {
unsigned long bit = 1UL << (irq_nr & 0x1f); unsigned long bit = 1UL << (irq_nr & 0x1f);
int i = irq_nr >> 5; int i = irq_nr >> 5;
...@@ -160,20 +160,20 @@ static unsigned int __pmac pmac_startup_irq(unsigned int irq_nr) ...@@ -160,20 +160,20 @@ static unsigned int __pmac pmac_startup_irq(unsigned int irq_nr)
return 0; return 0;
} }
static void __pmac pmac_mask_irq(unsigned int irq_nr) static void pmac_mask_irq(unsigned int irq_nr)
{ {
clear_bit(irq_nr, ppc_cached_irq_mask); clear_bit(irq_nr, ppc_cached_irq_mask);
pmac_set_irq_mask(irq_nr, 0); pmac_set_irq_mask(irq_nr, 0);
mb(); mb();
} }
static void __pmac pmac_unmask_irq(unsigned int irq_nr) static void pmac_unmask_irq(unsigned int irq_nr)
{ {
set_bit(irq_nr, ppc_cached_irq_mask); set_bit(irq_nr, ppc_cached_irq_mask);
pmac_set_irq_mask(irq_nr, 0); pmac_set_irq_mask(irq_nr, 0);
} }
static void __pmac pmac_end_irq(unsigned int irq_nr) static void pmac_end_irq(unsigned int irq_nr)
{ {
if (!(irq_desc[irq_nr].status & (IRQ_DISABLED|IRQ_INPROGRESS)) if (!(irq_desc[irq_nr].status & (IRQ_DISABLED|IRQ_INPROGRESS))
&& irq_desc[irq_nr].action) { && irq_desc[irq_nr].action) {
......
...@@ -123,7 +123,7 @@ extern struct smp_ops_t psurge_smp_ops; ...@@ -123,7 +123,7 @@ extern struct smp_ops_t psurge_smp_ops;
extern struct smp_ops_t core99_smp_ops; extern struct smp_ops_t core99_smp_ops;
#endif /* CONFIG_SMP */ #endif /* CONFIG_SMP */
static int __pmac static int
pmac_show_cpuinfo(struct seq_file *m) pmac_show_cpuinfo(struct seq_file *m)
{ {
struct device_node *np; struct device_node *np;
...@@ -227,7 +227,7 @@ pmac_show_cpuinfo(struct seq_file *m) ...@@ -227,7 +227,7 @@ pmac_show_cpuinfo(struct seq_file *m)
return 0; return 0;
} }
static int __openfirmware static int
pmac_show_percpuinfo(struct seq_file *m, int i) pmac_show_percpuinfo(struct seq_file *m, int i)
{ {
#ifdef CONFIG_CPU_FREQ_PMAC #ifdef CONFIG_CPU_FREQ_PMAC
...@@ -486,7 +486,7 @@ static int pmac_late_init(void) ...@@ -486,7 +486,7 @@ static int pmac_late_init(void)
late_initcall(pmac_late_init); late_initcall(pmac_late_init);
/* can't be __init - can be called whenever a disk is first accessed */ /* can't be __init - can be called whenever a disk is first accessed */
void __pmac void
note_bootable_part(dev_t dev, int part, int goodness) note_bootable_part(dev_t dev, int part, int goodness)
{ {
static int found_boot = 0; static int found_boot = 0;
...@@ -512,7 +512,7 @@ note_bootable_part(dev_t dev, int part, int goodness) ...@@ -512,7 +512,7 @@ note_bootable_part(dev_t dev, int part, int goodness)
} }
} }
static void __pmac static void
pmac_restart(char *cmd) pmac_restart(char *cmd)
{ {
#ifdef CONFIG_ADB_CUDA #ifdef CONFIG_ADB_CUDA
...@@ -537,7 +537,7 @@ pmac_restart(char *cmd) ...@@ -537,7 +537,7 @@ pmac_restart(char *cmd)
} }
} }
static void __pmac static void
pmac_power_off(void) pmac_power_off(void)
{ {
#ifdef CONFIG_ADB_CUDA #ifdef CONFIG_ADB_CUDA
...@@ -562,7 +562,7 @@ pmac_power_off(void) ...@@ -562,7 +562,7 @@ pmac_power_off(void)
} }
} }
static void __pmac static void
pmac_halt(void) pmac_halt(void)
{ {
pmac_power_off(); pmac_power_off();
......
...@@ -186,7 +186,7 @@ static inline void psurge_clr_ipi(int cpu) ...@@ -186,7 +186,7 @@ static inline void psurge_clr_ipi(int cpu)
*/ */
static unsigned long psurge_smp_message[NR_CPUS]; static unsigned long psurge_smp_message[NR_CPUS];
void __pmac psurge_smp_message_recv(struct pt_regs *regs) void psurge_smp_message_recv(struct pt_regs *regs)
{ {
int cpu = smp_processor_id(); int cpu = smp_processor_id();
int msg; int msg;
...@@ -203,13 +203,13 @@ void __pmac psurge_smp_message_recv(struct pt_regs *regs) ...@@ -203,13 +203,13 @@ void __pmac psurge_smp_message_recv(struct pt_regs *regs)
smp_message_recv(msg, regs); smp_message_recv(msg, regs);
} }
irqreturn_t __pmac psurge_primary_intr(int irq, void *d, struct pt_regs *regs) irqreturn_t psurge_primary_intr(int irq, void *d, struct pt_regs *regs)
{ {
psurge_smp_message_recv(regs); psurge_smp_message_recv(regs);
return IRQ_HANDLED; return IRQ_HANDLED;
} }
static void __pmac smp_psurge_message_pass(int target, int msg, unsigned long data, static void smp_psurge_message_pass(int target, int msg, unsigned long data,
int wait) int wait)
{ {
int i; int i;
...@@ -629,7 +629,7 @@ void smp_core99_give_timebase(void) ...@@ -629,7 +629,7 @@ void smp_core99_give_timebase(void)
/* PowerSurge-style Macs */ /* PowerSurge-style Macs */
struct smp_ops_t psurge_smp_ops __pmacdata = { struct smp_ops_t psurge_smp_ops = {
.message_pass = smp_psurge_message_pass, .message_pass = smp_psurge_message_pass,
.probe = smp_psurge_probe, .probe = smp_psurge_probe,
.kick_cpu = smp_psurge_kick_cpu, .kick_cpu = smp_psurge_kick_cpu,
...@@ -639,7 +639,7 @@ struct smp_ops_t psurge_smp_ops __pmacdata = { ...@@ -639,7 +639,7 @@ struct smp_ops_t psurge_smp_ops __pmacdata = {
}; };
/* Core99 Macs (dual G4s) */ /* Core99 Macs (dual G4s) */
struct smp_ops_t core99_smp_ops __pmacdata = { struct smp_ops_t core99_smp_ops = {
.message_pass = smp_openpic_message_pass, .message_pass = smp_openpic_message_pass,
.probe = smp_core99_probe, .probe = smp_core99_probe,
.kick_cpu = smp_core99_kick_cpu, .kick_cpu = smp_core99_kick_cpu,
......
...@@ -77,7 +77,7 @@ pmac_time_init(void) ...@@ -77,7 +77,7 @@ pmac_time_init(void)
#endif #endif
} }
unsigned long __pmac unsigned long
pmac_get_rtc_time(void) pmac_get_rtc_time(void)
{ {
#if defined(CONFIG_ADB_CUDA) || defined(CONFIG_ADB_PMU) #if defined(CONFIG_ADB_CUDA) || defined(CONFIG_ADB_PMU)
...@@ -118,7 +118,7 @@ pmac_get_rtc_time(void) ...@@ -118,7 +118,7 @@ pmac_get_rtc_time(void)
return 0; return 0;
} }
int __pmac int
pmac_set_rtc_time(unsigned long nowtime) pmac_set_rtc_time(unsigned long nowtime)
{ {
#if defined(CONFIG_ADB_CUDA) || defined(CONFIG_ADB_PMU) #if defined(CONFIG_ADB_CUDA) || defined(CONFIG_ADB_PMU)
...@@ -210,7 +210,7 @@ via_calibrate_decr(void) ...@@ -210,7 +210,7 @@ via_calibrate_decr(void)
/* /*
* Reset the time after a sleep. * Reset the time after a sleep.
*/ */
static int __pmac static int
time_sleep_notify(struct pmu_sleep_notifier *self, int when) time_sleep_notify(struct pmu_sleep_notifier *self, int when)
{ {
static unsigned long time_diff; static unsigned long time_diff;
...@@ -235,7 +235,7 @@ time_sleep_notify(struct pmu_sleep_notifier *self, int when) ...@@ -235,7 +235,7 @@ time_sleep_notify(struct pmu_sleep_notifier *self, int when)
return PBOOK_SLEEP_OK; return PBOOK_SLEEP_OK;
} }
static struct pmu_sleep_notifier time_sleep_notifier __pmacdata = { static struct pmu_sleep_notifier time_sleep_notifier = {
time_sleep_notify, SLEEP_LEVEL_MISC, time_sleep_notify, SLEEP_LEVEL_MISC,
}; };
#endif /* CONFIG_PM */ #endif /* CONFIG_PM */
......
...@@ -43,7 +43,7 @@ static unsigned long *ProcInfo; ...@@ -43,7 +43,7 @@ static unsigned long *ProcInfo;
/* Tables for known hardware */ /* Tables for known hardware */
/* Motorola PowerStackII - Utah */ /* Motorola PowerStackII - Utah */
static char Utah_pci_IRQ_map[23] __prepdata = static char Utah_pci_IRQ_map[23] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -72,7 +72,7 @@ static char Utah_pci_IRQ_map[23] __prepdata = ...@@ -72,7 +72,7 @@ static char Utah_pci_IRQ_map[23] __prepdata =
0, /* Slot 22 - unused */ 0, /* Slot 22 - unused */
}; };
static char Utah_pci_IRQ_routes[] __prepdata = static char Utah_pci_IRQ_routes[] =
{ {
0, /* Line 0 - Unused */ 0, /* Line 0 - Unused */
9, /* Line 1 */ 9, /* Line 1 */
...@@ -84,7 +84,7 @@ static char Utah_pci_IRQ_routes[] __prepdata = ...@@ -84,7 +84,7 @@ static char Utah_pci_IRQ_routes[] __prepdata =
/* Motorola PowerStackII - Omaha */ /* Motorola PowerStackII - Omaha */
/* no integrated SCSI or ethernet */ /* no integrated SCSI or ethernet */
static char Omaha_pci_IRQ_map[23] __prepdata = static char Omaha_pci_IRQ_map[23] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -111,7 +111,7 @@ static char Omaha_pci_IRQ_map[23] __prepdata = ...@@ -111,7 +111,7 @@ static char Omaha_pci_IRQ_map[23] __prepdata =
0, 0,
}; };
static char Omaha_pci_IRQ_routes[] __prepdata = static char Omaha_pci_IRQ_routes[] =
{ {
0, /* Line 0 - Unused */ 0, /* Line 0 - Unused */
9, /* Line 1 */ 9, /* Line 1 */
...@@ -121,7 +121,7 @@ static char Omaha_pci_IRQ_routes[] __prepdata = ...@@ -121,7 +121,7 @@ static char Omaha_pci_IRQ_routes[] __prepdata =
}; };
/* Motorola PowerStack */ /* Motorola PowerStack */
static char Blackhawk_pci_IRQ_map[19] __prepdata = static char Blackhawk_pci_IRQ_map[19] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -144,7 +144,7 @@ static char Blackhawk_pci_IRQ_map[19] __prepdata = ...@@ -144,7 +144,7 @@ static char Blackhawk_pci_IRQ_map[19] __prepdata =
3, /* Slot P5 */ 3, /* Slot P5 */
}; };
static char Blackhawk_pci_IRQ_routes[] __prepdata = static char Blackhawk_pci_IRQ_routes[] =
{ {
0, /* Line 0 - Unused */ 0, /* Line 0 - Unused */
9, /* Line 1 */ 9, /* Line 1 */
...@@ -154,7 +154,7 @@ static char Blackhawk_pci_IRQ_routes[] __prepdata = ...@@ -154,7 +154,7 @@ static char Blackhawk_pci_IRQ_routes[] __prepdata =
}; };
/* Motorola Mesquite */ /* Motorola Mesquite */
static char Mesquite_pci_IRQ_map[23] __prepdata = static char Mesquite_pci_IRQ_map[23] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -182,7 +182,7 @@ static char Mesquite_pci_IRQ_map[23] __prepdata = ...@@ -182,7 +182,7 @@ static char Mesquite_pci_IRQ_map[23] __prepdata =
}; };
/* Motorola Sitka */ /* Motorola Sitka */
static char Sitka_pci_IRQ_map[21] __prepdata = static char Sitka_pci_IRQ_map[21] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -208,7 +208,7 @@ static char Sitka_pci_IRQ_map[21] __prepdata = ...@@ -208,7 +208,7 @@ static char Sitka_pci_IRQ_map[21] __prepdata =
}; };
/* Motorola MTX */ /* Motorola MTX */
static char MTX_pci_IRQ_map[23] __prepdata = static char MTX_pci_IRQ_map[23] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -237,7 +237,7 @@ static char MTX_pci_IRQ_map[23] __prepdata = ...@@ -237,7 +237,7 @@ static char MTX_pci_IRQ_map[23] __prepdata =
/* Motorola MTX Plus */ /* Motorola MTX Plus */
/* Secondary bus interrupt routing is not supported yet */ /* Secondary bus interrupt routing is not supported yet */
static char MTXplus_pci_IRQ_map[23] __prepdata = static char MTXplus_pci_IRQ_map[23] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -264,13 +264,13 @@ static char MTXplus_pci_IRQ_map[23] __prepdata = ...@@ -264,13 +264,13 @@ static char MTXplus_pci_IRQ_map[23] __prepdata =
0, /* Slot 22 - unused */ 0, /* Slot 22 - unused */
}; };
static char Raven_pci_IRQ_routes[] __prepdata = static char Raven_pci_IRQ_routes[] =
{ {
0, /* This is a dummy structure */ 0, /* This is a dummy structure */
}; };
/* Motorola MVME16xx */ /* Motorola MVME16xx */
static char Genesis_pci_IRQ_map[16] __prepdata = static char Genesis_pci_IRQ_map[16] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -290,7 +290,7 @@ static char Genesis_pci_IRQ_map[16] __prepdata = ...@@ -290,7 +290,7 @@ static char Genesis_pci_IRQ_map[16] __prepdata =
0, /* Slot 15 - unused */ 0, /* Slot 15 - unused */
}; };
static char Genesis_pci_IRQ_routes[] __prepdata = static char Genesis_pci_IRQ_routes[] =
{ {
0, /* Line 0 - Unused */ 0, /* Line 0 - Unused */
10, /* Line 1 */ 10, /* Line 1 */
...@@ -299,7 +299,7 @@ static char Genesis_pci_IRQ_routes[] __prepdata = ...@@ -299,7 +299,7 @@ static char Genesis_pci_IRQ_routes[] __prepdata =
15 /* Line 4 */ 15 /* Line 4 */
}; };
static char Genesis2_pci_IRQ_map[23] __prepdata = static char Genesis2_pci_IRQ_map[23] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -327,7 +327,7 @@ static char Genesis2_pci_IRQ_map[23] __prepdata = ...@@ -327,7 +327,7 @@ static char Genesis2_pci_IRQ_map[23] __prepdata =
}; };
/* Motorola Series-E */ /* Motorola Series-E */
static char Comet_pci_IRQ_map[23] __prepdata = static char Comet_pci_IRQ_map[23] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -354,7 +354,7 @@ static char Comet_pci_IRQ_map[23] __prepdata = ...@@ -354,7 +354,7 @@ static char Comet_pci_IRQ_map[23] __prepdata =
0, 0,
}; };
static char Comet_pci_IRQ_routes[] __prepdata = static char Comet_pci_IRQ_routes[] =
{ {
0, /* Line 0 - Unused */ 0, /* Line 0 - Unused */
10, /* Line 1 */ 10, /* Line 1 */
...@@ -364,7 +364,7 @@ static char Comet_pci_IRQ_routes[] __prepdata = ...@@ -364,7 +364,7 @@ static char Comet_pci_IRQ_routes[] __prepdata =
}; };
/* Motorola Series-EX */ /* Motorola Series-EX */
static char Comet2_pci_IRQ_map[23] __prepdata = static char Comet2_pci_IRQ_map[23] =
{ {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
...@@ -391,7 +391,7 @@ static char Comet2_pci_IRQ_map[23] __prepdata = ...@@ -391,7 +391,7 @@ static char Comet2_pci_IRQ_map[23] __prepdata =
0, 0,
}; };
static char Comet2_pci_IRQ_routes[] __prepdata = static char Comet2_pci_IRQ_routes[] =
{ {
0, /* Line 0 - Unused */ 0, /* Line 0 - Unused */
10, /* Line 1 */ 10, /* Line 1 */
...@@ -405,7 +405,7 @@ static char Comet2_pci_IRQ_routes[] __prepdata = ...@@ -405,7 +405,7 @@ static char Comet2_pci_IRQ_routes[] __prepdata =
* This is actually based on the Carolina motherboard * This is actually based on the Carolina motherboard
* -- Cort * -- Cort
*/ */
static char ibm8xx_pci_IRQ_map[23] __prepdata = { static char ibm8xx_pci_IRQ_map[23] = {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
0, /* Slot 2 - unused */ 0, /* Slot 2 - unused */
...@@ -431,7 +431,7 @@ static char ibm8xx_pci_IRQ_map[23] __prepdata = { ...@@ -431,7 +431,7 @@ static char ibm8xx_pci_IRQ_map[23] __prepdata = {
2, /* Slot 22 - PCI slot 1 PCIINTx# (See below) */ 2, /* Slot 22 - PCI slot 1 PCIINTx# (See below) */
}; };
static char ibm8xx_pci_IRQ_routes[] __prepdata = { static char ibm8xx_pci_IRQ_routes[] = {
0, /* Line 0 - unused */ 0, /* Line 0 - unused */
15, /* Line 1 */ 15, /* Line 1 */
15, /* Line 2 */ 15, /* Line 2 */
...@@ -443,7 +443,7 @@ static char ibm8xx_pci_IRQ_routes[] __prepdata = { ...@@ -443,7 +443,7 @@ static char ibm8xx_pci_IRQ_routes[] __prepdata = {
* a 6015 ibm board * a 6015 ibm board
* -- Cort * -- Cort
*/ */
static char ibm6015_pci_IRQ_map[23] __prepdata = { static char ibm6015_pci_IRQ_map[23] = {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
0, /* Slot 2 - unused */ 0, /* Slot 2 - unused */
...@@ -469,7 +469,7 @@ static char ibm6015_pci_IRQ_map[23] __prepdata = { ...@@ -469,7 +469,7 @@ static char ibm6015_pci_IRQ_map[23] __prepdata = {
2, /* Slot 22 - */ 2, /* Slot 22 - */
}; };
static char ibm6015_pci_IRQ_routes[] __prepdata = { static char ibm6015_pci_IRQ_routes[] = {
0, /* Line 0 - unused */ 0, /* Line 0 - unused */
13, /* Line 1 */ 13, /* Line 1 */
15, /* Line 2 */ 15, /* Line 2 */
...@@ -479,7 +479,7 @@ static char ibm6015_pci_IRQ_routes[] __prepdata = { ...@@ -479,7 +479,7 @@ static char ibm6015_pci_IRQ_routes[] __prepdata = {
/* IBM Nobis and Thinkpad 850 */ /* IBM Nobis and Thinkpad 850 */
static char Nobis_pci_IRQ_map[23] __prepdata ={ static char Nobis_pci_IRQ_map[23] ={
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
0, /* Slot 2 - unused */ 0, /* Slot 2 - unused */
...@@ -498,7 +498,7 @@ static char Nobis_pci_IRQ_map[23] __prepdata ={ ...@@ -498,7 +498,7 @@ static char Nobis_pci_IRQ_map[23] __prepdata ={
0, /* Slot 15 - unused */ 0, /* Slot 15 - unused */
}; };
static char Nobis_pci_IRQ_routes[] __prepdata = { static char Nobis_pci_IRQ_routes[] = {
0, /* Line 0 - Unused */ 0, /* Line 0 - Unused */
13, /* Line 1 */ 13, /* Line 1 */
13, /* Line 2 */ 13, /* Line 2 */
...@@ -510,7 +510,7 @@ static char Nobis_pci_IRQ_routes[] __prepdata = { ...@@ -510,7 +510,7 @@ static char Nobis_pci_IRQ_routes[] __prepdata = {
* IBM RS/6000 43p/140 -- paulus * IBM RS/6000 43p/140 -- paulus
* XXX we should get all this from the residual data * XXX we should get all this from the residual data
*/ */
static char ibm43p_pci_IRQ_map[23] __prepdata = { static char ibm43p_pci_IRQ_map[23] = {
0, /* Slot 0 - unused */ 0, /* Slot 0 - unused */
0, /* Slot 1 - unused */ 0, /* Slot 1 - unused */
0, /* Slot 2 - unused */ 0, /* Slot 2 - unused */
...@@ -536,7 +536,7 @@ static char ibm43p_pci_IRQ_map[23] __prepdata = { ...@@ -536,7 +536,7 @@ static char ibm43p_pci_IRQ_map[23] __prepdata = {
1, /* Slot 22 - PCI slot 1 PCIINTx# (See below) */ 1, /* Slot 22 - PCI slot 1 PCIINTx# (See below) */
}; };
static char ibm43p_pci_IRQ_routes[] __prepdata = { static char ibm43p_pci_IRQ_routes[] = {
0, /* Line 0 - unused */ 0, /* Line 0 - unused */
15, /* Line 1 */ 15, /* Line 1 */
15, /* Line 2 */ 15, /* Line 2 */
...@@ -559,7 +559,7 @@ struct powerplus_irq_list ...@@ -559,7 +559,7 @@ struct powerplus_irq_list
* are routed to OpenPIC inputs 5-8. These values are offset by * are routed to OpenPIC inputs 5-8. These values are offset by
* 16 in the table to reflect the Linux kernel interrupt value. * 16 in the table to reflect the Linux kernel interrupt value.
*/ */
struct powerplus_irq_list Powerplus_pci_IRQ_list __prepdata = struct powerplus_irq_list Powerplus_pci_IRQ_list =
{ {
{25, 26, 27, 28}, {25, 26, 27, 28},
{21, 22, 23, 24} {21, 22, 23, 24}
...@@ -572,7 +572,7 @@ struct powerplus_irq_list Powerplus_pci_IRQ_list __prepdata = ...@@ -572,7 +572,7 @@ struct powerplus_irq_list Powerplus_pci_IRQ_list __prepdata =
* are routed to OpenPIC inputs 12-15. These values are offset by * are routed to OpenPIC inputs 12-15. These values are offset by
* 16 in the table to reflect the Linux kernel interrupt value. * 16 in the table to reflect the Linux kernel interrupt value.
*/ */
struct powerplus_irq_list Mesquite_pci_IRQ_list __prepdata = struct powerplus_irq_list Mesquite_pci_IRQ_list =
{ {
{24, 25, 26, 27}, {24, 25, 26, 27},
{28, 29, 30, 31} {28, 29, 30, 31}
...@@ -582,7 +582,7 @@ struct powerplus_irq_list Mesquite_pci_IRQ_list __prepdata = ...@@ -582,7 +582,7 @@ struct powerplus_irq_list Mesquite_pci_IRQ_list __prepdata =
* This table represents the standard PCI swizzle defined in the * This table represents the standard PCI swizzle defined in the
* PCI bus specification. * PCI bus specification.
*/ */
static unsigned char prep_pci_intpins[4][4] __prepdata = static unsigned char prep_pci_intpins[4][4] =
{ {
{ 1, 2, 3, 4}, /* Buses 0, 4, 8, ... */ { 1, 2, 3, 4}, /* Buses 0, 4, 8, ... */
{ 2, 3, 4, 1}, /* Buses 1, 5, 9, ... */ { 2, 3, 4, 1}, /* Buses 1, 5, 9, ... */
...@@ -622,7 +622,7 @@ static unsigned char prep_pci_intpins[4][4] __prepdata = ...@@ -622,7 +622,7 @@ static unsigned char prep_pci_intpins[4][4] __prepdata =
#define MIN_DEVNR 11 #define MIN_DEVNR 11
#define MAX_DEVNR 22 #define MAX_DEVNR 22
static int __prep static int
prep_read_config(struct pci_bus *bus, unsigned int devfn, int offset, prep_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 *val) int len, u32 *val)
{ {
...@@ -652,7 +652,7 @@ prep_read_config(struct pci_bus *bus, unsigned int devfn, int offset, ...@@ -652,7 +652,7 @@ prep_read_config(struct pci_bus *bus, unsigned int devfn, int offset,
return PCIBIOS_SUCCESSFUL; return PCIBIOS_SUCCESSFUL;
} }
static int __prep static int
prep_write_config(struct pci_bus *bus, unsigned int devfn, int offset, prep_write_config(struct pci_bus *bus, unsigned int devfn, int offset,
int len, u32 val) int len, u32 val)
{ {
...@@ -804,7 +804,7 @@ struct mot_info { ...@@ -804,7 +804,7 @@ struct mot_info {
void (*map_non0_bus)(struct pci_dev *); /* For boards with more than bus 0 devices. */ void (*map_non0_bus)(struct pci_dev *); /* For boards with more than bus 0 devices. */
struct powerplus_irq_list *pci_irq_list; /* List of PCI MPIC inputs */ struct powerplus_irq_list *pci_irq_list; /* List of PCI MPIC inputs */
unsigned char secondary_bridge_devfn; /* devfn of secondary bus transparent bridge */ unsigned char secondary_bridge_devfn; /* devfn of secondary bus transparent bridge */
} mot_info[] __prepdata = { } mot_info[] = {
{0x300, 0x00, 0x00, "MVME 2400", Genesis2_pci_IRQ_map, Raven_pci_IRQ_routes, Powerplus_Map_Non0, &Powerplus_pci_IRQ_list, 0xFF}, {0x300, 0x00, 0x00, "MVME 2400", Genesis2_pci_IRQ_map, Raven_pci_IRQ_routes, Powerplus_Map_Non0, &Powerplus_pci_IRQ_list, 0xFF},
{0x010, 0x00, 0x00, "Genesis", Genesis_pci_IRQ_map, Genesis_pci_IRQ_routes, Powerplus_Map_Non0, &Powerplus_pci_IRQ_list, 0x00}, {0x010, 0x00, 0x00, "Genesis", Genesis_pci_IRQ_map, Genesis_pci_IRQ_routes, Powerplus_Map_Non0, &Powerplus_pci_IRQ_list, 0x00},
{0x020, 0x00, 0x00, "Powerstack (Series E)", Comet_pci_IRQ_map, Comet_pci_IRQ_routes, NULL, NULL, 0x00}, {0x020, 0x00, 0x00, "Powerstack (Series E)", Comet_pci_IRQ_map, Comet_pci_IRQ_routes, NULL, NULL, 0x00},
......
...@@ -173,7 +173,7 @@ prep_carolina_enable_l2(void) ...@@ -173,7 +173,7 @@ prep_carolina_enable_l2(void)
} }
/* cpuinfo code common to all IBM PReP */ /* cpuinfo code common to all IBM PReP */
static void __prep static void
prep_ibm_cpuinfo(struct seq_file *m) prep_ibm_cpuinfo(struct seq_file *m)
{ {
unsigned int equip_reg = inb(PREP_IBM_EQUIPMENT); unsigned int equip_reg = inb(PREP_IBM_EQUIPMENT);
...@@ -209,14 +209,14 @@ prep_ibm_cpuinfo(struct seq_file *m) ...@@ -209,14 +209,14 @@ prep_ibm_cpuinfo(struct seq_file *m)
} }
} }
static int __prep static int
prep_gen_cpuinfo(struct seq_file *m) prep_gen_cpuinfo(struct seq_file *m)
{ {
prep_ibm_cpuinfo(m); prep_ibm_cpuinfo(m);
return 0; return 0;
} }
static int __prep static int
prep_sandalfoot_cpuinfo(struct seq_file *m) prep_sandalfoot_cpuinfo(struct seq_file *m)
{ {
unsigned int equip_reg = inb(PREP_IBM_EQUIPMENT); unsigned int equip_reg = inb(PREP_IBM_EQUIPMENT);
...@@ -243,7 +243,7 @@ prep_sandalfoot_cpuinfo(struct seq_file *m) ...@@ -243,7 +243,7 @@ prep_sandalfoot_cpuinfo(struct seq_file *m)
return 0; return 0;
} }
static int __prep static int
prep_thinkpad_cpuinfo(struct seq_file *m) prep_thinkpad_cpuinfo(struct seq_file *m)
{ {
unsigned int equip_reg = inb(PREP_IBM_EQUIPMENT); unsigned int equip_reg = inb(PREP_IBM_EQUIPMENT);
...@@ -314,7 +314,7 @@ prep_thinkpad_cpuinfo(struct seq_file *m) ...@@ -314,7 +314,7 @@ prep_thinkpad_cpuinfo(struct seq_file *m)
return 0; return 0;
} }
static int __prep static int
prep_carolina_cpuinfo(struct seq_file *m) prep_carolina_cpuinfo(struct seq_file *m)
{ {
unsigned int equip_reg = inb(PREP_IBM_EQUIPMENT); unsigned int equip_reg = inb(PREP_IBM_EQUIPMENT);
...@@ -350,7 +350,7 @@ prep_carolina_cpuinfo(struct seq_file *m) ...@@ -350,7 +350,7 @@ prep_carolina_cpuinfo(struct seq_file *m)
return 0; return 0;
} }
static int __prep static int
prep_tiger1_cpuinfo(struct seq_file *m) prep_tiger1_cpuinfo(struct seq_file *m)
{ {
unsigned int l2_reg = inb(PREP_IBM_L2INFO); unsigned int l2_reg = inb(PREP_IBM_L2INFO);
...@@ -393,7 +393,7 @@ prep_tiger1_cpuinfo(struct seq_file *m) ...@@ -393,7 +393,7 @@ prep_tiger1_cpuinfo(struct seq_file *m)
/* Used by all Motorola PReP */ /* Used by all Motorola PReP */
static int __prep static int
prep_mot_cpuinfo(struct seq_file *m) prep_mot_cpuinfo(struct seq_file *m)
{ {
unsigned int cachew = *((unsigned char *)CACHECRBA); unsigned int cachew = *((unsigned char *)CACHECRBA);
...@@ -454,7 +454,7 @@ prep_mot_cpuinfo(struct seq_file *m) ...@@ -454,7 +454,7 @@ prep_mot_cpuinfo(struct seq_file *m)
return 0; return 0;
} }
static void __prep static void
prep_restart(char *cmd) prep_restart(char *cmd)
{ {
#define PREP_SP92 0x92 /* Special Port 92 */ #define PREP_SP92 0x92 /* Special Port 92 */
...@@ -473,7 +473,7 @@ prep_restart(char *cmd) ...@@ -473,7 +473,7 @@ prep_restart(char *cmd)
#undef PREP_SP92 #undef PREP_SP92
} }
static void __prep static void
prep_halt(void) prep_halt(void)
{ {
local_irq_disable(); /* no interrupts */ local_irq_disable(); /* no interrupts */
...@@ -488,7 +488,7 @@ prep_halt(void) ...@@ -488,7 +488,7 @@ prep_halt(void)
/* Carrera is the power manager in the Thinkpads. Unfortunately not much is /* Carrera is the power manager in the Thinkpads. Unfortunately not much is
* known about it, so we can't power down. * known about it, so we can't power down.
*/ */
static void __prep static void
prep_carrera_poweroff(void) prep_carrera_poweroff(void)
{ {
prep_halt(); prep_halt();
...@@ -501,7 +501,7 @@ prep_carrera_poweroff(void) ...@@ -501,7 +501,7 @@ prep_carrera_poweroff(void)
* somewhat in the IBM Carolina Technical Specification. * somewhat in the IBM Carolina Technical Specification.
* -Hollis * -Hollis
*/ */
static void __prep static void
utah_sig87c750_setbit(unsigned int bytenum, unsigned int bitnum, int value) utah_sig87c750_setbit(unsigned int bytenum, unsigned int bitnum, int value)
{ {
/* /*
...@@ -539,7 +539,7 @@ utah_sig87c750_setbit(unsigned int bytenum, unsigned int bitnum, int value) ...@@ -539,7 +539,7 @@ utah_sig87c750_setbit(unsigned int bytenum, unsigned int bitnum, int value)
udelay(100); /* important: let controller recover */ udelay(100); /* important: let controller recover */
} }
static void __prep static void
prep_sig750_poweroff(void) prep_sig750_poweroff(void)
{ {
/* tweak the power manager found in most IBM PRePs (except Thinkpads) */ /* tweak the power manager found in most IBM PRePs (except Thinkpads) */
...@@ -554,7 +554,7 @@ prep_sig750_poweroff(void) ...@@ -554,7 +554,7 @@ prep_sig750_poweroff(void)
/* not reached */ /* not reached */
} }
static int __prep static int
prep_show_percpuinfo(struct seq_file *m, int i) prep_show_percpuinfo(struct seq_file *m, int i)
{ {
/* PREP's without residual data will give incorrect values here */ /* PREP's without residual data will give incorrect values here */
...@@ -700,12 +700,12 @@ prep_set_bat(void) ...@@ -700,12 +700,12 @@ prep_set_bat(void)
/* /*
* IBM 3-digit status LED * IBM 3-digit status LED
*/ */
static unsigned int ibm_statusled_base __prepdata; static unsigned int ibm_statusled_base;
static void __prep static void
ibm_statusled_progress(char *s, unsigned short hex); ibm_statusled_progress(char *s, unsigned short hex);
static int __prep static int
ibm_statusled_panic(struct notifier_block *dummy1, unsigned long dummy2, ibm_statusled_panic(struct notifier_block *dummy1, unsigned long dummy2,
void * dummy3) void * dummy3)
{ {
...@@ -713,13 +713,13 @@ ibm_statusled_panic(struct notifier_block *dummy1, unsigned long dummy2, ...@@ -713,13 +713,13 @@ ibm_statusled_panic(struct notifier_block *dummy1, unsigned long dummy2,
return NOTIFY_DONE; return NOTIFY_DONE;
} }
static struct notifier_block ibm_statusled_block __prepdata = { static struct notifier_block ibm_statusled_block = {
ibm_statusled_panic, ibm_statusled_panic,
NULL, NULL,
INT_MAX /* try to do it first */ INT_MAX /* try to do it first */
}; };
static void __prep static void
ibm_statusled_progress(char *s, unsigned short hex) ibm_statusled_progress(char *s, unsigned short hex)
{ {
static int notifier_installed; static int notifier_installed;
...@@ -945,7 +945,7 @@ prep_calibrate_decr(void) ...@@ -945,7 +945,7 @@ prep_calibrate_decr(void)
todc_calibrate_decr(); todc_calibrate_decr();
} }
static unsigned int __prep static unsigned int
prep_irq_canonicalize(u_int irq) prep_irq_canonicalize(u_int irq)
{ {
if (irq == 2) if (irq == 2)
...@@ -996,7 +996,7 @@ prep_init_IRQ(void) ...@@ -996,7 +996,7 @@ prep_init_IRQ(void)
/* /*
* IDE stuff. * IDE stuff.
*/ */
static int __prep static int
prep_ide_default_irq(unsigned long base) prep_ide_default_irq(unsigned long base)
{ {
switch (base) { switch (base) {
...@@ -1010,7 +1010,7 @@ prep_ide_default_irq(unsigned long base) ...@@ -1010,7 +1010,7 @@ prep_ide_default_irq(unsigned long base)
} }
} }
static unsigned long __prep static unsigned long
prep_ide_default_io_base(int index) prep_ide_default_io_base(int index)
{ {
switch (index) { switch (index) {
...@@ -1055,7 +1055,7 @@ smp_prep_setup_cpu(int cpu_nr) ...@@ -1055,7 +1055,7 @@ smp_prep_setup_cpu(int cpu_nr)
do_openpic_setup_cpu(); do_openpic_setup_cpu();
} }
static struct smp_ops_t prep_smp_ops __prepdata = { static struct smp_ops_t prep_smp_ops = {
smp_openpic_message_pass, smp_openpic_message_pass,
smp_prep_probe, smp_prep_probe,
smp_prep_kick_cpu, smp_prep_kick_cpu,
......
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
#include <asm/ide.h> #include <asm/ide.h>
unsigned char __res[sizeof(RESIDUAL)] __prepdata = {0,}; unsigned char __res[sizeof(RESIDUAL)] = {0,};
RESIDUAL *res = (RESIDUAL *)&__res; RESIDUAL *res = (RESIDUAL *)&__res;
char * PnP_BASE_TYPES[] __initdata = { char * PnP_BASE_TYPES[] __initdata = {
......
...@@ -53,8 +53,8 @@ extern char *klimit; ...@@ -53,8 +53,8 @@ extern char *klimit;
* chrp only uses it during early boot. * chrp only uses it during early boot.
*/ */
#ifdef CONFIG_XMON #ifdef CONFIG_XMON
#define BTEXT __pmac #define BTEXT
#define BTDATA __pmacdata #define BTDATA
#else #else
#define BTEXT __init #define BTEXT __init
#define BTDATA __initdata #define BTDATA __initdata
...@@ -187,7 +187,7 @@ btext_setup_display(int width, int height, int depth, int pitch, ...@@ -187,7 +187,7 @@ btext_setup_display(int width, int height, int depth, int pitch,
* changes. * changes.
*/ */
void __openfirmware void
map_boot_text(void) map_boot_text(void)
{ {
unsigned long base, offset, size; unsigned long base, offset, size;
......
...@@ -22,14 +22,14 @@ ...@@ -22,14 +22,14 @@
static char nvramData[MAX_PREP_NVRAM]; static char nvramData[MAX_PREP_NVRAM];
static NVRAM_MAP *nvram=(NVRAM_MAP *)&nvramData[0]; static NVRAM_MAP *nvram=(NVRAM_MAP *)&nvramData[0];
unsigned char __prep prep_nvram_read_val(int addr) unsigned char prep_nvram_read_val(int addr)
{ {
outb(addr, PREP_NVRAM_AS0); outb(addr, PREP_NVRAM_AS0);
outb(addr>>8, PREP_NVRAM_AS1); outb(addr>>8, PREP_NVRAM_AS1);
return inb(PREP_NVRAM_DATA); return inb(PREP_NVRAM_DATA);
} }
void __prep prep_nvram_write_val(int addr, void prep_nvram_write_val(int addr,
unsigned char val) unsigned char val)
{ {
outb(addr, PREP_NVRAM_AS0); outb(addr, PREP_NVRAM_AS0);
...@@ -81,8 +81,7 @@ void __init init_prep_nvram(void) ...@@ -81,8 +81,7 @@ void __init init_prep_nvram(void)
} }
} }
__prep char *prep_nvram_get_var(const char *name)
char __prep *prep_nvram_get_var(const char *name)
{ {
char *cp; char *cp;
int namelen; int namelen;
...@@ -101,8 +100,7 @@ char __prep *prep_nvram_get_var(const char *name) ...@@ -101,8 +100,7 @@ char __prep *prep_nvram_get_var(const char *name)
return NULL; return NULL;
} }
__prep char *prep_nvram_first_var(void)
char __prep *prep_nvram_first_var(void)
{ {
if (nvram->Header.GELength == 0) { if (nvram->Header.GELength == 0) {
return NULL; return NULL;
...@@ -112,8 +110,7 @@ char __prep *prep_nvram_first_var(void) ...@@ -112,8 +110,7 @@ char __prep *prep_nvram_first_var(void)
} }
} }
__prep char *prep_nvram_next_var(char *name)
char __prep *prep_nvram_next_var(char *name)
{ {
char *cp; char *cp;
......
...@@ -89,7 +89,7 @@ extern char cmd_line[512]; /* XXX */ ...@@ -89,7 +89,7 @@ extern char cmd_line[512]; /* XXX */
extern boot_infos_t *boot_infos; extern boot_infos_t *boot_infos;
unsigned long dev_tree_size; unsigned long dev_tree_size;
void __openfirmware void
phys_call_rtas(int service, int nargs, int nret, ...) phys_call_rtas(int service, int nargs, int nret, ...)
{ {
va_list list; va_list list;
...@@ -862,7 +862,7 @@ find_type_devices(const char *type) ...@@ -862,7 +862,7 @@ find_type_devices(const char *type)
/* /*
* Returns all nodes linked together * Returns all nodes linked together
*/ */
struct device_node * __openfirmware struct device_node *
find_all_nodes(void) find_all_nodes(void)
{ {
struct device_node *head, **prevp, *np; struct device_node *head, **prevp, *np;
...@@ -1165,7 +1165,7 @@ get_property(struct device_node *np, const char *name, int *lenp) ...@@ -1165,7 +1165,7 @@ get_property(struct device_node *np, const char *name, int *lenp)
/* /*
* Add a property to a node * Add a property to a node
*/ */
void __openfirmware void
prom_add_property(struct device_node* np, struct property* prop) prom_add_property(struct device_node* np, struct property* prop)
{ {
struct property **next = &np->properties; struct property **next = &np->properties;
...@@ -1177,7 +1177,7 @@ prom_add_property(struct device_node* np, struct property* prop) ...@@ -1177,7 +1177,7 @@ prom_add_property(struct device_node* np, struct property* prop)
} }
/* I quickly hacked that one, check against spec ! */ /* I quickly hacked that one, check against spec ! */
static inline unsigned long __openfirmware static inline unsigned long
bus_space_to_resource_flags(unsigned int bus_space) bus_space_to_resource_flags(unsigned int bus_space)
{ {
u8 space = (bus_space >> 24) & 0xf; u8 space = (bus_space >> 24) & 0xf;
...@@ -1194,7 +1194,7 @@ bus_space_to_resource_flags(unsigned int bus_space) ...@@ -1194,7 +1194,7 @@ bus_space_to_resource_flags(unsigned int bus_space)
} }
} }
static struct resource* __openfirmware static struct resource*
find_parent_pci_resource(struct pci_dev* pdev, struct address_range *range) find_parent_pci_resource(struct pci_dev* pdev, struct address_range *range)
{ {
unsigned long mask; unsigned long mask;
...@@ -1224,7 +1224,7 @@ find_parent_pci_resource(struct pci_dev* pdev, struct address_range *range) ...@@ -1224,7 +1224,7 @@ find_parent_pci_resource(struct pci_dev* pdev, struct address_range *range)
* or other nodes attached to the root node. Ultimately, put some * or other nodes attached to the root node. Ultimately, put some
* link to resources in the OF node. * link to resources in the OF node.
*/ */
struct resource* __openfirmware struct resource*
request_OF_resource(struct device_node* node, int index, const char* name_postfix) request_OF_resource(struct device_node* node, int index, const char* name_postfix)
{ {
struct pci_dev* pcidev; struct pci_dev* pcidev;
...@@ -1280,7 +1280,7 @@ request_OF_resource(struct device_node* node, int index, const char* name_postfi ...@@ -1280,7 +1280,7 @@ request_OF_resource(struct device_node* node, int index, const char* name_postfi
return NULL; return NULL;
} }
int __openfirmware int
release_OF_resource(struct device_node* node, int index) release_OF_resource(struct device_node* node, int index)
{ {
struct pci_dev* pcidev; struct pci_dev* pcidev;
...@@ -1346,7 +1346,7 @@ release_OF_resource(struct device_node* node, int index) ...@@ -1346,7 +1346,7 @@ release_OF_resource(struct device_node* node, int index)
} }
#if 0 #if 0
void __openfirmware void
print_properties(struct device_node *np) print_properties(struct device_node *np)
{ {
struct property *pp; struct property *pp;
...@@ -1400,7 +1400,7 @@ print_properties(struct device_node *np) ...@@ -1400,7 +1400,7 @@ print_properties(struct device_node *np)
static DEFINE_SPINLOCK(rtas_lock); static DEFINE_SPINLOCK(rtas_lock);
/* this can be called after setup -- Cort */ /* this can be called after setup -- Cort */
int __openfirmware int
call_rtas(const char *service, int nargs, int nret, call_rtas(const char *service, int nargs, int nret,
unsigned long *outputs, ...) unsigned long *outputs, ...)
{ {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment