Commit 85082fd7 authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm

* 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm: (241 commits)
  [ARM] 5171/1: ep93xx: fix compilation of modules using clocks
  [ARM] 5133/2: at91sam9g20 defconfig file
  [ARM] 5130/4: Support for the at91sam9g20
  [ARM] 5160/1: IOP3XX: gpio/gpiolib support
  [ARM] at91: Fix NAND FLASH timings for at91sam9x evaluation kits.
  [ARM] 5084/1: zylonite: Register AC97 device
  [ARM] 5085/2: PXA: Move AC97 over to the new central device declaration model
  [ARM] 5120/1: pxa: correct platform driver names for PXA25x and PXA27x UDC drivers
  [ARM] 5147/1: pxaficp_ir: drop pxa_gpio_mode calls, as pin setting
  [ARM] 5145/1: PXA2xx: provide api to control IrDA pins state
  [ARM] 5144/1: pxaficp_ir: cleanup includes
  [ARM] pxa: remove pxa_set_cken()
  [ARM] pxa: allow clk aliases
  [ARM] Feroceon: don't disable BPU on boot
  [ARM] Orion: LED support for HP mv2120
  [ARM] Orion: add RD88F5181L-FXO support
  [ARM] Orion: add RD88F5181L-GE support
  [ARM] Orion: add Netgear WNR854T support
  [ARM] s3c2410_defconfig: update for current build
  [ARM] Acer n30: Minor style and indentation fixes.
  ...
parents 666484f0 53ffe3b4
...@@ -1242,6 +1242,11 @@ and is between 256 and 4096 characters. It is defined in the file ...@@ -1242,6 +1242,11 @@ and is between 256 and 4096 characters. It is defined in the file
mtdparts= [MTD] mtdparts= [MTD]
See drivers/mtd/cmdlinepart.c. See drivers/mtd/cmdlinepart.c.
mtdset= [ARM]
ARM/S3C2412 JIVE boot control
See arch/arm/mach-s3c2412/mach-jive.c
mtouchusb.raw_coordinates= mtouchusb.raw_coordinates=
[HW] Make the MicroTouch USB driver use raw coordinates [HW] Make the MicroTouch USB driver use raw coordinates
('y', default) or cooked coordinates ('n') ('y', default) or cooked coordinates ('n')
......
...@@ -24,6 +24,9 @@ config ARM ...@@ -24,6 +24,9 @@ config ARM
Europe. There is an ARM Linux project with a web page at Europe. There is an ARM Linux project with a web page at
<http://www.arm.linux.org.uk/>. <http://www.arm.linux.org.uk/>.
config HAVE_PWM
bool
config SYS_SUPPORTS_APM_EMULATION config SYS_SUPPORTS_APM_EMULATION
bool bool
...@@ -86,6 +89,11 @@ config STACKTRACE_SUPPORT ...@@ -86,6 +89,11 @@ config STACKTRACE_SUPPORT
bool bool
default y default y
config HAVE_LATENCYTOP_SUPPORT
bool
depends on !SMP
default y
config LOCKDEP_SUPPORT config LOCKDEP_SUPPORT
bool bool
default y default y
...@@ -149,6 +157,10 @@ config FIQ ...@@ -149,6 +157,10 @@ config FIQ
config ARCH_MTD_XIP config ARCH_MTD_XIP
bool bool
config GENERIC_HARDIRQS_NO__DO_IRQ
bool
def_bool y
if OPROFILE if OPROFILE
config OPROFILE_ARMV6 config OPROFILE_ARMV6
...@@ -234,13 +246,6 @@ config ARCH_CLPS711X ...@@ -234,13 +246,6 @@ config ARCH_CLPS711X
help help
Support for Cirrus Logic 711x/721x based boards. Support for Cirrus Logic 711x/721x based boards.
config ARCH_CO285
bool "Co-EBSA285"
select FOOTBRIDGE
select FOOTBRIDGE_ADDIN
help
Support for Intel's EBSA285 companion chip.
config ARCH_EBSA110 config ARCH_EBSA110
bool "EBSA-110" bool "EBSA-110"
select ISA select ISA
...@@ -301,6 +306,8 @@ config ARCH_IOP32X ...@@ -301,6 +306,8 @@ config ARCH_IOP32X
depends on MMU depends on MMU
select PLAT_IOP select PLAT_IOP
select PCI select PCI
select GENERIC_GPIO
select HAVE_GPIO_LIB
help help
Support for Intel's 80219 and IOP32X (XScale) family of Support for Intel's 80219 and IOP32X (XScale) family of
processors. processors.
...@@ -310,6 +317,8 @@ config ARCH_IOP33X ...@@ -310,6 +317,8 @@ config ARCH_IOP33X
depends on MMU depends on MMU
select PLAT_IOP select PLAT_IOP
select PCI select PCI
select GENERIC_GPIO
select HAVE_GPIO_LIB
help help
Support for Intel's IOP33X (XScale) family of processors. Support for Intel's IOP33X (XScale) family of processors.
...@@ -349,6 +358,16 @@ config ARCH_L7200 ...@@ -349,6 +358,16 @@ config ARCH_L7200
If you have any questions or comments about the Linux kernel port If you have any questions or comments about the Linux kernel port
to this board, send e-mail to <sjhill@cotw.com>. to this board, send e-mail to <sjhill@cotw.com>.
config ARCH_KIRKWOOD
bool "Marvell Kirkwood"
select PCI
select GENERIC_TIME
select GENERIC_CLOCKEVENTS
select PLAT_ORION
help
Support for the following Marvell Kirkwood series SoCs:
88F6180, 88F6192 and 88F6281.
config ARCH_KS8695 config ARCH_KS8695
bool "Micrel/Kendin KS8695" bool "Micrel/Kendin KS8695"
select GENERIC_GPIO select GENERIC_GPIO
...@@ -367,9 +386,31 @@ config ARCH_NS9XXX ...@@ -367,9 +386,31 @@ config ARCH_NS9XXX
<http://www.digi.com/products/microprocessors/index.jsp> <http://www.digi.com/products/microprocessors/index.jsp>
config ARCH_LOKI
bool "Marvell Loki (88RC8480)"
select GENERIC_TIME
select GENERIC_CLOCKEVENTS
select PLAT_ORION
help
Support for the Marvell Loki (88RC8480) SoC.
config ARCH_MV78XX0
bool "Marvell MV78xx0"
select PCI
select GENERIC_TIME
select GENERIC_CLOCKEVENTS
select PLAT_ORION
help
Support for the following Marvell MV78xx0 series SoCs:
MV781x0, MV782x0.
config ARCH_MXC config ARCH_MXC
bool "Freescale MXC/iMX-based" bool "Freescale MXC/iMX-based"
select GENERIC_TIME
select GENERIC_CLOCKEVENTS
select ARCH_MTD_XIP select ARCH_MTD_XIP
select GENERIC_GPIO
select HAVE_GPIO_LIB
help help
Support for Freescale MXC/iMX-based family of processors Support for Freescale MXC/iMX-based family of processors
...@@ -383,7 +424,8 @@ config ARCH_ORION5X ...@@ -383,7 +424,8 @@ config ARCH_ORION5X
select PLAT_ORION select PLAT_ORION
help help
Support for the following Marvell Orion 5x series SoCs: Support for the following Marvell Orion 5x series SoCs:
Orion-1 (5181), Orion-NAS (5182), Orion-2 (5281.) Orion-1 (5181), Orion-VoIP (5181L), Orion-NAS (5182),
Orion-2 (5281).
config ARCH_PNX4008 config ARCH_PNX4008
bool "Philips Nexperia PNX4008 Mobile" bool "Philips Nexperia PNX4008 Mobile"
...@@ -408,6 +450,7 @@ config ARCH_RPC ...@@ -408,6 +450,7 @@ config ARCH_RPC
select FIQ select FIQ
select TIMER_ACORN select TIMER_ACORN
select ARCH_MAY_HAVE_PC_FDC select ARCH_MAY_HAVE_PC_FDC
select HAVE_PATA_PLATFORM
select ISA_DMA_API select ISA_DMA_API
select NO_IOPORT select NO_IOPORT
help help
...@@ -504,6 +547,10 @@ source "arch/arm/mach-ixp2000/Kconfig" ...@@ -504,6 +547,10 @@ source "arch/arm/mach-ixp2000/Kconfig"
source "arch/arm/mach-ixp23xx/Kconfig" source "arch/arm/mach-ixp23xx/Kconfig"
source "arch/arm/mach-loki/Kconfig"
source "arch/arm/mach-mv78xx0/Kconfig"
source "arch/arm/mach-pxa/Kconfig" source "arch/arm/mach-pxa/Kconfig"
source "arch/arm/mach-sa1100/Kconfig" source "arch/arm/mach-sa1100/Kconfig"
...@@ -516,6 +563,8 @@ source "arch/arm/mach-omap2/Kconfig" ...@@ -516,6 +563,8 @@ source "arch/arm/mach-omap2/Kconfig"
source "arch/arm/mach-orion5x/Kconfig" source "arch/arm/mach-orion5x/Kconfig"
source "arch/arm/mach-kirkwood/Kconfig"
source "arch/arm/plat-s3c24xx/Kconfig" source "arch/arm/plat-s3c24xx/Kconfig"
source "arch/arm/plat-s3c/Kconfig" source "arch/arm/plat-s3c/Kconfig"
...@@ -705,27 +754,6 @@ config PREEMPT ...@@ -705,27 +754,6 @@ config PREEMPT
Say Y here if you are building a kernel for a desktop, embedded Say Y here if you are building a kernel for a desktop, embedded
or real-time system. Say N if you are unsure. or real-time system. Say N if you are unsure.
config NO_IDLE_HZ
bool "Dynamic tick timer"
depends on !GENERIC_CLOCKEVENTS
help
Select this option if you want to disable continuous timer ticks
and have them programmed to occur as required. This option saves
power as the system can remain in idle state for longer.
By default dynamic tick is disabled during the boot, and can be
manually enabled with:
echo 1 > /sys/devices/system/timer/timer0/dyn_tick
Alternatively, if you want dynamic tick automatically enabled
during boot, pass "dyntick=enable" via the kernel command string.
Please note that dynamic tick may affect the accuracy of
timekeeping on some platforms depending on the implementation.
Currently at least OMAP, PXA2xx and SA11x0 platforms are known
to have accurate timekeeping with dynamic tick.
config HZ config HZ
int int
default 128 if ARCH_L7200 default 128 if ARCH_L7200
...@@ -791,7 +819,7 @@ source "mm/Kconfig" ...@@ -791,7 +819,7 @@ source "mm/Kconfig"
config LEDS config LEDS
bool "Timer and CPU usage LEDs" bool "Timer and CPU usage LEDs"
depends on ARCH_CDB89712 || ARCH_CO285 || ARCH_EBSA110 || \ depends on ARCH_CDB89712 || ARCH_EBSA110 || \
ARCH_EBSA285 || ARCH_IMX || ARCH_INTEGRATOR || \ ARCH_EBSA285 || ARCH_IMX || ARCH_INTEGRATOR || \
ARCH_LUBBOCK || MACH_MAINSTONE || ARCH_NETWINDER || \ ARCH_LUBBOCK || MACH_MAINSTONE || ARCH_NETWINDER || \
ARCH_OMAP || ARCH_P720T || ARCH_PXA_IDP || \ ARCH_OMAP || ARCH_P720T || ARCH_PXA_IDP || \
......
...@@ -100,8 +100,6 @@ textofs-y := 0x00008000 ...@@ -100,8 +100,6 @@ textofs-y := 0x00008000
incdir-$(CONFIG_ARCH_CLPS7500) := cl7500 incdir-$(CONFIG_ARCH_CLPS7500) := cl7500
machine-$(CONFIG_FOOTBRIDGE) := footbridge machine-$(CONFIG_FOOTBRIDGE) := footbridge
incdir-$(CONFIG_FOOTBRIDGE) := ebsa285 incdir-$(CONFIG_FOOTBRIDGE) := ebsa285
machine-$(CONFIG_ARCH_CO285) := footbridge
incdir-$(CONFIG_ARCH_CO285) := ebsa285
machine-$(CONFIG_ARCH_SHARK) := shark machine-$(CONFIG_ARCH_SHARK) := shark
machine-$(CONFIG_ARCH_SA1100) := sa1100 machine-$(CONFIG_ARCH_SA1100) := sa1100
ifeq ($(CONFIG_ARCH_SA1100),y) ifeq ($(CONFIG_ARCH_SA1100),y)
...@@ -135,11 +133,15 @@ endif ...@@ -135,11 +133,15 @@ endif
machine-$(CONFIG_ARCH_NETX) := netx machine-$(CONFIG_ARCH_NETX) := netx
machine-$(CONFIG_ARCH_NS9XXX) := ns9xxx machine-$(CONFIG_ARCH_NS9XXX) := ns9xxx
machine-$(CONFIG_ARCH_DAVINCI) := davinci machine-$(CONFIG_ARCH_DAVINCI) := davinci
machine-$(CONFIG_ARCH_KIRKWOOD) := kirkwood
machine-$(CONFIG_ARCH_KS8695) := ks8695 machine-$(CONFIG_ARCH_KS8695) := ks8695
incdir-$(CONFIG_ARCH_MXC) := mxc incdir-$(CONFIG_ARCH_MXC) := mxc
machine-$(CONFIG_ARCH_MX2) := mx2
machine-$(CONFIG_ARCH_MX3) := mx3 machine-$(CONFIG_ARCH_MX3) := mx3
machine-$(CONFIG_ARCH_ORION5X) := orion5x machine-$(CONFIG_ARCH_ORION5X) := orion5x
machine-$(CONFIG_ARCH_MSM7X00A) := msm machine-$(CONFIG_ARCH_MSM7X00A) := msm
machine-$(CONFIG_ARCH_LOKI) := loki
machine-$(CONFIG_ARCH_MV78XX0) := mv78xx0
ifeq ($(CONFIG_ARCH_EBSA110),y) ifeq ($(CONFIG_ARCH_EBSA110),y)
# This is what happens if you forget the IOCS16 line. # This is what happens if you forget the IOCS16 line.
...@@ -190,8 +192,6 @@ core-$(CONFIG_PLAT_S3C24XX) += arch/arm/plat-s3c24xx/ ...@@ -190,8 +192,6 @@ core-$(CONFIG_PLAT_S3C24XX) += arch/arm/plat-s3c24xx/
core-$(CONFIG_ARCH_MXC) += arch/arm/plat-mxc/ core-$(CONFIG_ARCH_MXC) += arch/arm/plat-mxc/
drivers-$(CONFIG_OPROFILE) += arch/arm/oprofile/ drivers-$(CONFIG_OPROFILE) += arch/arm/oprofile/
drivers-$(CONFIG_ARCH_CLPS7500) += drivers/acorn/char/
drivers-$(CONFIG_ARCH_L7200) += drivers/acorn/char/
libs-y := arch/arm/lib/ $(libs-y) libs-y := arch/arm/lib/ $(libs-y)
......
...@@ -623,8 +623,8 @@ proc_types: ...@@ -623,8 +623,8 @@ proc_types:
b __armv4_mmu_cache_off b __armv4_mmu_cache_off
b __armv4_mmu_cache_flush b __armv4_mmu_cache_flush
.word 0x56055310 @ Feroceon .word 0x56050000 @ Feroceon
.word 0xfffffff0 .word 0xff0f0000
b __armv4_mmu_cache_on b __armv4_mmu_cache_on
b __armv4_mmu_cache_off b __armv4_mmu_cache_off
b __armv5tej_mmu_cache_flush b __armv5tej_mmu_cache_flush
......
...@@ -2,7 +2,6 @@ ...@@ -2,7 +2,6 @@
# Makefile for the linux kernel. # Makefile for the linux kernel.
# #
obj-y += rtctime.o
obj-$(CONFIG_ARM_GIC) += gic.o obj-$(CONFIG_ARM_GIC) += gic.o
obj-$(CONFIG_ARM_VIC) += vic.o obj-$(CONFIG_ARM_VIC) += vic.o
obj-$(CONFIG_ICST525) += icst525.o obj-$(CONFIG_ICST525) += icst525.o
......
/*
* linux/arch/arm/common/rtctime.c
*
* Copyright (C) 2003 Deep Blue Solutions Ltd.
* Based on sa1100-rtc.c, Nils Faerber, CIH, Nicolas Pitre.
* Based on rtc.c by Paul Gortmaker
*
* 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.
*/
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/time.h>
#include <linux/rtc.h>
#include <linux/poll.h>
#include <linux/proc_fs.h>
#include <linux/miscdevice.h>
#include <linux/spinlock.h>
#include <linux/capability.h>
#include <linux/device.h>
#include <linux/mutex.h>
#include <asm/rtc.h>
static DECLARE_WAIT_QUEUE_HEAD(rtc_wait);
static struct fasync_struct *rtc_async_queue;
/*
* rtc_lock protects rtc_irq_data
*/
static DEFINE_SPINLOCK(rtc_lock);
static unsigned long rtc_irq_data;
/*
* rtc_sem protects rtc_inuse and rtc_ops
*/
static DEFINE_MUTEX(rtc_mutex);
static unsigned long rtc_inuse;
static struct rtc_ops *rtc_ops;
#define rtc_epoch 1900UL
/*
* Calculate the next alarm time given the requested alarm time mask
* and the current time.
*/
void rtc_next_alarm_time(struct rtc_time *next, struct rtc_time *now, struct rtc_time *alrm)
{
unsigned long next_time;
unsigned long now_time;
next->tm_year = now->tm_year;
next->tm_mon = now->tm_mon;
next->tm_mday = now->tm_mday;
next->tm_hour = alrm->tm_hour;
next->tm_min = alrm->tm_min;
next->tm_sec = alrm->tm_sec;
rtc_tm_to_time(now, &now_time);
rtc_tm_to_time(next, &next_time);
if (next_time < now_time) {
/* Advance one day */
next_time += 60 * 60 * 24;
rtc_time_to_tm(next_time, next);
}
}
EXPORT_SYMBOL(rtc_next_alarm_time);
static inline int rtc_arm_read_time(struct rtc_ops *ops, struct rtc_time *tm)
{
memset(tm, 0, sizeof(struct rtc_time));
return ops->read_time(tm);
}
static inline int rtc_arm_set_time(struct rtc_ops *ops, struct rtc_time *tm)
{
int ret;
ret = rtc_valid_tm(tm);
if (ret == 0)
ret = ops->set_time(tm);
return ret;
}
static inline int rtc_arm_read_alarm(struct rtc_ops *ops, struct rtc_wkalrm *alrm)
{
int ret = -EINVAL;
if (ops->read_alarm) {
memset(alrm, 0, sizeof(struct rtc_wkalrm));
ret = ops->read_alarm(alrm);
}
return ret;
}
static inline int rtc_arm_set_alarm(struct rtc_ops *ops, struct rtc_wkalrm *alrm)
{
int ret = -EINVAL;
if (ops->set_alarm)
ret = ops->set_alarm(alrm);
return ret;
}
void rtc_update(unsigned long num, unsigned long events)
{
spin_lock(&rtc_lock);
rtc_irq_data = (rtc_irq_data + (num << 8)) | events;
spin_unlock(&rtc_lock);
wake_up_interruptible(&rtc_wait);
kill_fasync(&rtc_async_queue, SIGIO, POLL_IN);
}
EXPORT_SYMBOL(rtc_update);
static ssize_t
rtc_read(struct file *file, char __user *buf, size_t count, loff_t *ppos)
{
DECLARE_WAITQUEUE(wait, current);
unsigned long data;
ssize_t ret;
if (count < sizeof(unsigned long))
return -EINVAL;
add_wait_queue(&rtc_wait, &wait);
do {
__set_current_state(TASK_INTERRUPTIBLE);
spin_lock_irq(&rtc_lock);
data = rtc_irq_data;
rtc_irq_data = 0;
spin_unlock_irq(&rtc_lock);
if (data != 0) {
ret = 0;
break;
}
if (file->f_flags & O_NONBLOCK) {
ret = -EAGAIN;
break;
}
if (signal_pending(current)) {
ret = -ERESTARTSYS;
break;
}
schedule();
} while (1);
set_current_state(TASK_RUNNING);
remove_wait_queue(&rtc_wait, &wait);
if (ret == 0) {
ret = put_user(data, (unsigned long __user *)buf);
if (ret == 0)
ret = sizeof(unsigned long);
}
return ret;
}
static unsigned int rtc_poll(struct file *file, poll_table *wait)
{
unsigned long data;
poll_wait(file, &rtc_wait, wait);
spin_lock_irq(&rtc_lock);
data = rtc_irq_data;
spin_unlock_irq(&rtc_lock);
return data != 0 ? POLLIN | POLLRDNORM : 0;
}
static int rtc_ioctl(struct inode *inode, struct file *file, unsigned int cmd,
unsigned long arg)
{
struct rtc_ops *ops = file->private_data;
struct rtc_time tm;
struct rtc_wkalrm alrm;
void __user *uarg = (void __user *)arg;
int ret = -EINVAL;
switch (cmd) {
case RTC_ALM_READ:
ret = rtc_arm_read_alarm(ops, &alrm);
if (ret)
break;
ret = copy_to_user(uarg, &alrm.time, sizeof(tm));
if (ret)
ret = -EFAULT;
break;
case RTC_ALM_SET:
ret = copy_from_user(&alrm.time, uarg, sizeof(tm));
if (ret) {
ret = -EFAULT;
break;
}
alrm.enabled = 0;
alrm.pending = 0;
alrm.time.tm_mday = -1;
alrm.time.tm_mon = -1;
alrm.time.tm_year = -1;
alrm.time.tm_wday = -1;
alrm.time.tm_yday = -1;
alrm.time.tm_isdst = -1;
ret = rtc_arm_set_alarm(ops, &alrm);
break;
case RTC_RD_TIME:
ret = rtc_arm_read_time(ops, &tm);
if (ret)
break;
ret = copy_to_user(uarg, &tm, sizeof(tm));
if (ret)
ret = -EFAULT;
break;
case RTC_SET_TIME:
if (!capable(CAP_SYS_TIME)) {
ret = -EACCES;
break;
}
ret = copy_from_user(&tm, uarg, sizeof(tm));
if (ret) {
ret = -EFAULT;
break;
}
ret = rtc_arm_set_time(ops, &tm);
break;
case RTC_EPOCH_SET:
#ifndef rtc_epoch
/*
* There were no RTC clocks before 1900.
*/
if (arg < 1900) {
ret = -EINVAL;
break;
}
if (!capable(CAP_SYS_TIME)) {
ret = -EACCES;
break;
}
rtc_epoch = arg;
ret = 0;
#endif
break;
case RTC_EPOCH_READ:
ret = put_user(rtc_epoch, (unsigned long __user *)uarg);
break;
case RTC_WKALM_SET:
ret = copy_from_user(&alrm, uarg, sizeof(alrm));
if (ret) {
ret = -EFAULT;
break;
}
ret = rtc_arm_set_alarm(ops, &alrm);
break;
case RTC_WKALM_RD:
ret = rtc_arm_read_alarm(ops, &alrm);
if (ret)
break;
ret = copy_to_user(uarg, &alrm, sizeof(alrm));
if (ret)
ret = -EFAULT;
break;
default:
if (ops->ioctl)
ret = ops->ioctl(cmd, arg);
break;
}
return ret;
}
static int rtc_open(struct inode *inode, struct file *file)
{
int ret;
mutex_lock(&rtc_mutex);
if (rtc_inuse) {
ret = -EBUSY;
} else if (!rtc_ops || !try_module_get(rtc_ops->owner)) {
ret = -ENODEV;
} else {
file->private_data = rtc_ops;
ret = rtc_ops->open ? rtc_ops->open() : 0;
if (ret == 0) {
spin_lock_irq(&rtc_lock);
rtc_irq_data = 0;
spin_unlock_irq(&rtc_lock);
rtc_inuse = 1;
}
}
mutex_unlock(&rtc_mutex);
return ret;
}
static int rtc_release(struct inode *inode, struct file *file)
{
struct rtc_ops *ops = file->private_data;
if (ops->release)
ops->release();
spin_lock_irq(&rtc_lock);
rtc_irq_data = 0;
spin_unlock_irq(&rtc_lock);
module_put(rtc_ops->owner);
rtc_inuse = 0;
return 0;
}
static int rtc_fasync(int fd, struct file *file, int on)
{
return fasync_helper(fd, file, on, &rtc_async_queue);
}
static const struct file_operations rtc_fops = {
.owner = THIS_MODULE,
.llseek = no_llseek,
.read = rtc_read,
.poll = rtc_poll,
.ioctl = rtc_ioctl,
.open = rtc_open,
.release = rtc_release,
.fasync = rtc_fasync,
};
static struct miscdevice rtc_miscdev = {
.minor = RTC_MINOR,
.name = "rtc",
.fops = &rtc_fops,
};
static int rtc_read_proc(char *page, char **start, off_t off, int count, int *eof, void *data)
{
struct rtc_ops *ops = data;
struct rtc_wkalrm alrm;
struct rtc_time tm;
char *p = page;
if (rtc_arm_read_time(ops, &tm) == 0) {
p += sprintf(p,
"rtc_time\t: %02d:%02d:%02d\n"
"rtc_date\t: %04d-%02d-%02d\n"
"rtc_epoch\t: %04lu\n",
tm.tm_hour, tm.tm_min, tm.tm_sec,
tm.tm_year + 1900, tm.tm_mon + 1, tm.tm_mday,
rtc_epoch);
}
if (rtc_arm_read_alarm(ops, &alrm) == 0) {
p += sprintf(p, "alrm_time\t: ");
if ((unsigned int)alrm.time.tm_hour <= 24)
p += sprintf(p, "%02d:", alrm.time.tm_hour);
else
p += sprintf(p, "**:");
if ((unsigned int)alrm.time.tm_min <= 59)
p += sprintf(p, "%02d:", alrm.time.tm_min);
else
p += sprintf(p, "**:");
if ((unsigned int)alrm.time.tm_sec <= 59)
p += sprintf(p, "%02d\n", alrm.time.tm_sec);
else
p += sprintf(p, "**\n");
p += sprintf(p, "alrm_date\t: ");
if ((unsigned int)alrm.time.tm_year <= 200)
p += sprintf(p, "%04d-", alrm.time.tm_year + 1900);
else
p += sprintf(p, "****-");
if ((unsigned int)alrm.time.tm_mon <= 11)
p += sprintf(p, "%02d-", alrm.time.tm_mon + 1);
else
p += sprintf(p, "**-");
if ((unsigned int)alrm.time.tm_mday <= 31)
p += sprintf(p, "%02d\n", alrm.time.tm_mday);
else
p += sprintf(p, "**\n");
p += sprintf(p, "alrm_wakeup\t: %s\n",
alrm.enabled ? "yes" : "no");
p += sprintf(p, "alrm_pending\t: %s\n",
alrm.pending ? "yes" : "no");
}
if (ops->proc)
p += ops->proc(p);
return p - page;
}
int register_rtc(struct rtc_ops *ops)
{
int ret = -EBUSY;
mutex_lock(&rtc_mutex);
if (rtc_ops == NULL) {
rtc_ops = ops;
ret = misc_register(&rtc_miscdev);
if (ret == 0)
create_proc_read_entry("driver/rtc", 0, NULL,
rtc_read_proc, ops);
}
mutex_unlock(&rtc_mutex);
return ret;
}
EXPORT_SYMBOL(register_rtc);
void unregister_rtc(struct rtc_ops *rtc)
{
mutex_lock(&rtc_mutex);
if (rtc == rtc_ops) {
remove_proc_entry("driver/rtc", NULL);
misc_deregister(&rtc_miscdev);
rtc_ops = NULL;
}
mutex_unlock(&rtc_mutex);
}
EXPORT_SYMBOL(unregister_rtc);
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
#include <asm/irq.h> #include <asm/irq.h>
#include <asm/arch/pm.h> #include <asm/arch/pm.h>
#include <asm/arch/pxa-regs.h> #include <asm/arch/pxa-regs.h>
#include <asm/arch/pxa2xx-regs.h>
#include <asm/arch/sharpsl.h> #include <asm/arch/sharpsl.h>
#include <asm/hardware/sharpsl_pm.h> #include <asm/hardware/sharpsl_pm.h>
...@@ -157,6 +158,7 @@ static void sharpsl_battery_thread(struct work_struct *private_) ...@@ -157,6 +158,7 @@ static void sharpsl_battery_thread(struct work_struct *private_)
dev_dbg(sharpsl_pm.dev, "Battery: voltage: %d, status: %d, percentage: %d, time: %ld\n", voltage, dev_dbg(sharpsl_pm.dev, "Battery: voltage: %d, status: %d, percentage: %d, time: %ld\n", voltage,
sharpsl_pm.battstat.mainbat_status, sharpsl_pm.battstat.mainbat_percent, jiffies); sharpsl_pm.battstat.mainbat_status, sharpsl_pm.battstat.mainbat_percent, jiffies);
#ifdef CONFIG_BACKLIGHT_CORGI
/* If battery is low. limit backlight intensity to save power. */ /* If battery is low. limit backlight intensity to save power. */
if ((sharpsl_pm.battstat.ac_status != APM_AC_ONLINE) if ((sharpsl_pm.battstat.ac_status != APM_AC_ONLINE)
&& ((sharpsl_pm.battstat.mainbat_status == APM_BATTERY_STATUS_LOW) || && ((sharpsl_pm.battstat.mainbat_status == APM_BATTERY_STATUS_LOW) ||
...@@ -169,6 +171,7 @@ static void sharpsl_battery_thread(struct work_struct *private_) ...@@ -169,6 +171,7 @@ static void sharpsl_battery_thread(struct work_struct *private_)
sharpsl_pm.machinfo->backlight_limit(0); sharpsl_pm.machinfo->backlight_limit(0);
sharpsl_pm.flags &= ~SHARPSL_BL_LIMIT; sharpsl_pm.flags &= ~SHARPSL_BL_LIMIT;
} }
#endif
/* Suspend if critical battery level */ /* Suspend if critical battery level */
if ((sharpsl_pm.battstat.ac_status != APM_AC_ONLINE) if ((sharpsl_pm.battstat.ac_status != APM_AC_ONLINE)
......
...@@ -213,7 +213,6 @@ CONFIG_CPU_CP15_MMU=y ...@@ -213,7 +213,6 @@ CONFIG_CPU_CP15_MMU=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
CONFIG_AEABI=y CONFIG_AEABI=y
CONFIG_OABI_COMPAT=y CONFIG_OABI_COMPAT=y
...@@ -907,7 +906,32 @@ CONFIG_USB_MON=y ...@@ -907,7 +906,32 @@ CONFIG_USB_MON=y
# #
# USB Gadget Support # USB Gadget Support
# #
# CONFIG_USB_GADGET is not set CONFIG_USB_GADGET=y
# CONFIG_USB_GADGET_DEBUG is not set
# CONFIG_USB_GADGET_DEBUG_FILES is not set
CONFIG_USB_GADGET_SELECTED=y
# CONFIG_USB_GADGET_AMD5536UDC is not set
CONFIG_USB_GADGET_ATMEL_USBA=y
CONFIG_USB_ATMEL_USBA=y
# CONFIG_USB_GADGET_FSL_USB2 is not set
# CONFIG_USB_GADGET_NET2280 is not set
# CONFIG_USB_GADGET_PXA2XX is not set
# CONFIG_USB_GADGET_M66592 is not set
# CONFIG_USB_GADGET_GOKU is not set
# CONFIG_USB_GADGET_LH7A40X is not set
# CONFIG_USB_GADGET_OMAP is not set
# CONFIG_USB_GADGET_S3C2410 is not set
# CONFIG_USB_GADGET_AT91 is not set
# CONFIG_USB_GADGET_DUMMY_HCD is not set
CONFIG_USB_GADGET_DUALSPEED=y
# CONFIG_USB_ZERO is not set
CONFIG_USB_ETH=m
CONFIG_USB_ETH_RNDIS=y
# CONFIG_USB_GADGETFS is not set
CONFIG_USB_FILE_STORAGE=m
# CONFIG_USB_FILE_STORAGE_TEST is not set
# CONFIG_USB_G_SERIAL is not set
# CONFIG_USB_MIDI_GADGET is not set
CONFIG_MMC=y CONFIG_MMC=y
# CONFIG_MMC_DEBUG is not set # CONFIG_MMC_DEBUG is not set
# CONFIG_MMC_UNSAFE_RESUME is not set # CONFIG_MMC_UNSAFE_RESUME is not set
...@@ -926,7 +950,59 @@ CONFIG_MMC_AT91=y ...@@ -926,7 +950,59 @@ CONFIG_MMC_AT91=y
# CONFIG_MMC_SPI is not set # CONFIG_MMC_SPI is not set
# CONFIG_NEW_LEDS is not set # CONFIG_NEW_LEDS is not set
CONFIG_RTC_LIB=y CONFIG_RTC_LIB=y
# CONFIG_RTC_CLASS is not set CONFIG_RTC_CLASS=y
CONFIG_RTC_HCTOSYS=y
CONFIG_RTC_HCTOSYS_DEVICE="rtc0"
# CONFIG_RTC_DEBUG is not set
#
# RTC interfaces
#
CONFIG_RTC_INTF_SYSFS=y
CONFIG_RTC_INTF_PROC=y
CONFIG_RTC_INTF_DEV=y
# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set
# CONFIG_RTC_DRV_TEST is not set
#
# I2C RTC drivers
#
# CONFIG_RTC_DRV_DS1307 is not set
# CONFIG_RTC_DRV_DS1374 is not set
# CONFIG_RTC_DRV_DS1672 is not set
# CONFIG_RTC_DRV_MAX6900 is not set
# CONFIG_RTC_DRV_RS5C372 is not set
# CONFIG_RTC_DRV_ISL1208 is not set
# CONFIG_RTC_DRV_X1205 is not set
# CONFIG_RTC_DRV_PCF8563 is not set
# CONFIG_RTC_DRV_PCF8583 is not set
# CONFIG_RTC_DRV_M41T80 is not set
#
# SPI RTC drivers
#
# CONFIG_RTC_DRV_MAX6902 is not set
# CONFIG_RTC_DRV_R9701 is not set
# CONFIG_RTC_DRV_RS5C348 is not set
#
# Platform RTC drivers
#
# CONFIG_RTC_DRV_CMOS is not set
# CONFIG_RTC_DRV_DS1511 is not set
# CONFIG_RTC_DRV_DS1553 is not set
# CONFIG_RTC_DRV_DS1742 is not set
# CONFIG_RTC_DRV_STK17TA8 is not set
# CONFIG_RTC_DRV_M48T86 is not set
# CONFIG_RTC_DRV_M48T59 is not set
# CONFIG_RTC_DRV_V3020 is not set
#
# on-CPU RTC drivers
#
CONFIG_RTC_DRV_AT91SAM9=y
CONFIG_RTC_DRV_AT91SAM9_RTT=0
CONFIG_RTC_DRV_AT91SAM9_GPBR=0
# #
# File systems # File systems
......
...@@ -169,7 +169,6 @@ CONFIG_AT91_CF=y ...@@ -169,7 +169,6 @@ CONFIG_AT91_CF=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
CONFIG_SELECT_MEMORY_MODEL=y CONFIG_SELECT_MEMORY_MODEL=y
CONFIG_FLATMEM_MANUAL=y CONFIG_FLATMEM_MANUAL=y
......
...@@ -160,7 +160,6 @@ CONFIG_ISA_DMA_API=y ...@@ -160,7 +160,6 @@ CONFIG_ISA_DMA_API=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
CONFIG_SELECT_MEMORY_MODEL=y CONFIG_SELECT_MEMORY_MODEL=y
CONFIG_FLATMEM_MANUAL=y CONFIG_FLATMEM_MANUAL=y
......
...@@ -220,7 +220,6 @@ CONFIG_CPU_CP15_MMU=y ...@@ -220,7 +220,6 @@ CONFIG_CPU_CP15_MMU=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -213,7 +213,6 @@ CONFIG_CPU_CP15_MMU=y ...@@ -213,7 +213,6 @@ CONFIG_CPU_CP15_MMU=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -213,7 +213,6 @@ CONFIG_CPU_CP15_MMU=y ...@@ -213,7 +213,6 @@ CONFIG_CPU_CP15_MMU=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -211,7 +211,6 @@ CONFIG_CPU_CP15_MMU=y ...@@ -211,7 +211,6 @@ CONFIG_CPU_CP15_MMU=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -171,7 +171,6 @@ CONFIG_AT91_CF=m ...@@ -171,7 +171,6 @@ CONFIG_AT91_CF=m
# Kernel Features # Kernel Features
# #
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
CONFIG_NO_IDLE_HZ=y
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -166,7 +166,6 @@ CONFIG_PCMCIA_SA1100=y ...@@ -166,7 +166,6 @@ CONFIG_PCMCIA_SA1100=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
CONFIG_ARCH_DISCONTIGMEM_ENABLE=y CONFIG_ARCH_DISCONTIGMEM_ENABLE=y
......
...@@ -165,7 +165,6 @@ CONFIG_PCMCIA_PXA2XX=y ...@@ -165,7 +165,6 @@ CONFIG_PCMCIA_PXA2XX=y
# Kernel Features # Kernel Features
# #
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
# CONFIG_NO_IDLE_HZ is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
CONFIG_SELECT_MEMORY_MODEL=y CONFIG_SELECT_MEMORY_MODEL=y
CONFIG_FLATMEM_MANUAL=y CONFIG_FLATMEM_MANUAL=y
......
...@@ -230,7 +230,6 @@ CONFIG_AT91_CF=y ...@@ -230,7 +230,6 @@ CONFIG_AT91_CF=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -184,7 +184,6 @@ CONFIG_ARM_AMBA=y ...@@ -184,7 +184,6 @@ CONFIG_ARM_AMBA=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -251,7 +251,6 @@ CONFIG_PCMCIA_PXA2XX=m ...@@ -251,7 +251,6 @@ CONFIG_PCMCIA_PXA2XX=m
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
CONFIG_AEABI=y CONFIG_AEABI=y
CONFIG_OABI_COMPAT=y CONFIG_OABI_COMPAT=y
......
This diff is collapsed.
...@@ -197,7 +197,6 @@ CONFIG_PCI_LEGACY=y ...@@ -197,7 +197,6 @@ CONFIG_PCI_LEGACY=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -201,7 +201,6 @@ CONFIG_PCI_LEGACY=y ...@@ -201,7 +201,6 @@ CONFIG_PCI_LEGACY=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -197,7 +197,6 @@ CONFIG_PCI_LEGACY=y ...@@ -197,7 +197,6 @@ CONFIG_PCI_LEGACY=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -184,7 +184,6 @@ CONFIG_PCI=y ...@@ -184,7 +184,6 @@ CONFIG_PCI=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -180,7 +180,6 @@ CONFIG_PCI=y ...@@ -180,7 +180,6 @@ CONFIG_PCI=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -165,6 +165,7 @@ CONFIG_ARCH_PRPMC1100=y ...@@ -165,6 +165,7 @@ CONFIG_ARCH_PRPMC1100=y
CONFIG_MACH_NAS100D=y CONFIG_MACH_NAS100D=y
CONFIG_MACH_DSMG600=y CONFIG_MACH_DSMG600=y
CONFIG_ARCH_IXDP4XX=y CONFIG_ARCH_IXDP4XX=y
CONFIG_MACH_FSG=y
CONFIG_CPU_IXP46X=y CONFIG_CPU_IXP46X=y
CONFIG_CPU_IXP43X=y CONFIG_CPU_IXP43X=y
CONFIG_MACH_GTWX5715=y CONFIG_MACH_GTWX5715=y
...@@ -770,7 +771,7 @@ CONFIG_ATA=y ...@@ -770,7 +771,7 @@ CONFIG_ATA=y
# CONFIG_SATA_SIL24 is not set # CONFIG_SATA_SIL24 is not set
# CONFIG_SATA_SIS is not set # CONFIG_SATA_SIS is not set
# CONFIG_SATA_ULI is not set # CONFIG_SATA_ULI is not set
# CONFIG_SATA_VIA is not set CONFIG_SATA_VIA=y
# CONFIG_SATA_VITESSE is not set # CONFIG_SATA_VITESSE is not set
# CONFIG_SATA_INIC162X is not set # CONFIG_SATA_INIC162X is not set
# CONFIG_PATA_ALI is not set # CONFIG_PATA_ALI is not set
...@@ -1143,7 +1144,7 @@ CONFIG_HWMON=y ...@@ -1143,7 +1144,7 @@ CONFIG_HWMON=y
# CONFIG_SENSORS_VIA686A is not set # CONFIG_SENSORS_VIA686A is not set
# CONFIG_SENSORS_VT1211 is not set # CONFIG_SENSORS_VT1211 is not set
# CONFIG_SENSORS_VT8231 is not set # CONFIG_SENSORS_VT8231 is not set
# CONFIG_SENSORS_W83781D is not set CONFIG_SENSORS_W83781D=y
# CONFIG_SENSORS_W83791D is not set # CONFIG_SENSORS_W83791D is not set
# CONFIG_SENSORS_W83792D is not set # CONFIG_SENSORS_W83792D is not set
# CONFIG_SENSORS_W83793 is not set # CONFIG_SENSORS_W83793 is not set
...@@ -1334,8 +1335,8 @@ CONFIG_LEDS_CLASS=y ...@@ -1334,8 +1335,8 @@ CONFIG_LEDS_CLASS=y
# #
# LED drivers # LED drivers
# #
# CONFIG_LEDS_IXP4XX is not set
CONFIG_LEDS_GPIO=y CONFIG_LEDS_GPIO=y
CONFIG_LEDS_FSG=y
# #
# LED Triggers # LED Triggers
...@@ -1367,7 +1368,7 @@ CONFIG_RTC_INTF_DEV=y ...@@ -1367,7 +1368,7 @@ CONFIG_RTC_INTF_DEV=y
# CONFIG_RTC_DRV_DS1672 is not set # CONFIG_RTC_DRV_DS1672 is not set
# CONFIG_RTC_DRV_MAX6900 is not set # CONFIG_RTC_DRV_MAX6900 is not set
# CONFIG_RTC_DRV_RS5C372 is not set # CONFIG_RTC_DRV_RS5C372 is not set
# CONFIG_RTC_DRV_ISL1208 is not set CONFIG_RTC_DRV_ISL1208=y
CONFIG_RTC_DRV_X1205=y CONFIG_RTC_DRV_X1205=y
CONFIG_RTC_DRV_PCF8563=y CONFIG_RTC_DRV_PCF8563=y
# CONFIG_RTC_DRV_PCF8583 is not set # CONFIG_RTC_DRV_PCF8583 is not set
......
...@@ -162,7 +162,6 @@ CONFIG_CPU_TLB_V4WBI=y ...@@ -162,7 +162,6 @@ CONFIG_CPU_TLB_V4WBI=y
# Kernel Features # Kernel Features
# #
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -126,7 +126,6 @@ CONFIG_ISA_DMA_API=y ...@@ -126,7 +126,6 @@ CONFIG_ISA_DMA_API=y
# #
# Kernel Features # Kernel Features
# #
# CONFIG_NO_IDLE_HZ is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
CONFIG_FLATMEM=y CONFIG_FLATMEM=y
CONFIG_FLAT_NODE_MEM_MAP=y CONFIG_FLAT_NODE_MEM_MAP=y
......
This diff is collapsed.
...@@ -174,7 +174,6 @@ CONFIG_PCCARD_NONSTATIC=y ...@@ -174,7 +174,6 @@ CONFIG_PCCARD_NONSTATIC=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
This diff is collapsed.
...@@ -173,7 +173,6 @@ CONFIG_XSCALE_PMU=y ...@@ -173,7 +173,6 @@ CONFIG_XSCALE_PMU=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -148,7 +148,6 @@ CONFIG_ARM_AMBA=y ...@@ -148,7 +148,6 @@ CONFIG_ARM_AMBA=y
# Kernel Features # Kernel Features
# #
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
# CONFIG_NO_IDLE_HZ is not set
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
CONFIG_ARCH_DISCONTIGMEM_ENABLE=y CONFIG_ARCH_DISCONTIGMEM_ENABLE=y
CONFIG_SELECT_MEMORY_MODEL=y CONFIG_SELECT_MEMORY_MODEL=y
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -154,7 +154,6 @@ CONFIG_ARM_AMBA=y ...@@ -154,7 +154,6 @@ CONFIG_ARM_AMBA=y
# Kernel Features # Kernel Features
# #
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -202,7 +202,6 @@ CONFIG_AT91_CF=y ...@@ -202,7 +202,6 @@ CONFIG_AT91_CF=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -201,7 +201,6 @@ CONFIG_ARM_THUMB=y ...@@ -201,7 +201,6 @@ CONFIG_ARM_THUMB=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
CONFIG_NO_IDLE_HZ=y
CONFIG_HZ=100 CONFIG_HZ=100
CONFIG_AEABI=y CONFIG_AEABI=y
CONFIG_OABI_COMPAT=y CONFIG_OABI_COMPAT=y
......
...@@ -151,7 +151,6 @@ CONFIG_ARM_THUMB=y ...@@ -151,7 +151,6 @@ CONFIG_ARM_THUMB=y
# Kernel Features # Kernel Features
# #
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
This diff is collapsed.
...@@ -177,7 +177,6 @@ CONFIG_NR_CPUS=4 ...@@ -177,7 +177,6 @@ CONFIG_NR_CPUS=4
CONFIG_HOTPLUG_CPU=y CONFIG_HOTPLUG_CPU=y
CONFIG_LOCAL_TIMERS=y CONFIG_LOCAL_TIMERS=y
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -126,7 +126,6 @@ CONFIG_ISA_DMA_API=y ...@@ -126,7 +126,6 @@ CONFIG_ISA_DMA_API=y
# #
# Kernel Features # Kernel Features
# #
# CONFIG_NO_IDLE_HZ is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
CONFIG_FLATMEM=y CONFIG_FLATMEM=y
CONFIG_FLAT_NODE_MEM_MAP=y CONFIG_FLAT_NODE_MEM_MAP=y
......
...@@ -190,7 +190,6 @@ CONFIG_ISA_DMA_API=y ...@@ -190,7 +190,6 @@ CONFIG_ISA_DMA_API=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
This diff is collapsed.
...@@ -211,7 +211,6 @@ CONFIG_ARM_THUMB=y ...@@ -211,7 +211,6 @@ CONFIG_ARM_THUMB=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -164,7 +164,6 @@ CONFIG_PCMCIA_PXA2XX=y ...@@ -164,7 +164,6 @@ CONFIG_PCMCIA_PXA2XX=y
# Kernel Features # Kernel Features
# #
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
# CONFIG_NO_IDLE_HZ is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
CONFIG_SELECT_MEMORY_MODEL=y CONFIG_SELECT_MEMORY_MODEL=y
CONFIG_FLATMEM_MANUAL=y CONFIG_FLATMEM_MANUAL=y
......
...@@ -247,7 +247,6 @@ CONFIG_ARM_THUMB=y ...@@ -247,7 +247,6 @@ CONFIG_ARM_THUMB=y
# #
# CONFIG_TICK_ONESHOT is not set # CONFIG_TICK_ONESHOT is not set
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=200 CONFIG_HZ=200
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
...@@ -195,7 +195,6 @@ CONFIG_PCMCIA_PXA2XX=y ...@@ -195,7 +195,6 @@ CONFIG_PCMCIA_PXA2XX=y
# Kernel Features # Kernel Features
# #
CONFIG_PREEMPT=y CONFIG_PREEMPT=y
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
CONFIG_AEABI=y CONFIG_AEABI=y
CONFIG_OABI_COMPAT=y CONFIG_OABI_COMPAT=y
......
This diff is collapsed.
This diff is collapsed.
...@@ -151,7 +151,6 @@ CONFIG_ARM_AMBA=y ...@@ -151,7 +151,6 @@ CONFIG_ARM_AMBA=y
# Kernel Features # Kernel Features
# #
# CONFIG_PREEMPT is not set # CONFIG_PREEMPT is not set
# CONFIG_NO_IDLE_HZ is not set
CONFIG_HZ=100 CONFIG_HZ=100
# CONFIG_AEABI is not set # CONFIG_AEABI is not set
# CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set
......
#include <linux/slab.h> #include <linux/slab.h>
#include <linux/kexec.h>
#include <linux/proc_fs.h> #include <linux/proc_fs.h>
#include <asm/setup.h> #include <asm/setup.h>
#include <asm/types.h> #include <asm/types.h>
...@@ -7,9 +6,8 @@ ...@@ -7,9 +6,8 @@
struct buffer { struct buffer {
size_t size; size_t size;
char *data; char data[];
}; };
static struct buffer tags_buffer;
static int static int
read_buffer(char* page, char** start, off_t off, int count, read_buffer(char* page, char** start, off_t off, int count,
...@@ -29,58 +27,57 @@ read_buffer(char* page, char** start, off_t off, int count, ...@@ -29,58 +27,57 @@ read_buffer(char* page, char** start, off_t off, int count,
return count; return count;
} }
#define BOOT_PARAMS_SIZE 1536
static int static char __initdata atags_copy[BOOT_PARAMS_SIZE];
create_proc_entries(void)
{
struct proc_dir_entry* tags_entry;
tags_entry = create_proc_read_entry("atags", 0400, NULL, read_buffer, &tags_buffer);
if (!tags_entry)
return -ENOMEM;
return 0;
}
static char __initdata atags_copy_buf[KEXEC_BOOT_PARAMS_SIZE];
static char __initdata *atags_copy;
void __init save_atags(const struct tag *tags) void __init save_atags(const struct tag *tags)
{ {
atags_copy = atags_copy_buf; memcpy(atags_copy, tags, sizeof(atags_copy));
memcpy(atags_copy, tags, KEXEC_BOOT_PARAMS_SIZE);
} }
static int __init init_atags_procfs(void) static int __init init_atags_procfs(void)
{ {
struct tag *tag; /*
int error; * This cannot go into save_atags() because kmalloc and proc don't work
* yet when it is called.
*/
struct proc_dir_entry *tags_entry;
struct tag *tag = (struct tag *)atags_copy;
struct buffer *b;
size_t size;
if (!atags_copy) { if (tag->hdr.tag != ATAG_CORE) {
printk(KERN_WARNING "Exporting ATAGs: No saved tags found\n"); printk(KERN_INFO "No ATAGs?");
return -EIO; return -EINVAL;
} }
for (tag = (struct tag *) atags_copy; tag->hdr.size; tag = tag_next(tag)) for (; tag->hdr.size; tag = tag_next(tag))
; ;
tags_buffer.size = ((char *) tag - atags_copy) + sizeof(tag->hdr); /* include the terminating ATAG_NONE */
tags_buffer.data = kmalloc(tags_buffer.size, GFP_KERNEL); size = (char *)tag - atags_copy + sizeof(struct tag_header);
if (tags_buffer.data == NULL)
return -ENOMEM; WARN_ON(tag->hdr.tag != ATAG_NONE);
memcpy(tags_buffer.data, atags_copy, tags_buffer.size);
b = kmalloc(sizeof(*b) + size, GFP_KERNEL);
if (!b)
goto nomem;
b->size = size;
memcpy(b->data, atags_copy, size);
tags_entry = create_proc_read_entry("atags", 0400,
NULL, read_buffer, b);
if (!tags_entry)
goto nomem;
return 0;
error = create_proc_entries(); nomem:
if (error) { kfree(b);
printk(KERN_ERR "Exporting ATAGs: not enough memory\n"); printk(KERN_ERR "Exporting ATAGs: not enough memory\n");
kfree(tags_buffer.data);
tags_buffer.size = 0;
tags_buffer.data = NULL;
}
return error; return -ENOMEM;
} }
arch_initcall(init_atags_procfs); arch_initcall(init_atags_procfs);
...@@ -680,7 +680,7 @@ static int __init ecard_probeirqhw(void) ...@@ -680,7 +680,7 @@ static int __init ecard_probeirqhw(void)
#define IO_EC_MEMC8_BASE 0 #define IO_EC_MEMC8_BASE 0
#endif #endif
unsigned int __ecard_address(ecard_t *ec, card_type_t type, card_speed_t speed) static unsigned int __ecard_address(ecard_t *ec, card_type_t type, card_speed_t speed)
{ {
unsigned long address = 0; unsigned long address = 0;
int slot = ec->slot_no; int slot = ec->slot_no;
...@@ -1002,7 +1002,7 @@ ecard_probe(int slot, card_type_t type) ...@@ -1002,7 +1002,7 @@ ecard_probe(int slot, card_type_t type)
} }
rc = -ENODEV; rc = -ENODEV;
if ((ec->podaddr = ecard_address(ec, type, ECARD_SYNC)) == 0) if ((ec->podaddr = __ecard_address(ec, type, ECARD_SYNC)) == 0)
goto nodev; goto nodev;
cid.r_zero = 1; cid.r_zero = 1;
...@@ -1141,10 +1141,10 @@ static int ecard_drv_probe(struct device *dev) ...@@ -1141,10 +1141,10 @@ static int ecard_drv_probe(struct device *dev)
id = ecard_match_device(drv->id_table, ec); id = ecard_match_device(drv->id_table, ec);
ecard_claim(ec); ec->claimed = 1;
ret = drv->probe(ec, id); ret = drv->probe(ec, id);
if (ret) if (ret)
ecard_release(ec); ec->claimed = 0;
return ret; return ret;
} }
...@@ -1154,7 +1154,7 @@ static int ecard_drv_remove(struct device *dev) ...@@ -1154,7 +1154,7 @@ static int ecard_drv_remove(struct device *dev)
struct ecard_driver *drv = ECARD_DRV(dev->driver); struct ecard_driver *drv = ECARD_DRV(dev->driver);
drv->remove(ec); drv->remove(ec);
ecard_release(ec); ec->claimed = 0;
/* /*
* Restore the default operations. We ensure that the * Restore the default operations. We ensure that the
...@@ -1182,7 +1182,7 @@ static void ecard_drv_shutdown(struct device *dev) ...@@ -1182,7 +1182,7 @@ static void ecard_drv_shutdown(struct device *dev)
if (dev->driver) { if (dev->driver) {
if (drv->shutdown) if (drv->shutdown)
drv->shutdown(ec); drv->shutdown(ec);
ecard_release(ec); ec->claimed = 0;
} }
/* /*
...@@ -1239,7 +1239,6 @@ static int ecard_bus_init(void) ...@@ -1239,7 +1239,6 @@ static int ecard_bus_init(void)
postcore_initcall(ecard_bus_init); postcore_initcall(ecard_bus_init);
EXPORT_SYMBOL(ecard_readchunk); EXPORT_SYMBOL(ecard_readchunk);
EXPORT_SYMBOL(__ecard_address);
EXPORT_SYMBOL(ecard_register_driver); EXPORT_SYMBOL(ecard_register_driver);
EXPORT_SYMBOL(ecard_remove_driver); EXPORT_SYMBOL(ecard_remove_driver);
EXPORT_SYMBOL(ecard_bus_type); EXPORT_SYMBOL(ecard_bus_type);
...@@ -54,3 +54,16 @@ struct ex_chunk_dir { ...@@ -54,3 +54,16 @@ struct ex_chunk_dir {
#define c_len(x) ((x)->r_len[0]|((x)->r_len[1]<<8)|((x)->r_len[2]<<16)) #define c_len(x) ((x)->r_len[0]|((x)->r_len[1]<<8)|((x)->r_len[2]<<16))
#define c_start(x) ((x)->r_start) #define c_start(x) ((x)->r_start)
}; };
typedef enum ecard_type { /* Cards address space */
ECARD_IOC,
ECARD_MEMC,
ECARD_EASI
} card_type_t;
typedef enum { /* Speed for ECARD_IOC space */
ECARD_SLOW = 0,
ECARD_MEDIUM = 1,
ECARD_FAST = 2,
ECARD_SYNC = 3
} card_speed_t;
...@@ -133,10 +133,8 @@ static void default_idle(void) ...@@ -133,10 +133,8 @@ static void default_idle(void)
cpu_relax(); cpu_relax();
else { else {
local_irq_disable(); local_irq_disable();
if (!need_resched()) { if (!need_resched())
timer_dyn_reprogram();
arch_idle(); arch_idle();
}
local_irq_enable(); local_irq_enable();
} }
} }
......
...@@ -36,6 +36,7 @@ EXPORT_SYMBOL(walk_stackframe); ...@@ -36,6 +36,7 @@ EXPORT_SYMBOL(walk_stackframe);
#ifdef CONFIG_STACKTRACE #ifdef CONFIG_STACKTRACE
struct stack_trace_data { struct stack_trace_data {
struct stack_trace *trace; struct stack_trace *trace;
unsigned int no_sched_functions;
unsigned int skip; unsigned int skip;
}; };
...@@ -43,27 +44,52 @@ static int save_trace(struct stackframe *frame, void *d) ...@@ -43,27 +44,52 @@ static int save_trace(struct stackframe *frame, void *d)
{ {
struct stack_trace_data *data = d; struct stack_trace_data *data = d;
struct stack_trace *trace = data->trace; struct stack_trace *trace = data->trace;
unsigned long addr = frame->lr;
if (data->no_sched_functions && in_sched_functions(addr))
return 0;
if (data->skip) { if (data->skip) {
data->skip--; data->skip--;
return 0; return 0;
} }
trace->entries[trace->nr_entries++] = frame->lr; trace->entries[trace->nr_entries++] = addr;
return trace->nr_entries >= trace->max_entries; return trace->nr_entries >= trace->max_entries;
} }
void save_stack_trace(struct stack_trace *trace) void save_stack_trace_tsk(struct task_struct *tsk, struct stack_trace *trace)
{ {
struct stack_trace_data data; struct stack_trace_data data;
unsigned long fp, base; unsigned long fp, base;
data.trace = trace; data.trace = trace;
data.skip = trace->skip; data.skip = trace->skip;
base = (unsigned long)task_stack_page(current); base = (unsigned long)task_stack_page(tsk);
if (tsk != current) {
#ifdef CONFIG_SMP
/*
* What guarantees do we have here that 'tsk'
* is not running on another CPU?
*/
BUG();
#else
data.no_sched_functions = 1;
fp = thread_saved_fp(tsk);
#endif
} else {
data.no_sched_functions = 0;
asm("mov %0, fp" : "=r" (fp)); asm("mov %0, fp" : "=r" (fp));
}
walk_stackframe(fp, base, base + THREAD_SIZE, save_trace, &data); walk_stackframe(fp, base, base + THREAD_SIZE, save_trace, &data);
if (trace->nr_entries < trace->max_entries)
trace->entries[trace->nr_entries++] = ULONG_MAX;
}
void save_stack_trace(struct stack_trace *trace)
{
save_stack_trace_tsk(current, trace);
} }
#endif #endif
...@@ -365,108 +365,6 @@ static struct sysdev_class timer_sysclass = { ...@@ -365,108 +365,6 @@ static struct sysdev_class timer_sysclass = {
.resume = timer_resume, .resume = timer_resume,
}; };
#ifdef CONFIG_NO_IDLE_HZ
static int timer_dyn_tick_enable(void)
{
struct dyn_tick_timer *dyn_tick = system_timer->dyn_tick;
unsigned long flags;
int ret = -ENODEV;
if (dyn_tick) {
spin_lock_irqsave(&dyn_tick->lock, flags);
ret = 0;
if (!(dyn_tick->state & DYN_TICK_ENABLED)) {
ret = dyn_tick->enable();
if (ret == 0)
dyn_tick->state |= DYN_TICK_ENABLED;
}
spin_unlock_irqrestore(&dyn_tick->lock, flags);
}
return ret;
}
static int timer_dyn_tick_disable(void)
{
struct dyn_tick_timer *dyn_tick = system_timer->dyn_tick;
unsigned long flags;
int ret = -ENODEV;
if (dyn_tick) {
spin_lock_irqsave(&dyn_tick->lock, flags);
ret = 0;
if (dyn_tick->state & DYN_TICK_ENABLED) {
ret = dyn_tick->disable();
if (ret == 0)
dyn_tick->state &= ~DYN_TICK_ENABLED;
}
spin_unlock_irqrestore(&dyn_tick->lock, flags);
}
return ret;
}
/*
* Reprogram the system timer for at least the calculated time interval.
* This function should be called from the idle thread with IRQs disabled,
* immediately before sleeping.
*/
void timer_dyn_reprogram(void)
{
struct dyn_tick_timer *dyn_tick = system_timer->dyn_tick;
unsigned long next, seq, flags;
if (!dyn_tick)
return;
spin_lock_irqsave(&dyn_tick->lock, flags);
if (dyn_tick->state & DYN_TICK_ENABLED) {
next = next_timer_interrupt();
do {
seq = read_seqbegin(&xtime_lock);
dyn_tick->reprogram(next - jiffies);
} while (read_seqretry(&xtime_lock, seq));
}
spin_unlock_irqrestore(&dyn_tick->lock, flags);
}
static ssize_t timer_show_dyn_tick(struct sys_device *dev, char *buf)
{
return sprintf(buf, "%i\n",
(system_timer->dyn_tick->state & DYN_TICK_ENABLED) >> 1);
}
static ssize_t timer_set_dyn_tick(struct sys_device *dev, const char *buf,
size_t count)
{
unsigned int enable = simple_strtoul(buf, NULL, 2);
if (enable)
timer_dyn_tick_enable();
else
timer_dyn_tick_disable();
return count;
}
static SYSDEV_ATTR(dyn_tick, 0644, timer_show_dyn_tick, timer_set_dyn_tick);
/*
* dyntick=enable|disable
*/
static char dyntick_str[4] __initdata = "";
static int __init dyntick_setup(char *str)
{
if (str)
strlcpy(dyntick_str, str, sizeof(dyntick_str));
return 1;
}
__setup("dyntick=", dyntick_setup);
#endif
static int __init timer_init_sysfs(void) static int __init timer_init_sysfs(void)
{ {
int ret = sysdev_class_register(&timer_sysclass); int ret = sysdev_class_register(&timer_sysclass);
...@@ -475,19 +373,6 @@ static int __init timer_init_sysfs(void) ...@@ -475,19 +373,6 @@ static int __init timer_init_sysfs(void)
ret = sysdev_register(&system_timer->dev); ret = sysdev_register(&system_timer->dev);
} }
#ifdef CONFIG_NO_IDLE_HZ
if (ret == 0 && system_timer->dyn_tick) {
ret = sysdev_create_file(&system_timer->dev, &attr_dyn_tick);
/*
* Turn on dynamic tick after calibrate delay
* for correct bogomips
*/
if (ret == 0 && dyntick_str[0] == 'e')
ret = timer_dyn_tick_enable();
}
#endif
return ret; return ret;
} }
...@@ -500,10 +385,5 @@ void __init time_init(void) ...@@ -500,10 +385,5 @@ void __init time_init(void)
system_timer->offset = dummy_gettimeoffset; system_timer->offset = dummy_gettimeoffset;
#endif #endif
system_timer->init(); system_timer->init();
#ifdef CONFIG_NO_IDLE_HZ
if (system_timer->dyn_tick)
spin_lock_init(&system_timer->dyn_tick->lock);
#endif
} }
...@@ -12,14 +12,6 @@ ...@@ -12,14 +12,6 @@
* published by the Free Software Foundation. * published by the Free Software Foundation.
*/ */
/*
* This can be used to enable code to cacheline align the source pointer.
* Experiments on tested architectures (StrongARM and XScale) didn't show
* this a worthwhile thing to do. That might be different in the future.
*/
//#define CALGN(code...) code
#define CALGN(code...)
/* /*
* Theory of operation * Theory of operation
* ------------------- * -------------------
...@@ -82,7 +74,7 @@ ...@@ -82,7 +74,7 @@
stmfd sp!, {r5 - r8} stmfd sp!, {r5 - r8}
blt 5f blt 5f
CALGN( ands ip, r1, #31 ) CALGN( ands ip, r0, #31 )
CALGN( rsb r3, ip, #32 ) CALGN( rsb r3, ip, #32 )
CALGN( sbcnes r4, r3, r2 ) @ C is always set here CALGN( sbcnes r4, r3, r2 ) @ C is always set here
CALGN( bcs 2f ) CALGN( bcs 2f )
...@@ -168,7 +160,7 @@ ...@@ -168,7 +160,7 @@
subs r2, r2, #28 subs r2, r2, #28
blt 14f blt 14f
CALGN( ands ip, r1, #31 ) CALGN( ands ip, r0, #31 )
CALGN( rsb ip, ip, #32 ) CALGN( rsb ip, ip, #32 )
CALGN( sbcnes r4, ip, r2 ) @ C is always set here CALGN( sbcnes r4, ip, r2 ) @ C is always set here
CALGN( subcc r2, r2, ip ) CALGN( subcc r2, r2, ip )
......
...@@ -13,14 +13,6 @@ ...@@ -13,14 +13,6 @@
#include <linux/linkage.h> #include <linux/linkage.h>
#include <asm/assembler.h> #include <asm/assembler.h>
/*
* This can be used to enable code to cacheline align the source pointer.
* Experiments on tested architectures (StrongARM and XScale) didn't show
* this a worthwhile thing to do. That might be different in the future.
*/
//#define CALGN(code...) code
#define CALGN(code...)
.text .text
/* /*
...@@ -55,11 +47,12 @@ ENTRY(memmove) ...@@ -55,11 +47,12 @@ ENTRY(memmove)
stmfd sp!, {r5 - r8} stmfd sp!, {r5 - r8}
blt 5f blt 5f
CALGN( ands ip, r1, #31 ) CALGN( ands ip, r0, #31 )
CALGN( sbcnes r4, ip, r2 ) @ C is always set here CALGN( sbcnes r4, ip, r2 ) @ C is always set here
CALGN( bcs 2f ) CALGN( bcs 2f )
CALGN( adr r4, 6f ) CALGN( adr r4, 6f )
CALGN( subs r2, r2, ip ) @ C is set here CALGN( subs r2, r2, ip ) @ C is set here
CALGN( rsb ip, ip, #32 )
CALGN( add pc, r4, ip ) CALGN( add pc, r4, ip )
PLD( pld [r1, #-4] ) PLD( pld [r1, #-4] )
...@@ -138,8 +131,7 @@ ENTRY(memmove) ...@@ -138,8 +131,7 @@ ENTRY(memmove)
subs r2, r2, #28 subs r2, r2, #28
blt 14f blt 14f
CALGN( ands ip, r1, #31 ) CALGN( ands ip, r0, #31 )
CALGN( rsb ip, ip, #32 )
CALGN( sbcnes r4, ip, r2 ) @ C is always set here CALGN( sbcnes r4, ip, r2 ) @ C is always set here
CALGN( subcc r2, r2, ip ) CALGN( subcc r2, r2, ip )
CALGN( bcc 15f ) CALGN( bcc 15f )
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -232,19 +232,19 @@ void __init at91_add_device_nand(struct at91_nand_data *data) ...@@ -232,19 +232,19 @@ void __init at91_add_device_nand(struct at91_nand_data *data)
at91_sys_write(AT91_MATRIX_EBICSA, csa | AT91_MATRIX_CS3A_SMC_SMARTMEDIA); at91_sys_write(AT91_MATRIX_EBICSA, csa | AT91_MATRIX_CS3A_SMC_SMARTMEDIA);
/* set the bus interface characteristics */ /* set the bus interface characteristics */
at91_sys_write(AT91_SMC_SETUP(3), AT91_SMC_NWESETUP_(0) | AT91_SMC_NCS_WRSETUP_(0) at91_sys_write(AT91_SMC_SETUP(3), AT91_SMC_NWESETUP_(1) | AT91_SMC_NCS_WRSETUP_(0)
| AT91_SMC_NRDSETUP_(0) | AT91_SMC_NCS_RDSETUP_(0)); | AT91_SMC_NRDSETUP_(1) | AT91_SMC_NCS_RDSETUP_(0));
at91_sys_write(AT91_SMC_PULSE(3), AT91_SMC_NWEPULSE_(2) | AT91_SMC_NCS_WRPULSE_(5) at91_sys_write(AT91_SMC_PULSE(3), AT91_SMC_NWEPULSE_(3) | AT91_SMC_NCS_WRPULSE_(3)
| AT91_SMC_NRDPULSE_(2) | AT91_SMC_NCS_RDPULSE_(5)); | AT91_SMC_NRDPULSE_(3) | AT91_SMC_NCS_RDPULSE_(3));
at91_sys_write(AT91_SMC_CYCLE(3), AT91_SMC_NWECYCLE_(7) | AT91_SMC_NRDCYCLE_(7)); at91_sys_write(AT91_SMC_CYCLE(3), AT91_SMC_NWECYCLE_(5) | AT91_SMC_NRDCYCLE_(5));
if (data->bus_width_16) if (data->bus_width_16)
mode = AT91_SMC_DBW_16; mode = AT91_SMC_DBW_16;
else else
mode = AT91_SMC_DBW_8; mode = AT91_SMC_DBW_8;
at91_sys_write(AT91_SMC_MODE(3), mode | AT91_SMC_READMODE | AT91_SMC_WRITEMODE | AT91_SMC_EXNWMODE_DISABLE | AT91_SMC_TDF_(1)); at91_sys_write(AT91_SMC_MODE(3), mode | AT91_SMC_READMODE | AT91_SMC_WRITEMODE | AT91_SMC_EXNWMODE_DISABLE | AT91_SMC_TDF_(2));
/* enable pin */ /* enable pin */
if (data->enable_pin) if (data->enable_pin)
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment