diff mbox

rtc: at91sam9: include <mach/hardware.h> explicitly

Message ID 1384524058-20712-1-git-send-email-u.kleine-koenig@pengutronix.de
State New
Headers show

Commit Message

Uwe Kleine-König Nov. 15, 2013, 2 p.m. UTC
The driver needs the symbol AT91_SLOW_CLOCK which is defined in
arch/arm/mach-at91/include/mach/hardware.h. This file is included
implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .

So better include it explicitly not only because the last link will go
away soon.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
---
 drivers/rtc/rtc-at91sam9.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Jean-Christophe PLAGNIOL-VILLARD Nov. 15, 2013, 2:23 p.m. UTC | #1
On 15:00 Fri 15 Nov     , Uwe Kleine-K??nig wrote:
> The driver needs the symbol AT91_SLOW_CLOCK which is defined in
> arch/arm/mach-at91/include/mach/hardware.h. This file is included
> implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
> linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
> linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
> linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
> 
> So better include it explicitly not only because the last link will go
> away soon.
> 
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>

we should never use this symbol you need to request the clock clk32k

Best Regards,
J.
> ---
>  drivers/rtc/rtc-at91sam9.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/rtc/rtc-at91sam9.c b/drivers/rtc/rtc-at91sam9.c
> index 309b8b3..5963743 100644
> --- a/drivers/rtc/rtc-at91sam9.c
> +++ b/drivers/rtc/rtc-at91sam9.c
> @@ -24,7 +24,7 @@
>  
>  #include <mach/at91_rtt.h>
>  #include <mach/cpu.h>
> -
> +#include <mach/hardware.h>
>  
>  /*
>   * This driver uses two configurable hardware resources that live in the
> -- 
> 1.8.4.2
>
Uwe Kleine-König Nov. 15, 2013, 2:55 p.m. UTC | #2
Hello,

On Fri, Nov 15, 2013 at 03:23:27PM +0100, Jean-Christophe PLAGNIOL-VILLARD wrote:
> On 15:00 Fri 15 Nov     , Uwe Kleine-K??nig wrote:
> > The driver needs the symbol AT91_SLOW_CLOCK which is defined in
> > arch/arm/mach-at91/include/mach/hardware.h. This file is included
> > implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
> > linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
> > linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
> > linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
> > 
> > So better include it explicitly not only because the last link will go
> > away soon.
> > 
> > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> 
> we should never use this symbol you need to request the clock clk32k
IMHO this should be addressed in another patch. My intent is to get rid
of <mach/timex.h>. So I let someone else take this patch opportunity.

Best regards
Uwe
Uwe Kleine-König Nov. 26, 2013, 1:41 p.m. UTC | #3
On Fri, Nov 15, 2013 at 03:00:58PM +0100, Uwe Kleine-König wrote:
> The driver needs the symbol AT91_SLOW_CLOCK which is defined in
> arch/arm/mach-at91/include/mach/hardware.h. This file is included
> implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
> linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
> linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
> linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
> 
> So better include it explicitly not only because the last link will go
> away soon.
> 
> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Ping. Is this patch ok despite Jean-Christophe's objection?

Best regards
Uwe

> ---
>  drivers/rtc/rtc-at91sam9.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/rtc/rtc-at91sam9.c b/drivers/rtc/rtc-at91sam9.c
> index 309b8b3..5963743 100644
> --- a/drivers/rtc/rtc-at91sam9.c
> +++ b/drivers/rtc/rtc-at91sam9.c
> @@ -24,7 +24,7 @@
>  
>  #include <mach/at91_rtt.h>
>  #include <mach/cpu.h>
> -
> +#include <mach/hardware.h>
>  
>  /*
>   * This driver uses two configurable hardware resources that live in the
> -- 
> 1.8.4.2
> 
> 
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Uwe Kleine-König Nov. 26, 2013, 1:44 p.m. UTC | #4
On Tue, Nov 26, 2013 at 02:41:17PM +0100, Uwe Kleine-König wrote:
> On Fri, Nov 15, 2013 at 03:00:58PM +0100, Uwe Kleine-König wrote:
> > The driver needs the symbol AT91_SLOW_CLOCK which is defined in
> > arch/arm/mach-at91/include/mach/hardware.h. This file is included
> > implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
> > linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
> > linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
> > linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
> > 
> > So better include it explicitly not only because the last link will go
> > away soon.
> > 
> > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> Ping. Is this patch ok despite Jean-Christophe's objection?
I saw that akpm already took it into his tree.

Best regards
Uwe
Uwe Kleine-König Nov. 26, 2013, 6:36 p.m. UTC | #5
Hello Andrew,

On Tue, Nov 26, 2013 at 02:44:44PM +0100, Uwe Kleine-König wrote:
> On Tue, Nov 26, 2013 at 02:41:17PM +0100, Uwe Kleine-König wrote:
> > On Fri, Nov 15, 2013 at 03:00:58PM +0100, Uwe Kleine-König wrote:
> > > The driver needs the symbol AT91_SLOW_CLOCK which is defined in
> > > arch/arm/mach-at91/include/mach/hardware.h. This file is included
> > > implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
> > > linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
> > > linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
> > > linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
> > > 
> > > So better include it explicitly not only because the last link will go
> > > away soon.
> > > 
> > > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
> > Ping. Is this patch ok despite Jean-Christophe's objection?
> I saw that akpm already took it into his tree.
This patch is one of the last few that are needed to drop <mach/timex.h>
alltogether that I don't have an ack from the respective maintainer yet.

Can you give your ack instead of sending the patch to Linus, then I'd
take it with the patch dropping <mach/timex.h> to make it easier to
merge.

Thanks
Uwe
Nicolas Ferre Nov. 27, 2013, 8:49 a.m. UTC | #6
On 15/11/2013 15:55, Uwe Kleine-König :
> Hello,
>
> On Fri, Nov 15, 2013 at 03:23:27PM +0100, Jean-Christophe PLAGNIOL-VILLARD wrote:
>> On 15:00 Fri 15 Nov     , Uwe Kleine-K??nig wrote:
>>> The driver needs the symbol AT91_SLOW_CLOCK which is defined in
>>> arch/arm/mach-at91/include/mach/hardware.h. This file is included
>>> implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
>>> linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
>>> linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
>>> linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
>>>
>>> So better include it explicitly not only because the last link will go
>>> away soon.
>>>
>>> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
>>
>> we should never use this symbol you need to request the clock clk32k
> IMHO this should be addressed in another patch. My intent is to get rid
> of <mach/timex.h>. So I let someone else take this patch opportunity.

I understand the objective of this patch.

So, in the meantime, you have my:

Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com>

(if it is not too late, Uwe).

Thanks for addressing that, bye,
Andrew Morton Dec. 16, 2013, 8:11 a.m. UTC | #7
On Tue, 26 Nov 2013 19:36:29 +0100 Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de> wrote:

> Hello Andrew,
> 
> On Tue, Nov 26, 2013 at 02:44:44PM +0100, Uwe Kleine-K__nig wrote:
> > On Tue, Nov 26, 2013 at 02:41:17PM +0100, Uwe Kleine-K__nig wrote:
> > > On Fri, Nov 15, 2013 at 03:00:58PM +0100, Uwe Kleine-K__nig wrote:
> > > > The driver needs the symbol AT91_SLOW_CLOCK which is defined in
> > > > arch/arm/mach-at91/include/mach/hardware.h. This file is included
> > > > implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
> > > > linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
> > > > linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
> > > > linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
> > > > 
> > > > So better include it explicitly not only because the last link will go
> > > > away soon.
> > > > 
> > > > Signed-off-by: Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de>
> > > Ping. Is this patch ok despite Jean-Christophe's objection?
> > I saw that akpm already took it into his tree.
> This patch is one of the last few that are needed to drop <mach/timex.h>
> alltogether that I don't have an ack from the respective maintainer yet.
> 
> Can you give your ack instead of sending the patch to Linus, then I'd
> take it with the patch dropping <mach/timex.h> to make it easier to
> merge.

ack ;)

I dropped my copy.
Uwe Kleine-König Dec. 16, 2013, 7:28 p.m. UTC | #8
Hello Andrew,

On Mon, Dec 16, 2013 at 12:11:58AM -0800, Andrew Morton wrote:
> On Tue, 26 Nov 2013 19:36:29 +0100 Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de> wrote:
> > On Tue, Nov 26, 2013 at 02:44:44PM +0100, Uwe Kleine-K__nig wrote:
> > > On Tue, Nov 26, 2013 at 02:41:17PM +0100, Uwe Kleine-K__nig wrote:
> > > > On Fri, Nov 15, 2013 at 03:00:58PM +0100, Uwe Kleine-K__nig wrote:
> > > > > The driver needs the symbol AT91_SLOW_CLOCK which is defined in
> > > > > arch/arm/mach-at91/include/mach/hardware.h. This file is included
> > > > > implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
> > > > > linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
> > > > > linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
> > > > > linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
> > > > > 
> > > > > So better include it explicitly not only because the last link will go
> > > > > away soon.
> > > > > 
> > > > > Signed-off-by: Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de>
> > > > Ping. Is this patch ok despite Jean-Christophe's objection?
> > > I saw that akpm already took it into his tree.
> > This patch is one of the last few that are needed to drop <mach/timex.h>
> > alltogether that I don't have an ack from the respective maintainer yet.
> > 
> > Can you give your ack instead of sending the patch to Linus, then I'd
> > take it with the patch dropping <mach/timex.h> to make it easier to
> > merge.
> 
> ack ;)
thanks. There is another rtc change that I didn't receive any feedback
for from a maintainer:

	rtc: pxa: drop unused #define TIMER_FREQ

. In the meantime I send a pull request asking to ignore that I didn't
get any maintainer reply for the rtc changes. Do you think it's sensible
to change the entry in MAINTAINERS? Any combination of:

	a) drop Alessandro's M: line
	b) add you
	c) change Status from Maintained to Odd Fixes or Orphan

> I dropped my copy.
fine, thanks

I'll wait for some time now before adding your ack to my tree to prevent
that you give me an ack for the other change just when I sent a new pull
request :-)

Uwe
Andrew Morton Dec. 16, 2013, 10:46 p.m. UTC | #9
On Mon, 16 Dec 2013 20:28:16 +0100 Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de> wrote:

> Hello Andrew,
> 
> On Mon, Dec 16, 2013 at 12:11:58AM -0800, Andrew Morton wrote:
> > On Tue, 26 Nov 2013 19:36:29 +0100 Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de> wrote:
> > > On Tue, Nov 26, 2013 at 02:44:44PM +0100, Uwe Kleine-K__nig wrote:
> > > > On Tue, Nov 26, 2013 at 02:41:17PM +0100, Uwe Kleine-K__nig wrote:
> > > > > On Fri, Nov 15, 2013 at 03:00:58PM +0100, Uwe Kleine-K__nig wrote:
> > > > > > The driver needs the symbol AT91_SLOW_CLOCK which is defined in
> > > > > > arch/arm/mach-at91/include/mach/hardware.h. This file is included
> > > > > > implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
> > > > > > linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
> > > > > > linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
> > > > > > linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
> > > > > > 
> > > > > > So better include it explicitly not only because the last link will go
> > > > > > away soon.
> > > > > > 
> > > > > > Signed-off-by: Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de>
> > > > > Ping. Is this patch ok despite Jean-Christophe's objection?
> > > > I saw that akpm already took it into his tree.
> > > This patch is one of the last few that are needed to drop <mach/timex.h>
> > > alltogether that I don't have an ack from the respective maintainer yet.
> > > 
> > > Can you give your ack instead of sending the patch to Linus, then I'd
> > > take it with the patch dropping <mach/timex.h> to make it easier to
> > > merge.
> > 
> > ack ;)
> thanks. There is another rtc change that I didn't receive any feedback
> for from a maintainer:
> 
> 	rtc: pxa: drop unused #define TIMER_FREQ

ack.  Robert Jarzmik also acked that one.

> . In the meantime I send a pull request asking to ignore that I didn't
> get any maintainer reply for the rtc changes. Do you think it's sensible
> to change the entry in MAINTAINERS? Any combination of:
> 
> 	a) drop Alessandro's M: line
> 	b) add you
> 	c) change Status from Maintained to Odd Fixes or Orphan

Yeah, I should have a couple hundred MAINTAINERS entries.  Instead I
just lurk on mailing lists ;)
Uwe Kleine-König Dec. 17, 2013, 8:15 a.m. UTC | #10
Hello Andrew,

On Mon, Dec 16, 2013 at 02:46:12PM -0800, Andrew Morton wrote:
> On Mon, 16 Dec 2013 20:28:16 +0100 Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de> wrote:
> 
> > Hello Andrew,
> > 
> > On Mon, Dec 16, 2013 at 12:11:58AM -0800, Andrew Morton wrote:
> > > On Tue, 26 Nov 2013 19:36:29 +0100 Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de> wrote:
> > > > On Tue, Nov 26, 2013 at 02:44:44PM +0100, Uwe Kleine-K__nig wrote:
> > > > > On Tue, Nov 26, 2013 at 02:41:17PM +0100, Uwe Kleine-K__nig wrote:
> > > > > > On Fri, Nov 15, 2013 at 03:00:58PM +0100, Uwe Kleine-K__nig wrote:
> > > > > > > The driver needs the symbol AT91_SLOW_CLOCK which is defined in
> > > > > > > arch/arm/mach-at91/include/mach/hardware.h. This file is included
> > > > > > > implicitly via linux/module.h -> linux/kmod.h -> linux/gfp.h ->
> > > > > > > linux/mmzone.h -> linux/memory_hotplug.h -> linux/notifier.h ->
> > > > > > > linux/srcu.h -> linux/workqueue.h -> linux/timer.h -> linux/ktime.h ->
> > > > > > > linux/jiffies.h -> linux/timex.h -> mach/timex.h -> mach/hardware.h .
> > > > > > > 
> > > > > > > So better include it explicitly not only because the last link will go
> > > > > > > away soon.
> > > > > > > 
> > > > > > > Signed-off-by: Uwe Kleine-K__nig <u.kleine-koenig@pengutronix.de>
> > > > > > Ping. Is this patch ok despite Jean-Christophe's objection?
> > > > > I saw that akpm already took it into his tree.
> > > > This patch is one of the last few that are needed to drop <mach/timex.h>
> > > > alltogether that I don't have an ack from the respective maintainer yet.
> > > > 
> > > > Can you give your ack instead of sending the patch to Linus, then I'd
> > > > take it with the patch dropping <mach/timex.h> to make it easier to
> > > > merge.
> > > 
> > > ack ;)
> > thanks. There is another rtc change that I didn't receive any feedback
> > for from a maintainer:
> > 
> > 	rtc: pxa: drop unused #define TIMER_FREQ
> 
> ack.  Robert Jarzmik also acked that one.
Thanks, I saw Robert Jarzmik's ack, but for taking a $subsystem1 patch through
the $subsystem2 tree, I like to have an ack of the maintainer of
$subsystem1. And in this regard I think yours is better than Robert's
(who is the original author of the driver).

> > . In the meantime I send a pull request asking to ignore that I didn't
> > get any maintainer reply for the rtc changes. Do you think it's sensible
> > to change the entry in MAINTAINERS? Any combination of:
> > 
> > 	a) drop Alessandro's M: line
> > 	b) add you
> > 	c) change Status from Maintained to Odd Fixes or Orphan
> 
> Yeah, I should have a couple hundred MAINTAINERS entries.  Instead I
> just lurk on mailing lists ;)
So only a) and c).

Best regards
Uwe
diff mbox

Patch

diff --git a/drivers/rtc/rtc-at91sam9.c b/drivers/rtc/rtc-at91sam9.c
index 309b8b3..5963743 100644
--- a/drivers/rtc/rtc-at91sam9.c
+++ b/drivers/rtc/rtc-at91sam9.c
@@ -24,7 +24,7 @@ 
 
 #include <mach/at91_rtt.h>
 #include <mach/cpu.h>
-
+#include <mach/hardware.h>
 
 /*
  * This driver uses two configurable hardware resources that live in the