From: Santosh Shilimkar <santosh.shilimkar@ti.com>
To: Jon Hunter <jon-hunter@ti.com>
Cc: Tony Lindgren <tony@atomide.com>,
linux-omap <linux-omap@vger.kernel.org>,
linux-arm <linux-arm-kernel@lists.infradead.org>,
Igor Grinberg <grinberg@compulab.co.il>
Subject: Re: [PATCH 3/3] ARM: AM335x: Fix warning in timer.c
Date: Wed, 28 Nov 2012 11:58:57 +0530 [thread overview]
Message-ID: <50B5AF29.4020306@ti.com> (raw)
In-Reply-To: <1354068915-3378-4-git-send-email-jon-hunter@ti.com>
On Wednesday 28 November 2012 07:45 AM, Jon Hunter wrote:
> When compiling the kernel with configuration options ...
>
> # CONFIG_ARCH_OMAP2 is not set
> # CONFIG_ARCH_OMAP3 is not set
> # CONFIG_ARCH_OMAP4 is not set
> # CONFIG_SOC_OMAP5 is not set
> CONFIG_SOC_AM33XX=y
>
> ... the following build warning is seen.
>
> CC arch/arm/mach-omap2/timer.o
> arch/arm/mach-omap2/timer.c:395:19: warning: ‘omap2_sync32k_clocksource_init’
> defined but not used [-Wunused-function]
>
> This issue was introduced by commit 6f80b3b (ARM: OMAP2+: timer: remove
> CONFIG_OMAP_32K_TIMER) where the omap2_sync32k_clocksource_init() is no
> longer referenced by the timer initialisation function for the AM335x
> device as it has no 32k-sync timer.
>
> Fix this by only including the omap2_sync32k_clocksource_init() function
> if either OMAP2, OMAP3, OMAP4 or OMAP5 devices are enabled.
>
> Cc: Igor Grinberg <grinberg@compulab.co.il>
>
> Signed-off-by: Jon Hunter <jon-hunter@ti.com>
> ---
> arch/arm/mach-omap2/timer.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/arch/arm/mach-omap2/timer.c b/arch/arm/mach-omap2/timer.c
> index eb96712..085c7e7 100644
> --- a/arch/arm/mach-omap2/timer.c
> +++ b/arch/arm/mach-omap2/timer.c
> @@ -386,6 +386,8 @@ static u32 notrace dmtimer_read_sched_clock(void)
> return 0;
> }
>
> +#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3) || \
> + defined(CONFIG_ARCH_OMAP4) || defined(CONFIG_SOC_OMAP5)
#ifndef CONFIG_SOC_AM33XX ?
#ifdef things are really ugly and needs constant patching and
hence something like CONFIG_HAS_32K kind of feature flags are
better. But that will undo certain part of f80b3b
(ARM: OMAP2+: timer: remove CONFIG_OMAP_32K_TIMER).
Regards
santosh
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
WARNING: multiple messages have this Message-ID (diff)
From: santosh.shilimkar@ti.com (Santosh Shilimkar)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 3/3] ARM: AM335x: Fix warning in timer.c
Date: Wed, 28 Nov 2012 11:58:57 +0530 [thread overview]
Message-ID: <50B5AF29.4020306@ti.com> (raw)
In-Reply-To: <1354068915-3378-4-git-send-email-jon-hunter@ti.com>
On Wednesday 28 November 2012 07:45 AM, Jon Hunter wrote:
> When compiling the kernel with configuration options ...
>
> # CONFIG_ARCH_OMAP2 is not set
> # CONFIG_ARCH_OMAP3 is not set
> # CONFIG_ARCH_OMAP4 is not set
> # CONFIG_SOC_OMAP5 is not set
> CONFIG_SOC_AM33XX=y
>
> ... the following build warning is seen.
>
> CC arch/arm/mach-omap2/timer.o
> arch/arm/mach-omap2/timer.c:395:19: warning: ?omap2_sync32k_clocksource_init?
> defined but not used [-Wunused-function]
>
> This issue was introduced by commit 6f80b3b (ARM: OMAP2+: timer: remove
> CONFIG_OMAP_32K_TIMER) where the omap2_sync32k_clocksource_init() is no
> longer referenced by the timer initialisation function for the AM335x
> device as it has no 32k-sync timer.
>
> Fix this by only including the omap2_sync32k_clocksource_init() function
> if either OMAP2, OMAP3, OMAP4 or OMAP5 devices are enabled.
>
> Cc: Igor Grinberg <grinberg@compulab.co.il>
>
> Signed-off-by: Jon Hunter <jon-hunter@ti.com>
> ---
> arch/arm/mach-omap2/timer.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/arch/arm/mach-omap2/timer.c b/arch/arm/mach-omap2/timer.c
> index eb96712..085c7e7 100644
> --- a/arch/arm/mach-omap2/timer.c
> +++ b/arch/arm/mach-omap2/timer.c
> @@ -386,6 +386,8 @@ static u32 notrace dmtimer_read_sched_clock(void)
> return 0;
> }
>
> +#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3) || \
> + defined(CONFIG_ARCH_OMAP4) || defined(CONFIG_SOC_OMAP5)
#ifndef CONFIG_SOC_AM33XX ?
#ifdef things are really ugly and needs constant patching and
hence something like CONFIG_HAS_32K kind of feature flags are
better. But that will undo certain part of f80b3b
(ARM: OMAP2+: timer: remove CONFIG_OMAP_32K_TIMER).
Regards
santosh
next prev parent reply other threads:[~2012-11-28 6:28 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-28 2:15 [PATCH 0/3] ARM: OMAP2+: Timer build warnings and error fixes Jon Hunter
2012-11-28 2:15 ` Jon Hunter
2012-11-28 2:15 ` [PATCH 1/3] ARM: OMAP2+: Fix realtime_counter_init warning in timer.c Jon Hunter
2012-11-28 2:15 ` Jon Hunter
2012-11-28 6:09 ` Santosh Shilimkar
2012-11-28 6:09 ` Santosh Shilimkar
2012-11-28 15:47 ` Jon Hunter
2012-11-28 15:47 ` Jon Hunter
2012-11-28 15:55 ` Santosh Shilimkar
2012-11-28 15:55 ` Santosh Shilimkar
2012-11-28 16:01 ` Jon Hunter
2012-11-28 16:01 ` Jon Hunter
2012-11-28 16:06 ` Santosh Shilimkar
2012-11-28 16:06 ` Santosh Shilimkar
2012-11-28 16:04 ` Santosh Shilimkar
2012-11-28 16:04 ` Santosh Shilimkar
2012-11-28 2:15 ` [PATCH 2/3] ARM: OMAP4: Fix build error and " Jon Hunter
2012-11-28 2:15 ` Jon Hunter
2012-11-28 5:47 ` Santosh Shilimkar
2012-11-28 5:47 ` Santosh Shilimkar
2012-11-28 6:40 ` Igor Grinberg
2012-11-28 6:40 ` Igor Grinberg
2012-11-28 2:15 ` [PATCH 3/3] ARM: AM335x: Fix " Jon Hunter
2012-11-28 2:15 ` Jon Hunter
2012-11-28 6:28 ` Santosh Shilimkar [this message]
2012-11-28 6:28 ` Santosh Shilimkar
2012-11-28 6:46 ` Igor Grinberg
2012-11-28 6:46 ` Igor Grinberg
2012-11-28 7:20 ` Santosh Shilimkar
2012-11-28 7:20 ` Santosh Shilimkar
2012-11-28 16:06 ` Jon Hunter
2012-11-28 16:06 ` Jon Hunter
2012-11-28 10:21 ` Vaibhav Hiremath
2012-11-28 10:21 ` Vaibhav Hiremath
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=50B5AF29.4020306@ti.com \
--to=santosh.shilimkar@ti.com \
--cc=grinberg@compulab.co.il \
--cc=jon-hunter@ti.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-omap@vger.kernel.org \
--cc=tony@atomide.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.