kernel-hacking-2024-linux-s.../arch/alpha/kernel
Ivan Kokshaysky 5f7dc5d750 alpha: fix RTC on marvel
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 <ink@jurassic.park.msu.ru>
Cc: Richard Henderson <rth@twiddle.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-01-15 16:39:40 -08:00
..
alpha_ksyms.c
asm-offsets.c CRED: Separate task security context from task_struct 2008-11-14 10:39:16 +11:00
binfmt_loader.c get rid of special-casing the /sbin/loader on alpha 2009-01-03 11:45:54 -08:00
console.c
core_apecs.c
core_cia.c
core_irongate.c
core_lca.c
core_marvel.c alpha: fix RTC on marvel 2009-01-15 16:39:40 -08:00
core_mcpcia.c
core_polaris.c
core_t2.c
core_titan.c
core_tsunami.c
core_wildfire.c
entry.S [CVE-2009-0029] Remove __attribute__((weak)) from sys_pipe/sys_pipe2 2009-01-14 14:15:15 +01:00
err_common.c
err_ev6.c
err_ev7.c
err_impl.h
err_marvel.c
err_titan.c
es1888.c
gct.c
head.S
init_task.c take init_fs to saner place 2008-12-31 18:07:42 -05:00
io.c
irq.c cpumask: convert kernel/irq 2009-01-01 10:12:26 +10:30
irq_alpha.c
irq_i8259.c
irq_impl.h
irq_pyxis.c
irq_srm.c alpha: nautilus - fix compile failure with gcc-4.3 2009-01-15 16:39:40 -08:00
machvec_impl.h alpha: fix RTC on marvel 2009-01-15 16:39:40 -08:00
Makefile get rid of special-casing the /sbin/loader on alpha 2009-01-03 11:45:54 -08:00
module.c
ns87312.c
osf_sys.c Merge branch 'v28-range-hrtimers-for-linus-v2' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2008-10-23 10:53:02 -07:00
pci-noop.c
pci.c PCI: alpha: use generic INTx swizzle from PCI core 2009-01-07 11:13:13 -08:00
pci_impl.h PCI: alpha: use generic INTx swizzle from PCI core 2009-01-07 11:13:13 -08:00
pci_iommu.c alpha: use iommu_num_pages function in IOMMU code 2008-10-16 11:21:33 -07:00
process.c cpumask: centralize cpu_online_map and cpu_possible_map 2008-12-13 21:19:41 +10:30
proto.h alpha: fix RTC on marvel 2009-01-15 16:39:40 -08:00
ptrace.c
setup.c cpumask: alpha: Introduce cpumask_of_{node,pcibus} to replace {node,pcibus}_to_cpumask 2008-12-26 22:23:41 +10:30
signal.c
smc37c93x.c
smc37c669.c
smp.c cpumask: centralize cpu_online_map and cpu_possible_map 2008-12-13 21:19:41 +10:30
srm_env.c
srmcons.c
sys_alcor.c
sys_cabriolet.c
sys_dp264.c PCI: alpha: use generic pci_swizzle_interrupt_pin() 2009-01-07 11:12:53 -08:00
sys_eb64p.c
sys_eiger.c PCI: alpha: use generic pci_swizzle_interrupt_pin() 2009-01-07 11:12:53 -08:00
sys_jensen.c alpha: fix RTC on marvel 2009-01-15 16:39:40 -08:00
sys_marvel.c alpha: fix RTC on marvel 2009-01-15 16:39:40 -08:00
sys_miata.c PCI: alpha: use generic pci_swizzle_interrupt_pin() 2009-01-07 11:12:53 -08:00
sys_mikasa.c
sys_nautilus.c alpha: nautilus - fix hang on boot 2009-01-15 16:39:40 -08:00
sys_noritake.c PCI: alpha: use generic pci_swizzle_interrupt_pin() 2009-01-07 11:12:53 -08:00
sys_rawhide.c
sys_ruffian.c PCI: alpha: use generic pci_swizzle_interrupt_pin() 2009-01-07 11:12:53 -08:00
sys_rx164.c
sys_sable.c PCI: alpha: use generic pci_swizzle_interrupt_pin() 2009-01-07 11:12:53 -08:00
sys_sio.c
sys_sx164.c
sys_takara.c
sys_titan.c cpumask: make irq_set_affinity() take a const struct cpumask 2008-12-13 21:20:26 +10:30
sys_wildfire.c
systbls.S [CVE-2009-0029] Remove __attribute__((weak)) from sys_pipe/sys_pipe2 2009-01-14 14:15:15 +01:00
time.c alpha: fix RTC on marvel 2009-01-15 16:39:40 -08:00
traps.c false __cpuinit positives on alpha 2008-11-30 10:03:35 -08:00
vmlinux.lds.S