12 Jun, 2009
1 commit
-
Evidently, set_rtc_time is supposed to be overridable
by architectures that define their own version, but
unfortunately, get_rtc_ss would in that case still
use the generic version.This makes get_rtc_ss call the real set_rtc_time
to let architectures define their own version.
The change should fix the "Extended RTC operation"
on Alpha, which uses the incorrect get_rtc_ss
call. It also allows PowerPC to use the asm-generic/rtc.h
file in the future.Cc: Richard Henderson
Cc: linux-alpha@vger.kernel.org
Cc: Tom Rini
Cc: rtc-linux@googlegroups.com
Cc: Alessandro Zummo
Cc: Paul Gortmaker
Signed-off-by: Arnd Bergmann
16 Jan, 2009
1 commit
-
Unlike other alphas, marvel doesn't have real PC-style CMOS clock hardware
- RTC accesses are emulated via PAL calls. Unfortunately, for unknown
reason these calls work only on CPU #0. So current implementation for
arbitrary CPU makes CMOS_READ/WRITE to be executed on CPU #0 via IPI.
However, for obvious reason this doesn't work with standard
get/set_rtc_time() functions, where a bunch of CMOS accesses is done with
disabled interrupts.Solved by making the IPI calls for entire get/set_rtc_time() functions,
not for individual CMOS accesses. Which is also a lot more effective
performance-wise.The patch is largely based on the code from Jay Estabrook.
My changes:
- tweak asm-generic/rtc.h by adding a couple of #defines to
avoid a massive code duplication in arch/alpha/include/asm/rtc.h;
- sys_marvel.c: fix get/set_rtc_time() return values (Jay's FIXMEs).NOTE: this fixes *only* LIB_RTC drivers. Legacy (CONFIG_RTC) driver
wont't work on marvel. Actually I think that we should just disable
CONFIG_RTC on alpha (maybe in 2.6.30?), like most other arches - AFAIK,
all modern distributions use LIB_RTC anyway.Signed-off-by: Ivan Kokshaysky
Cc: Richard Henderson
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
20 Oct, 2008
1 commit
-
Change various rtc related code to use the new bcd2bin/bin2bcd functions
instead of the obsolete BCD_TO_BIN/BIN_TO_BCD/BCD2BIN/BIN2BCD macros.Signed-off-by: Adrian Bunk
Acked-by: Alessandro Zummo
Cc: David Brownell
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
24 Aug, 2008
1 commit
-
if get_rtc_time() is _ever_ called with IRQs off, we deadlock badly
in it, waiting for jiffies to increment.So make the code more robust by doing an explicit mdelay(20).
This solves a very hard to reproduce/debug hard lockup reported
by Mikael Pettersson.Reported-by: Mikael Pettersson
Signed-off-by: Ingo Molnar
30 Apr, 2008
1 commit
-
Signed-off-by: Robert P. J. Day
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
04 Feb, 2008
1 commit
-
After disabling both CONFIG_DEBUG_LOCKING_API_SELFTESTS and netconsole
(using current mainline) I get a login prompt, and also...[ 5.181668] SELinux: policy loaded with handle_unknown=deny
[ 5.183315] type=1403 audit(1202100038.157:3): policy loaded auid=4294967295 ses=4294967295
[ 5.822073] SELinux: initialized (dev usbfs, type usbfs), uses genfs_contexts
[ 7.819146] ------------[ cut here ]------------
[ 7.819146] WARNING: at kernel/lockdep.c:2033 trace_hardirqs_on+0x9b/0x10d()
[ 7.819146] Modules linked in: generic ext3 jbd ide_disk ide_core
[ 7.819146] Pid: 399, comm: hwclock Not tainted 2.6.24 #4
[ 7.819146] [] warn_on_slowpath+0x41/0x51
[ 7.819146] [] ? lock_release_holdtime+0x50/0x56
[ 7.819146] [] ? check_usage_forwards+0x19/0x3b
[ 7.819146] [] ? __lock_acquire+0xac3/0xb0b
[ 7.819146] [] ? native_sched_clock+0x8b/0x9f
[ 7.819146] [] ? lock_release_holdtime+0x50/0x56
[ 7.819146] [] ? _spin_unlock_irq+0x22/0x42
[ 7.819146] [] trace_hardirqs_on+0x9b/0x10d
[ 7.819146] [] _spin_unlock_irq+0x22/0x42
[ 7.819146] [] hpet_rtc_interrupt+0xdf/0x290
[ 7.819146] [] handle_IRQ_event+0x1a/0x46
[ 7.819146] [] handle_edge_irq+0xbe/0xff
[ 7.819146] [] do_IRQ+0x6d/0x84
[ 7.819146] [] common_interrupt+0x2e/0x34
[ 7.819146] [] ? ktime_get_ts+0x8/0x3f
[ 7.819146] [] ? lock_release+0x167/0x16f
[ 7.819146] [] ? core_sys_select+0x2c/0x327
[ 7.819146] [] core_sys_select+0x74/0x327
[ 7.819146] [] ? native_sched_clock+0x8b/0x9f
[ 7.819146] [] ? lock_release_holdtime+0x50/0x56
[ 7.819146] [] ? _spin_unlock_irq+0x22/0x42
[ 7.819146] [] ? trace_hardirqs_on+0xe6/0x10d
[ 7.819146] [] ? _spin_unlock_irq+0x2d/0x42
[ 7.819146] [] ? rtc_do_ioctl+0x11b/0x677
[ 7.819146] [] ? inode_has_perm+0x5e/0x68
[ 7.819146] [] ? lock_release_holdtime+0x50/0x56
[ 7.819146] [] ? native_sched_clock+0x8b/0x9f
[ 7.819146] [] ? file_has_perm+0x83/0x8c
[ 7.819146] [] ? rtc_ioctl+0xf/0x11
[ 7.819146] [] ? do_ioctl+0x55/0x67
[ 7.819146] [] sys_select+0x93/0x163
[ 7.819146] [] ? sysenter_past_esp+0x9a/0xa5
[ 7.819146] [] sysenter_past_esp+0x5f/0xa5
[ 7.819146] =======================
[ 7.819146] ---[ end trace 96540ca301ffb84c ]---
[ 7.819210] rtc: lost 6 interrupts
[ 7.870668] type=1400 audit(1202128840.794:4): avc: denied { audit_write } for pid=399 comm="hwclock" capability=29 scontext=system_u:system_r:hwclock_t:s0 tcontext=system_u:system_r:hwclock_t:s0 tclass=capability
[ 9.538866] input: PC Speaker as /class/input/input5Because hpet_rtc_interrupt()'s call to get_rtc_time() ends up
resolving to include/asm-generic/rtc.h's (hilariously inlined)
get_rtc_time(), which does spin_unlock_irq() from hard IRQ context.The obvious patch fixes it.
Signed-off-by: Thomas Gleixner
Signed-off-by: Ingo Molnar
04 Oct, 2006
1 commit
-
Many files include the filename at the beginning, serveral used a wrong one.
Signed-off-by: Uwe Zeisberger
Signed-off-by: Adrian Bunk
25 Jun, 2006
1 commit
-
Considering that there isn't a lot of hw we can depend on during resume,
this is about as good as it gets.This is x86-only for now, although the basic concept (and most of the
code) will certainly work on almost any platform.Signed-off-by: Linus Torvalds
17 Apr, 2005
1 commit
-
Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.Let it rip!