Commit 1c21a293 authored by Michael Ellerman's avatar Michael Ellerman Committed by Paul Mackerras
Browse files

[POWERPC] Fix sparse warnings in arch/powerpc/kernel



Make a few things static in lparcfg.c
Make init and exit routines static in rtas_flash.c
Make things static in rtas_pci.c
Make some functions static in rtas.c
Make fops static in rtas-proc.c
Remove unneeded extern for do_gtod in smp.c
Make clocksource_init() static in time.c
Make last_tick_len and ticklen_to_xs static in time.c
Move the declaration of the pvr per-cpu into smp.h
Make kexec_smp_down() and kexec_stack static in machine_kexec_64.c
Don't return void in arch_teardown_msi_irqs() in msi.c
Move declaration of GregorianDay()into asm/time.h

Signed-off-by: default avatarMichael Ellerman <michael@ellerman.id.au>
Signed-off-by: default avatarPaul Mackerras <paulus@samba.org>
parent 1c8950ff
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -573,7 +573,7 @@ static int lparcfg_open(struct inode *inode, struct file *file)
	return single_open(file, lparcfg_data, NULL);
}

const struct file_operations lparcfg_fops = {
static const struct file_operations lparcfg_fops = {
	.owner		= THIS_MODULE,
	.read		= seq_read,
	.write		= lparcfg_write,
@@ -581,7 +581,7 @@ const struct file_operations lparcfg_fops = {
	.release	= single_release,
};

int __init lparcfg_init(void)
static int __init lparcfg_init(void)
{
	struct proc_dir_entry *ent;
	mode_t mode = S_IRUSR | S_IRGRP | S_IROTH;
@@ -601,7 +601,7 @@ int __init lparcfg_init(void)
	return 0;
}

void __exit lparcfg_cleanup(void)
static void __exit lparcfg_cleanup(void)
{
	if (proc_ppc64_lparcfg)
		remove_proc_entry("lparcfg", proc_ppc64_lparcfg->parent);
+2 −2
Original line number Diff line number Diff line
@@ -158,7 +158,7 @@ void kexec_copy_flush(struct kimage *image)
 * on calling the interrupts, but we would like to call it off irq level
 * so that the interrupt controller is clean.
 */
void kexec_smp_down(void *arg)
static void kexec_smp_down(void *arg)
{
	if (ppc_md.kexec_cpu_down)
		ppc_md.kexec_cpu_down(0, 1);
@@ -249,7 +249,7 @@ static void kexec_prepare_cpus(void)
 * We could use a smaller stack if we don't care about anything using
 * current, but that audit has not been performed.
 */
union thread_union kexec_stack
static union thread_union kexec_stack
	__attribute__((__section__(".data.init_task"))) = { };

/* Our assembly helper, in kexec_stub.S */
+1 −1
Original line number Diff line number Diff line
@@ -34,5 +34,5 @@ int arch_setup_msi_irqs(struct pci_dev *dev, int nvec, int type)

void arch_teardown_msi_irqs(struct pci_dev *dev)
{
	return ppc_md.teardown_msi_irqs(dev);
	ppc_md.teardown_msi_irqs(dev);
}
+7 −7
Original line number Diff line number Diff line
@@ -160,7 +160,7 @@ static int sensors_open(struct inode *inode, struct file *file)
	return single_open(file, ppc_rtas_sensors_show, NULL);
}

const struct file_operations ppc_rtas_sensors_operations = {
static const struct file_operations ppc_rtas_sensors_operations = {
	.open		= sensors_open,
	.read		= seq_read,
	.llseek		= seq_lseek,
@@ -172,7 +172,7 @@ static int poweron_open(struct inode *inode, struct file *file)
	return single_open(file, ppc_rtas_poweron_show, NULL);
}

const struct file_operations ppc_rtas_poweron_operations = {
static const struct file_operations ppc_rtas_poweron_operations = {
	.open		= poweron_open,
	.read		= seq_read,
	.llseek		= seq_lseek,
@@ -185,7 +185,7 @@ static int progress_open(struct inode *inode, struct file *file)
	return single_open(file, ppc_rtas_progress_show, NULL);
}

const struct file_operations ppc_rtas_progress_operations = {
static const struct file_operations ppc_rtas_progress_operations = {
	.open		= progress_open,
	.read		= seq_read,
	.llseek		= seq_lseek,
@@ -198,7 +198,7 @@ static int clock_open(struct inode *inode, struct file *file)
	return single_open(file, ppc_rtas_clock_show, NULL);
}

const struct file_operations ppc_rtas_clock_operations = {
static const struct file_operations ppc_rtas_clock_operations = {
	.open		= clock_open,
	.read		= seq_read,
	.llseek		= seq_lseek,
@@ -211,7 +211,7 @@ static int tone_freq_open(struct inode *inode, struct file *file)
	return single_open(file, ppc_rtas_tone_freq_show, NULL);
}

const struct file_operations ppc_rtas_tone_freq_operations = {
static const struct file_operations ppc_rtas_tone_freq_operations = {
	.open		= tone_freq_open,
	.read		= seq_read,
	.llseek		= seq_lseek,
@@ -224,7 +224,7 @@ static int tone_volume_open(struct inode *inode, struct file *file)
	return single_open(file, ppc_rtas_tone_volume_show, NULL);
}

const struct file_operations ppc_rtas_tone_volume_operations = {
static const struct file_operations ppc_rtas_tone_volume_operations = {
	.open		= tone_volume_open,
	.read		= seq_read,
	.llseek		= seq_lseek,
@@ -237,7 +237,7 @@ static int rmo_buf_open(struct inode *inode, struct file *file)
	return single_open(file, ppc_rtas_rmo_buf_show, NULL);
}

const struct file_operations ppc_rtas_rmo_buf_ops = {
static const struct file_operations ppc_rtas_rmo_buf_ops = {
	.open		= rmo_buf_open,
	.read		= seq_read,
	.llseek		= seq_lseek,
+3 −3
Original line number Diff line number Diff line
@@ -340,8 +340,8 @@ int rtas_get_error_log_max(void)
EXPORT_SYMBOL(rtas_get_error_log_max);


char rtas_err_buf[RTAS_ERROR_LOG_MAX];
int rtas_last_error_token;
static char rtas_err_buf[RTAS_ERROR_LOG_MAX];
static int rtas_last_error_token;

/** Return a copy of the detailed error text associated with the
 *  most recent failed call to rtas.  Because the error text
@@ -484,7 +484,7 @@ unsigned int rtas_busy_delay(int status)
}
EXPORT_SYMBOL(rtas_busy_delay);

int rtas_error_rc(int rtas_rc)
static int rtas_error_rc(int rtas_rc)
{
	int rc;

Loading