All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] generic RTC support for PPC
@ 2007-01-25  7:37 Olof Johansson
  2007-01-30  5:17 ` Tom Rini
  2007-02-06 11:08 ` Paul Mackerras
  0 siblings, 2 replies; 15+ messages in thread
From: Olof Johansson @ 2007-01-25  7:37 UTC (permalink / raw)
  To: paulus; +Cc: linuxppc-dev, kimphill

Make the PPC RTC functions use the generic RTC infrastructure if they
are not already defined (and an RTC is registered in the system).

This should make it possible to remove the hideous direct access used
in some of the 83xx platforms.


Signed-off-by: Olof Johansson <olof@lixom.net>

Index: powerpc/arch/powerpc/Kconfig
===================================================================
--- powerpc.orig/arch/powerpc/Kconfig
+++ powerpc/arch/powerpc/Kconfig
@@ -687,6 +687,12 @@ config TAU_AVERAGE
 
 	  If in doubt, say N here.
 
+config PPC_GENRTC
+	bool "Generic RTC support"
+	help
+	  Support for using regular RTC registered with the RTC framework
+	  as the main hardware clock on powerpc.
+
 endmenu
 
 source arch/powerpc/platforms/embedded6xx/Kconfig
Index: powerpc/arch/powerpc/sysdev/Makefile
===================================================================
--- powerpc.orig/arch/powerpc/sysdev/Makefile
+++ powerpc/arch/powerpc/sysdev/Makefile
@@ -22,4 +22,5 @@ endif
 ifeq ($(ARCH),powerpc)
 obj-$(CONFIG_MTD)		+= rom.o
 obj-$(CONFIG_CPM2)		+= cpm2_common.o cpm2_pic.o
+obj-$(CONFIG_PPC_GENRTC)	+= genrtc.o
 endif
Index: powerpc/arch/powerpc/sysdev/genrtc.c
===================================================================
--- /dev/null
+++ powerpc/arch/powerpc/sysdev/genrtc.c
@@ -0,0 +1,76 @@
+/*
+ * Copyright (C) Olof Johansson <olof@lixom.net>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+ */
+
+#include <linux/time.h>
+#include <linux/device.h>
+#include <linux/rtc.h>
+
+#include <asm/machdep.h>
+#include <asm/time.h>
+
+static struct class_device *rtc_dev;
+
+static void genrtc_set_rtc_time_work(struct work_struct *work);
+
+static struct rtc_time delayed_tm;
+static struct workqueue_struct *rtc_workqueue;
+static DECLARE_WORK(rtc_work, genrtc_set_rtc_time_work);
+
+static void genrtc_set_rtc_time_work(struct work_struct *work)
+{
+	rtc_set_time(rtc_dev, &delayed_tm);
+}
+
+static int genrtc_set_rtc_time(struct rtc_time *tm)
+{
+	if (in_interrupt()) {
+		/* Can't access RTC with interrupts off, since some of
+		 * the drivers might sleep. Delay the setting with a
+		 * work queue.
+		 */
+		memcpy(&delayed_tm, tm, sizeof(struct rtc_time));
+		queue_work(rtc_workqueue, &rtc_work);
+		return 0;
+	} else
+		return rtc_set_time(rtc_dev, tm);
+}
+
+static void genrtc_get_rtc_time(struct rtc_time *tm)
+{
+	rtc_read_time(rtc_dev, tm);
+}
+
+static int __init genrtc_rtc_hookup(void)
+{
+	/* Don't init if the platform has already set up rtc functions. */
+	if (ppc_md.get_rtc_time || ppc_md.set_rtc_time)
+		return -1;
+
+	rtc_dev = rtc_class_open("rtc0");
+
+	if (!rtc_dev) {
+		printk("genrtc_rtc_hookup: Failed to open rtc0\n");
+		return -1;
+	}
+
+	ppc_md.get_rtc_time = genrtc_get_rtc_time;
+	ppc_md.set_rtc_time = genrtc_set_rtc_time;
+
+	return 0;
+}
+late_initcall(genrtc_rtc_hookup);
+

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

* Re: [PATCH] generic RTC support for PPC
  2007-01-25  7:37 [PATCH] generic RTC support for PPC Olof Johansson
@ 2007-01-30  5:17 ` Tom Rini
  2007-01-30  6:37   ` Kumar Gala
  2007-02-06 11:08 ` Paul Mackerras
  1 sibling, 1 reply; 15+ messages in thread
From: Tom Rini @ 2007-01-30  5:17 UTC (permalink / raw)
  To: Olof Johansson; +Cc: linuxppc-dev, paulus, kimphill

On Thu, Jan 25, 2007 at 01:37:54AM -0600, Olof Johansson wrote:

> Make the PPC RTC functions use the generic RTC infrastructure if they
> are not already defined (and an RTC is registered in the system).
> 
> This should make it possible to remove the hideous direct access used
> in some of the 83xx platforms.

Now, I know I'm a bit late, and I've been quiet of late, but, um, why is
there anything other than the RTC class stuff being used?  I know
drivers/char/genrtc.c isn't gone yet, but really, it should be in the
process of being phased out.  IMHO, it should depend on !POWERPC (or
whatever the magic is to allow arch/ppc && !arch/powerpc).

-- 
Tom Rini

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

* Re: [PATCH] generic RTC support for PPC
  2007-01-30  5:17 ` Tom Rini
@ 2007-01-30  6:37   ` Kumar Gala
  2007-01-30 16:03     ` Olof Johansson
  0 siblings, 1 reply; 15+ messages in thread
From: Kumar Gala @ 2007-01-30  6:37 UTC (permalink / raw)
  To: Tom Rini; +Cc: Olof Johansson, linuxppc-dev, paulus, kimphill


On Jan 29, 2007, at 11:17 PM, Tom Rini wrote:

> On Thu, Jan 25, 2007 at 01:37:54AM -0600, Olof Johansson wrote:
>
>> Make the PPC RTC functions use the generic RTC infrastructure if they
>> are not already defined (and an RTC is registered in the system).
>>
>> This should make it possible to remove the hideous direct access used
>> in some of the 83xx platforms.
>
> Now, I know I'm a bit late, and I've been quiet of late, but, um,  
> why is
> there anything other than the RTC class stuff being used?  I know
> drivers/char/genrtc.c isn't gone yet, but really, it should be in the
> process of being phased out.  IMHO, it should depend on !POWERPC (or
> whatever the magic is to allow arch/ppc && !arch/powerpc).

I think the problem was calling the RTC class code from the place's  
we use rtc in ppc had locking issues or something like that.

- k

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

* Re: [PATCH] generic RTC support for PPC
  2007-01-30  6:37   ` Kumar Gala
@ 2007-01-30 16:03     ` Olof Johansson
  2007-01-30 18:53       ` Tom Rini
  2007-01-30 19:25         ` Kim Phillips
  0 siblings, 2 replies; 15+ messages in thread
From: Olof Johansson @ 2007-01-30 16:03 UTC (permalink / raw)
  To: Kumar Gala; +Cc: Tom Rini, paulus, kimphill, linuxppc-dev

On Tue, Jan 30, 2007 at 12:37:12AM -0600, Kumar Gala wrote:
> 
> On Jan 29, 2007, at 11:17 PM, Tom Rini wrote:
> 
> >On Thu, Jan 25, 2007 at 01:37:54AM -0600, Olof Johansson wrote:
> >
> >>Make the PPC RTC functions use the generic RTC infrastructure if they
> >>are not already defined (and an RTC is registered in the system).
> >>
> >>This should make it possible to remove the hideous direct access used
> >>in some of the 83xx platforms.
> >
> >Now, I know I'm a bit late, and I've been quiet of late, but, um,  
> >why is
> >there anything other than the RTC class stuff being used?  I know
> >drivers/char/genrtc.c isn't gone yet, but really, it should be in the
> >process of being phased out.  IMHO, it should depend on !POWERPC (or
> >whatever the magic is to allow arch/ppc && !arch/powerpc).
> 
> I think the problem was calling the RTC class code from the place's  
> we use rtc in ppc had locking issues or something like that.

Yes, and it does a direct call into the driver instead of using the
subsystem, exporting the symbol from the driver. Not a very pretty
solution but it's possible that the genrtc stuff wasn't available when
it was first implemented.


-Olof

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

* Re: [PATCH] generic RTC support for PPC
  2007-01-30 16:03     ` Olof Johansson
@ 2007-01-30 18:53       ` Tom Rini
  2007-01-30 19:25         ` Kim Phillips
  1 sibling, 0 replies; 15+ messages in thread
From: Tom Rini @ 2007-01-30 18:53 UTC (permalink / raw)
  To: Olof Johansson; +Cc: kimphill, paulus, linuxppc-dev

On Tue, Jan 30, 2007 at 10:03:40AM -0600, Olof Johansson wrote:
> On Tue, Jan 30, 2007 at 12:37:12AM -0600, Kumar Gala wrote:
> > 
> > On Jan 29, 2007, at 11:17 PM, Tom Rini wrote:
> > 
> > >On Thu, Jan 25, 2007 at 01:37:54AM -0600, Olof Johansson wrote:
> > >
> > >>Make the PPC RTC functions use the generic RTC infrastructure if they
> > >>are not already defined (and an RTC is registered in the system).
> > >>
> > >>This should make it possible to remove the hideous direct access used
> > >>in some of the 83xx platforms.
> > >
> > >Now, I know I'm a bit late, and I've been quiet of late, but, um,  
> > >why is
> > >there anything other than the RTC class stuff being used?  I know
> > >drivers/char/genrtc.c isn't gone yet, but really, it should be in the
> > >process of being phased out.  IMHO, it should depend on !POWERPC (or
> > >whatever the magic is to allow arch/ppc && !arch/powerpc).
> > 
> > I think the problem was calling the RTC class code from the place's  
> > we use rtc in ppc had locking issues or something like that.

Sounds like the RTC class code needs to be fixed up then.  There's
really no good reason for drivers/char/genrtc.c to live anymore, a
better 'generic rtc' driver set exists now.

> Yes, and it does a direct call into the driver instead of using the
> subsystem, exporting the symbol from the driver. Not a very pretty
> solution but it's possible that the genrtc stuff wasn't available when
> it was first implemented.

genrtc is quite old, really :)

-- 
Tom Rini

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

* Re: [PATCH] generic RTC support for PPC
  2007-01-30 16:03     ` Olof Johansson
@ 2007-01-30 19:25         ` Kim Phillips
  2007-01-30 19:25         ` Kim Phillips
  1 sibling, 0 replies; 15+ messages in thread
From: Kim Phillips @ 2007-01-30 19:25 UTC (permalink / raw)
  To: Olof Johansson
  Cc: galak, trini, linuxppc-dev, paulus, Scott Wood, david-b, linux-kernel

On Tue, 30 Jan 2007 10:03:40 -0600
olof@lixom.net (Olof Johansson) wrote:

> On Tue, Jan 30, 2007 at 12:37:12AM -0600, Kumar Gala wrote:
> > 
> > On Jan 29, 2007, at 11:17 PM, Tom Rini wrote:
> > 
> > >On Thu, Jan 25, 2007 at 01:37:54AM -0600, Olof Johansson wrote:
> > >
> > >>Make the PPC RTC functions use the generic RTC infrastructure if they
> > >>are not already defined (and an RTC is registered in the system).
> > >>
> > >>This should make it possible to remove the hideous direct access used
> > >>in some of the 83xx platforms.
> > >
> > >Now, I know I'm a bit late, and I've been quiet of late, but, um,  
> > >why is
> > >there anything other than the RTC class stuff being used?  I know
> > >drivers/char/genrtc.c isn't gone yet, but really, it should be in the
> > >process of being phased out.  IMHO, it should depend on !POWERPC (or
> > >whatever the magic is to allow arch/ppc && !arch/powerpc).
> > 
> > I think the problem was calling the RTC class code from the place's  
> > we use rtc in ppc had locking issues or something like that.
> 
> Yes, and it does a direct call into the driver instead of using the
> subsystem, exporting the symbol from the driver. Not a very pretty
> solution but it's possible that the genrtc stuff wasn't available when
> it was first implemented.
> 
that's probably true.

afaict, this powerpc platform <--> RTC class code glue is totally unnecessary; RTC class sets things up fine on 83xx based boards that have rtc chips supported in RTC class (e.g., the ITX).  I'm referring to the third bullet point here:

http://marc.theaimsgroup.com/?l=linux-kernel&m=116387226902131&w=2

For the MDS boards, which use the ds1374, I'd rather fix the problem properly and add a ds1374 driver to the RTC class.  While Scott Wood (cc'd) has already done the port, I believe his patches are pending some patches by David Brownell.

Kim

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

* Re: [PATCH] generic RTC support for PPC
@ 2007-01-30 19:25         ` Kim Phillips
  0 siblings, 0 replies; 15+ messages in thread
From: Kim Phillips @ 2007-01-30 19:25 UTC (permalink / raw)
  To: Olof Johansson; +Cc: trini, linux-kernel, david-b, linuxppc-dev, paulus

On Tue, 30 Jan 2007 10:03:40 -0600
olof@lixom.net (Olof Johansson) wrote:

> On Tue, Jan 30, 2007 at 12:37:12AM -0600, Kumar Gala wrote:
> > 
> > On Jan 29, 2007, at 11:17 PM, Tom Rini wrote:
> > 
> > >On Thu, Jan 25, 2007 at 01:37:54AM -0600, Olof Johansson wrote:
> > >
> > >>Make the PPC RTC functions use the generic RTC infrastructure if they
> > >>are not already defined (and an RTC is registered in the system).
> > >>
> > >>This should make it possible to remove the hideous direct access used
> > >>in some of the 83xx platforms.
> > >
> > >Now, I know I'm a bit late, and I've been quiet of late, but, um,  
> > >why is
> > >there anything other than the RTC class stuff being used?  I know
> > >drivers/char/genrtc.c isn't gone yet, but really, it should be in the
> > >process of being phased out.  IMHO, it should depend on !POWERPC (or
> > >whatever the magic is to allow arch/ppc && !arch/powerpc).
> > 
> > I think the problem was calling the RTC class code from the place's  
> > we use rtc in ppc had locking issues or something like that.
> 
> Yes, and it does a direct call into the driver instead of using the
> subsystem, exporting the symbol from the driver. Not a very pretty
> solution but it's possible that the genrtc stuff wasn't available when
> it was first implemented.
> 
that's probably true.

afaict, this powerpc platform <--> RTC class code glue is totally unnecessary; RTC class sets things up fine on 83xx based boards that have rtc chips supported in RTC class (e.g., the ITX).  I'm referring to the third bullet point here:

http://marc.theaimsgroup.com/?l=linux-kernel&m=116387226902131&w=2

For the MDS boards, which use the ds1374, I'd rather fix the problem properly and add a ds1374 driver to the RTC class.  While Scott Wood (cc'd) has already done the port, I believe his patches are pending some patches by David Brownell.

Kim

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

* Re: [PATCH] generic RTC support for PPC
  2007-01-30 19:25         ` Kim Phillips
@ 2007-01-30 19:55           ` David Brownell
  -1 siblings, 0 replies; 15+ messages in thread
From: David Brownell @ 2007-01-30 19:55 UTC (permalink / raw)
  To: Kim Phillips
  Cc: Olof Johansson, galak, trini, linuxppc-dev, paulus, Scott Wood,
	linux-kernel

On Tuesday 30 January 2007 11:25 am, Kim Phillips wrote:
> 
> For the MDS boards, which use the ds1374, I'd rather fix the problem properly
> and add a ds1374 driver to the RTC class.  While Scott Wood (cc'd) has already
> done the port, I believe his patches are pending some patches by David Brownell.  

I can't imagine what such patches would be, unless maybe you're referring to
I2C framework updates that make it follow the driver model and support platform
specific data, like an RTC alarm's IRQ number?  Those will take some time.

Just submit a normal I2C driver for that RTC, and any IRQ capability can be
added later.  (Or as a board-specific patch, which seems to be the normal
solution for I2C, though they won't go upstream.)

- Dave


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

* Re: [PATCH] generic RTC support for PPC
@ 2007-01-30 19:55           ` David Brownell
  0 siblings, 0 replies; 15+ messages in thread
From: David Brownell @ 2007-01-30 19:55 UTC (permalink / raw)
  To: Kim Phillips; +Cc: trini, linuxppc-dev, linux-kernel, paulus, Olof Johansson

On Tuesday 30 January 2007 11:25 am, Kim Phillips wrote:
> 
> For the MDS boards, which use the ds1374, I'd rather fix the problem properly
> and add a ds1374 driver to the RTC class.  While Scott Wood (cc'd) has already
> done the port, I believe his patches are pending some patches by David Brownell.  

I can't imagine what such patches would be, unless maybe you're referring to
I2C framework updates that make it follow the driver model and support platform
specific data, like an RTC alarm's IRQ number?  Those will take some time.

Just submit a normal I2C driver for that RTC, and any IRQ capability can be
added later.  (Or as a board-specific patch, which seems to be the normal
solution for I2C, though they won't go upstream.)

- Dave

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

* Re: [PATCH] generic RTC support for PPC
  2007-01-25  7:37 [PATCH] generic RTC support for PPC Olof Johansson
  2007-01-30  5:17 ` Tom Rini
@ 2007-02-06 11:08 ` Paul Mackerras
  2007-02-06 14:40   ` Kumar Gala
  2007-02-06 15:16   ` Olof Johansson
  1 sibling, 2 replies; 15+ messages in thread
From: Paul Mackerras @ 2007-02-06 11:08 UTC (permalink / raw)
  To: Olof Johansson; +Cc: linuxppc-dev, kimphill

Olof Johansson writes:

> Make the PPC RTC functions use the generic RTC infrastructure if they
> are not already defined (and an RTC is registered in the system).
> 
> This should make it possible to remove the hideous direct access used
> in some of the 83xx platforms.

What was the consensus in the end about this?  Should it go in for
2.6.21?

Paul.

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

* Re: [PATCH] generic RTC support for PPC
  2007-02-06 11:08 ` Paul Mackerras
@ 2007-02-06 14:40   ` Kumar Gala
  2007-02-06 15:24     ` Olof Johansson
  2007-02-06 15:16   ` Olof Johansson
  1 sibling, 1 reply; 15+ messages in thread
From: Kumar Gala @ 2007-02-06 14:40 UTC (permalink / raw)
  To: Paul Mackerras; +Cc: Olof Johansson, linuxppc-dev, kimphill


On Feb 6, 2007, at 5:08 AM, Paul Mackerras wrote:

> Olof Johansson writes:
>
>> Make the PPC RTC functions use the generic RTC infrastructure if they
>> are not already defined (and an RTC is registered in the system).
>>
>> This should make it possible to remove the hideous direct access used
>> in some of the 83xx platforms.
>
> What was the consensus in the end about this?  Should it go in for
> 2.6.21?

Are the "scheduling while atomic" issues that existed before actually  
been fixed?

http://marc.theaimsgroup.com/?l=linux-kernel&m=116378523012349&w=2

- k

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

* Re: [PATCH] generic RTC support for PPC
  2007-02-06 11:08 ` Paul Mackerras
  2007-02-06 14:40   ` Kumar Gala
@ 2007-02-06 15:16   ` Olof Johansson
  1 sibling, 0 replies; 15+ messages in thread
From: Olof Johansson @ 2007-02-06 15:16 UTC (permalink / raw)
  To: Paul Mackerras; +Cc: linuxppc-dev, kimphill

On Tue, Feb 06, 2007 at 10:08:35PM +1100, Paul Mackerras wrote:
> Olof Johansson writes:
> 
> > Make the PPC RTC functions use the generic RTC infrastructure if they
> > are not already defined (and an RTC is registered in the system).
> > 
> > This should make it possible to remove the hideous direct access used
> > in some of the 83xx platforms.
> 
> What was the consensus in the end about this?  Should it go in for
> 2.6.21?

Sounds like Tom Rini was strongly against it since the rtc class api
should be the way to do it now. I don't care much either way, and
it's not urgent for 2.6.21. Leave it out for now, I had written it off
already myself.



-Olof

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

* Re: [PATCH] generic RTC support for PPC
  2007-02-06 14:40   ` Kumar Gala
@ 2007-02-06 15:24     ` Olof Johansson
  2007-02-06 16:16       ` Kumar Gala
  0 siblings, 1 reply; 15+ messages in thread
From: Olof Johansson @ 2007-02-06 15:24 UTC (permalink / raw)
  To: Kumar Gala; +Cc: linuxppc-dev, Paul Mackerras, kimphill

On Tue, Feb 06, 2007 at 08:40:33AM -0600, Kumar Gala wrote:
> 
> On Feb 6, 2007, at 5:08 AM, Paul Mackerras wrote:
> 
> >Olof Johansson writes:
> >
> >>Make the PPC RTC functions use the generic RTC infrastructure if they
> >>are not already defined (and an RTC is registered in the system).
> >>
> >>This should make it possible to remove the hideous direct access used
> >>in some of the 83xx platforms.
> >
> >What was the consensus in the end about this?  Should it go in for
> >2.6.21?
> 
> Are the "scheduling while atomic" issues that existed before actually  
> been fixed?
> 
> http://marc.theaimsgroup.com/?l=linux-kernel&m=116378523012349&w=2

My patch shouldn't do it since it uses a work queue, but that bug report
was for the rtc class api instead of genrtc. It'll need something similar.

I can't even find the rtc_class_hookup code in 2.6.20, so I'm not sure
just what he was running.


-Olof

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

* Re: [PATCH] generic RTC support for PPC
  2007-02-06 15:24     ` Olof Johansson
@ 2007-02-06 16:16       ` Kumar Gala
  2007-02-07  1:55         ` Kim Phillips
  0 siblings, 1 reply; 15+ messages in thread
From: Kumar Gala @ 2007-02-06 16:16 UTC (permalink / raw)
  To: Olof Johansson; +Cc: linuxppc-dev, Paul Mackerras, kimphill


On Feb 6, 2007, at 9:24 AM, Olof Johansson wrote:

> On Tue, Feb 06, 2007 at 08:40:33AM -0600, Kumar Gala wrote:
>>
>> On Feb 6, 2007, at 5:08 AM, Paul Mackerras wrote:
>>
>>> Olof Johansson writes:
>>>
>>>> Make the PPC RTC functions use the generic RTC infrastructure if  
>>>> they
>>>> are not already defined (and an RTC is registered in the system).
>>>>
>>>> This should make it possible to remove the hideous direct access  
>>>> used
>>>> in some of the 83xx platforms.
>>>
>>> What was the consensus in the end about this?  Should it go in for
>>> 2.6.21?
>>
>> Are the "scheduling while atomic" issues that existed before actually
>> been fixed?
>>
>> http://marc.theaimsgroup.com/?l=linux-kernel&m=116378523012349&w=2
>
> My patch shouldn't do it since it uses a work queue, but that bug  
> report
> was for the rtc class api instead of genrtc. It'll need something  
> similar.
>
> I can't even find the rtc_class_hookup code in 2.6.20, so I'm not sure
> just what he was running.

Not 100% sure but we did back out some of the patches to arch/powerpc  
code related to this.

- k

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

* Re: [PATCH] generic RTC support for PPC
  2007-02-06 16:16       ` Kumar Gala
@ 2007-02-07  1:55         ` Kim Phillips
  0 siblings, 0 replies; 15+ messages in thread
From: Kim Phillips @ 2007-02-07  1:55 UTC (permalink / raw)
  To: Kumar Gala; +Cc: olof, linuxppc-dev, paulus, kimphill

On Tue, 6 Feb 2007 10:16:55 -0600
Kumar Gala <galak@kernel.crashing.org> wrote:

> 
> On Feb 6, 2007, at 9:24 AM, Olof Johansson wrote:
> 
> > On Tue, Feb 06, 2007 at 08:40:33AM -0600, Kumar Gala wrote:
> >>
> >> On Feb 6, 2007, at 5:08 AM, Paul Mackerras wrote:
> >>
> >>> Olof Johansson writes:
> >>>
> >>>> Make the PPC RTC functions use the generic RTC infrastructure if  
> >>>> they
> >>>> are not already defined (and an RTC is registered in the system).
> >>>>
> >>>> This should make it possible to remove the hideous direct access  
> >>>> used
> >>>> in some of the 83xx platforms.
> >>>
> >>> What was the consensus in the end about this?  Should it go in for
> >>> 2.6.21?
> >>
> >> Are the "scheduling while atomic" issues that existed before actually
> >> been fixed?
> >>
> >> http://marc.theaimsgroup.com/?l=linux-kernel&m=116378523012349&w=2
> >
> > My patch shouldn't do it since it uses a work queue, but that bug  
> > report
> > was for the rtc class api instead of genrtc. It'll need something  
> > similar.
> >
> > I can't even find the rtc_class_hookup code in 2.6.20, so I'm not sure
> > just what he was running.
> 
> Not 100% sure but we did back out some of the patches to arch/powerpc  
> code related to this.
> 
hwclock works fine here without this patch.  So unless there is a dependency I'm unaware of, this patch should not go into 2.6.21.

I'll send a patch out to remove the ds1374_[gs]et_rtc_time cruft from the 83xxMDS platform files when the ds1374 rtc class support patch goes in.

Kim

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

end of thread, other threads:[~2007-02-07  1:55 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-01-25  7:37 [PATCH] generic RTC support for PPC Olof Johansson
2007-01-30  5:17 ` Tom Rini
2007-01-30  6:37   ` Kumar Gala
2007-01-30 16:03     ` Olof Johansson
2007-01-30 18:53       ` Tom Rini
2007-01-30 19:25       ` Kim Phillips
2007-01-30 19:25         ` Kim Phillips
2007-01-30 19:55         ` David Brownell
2007-01-30 19:55           ` David Brownell
2007-02-06 11:08 ` Paul Mackerras
2007-02-06 14:40   ` Kumar Gala
2007-02-06 15:24     ` Olof Johansson
2007-02-06 16:16       ` Kumar Gala
2007-02-07  1:55         ` Kim Phillips
2007-02-06 15:16   ` Olof Johansson

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.