diff options
author | Jan Beulich <JBeulich@novell.com> | 2009-06-30 07:01:57 -0400 |
---|---|---|
committer | Tony Luck <tony.luck@intel.com> | 2009-06-30 17:26:34 -0400 |
commit | fa276f36f3d8743295e067fb483b42dca8bd1ece (patch) | |
tree | 4a31e3ce3d2242a26aa361d330424060daafd311 /arch/ia64/kernel | |
parent | 58782b34e9ffcc04619634efe9658263344ed188 (diff) |
[IA64] address compiler warnings perfmon.c/salinfo.c
perfmon.c has a dubious cast directly from "int" to "void *". Add
an intermediate cast to "long" to keep gcc happy.
salinfo.c uses "down_trylock()" in a highly creative way (explained
in the comments in the file) ... but it does kick out this warning:
arch/ia64/kernel/salinfo.c:195: warning: ignoring return value of 'down_trylock'
which people occasionally try to "fix" in ways that do not work. Use some
casts to keep gcc quiet.
Signed-off-by: Jan Beulich <jbeulich@novell.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Diffstat (limited to 'arch/ia64/kernel')
-rw-r--r-- | arch/ia64/kernel/perfmon.c | 2 | ||||
-rw-r--r-- | arch/ia64/kernel/salinfo.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/arch/ia64/kernel/perfmon.c b/arch/ia64/kernel/perfmon.c index abce2468a40b..f1782705b1f7 100644 --- a/arch/ia64/kernel/perfmon.c +++ b/arch/ia64/kernel/perfmon.c | |||
@@ -5603,7 +5603,7 @@ pfm_interrupt_handler(int irq, void *arg) | |||
5603 | * /proc/perfmon interface, for debug only | 5603 | * /proc/perfmon interface, for debug only |
5604 | */ | 5604 | */ |
5605 | 5605 | ||
5606 | #define PFM_PROC_SHOW_HEADER ((void *)nr_cpu_ids+1) | 5606 | #define PFM_PROC_SHOW_HEADER ((void *)(long)nr_cpu_ids+1) |
5607 | 5607 | ||
5608 | static void * | 5608 | static void * |
5609 | pfm_proc_start(struct seq_file *m, loff_t *pos) | 5609 | pfm_proc_start(struct seq_file *m, loff_t *pos) |
diff --git a/arch/ia64/kernel/salinfo.c b/arch/ia64/kernel/salinfo.c index 7053c55b7649..e6676fca4828 100644 --- a/arch/ia64/kernel/salinfo.c +++ b/arch/ia64/kernel/salinfo.c | |||
@@ -192,7 +192,7 @@ struct salinfo_platform_oemdata_parms { | |||
192 | static void | 192 | static void |
193 | salinfo_work_to_do(struct salinfo_data *data) | 193 | salinfo_work_to_do(struct salinfo_data *data) |
194 | { | 194 | { |
195 | down_trylock(&data->mutex); | 195 | (void)(down_trylock(&data->mutex) ?: 0); |
196 | up(&data->mutex); | 196 | up(&data->mutex); |
197 | } | 197 | } |
198 | 198 | ||