<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/rtc, branch v2.6.27.40</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/rtc?h=v2.6.27.40</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/rtc?h=v2.6.27.40'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2008-11-07T03:05:50Z</updated>
<entry>
<title>rtc-cmos: look for PNP RTC first, then for platform RTC</title>
<updated>2008-11-07T03:05:50Z</updated>
<author>
<name>Bjorn Helgaas</name>
<email>bjorn.helgaas@hp.com</email>
</author>
<published>2008-10-26T22:56:04Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=257c3546190e87a6cb761ce146b4fe81b1ad8e86'/>
<id>urn:sha1:257c3546190e87a6cb761ce146b4fe81b1ad8e86</id>
<content type='text'>
commit 72f22b1eb6ca5e4676a632a04d40d46cb61d4562 upstream

rtc-cmos: look for PNP RTC first, then for platform RTC

We shouldn't rely on "pnp_platform_devices" to tell us whether there
is a PNP RTC device.

I introduced "pnp_platform_devices", but I think it was a mistake.
All it tells us is whether we found any PNPBIOS or PNPACPI devices.
Many machines have some PNP devices, but do not describe the RTC
via PNP.  On those machines, we need to do the platform driver probe
to find the RTC.

We should just register the PNP driver and see whether it claims anything.
If we don't find a PNP RTC, fall back to the platform driver probe.

This (in conjunction with the arch/x86/kernel/rtc.c patch to add
a platform RTC device when PNP doesn't have one) should resolve
these issues:

    http://bugzilla.kernel.org/show_bug.cgi?id=11580
    https://bugzilla.redhat.com/show_bug.cgi?id=451188

Signed-off-by: Bjorn Helgaas &lt;bjorn.helgaas@hp.com&gt;
Acked-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
Acked-by: David Brownell &lt;dbrownell@users.sourceforge.net&gt;
Reported-by: Rik Theys &lt;rik.theys@esat.kuleuven.be&gt;
Reported-by: shr_msn@yahoo.com.tw
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Chuck Ebbert &lt;cebbert@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>rtc: fix kernel panic on second use of SIGIO nofitication</title>
<updated>2008-10-04T01:22:17Z</updated>
<author>
<name>Marcin Slusarz</name>
<email>marcin.slusarz@gmail.com</email>
</author>
<published>2008-10-03T22:23:36Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=2e4a75cdcb89ff53bb182dda3a6dcdc14befe007'/>
<id>urn:sha1:2e4a75cdcb89ff53bb182dda3a6dcdc14befe007</id>
<content type='text'>
When userspace uses SIGIO notification and forgets to disable it before
closing file descriptor, rtc-&gt;async_queue contains stale pointer to struct
file.  When user space enables again SIGIO notification in different
process, kernel dereferences this (poisoned) pointer and crashes.

So disable SIGIO notification on close.

Kernel panic:
(second run of qemu (requires echo 1024 &gt; /sys/class/rtc/rtc0/max_user_freq))

general protection fault: 0000 [1] PREEMPT
CPU 0
Modules linked in: af_packet snd_pcm_oss snd_mixer_oss snd_seq_oss snd_seq_midi_event snd_seq usbhid tuner tea5767 tda8290 tuner_xc2028 xc5000 tda9887 tuner_simple tuner_types mt20xx tea5761 tda9875 uhci_hcd ehci_hcd usbcore bttv snd_via82xx snd_ac97_codec ac97_bus snd_pcm snd_timer ir_common compat_ioctl32 snd_page_alloc videodev v4l1_compat snd_mpu401_uart snd_rawmidi v4l2_common videobuf_dma_sg videobuf_core snd_seq_device snd btcx_risc soundcore tveeprom i2c_viapro
Pid: 5781, comm: qemu-system-x86 Not tainted 2.6.27-rc6 #363
RIP: 0010:[&lt;ffffffff8024f891&gt;]  [&lt;ffffffff8024f891&gt;] __lock_acquire+0x3db/0x73f
RSP: 0000:ffffffff80674cb8  EFLAGS: 00010002
RAX: ffff8800224c62f0 RBX: 0000000000000046 RCX: 0000000000000002
RDX: 0000000000000000 RSI: 0000000000000000 RDI: ffff8800224c62f0
RBP: ffffffff80674d08 R08: 0000000000000002 R09: 0000000000000001
R10: ffffffff80238941 R11: 0000000000000001 R12: 0000000000000000
R13: 6b6b6b6b6b6b6b6b R14: ffff88003a450080 R15: 0000000000000000
FS:  00007f98b69516f0(0000) GS:ffffffff80623200(0000) knlGS:00000000f7cc86d0
CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
CR2: 0000000000a87000 CR3: 0000000022598000 CR4: 00000000000006e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process qemu-system-x86 (pid: 5781, threadinfo ffff880028812000, task ffff88003a450080)
Stack:  ffffffff80674cf8 0000000180238440 0000000200000002 0000000000000000
 ffff8800224c62f0 0000000000000046 0000000000000000 0000000000000002
 0000000000000002 0000000000000000 ffffffff80674d68 ffffffff8024fc7a
Call Trace:
 &lt;IRQ&gt;  [&lt;ffffffff8024fc7a&gt;] lock_acquire+0x85/0xa9
 [&lt;ffffffff8029cb62&gt;] ? send_sigio+0x2a/0x184
 [&lt;ffffffff80491d1f&gt;] _read_lock+0x3e/0x4a
 [&lt;ffffffff8029cb62&gt;] ? send_sigio+0x2a/0x184
 [&lt;ffffffff8029cb62&gt;] send_sigio+0x2a/0x184
 [&lt;ffffffff8024fb97&gt;] ? __lock_acquire+0x6e1/0x73f
 [&lt;ffffffff8029cd4d&gt;] ? kill_fasync+0x2c/0x4e
 [&lt;ffffffff8029cd10&gt;] __kill_fasync+0x54/0x65
 [&lt;ffffffff8029cd5b&gt;] kill_fasync+0x3a/0x4e
 [&lt;ffffffff80402896&gt;] rtc_update_irq+0x9c/0xa5
 [&lt;ffffffff80404640&gt;] cmos_interrupt+0xae/0xc0
 [&lt;ffffffff8025d1c1&gt;] handle_IRQ_event+0x25/0x5a
 [&lt;ffffffff8025e5e4&gt;] handle_edge_irq+0xdd/0x123
 [&lt;ffffffff8020da34&gt;] do_IRQ+0xe4/0x144
 [&lt;ffffffff8020bad6&gt;] ret_from_intr+0x0/0xf
 &lt;EOI&gt;  [&lt;ffffffff8026fdc2&gt;] ? __alloc_pages_internal+0xe7/0x3ad
 [&lt;ffffffff8033fe67&gt;] ? clear_page_c+0x7/0x10
 [&lt;ffffffff8026fc10&gt;] ? get_page_from_freelist+0x385/0x450
 [&lt;ffffffff8026fdc2&gt;] ? __alloc_pages_internal+0xe7/0x3ad
 [&lt;ffffffff80280aac&gt;] ? anon_vma_prepare+0x2e/0xf6
 [&lt;ffffffff80279400&gt;] ? handle_mm_fault+0x227/0x6a5
 [&lt;ffffffff80494716&gt;] ? do_page_fault+0x494/0x83f
 [&lt;ffffffff8049251d&gt;] ? error_exit+0x0/0xa9

Code: cc 41 39 45 28 74 24 e8 5e 1d 0f 00 85 c0 0f 84 6a 03 00 00 83 3d 8f a9 aa 00 00 be 47 03 00 00 0f 84 6a 02 00 00 e9 53 03 00 00 &lt;41&gt; ff 85 38 01 00 00 45 8b be 90 06 00 00 41 83 ff 2f 76 24 e8
RIP  [&lt;ffffffff8024f891&gt;] __lock_acquire+0x3db/0x73f
 RSP &lt;ffffffff80674cb8&gt;
---[ end trace 431877d860448760 ]---
Kernel panic - not syncing: Aiee, killing interrupt handler!

Signed-off-by: Marcin Slusarz &lt;marcin.slusarz@gmail.com&gt;
Acked-by: Alessandro Zummo &lt;alessandro.zummo@towertech.it&gt;
Acked-by: David Brownell &lt;dbrownell@users.sourceforge.net&gt;
Cc: &lt;stable@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>rtc-cmos: wake again from S5</title>
<updated>2008-09-03T02:21:40Z</updated>
<author>
<name>Rafael J. Wysocki</name>
<email>rjw@sisk.pl</email>
</author>
<published>2008-09-02T21:36:11Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=74c4633da7994eddcfcd2762a448c6889cc2b5bd'/>
<id>urn:sha1:74c4633da7994eddcfcd2762a448c6889cc2b5bd</id>
<content type='text'>
Update rtc-cmos shutdown handling to leave RTC alarms active, resolving
http://bugzilla.kernel.org/show_bug.cgi?id=11411 on several boards.  There
are still some systems where the ACPI event handling doesn't cooperate.
(Possibly related to bugid 11312, reporting the spontaneous disabling of
RTC events.)

Bug 11411 reported that changes to work around some ACPI event issues
broke wake-from-S5 handling, as used for DVR applications.  (They like to
power off, then wake later to record programs.)

[yakui.zhao@intel.com: add shutdown for PNP devices]
[dbrownell@users.sourceforge.net: update comments]
Signed-off-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
Signed-off-by: Zhao Yakui &lt;yakui.zhao@intel.com&gt;
Signed-off-by: Zhang Rui &lt;rui.zhang@intel.com&gt;
Signed-off-by: David Brownell &lt;dbrownell@users.sourceforge.net&gt;
Cc: Stefan Bauer &lt;stefan.bauer@cs.tu-chemnitz.de&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>rtc_time_to_tm: fix signed/unsigned arithmetic</title>
<updated>2008-09-03T02:21:40Z</updated>
<author>
<name>Jan Altenberg</name>
<email>jan.altenberg@linutronix.de</email>
</author>
<published>2008-09-02T21:36:05Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=73442daf2ea85e2a779396b76b1a39b10188ecb5'/>
<id>urn:sha1:73442daf2ea85e2a779396b76b1a39b10188ecb5</id>
<content type='text'>
commit 945185a69daa457c4c5e46e47f4afad7dcea734f ("rtc: rtc_time_to_tm: use
unsigned arithmetic") changed the some types in rtc_time_to_tm() to
unsigned:

 void rtc_time_to_tm(unsigned long time, struct rtc_time *tm)
 {
-       register int days, month, year;
+       unsigned int days, month, year;

This doesn't work for all cases, because days is checked for &lt; 0 later
on:

if (days &lt; 0) {
	year -= 1;
	days += 365 + LEAP_YEAR(year);
}

I think the correct fix would be to keep days signed and do an appropriate
cast later on.

Signed-off-by: Jan Altenberg &lt;jan.altenberg@linutronix.de&gt;
Cc: Maciej W. Rozycki &lt;macro@linux-mips.org&gt;
Cc: Alessandro Zummo &lt;a.zummo@towertech.it&gt;
Cc: David Brownell &lt;david-b@pacbell.net&gt;
Cc: Dmitri Vorobiev &lt;dmitri.vorobiev@gmail.com&gt;
Cc: &lt;stable@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>removed unused #include &lt;linux/version.h&gt;'s</title>
<updated>2008-08-23T19:14:12Z</updated>
<author>
<name>Adrian Bunk</name>
<email>bunk@kernel.org</email>
</author>
<published>2008-08-17T14:36:59Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7a8fc9b248e77a4eab0613acf30a6811799786b3'/>
<id>urn:sha1:7a8fc9b248e77a4eab0613acf30a6811799786b3</id>
<content type='text'>
This patch lets the files using linux/version.h match the files that
#include it.

Signed-off-by: Adrian Bunk &lt;bunk@kernel.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>rtc: rtc-ds1374: fix 'no irq' case handling</title>
<updated>2008-08-20T22:40:32Z</updated>
<author>
<name>Anton Vorontsov</name>
<email>avorontsov@ru.mvista.com</email>
</author>
<published>2008-08-20T21:09:21Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=b42f931737bea8ca3982449d63ec46410d13e891'/>
<id>urn:sha1:b42f931737bea8ca3982449d63ec46410d13e891</id>
<content type='text'>
On a PowerPC board with ds1374 RTC I'm getting this error while RTC tries
to probe:

rtc-ds1374 0-0068: unable to request IRQ

This happens because I2C probing code (drivers/of/of_i2c.c) is specifying
IRQ0 for 'no irq' case, which is correct.

The driver handles this incorrectly, though. This patch fixes it.

Signed-off-by: Anton Vorontsov &lt;avorontsov@ru.mvista.com&gt;
Cc: David Brownell &lt;david-b@pacbell.net&gt;
Cc: Alessandro Zummo &lt;a.zummo@towertech.it&gt;
Acked-by: Peter Korsgaard &lt;jacmet@sunsite.dk&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>rtc: fix double lock on UIE emulation</title>
<updated>2008-08-20T22:40:31Z</updated>
<author>
<name>Atsushi Nemoto</name>
<email>anemo@mba.ocn.ne.jp</email>
</author>
<published>2008-08-20T21:09:11Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=1d96469a34781340b2cc9bdf97d5913eecdaa038'/>
<id>urn:sha1:1d96469a34781340b2cc9bdf97d5913eecdaa038</id>
<content type='text'>
With commit 5ad31a575157147b43fa84ef1e21471661653878 ("rtc: remove BKL
for ioctl()"), RTC_UIE_ON ioctl cause double lock on rtc-&gt;ops_lock.
The ops_lock must not be held while set_uie() calls rtc_read_time()
which takes the lock.  Also clear_uie() does not need ops_lock.  This
patch fixes return value of RTC_UIE_OFF ioctl too.

Signed-off-by: Atsushi Nemoto &lt;anemo@mba.ocn.ne.jp&gt;
Cc: David Brownell &lt;david-b@pacbell.net&gt;
Cc: Russell King &lt;rmk@arm.linux.org.uk&gt;
Cc: Alessandro Zummo &lt;a.zummo@towertech.it&gt;
Cc: "Rafael J. Wysocki" &lt;rjw@sisk.pl&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Blackfin RTC Driver: dont let RTC programming in bootloaders randomly cause ~5 second boot delays</title>
<updated>2008-08-20T22:40:30Z</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier.adi@gmail.com</email>
</author>
<published>2008-08-20T21:09:03Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=d0fd93781c49cbe127f9e7a5b402e9b167c105a6'/>
<id>urn:sha1:d0fd93781c49cbe127f9e7a5b402e9b167c105a6</id>
<content type='text'>
Signed-off-by: Mike Frysinger &lt;vapier.adi@gmail.com&gt;
Signed-off-by: Bryan Wu &lt;cooloney@kernel.org&gt;
Cc: Alessandro Zummo &lt;a.zummo@towertech.it&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Blackfin RTC Driver: BF561 not have on-chip RTC</title>
<updated>2008-08-20T22:40:30Z</updated>
<author>
<name>Graf Yang</name>
<email>graf.yang@analog.com</email>
</author>
<published>2008-08-20T21:09:02Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=7f60459921bd24e86b21e07c42244c510b4f46b2'/>
<id>urn:sha1:7f60459921bd24e86b21e07c42244c510b4f46b2</id>
<content type='text'>
Signed-off-by: Graf Yang &lt;graf.yang@analog.com&gt;
Signed-off-by: Bryan Wu &lt;cooloney@kernel.org&gt;
Cc: Alessandro Zummo &lt;a.zummo@towertech.it&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>Blackfin RTC Driver: do all initialization before we register the rtc and make it available</title>
<updated>2008-08-20T22:40:30Z</updated>
<author>
<name>Mike Frysinger</name>
<email>vapier.adi@gmail.com</email>
</author>
<published>2008-08-20T21:09:02Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=8c9166f7a60b67909632ea60a032c18d84ed8af0'/>
<id>urn:sha1:8c9166f7a60b67909632ea60a032c18d84ed8af0</id>
<content type='text'>
Signed-off-by: Mike Frysinger &lt;vapier.adi@gmail.com&gt;
Signed-off-by: Bryan Wu &lt;cooloney@kernel.org&gt;
Cc: Alessandro Zummo &lt;a.zummo@towertech.it&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
</feed>
