Re: [PATCH] RTC: Add mmap method to rtc character driver

From: hui
Date: Sat Jul 29 2006 - 16:39:25 EST

On Sat, Jul 29, 2006 at 08:54:27AM -0400, Neil Horman wrote:
> On Fri, Jul 28, 2006 at 09:28:20PM -0700, Bill Huey wrote:
> > Not to poop on people's parade, but the last time I looked /dev/rtc was
> > a single instance device, right ? If this reasoning is true, then mplayer
> > and other apps that want to open it can't.
> >
> > What's the story with this ?
> >
> Its always been the case. Its hardware can only support one timer (or at least
> one timer period), and as such multiple users would interefere with each other.

Well, this points out a serious problem with doing an mmap extension to
/dev/rtc. It would be better to have a page mapped by another device like
/dev/jiffy_counter, or something like that rather than to overload the
/dev/rtc with that functionality. The semantic for this change is shadey
in the first place so you should consider that option. It basically means
that, if Xorg, adopts this interface, no userspace applications can get at
and use the 'rtc' for any existing purposes with X running (mplayer and

It's not a really usable interface for Keith's purposes because of this
and it is a serious problem. You might want to consider writting special
device to do this like I mentioned above instead of mmap extension to


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at