All of lore.kernel.org
 help / color / mirror / Atom feed
* [patch] cpufreq: do not declare undefined functions
@ 2007-04-30 14:34 David Rientjes
  2007-04-30 15:59 ` Dave Jones
  0 siblings, 1 reply; 6+ messages in thread
From: David Rientjes @ 2007-04-30 14:34 UTC (permalink / raw)
  To: Dave Jones; +Cc: linux-kernel

fill_powernow_table_pstate() and fill_powernow_table_fidvid() are only
defined and used for X86_POWERNOW_K8_ACPI.

Cc: Dave Jones <davej@codemonkey.org.uk>
Signed-off-by: David Rientjes <rientjes@google.com>
---
 arch/i386/kernel/cpu/cpufreq/powernow-k8.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/i386/kernel/cpu/cpufreq/powernow-k8.h b/arch/i386/kernel/cpu/cpufreq/powernow-k8.h
--- a/arch/i386/kernel/cpu/cpufreq/powernow-k8.h
+++ b/arch/i386/kernel/cpu/cpufreq/powernow-k8.h
@@ -215,8 +215,10 @@ static int core_frequency_transition(struct powernow_k8_data *data, u32 reqfid);
 
 static void powernow_k8_acpi_pst_values(struct powernow_k8_data *data, unsigned int index);
 
+#ifdef CONFIG_X86_POWERNOW_K8_ACPI
 static int fill_powernow_table_pstate(struct powernow_k8_data *data, struct cpufreq_frequency_table *powernow_table);
 static int fill_powernow_table_fidvid(struct powernow_k8_data *data, struct cpufreq_frequency_table *powernow_table);
+#endif
 
 #ifdef CONFIG_SMP
 static inline void define_siblings(int cpu, cpumask_t cpu_sharedcore_mask[])

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [patch] cpufreq: do not declare undefined functions
  2007-04-30 14:34 [patch] cpufreq: do not declare undefined functions David Rientjes
@ 2007-04-30 15:59 ` Dave Jones
  2007-04-30 18:42   ` David Rientjes
  0 siblings, 1 reply; 6+ messages in thread
From: Dave Jones @ 2007-04-30 15:59 UTC (permalink / raw)
  To: David Rientjes; +Cc: linux-kernel

On Mon, Apr 30, 2007 at 07:34:37AM -0700, David Rientjes wrote:
 > fill_powernow_table_pstate() and fill_powernow_table_fidvid() are only
 > defined and used for X86_POWERNOW_K8_ACPI.

it's just a prototype, so no code is generated by declaring one
to an unused (or even non-existant) function.

Or are you using some oddball compiler that warns about this?

	Dave

-- 
http://www.codemonkey.org.uk

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [patch] cpufreq: do not declare undefined functions
  2007-04-30 15:59 ` Dave Jones
@ 2007-04-30 18:42   ` David Rientjes
  2007-04-30 18:52     ` Dave Jones
  0 siblings, 1 reply; 6+ messages in thread
From: David Rientjes @ 2007-04-30 18:42 UTC (permalink / raw)
  To: Dave Jones; +Cc: linux-kernel

On Mon, 30 Apr 2007, Dave Jones wrote:

> it's just a prototype, so no code is generated by declaring one
> to an unused (or even non-existant) function.
> 
> Or are you using some oddball compiler that warns about this?
> 

If you consider gcc to be oddball, yes.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [patch] cpufreq: do not declare undefined functions
  2007-04-30 18:42   ` David Rientjes
@ 2007-04-30 18:52     ` Dave Jones
  2007-04-30 19:10       ` David Rientjes
  0 siblings, 1 reply; 6+ messages in thread
From: Dave Jones @ 2007-04-30 18:52 UTC (permalink / raw)
  To: David Rientjes; +Cc: linux-kernel

On Mon, Apr 30, 2007 at 11:42:44AM -0700, David Rientjes wrote:
 > On Mon, 30 Apr 2007, Dave Jones wrote:
 > 
 > > it's just a prototype, so no code is generated by declaring one
 > > to an unused (or even non-existant) function.
 > > 
 > > Or are you using some oddball compiler that warns about this?
 > > 
 > 
 > If you consider gcc to be oddball, yes.

what version ? Mine doesn't seem to warn on that.

	Dave

-- 
http://www.codemonkey.org.uk

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [patch] cpufreq: do not declare undefined functions
  2007-04-30 18:52     ` Dave Jones
@ 2007-04-30 19:10       ` David Rientjes
  2007-04-30 19:35         ` Dave Jones
  0 siblings, 1 reply; 6+ messages in thread
From: David Rientjes @ 2007-04-30 19:10 UTC (permalink / raw)
  To: Dave Jones; +Cc: linux-kernel

On Mon, 30 Apr 2007, Dave Jones wrote:

>  > > it's just a prototype, so no code is generated by declaring one
>  > > to an unused (or even non-existant) function.
>  > > 
>  > > Or are you using some oddball compiler that warns about this?
>  > > 
>  > 
>  > If you consider gcc to be oddball, yes.
> 
> what version ? Mine doesn't seem to warn on that.
> 

4.1.2

arch/i386/kernel/cpu/cpufreq/powernow-k8.h:218: warning: 'fill_powernow_table_pstate' declared 'static' but never defined
arch/i386/kernel/cpu/cpufreq/powernow-k8.h:219: warning: 'fill_powernow_table_fidvid' declared 'static' but never defined

Make sure CONFIG_X86_POWERNOW_K8=y and CONFIG_X86_POWERNOW_K8_ACPI=n.

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [patch] cpufreq: do not declare undefined functions
  2007-04-30 19:10       ` David Rientjes
@ 2007-04-30 19:35         ` Dave Jones
  0 siblings, 0 replies; 6+ messages in thread
From: Dave Jones @ 2007-04-30 19:35 UTC (permalink / raw)
  To: David Rientjes; +Cc: linux-kernel

On Mon, Apr 30, 2007 at 12:10:45PM -0700, David Rientjes wrote:
 > On Mon, 30 Apr 2007, Dave Jones wrote:
 > 
 > >  > > it's just a prototype, so no code is generated by declaring one
 > >  > > to an unused (or even non-existant) function.
 > >  > > 
 > >  > > Or are you using some oddball compiler that warns about this?
 > >  > > 
 > >  > 
 > >  > If you consider gcc to be oddball, yes.
 > > 
 > > what version ? Mine doesn't seem to warn on that.
 > > 
 > 4.1.2
 > 
 > arch/i386/kernel/cpu/cpufreq/powernow-k8.h:218: warning: 'fill_powernow_table_pstate' declared 'static' but never defined
 > arch/i386/kernel/cpu/cpufreq/powernow-k8.h:219: warning: 'fill_powernow_table_fidvid' declared 'static' but never defined
 > 
 > Make sure CONFIG_X86_POWERNOW_K8=y and CONFIG_X86_POWERNOW_K8_ACPI=n.

Ah, I had ACPI_PROCESSOR=y, which was flipping it back on after I'd changed it.

Ok. Thanks.

	Dave

-- 
http://www.codemonkey.org.uk

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2007-04-30 19:36 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-04-30 14:34 [patch] cpufreq: do not declare undefined functions David Rientjes
2007-04-30 15:59 ` Dave Jones
2007-04-30 18:42   ` David Rientjes
2007-04-30 18:52     ` Dave Jones
2007-04-30 19:10       ` David Rientjes
2007-04-30 19:35         ` Dave Jones

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.