]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/log
linux-2.6-omap-h63xx.git
16 years agoARM: OMAP: Move timer32k to mach-omap1
Kevin Hilman [Mon, 12 Nov 2007 23:24:05 +0000 (15:24 -0800)]
ARM: OMAP: Move timer32k to mach-omap1

Move now OMAP1-specific timer32k code to mach-omap1 since OMAP2/3 32k
timers are done in gptimer code.

Signed-off-by: Kevin Hilman <khilman@mvista.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: Move 32k-based sched_clock() to common code
Kevin Hilman [Mon, 12 Nov 2007 23:24:03 +0000 (15:24 -0800)]
ARM: OMAP: Move 32k-based sched_clock() to common code

Since 32k timer code is moving to OMAP1 specific dir, move the
32k-based sched_clock() into common code where it is based on the 32k
sync counter and can be used even when using MPU timer.

While moving, change the ticks-to-nsecs conversion to use the helper
functions provided by clocksource.h.

Also removed the unused ticks_to_usec, leaving only ticks_to_nsec.

Signed-off-by: Kevin Hilman <khilman@mvista.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: re-organize duplicated 32k-timer code
Kevin Hilman [Mon, 12 Nov 2007 23:24:02 +0000 (15:24 -0800)]
ARM: OMAP: re-organize duplicated 32k-timer code

On OMAP2/3, the gp-timer code can be used for a 32kHz timer simply by
setting the source to be the 32k clock instead of sys_clk.

This patch uses the mach-omap2/timer-gp.c code for 32kHz timer on
OMAP2, moving the logic into mach-omap2/timer-gp.c, and not using
plat-omap/timer32k.c which, for OMAP2, is redundant with the timer-gp
code.

Also, if CONFIG_OMAP_32K_TIMER is enabled, the gptimer-based
clocksource is not used.  Instead the default 32k sync counter is used
as the clocksource (see the clocksource in plat-omap/common.c.)  This
is important for sleep/suspend so there is a valid counter during
sleep.  Note that the suspend/sleep code needs fixing to check for
overflows of this counter.

In addition, the OMAP2/3 details are removed from timer32k.c leaving
that with only OMAP1 specifics.  A follow-up patch will move it from
plat-omap common code to mach-omap1.

Signed-off-by: Kevin Hilman <khilman@mvista.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoMerge current mainline tree into linux-omap tree
Tony Lindgren [Wed, 21 Nov 2007 02:27:29 +0000 (18:27 -0800)]
Merge current mainline tree into linux-omap tree

Merge branch 'linus'

Conflicts:

arch/arm/mach-omap1/board-h2.c
arch/arm/mach-omap2/clock.c
drivers/video/omap/Kconfig
net/ipv4/netfilter/Makefile

16 years agoMerge current mainline tree into linux-omap tree
Tony Lindgren [Wed, 21 Nov 2007 01:17:21 +0000 (17:17 -0800)]
Merge current mainline tree into linux-omap tree

Merge branches 'master' and 'linus' into linus

16 years agoMerge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux...
Linus Torvalds [Sat, 17 Nov 2007 16:36:10 +0000 (08:36 -0800)]
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-x86

* 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-x86:
  x86: simplify "make ARCH=x86" and fix kconfig all.config
  x86: reboot fixup for wrap2c board
  x86: check boundary in count setup resource
  x86: fix reboot with no keyboard attached
  x86: add hpet sanity checks
  x86: on x86_64, correct reading of PC RTC when update in progress in time_64.c
  x86: fix freeze in x86_64 RTC update code in time_64.c
  ntp: fix typo that makes sync_cmos_clock erratic
  Remove x86 merge artifact from top Makefile
  x86: fixup cpu_info array conversion
  x86: show cpuinfo only for online CPUs
  x86: fix cpu-hotplug regression
  x86: ignore the sys_getcpu() tcache parameter
  x86: voyager use correct header file name
  x86: fix smp init sections
  x86: fix voyager_cat_init section
  x86: fix bogus memcpy in es7000_check_dsdt()

16 years agox86: simplify "make ARCH=x86" and fix kconfig all.config
Sam Ravnborg [Sat, 17 Nov 2007 14:37:31 +0000 (15:37 +0100)]
x86: simplify "make ARCH=x86" and fix kconfig all.config

Simplify "make ARCH=x86" and fix kconfig so we again can set 64BIT in
all.config.

For a fix the diffstat is nice:
 6 files changed, 3 insertions(+), 36 deletions(-)

The patch reverts these commits:
 - 0f855aa64b3f63d35a891510cf7db932a435c116 ("kconfig: add helper to set
   config symbol from environment variable")
 - 2a113281f5cd2febbab21a93c8943f8d3eece4d3 ("kconfig: use $K64BIT to
   set 64BIT with all*config targets")

Roman Zippel pointed out that kconfig supported string compares so
the additional complexity introduced by the above two patches were
not needed.

With this patch we have following behaviour:

  # make {allno,allyes,allmod,rand}config [ARCH=...]
  option \ host arch      | 32bit         | 64bit
  =====================================================
  ./.                     | 32bit         | 64bit
  ARCH=x86                | 32bit         | 32bit
  ARCH=i386               | 32bit         | 32bit
  ARCH=x86_64             | 64bit         | 64bit

The general rule are that ARCH= and native architecture takes
precedence over the configuration.

So make ARCH=i386 [whatever] will always build a 32-bit kernel
no matter what the configuration says.  The configuration will
be updated to 32-bit if it was configured to 64-bit and the
other way around.

This behaviour is consistent with previous behaviour so no
suprises here.

make ARCH=x86 will per default result in a 32-bit kernel but as
the only ARCH= value x86 allow the user to select between 32-bit
and 64-bit using menuconfig.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Cc: Andreas Herrmann <aherrman@arcor.de>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agox86: simplify "make ARCH=x86" and fix kconfig all.config
Sam Ravnborg [Sat, 17 Nov 2007 14:37:31 +0000 (15:37 +0100)]
x86: simplify "make ARCH=x86" and fix kconfig all.config

Simplify "make ARCH=x86" and fix kconfig so we again
can set 64BIT in all.config.

For a fix the diffstat is nice:
 6 files changed, 3 insertions(+), 36 deletions(-)

The patch reverts these commits:
0f855aa64b3f63d35a891510cf7db932a435c116
-> kconfig: add helper to set config symbol from environment variable

2a113281f5cd2febbab21a93c8943f8d3eece4d3
-> kconfig: use $K64BIT to set 64BIT with all*config targets

Roman Zippel pointed out that kconfig supported string
compares so the additional complexity introduced by the
above two patches were not needed.

With this patch we have following behaviour:

# make {allno,allyes,allmod,rand}config [ARCH=...]
option \ host arch      | 32bit         | 64bit
=====================================================
./.                     | 32bit         | 64bit
ARCH=x86                | 32bit         | 32bit
ARCH=i386               | 32bit         | 32bit
ARCH=x86_64             | 64bit         | 64bit

The general rule are that ARCH= and native architecture
takes precedence over the configuration.
So make ARCH=i386 [whatever] will always build a 32-bit
kernel no matter what the configuration says.
The configuration will be updated to 32-bit if it was
configured to 64-bit and the other way around.

This behaviour is consistent with previous behaviour so
no suprises here.

make ARCH=x86 will per default result in a 32-bit kernel
but as the only ARCH= value x86 allow the user to select
between 32-bit and 64-bit using menuconfig.

Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Roman Zippel <zippel@linux-m68k.org>
Cc: Andreas Herrmann <aherrman@arcor.de>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
16 years agox86: reboot fixup for wrap2c board
Denys [Sat, 17 Nov 2007 15:27:02 +0000 (16:27 +0100)]
x86: reboot fixup for wrap2c board

Needed to make the wireless board, WRAP2C reboot.

Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: check boundary in count setup resource
Yinghai Lu [Sat, 17 Nov 2007 15:27:01 +0000 (16:27 +0100)]
x86: check boundary in count setup resource

need to check info->res_num less than PCI_BUS_NUM_RESOURCES, so
info->bus->resource[info->res_num] = res will not beyond of bus resource
array when acpi returns too many resource entries.

Signed-off-by: Yinghai Lu <yinghai.lu@sun.com>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
Cc: Gary Hade <gary.hade@us.ibm.com>
Cc: Len Brown <lenb@kernel.org>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: fix reboot with no keyboard attached
Truxton Fulton [Sat, 17 Nov 2007 15:27:01 +0000 (16:27 +0100)]
x86: fix reboot with no keyboard attached

Attempt to fix http://bugzilla.kernel.org/show_bug.cgi?id=8378

Hiroto Shibuya wrote to tell me that he has a VIA EPIA-EK10000 which
suffers from the reboot problem when no keyboard is attached.  My first
patch works for him:

  http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=59f4e7d572980a521b7bdba74ab71b21f5995538

But the latest patch does not work for him :

  http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=8b93789808756bcc1e5c90c99f1b1ef52f839a51

We found that it was necessary to also set the "disable keyboard" flag in
the command byte, as the first patch was doing.  The second patch tries to
minimally modify the command byte, but it is not enough.

Please consider this simple one-line patch to help people with low end VIA
motherboards reboot when no keyboard is attached.  Hiroto Shibuya has
verified that this works for him (as I no longer have an afflicted
machine).

Additional discussion:

Note that original patch from Truxton DOES
disable keyboard and this has been in main tree since 2.6.14, thus it must have
quite a bit of air time already.

http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.14.y.git;a=commit;h=59f4e7d572980a521b7bdba74ab71b21f5995538

Note that he only mention "System flag" in the description and comment, but
in the code, "disable keyboard" flag is set.

  outb(0x14, 0x60);       /* set "System flag" */

In 2.6.23, he made a change to read the current byte and then mask the flags,
but along this change,  he only set the "System flag" and dropped the setting
of "disable keyboard" flag.

http://git.kernel.org/?p=linux/kernel/git/stable/linux-2.6.23.y.git;a=commit;h=8b93789808756bcc1e5c90c99f1b1ef52f839a51

   outb(cmd | 0x04, 0x60); /* set "System flag" */

So my request is to restore the setting of disable keyboard flag which has been
there since 2.6.14 but disappeared in 2.6.23.

Cc: Lee Garrett <lee-in-berlin@web.de>
Cc: "Hiroto Shibuya" <hiroto.shibuya@gmail.com>
Cc: Natalie Protasevich <protasnb@gmail.com>
Cc: Dmitry Torokhov <dtor@mail.ru>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Aristeu Rozanski <aris@ruivo.org>
Cc: <stable@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: add hpet sanity checks
Thomas Gleixner [Fri, 16 Nov 2007 02:41:50 +0000 (21:41 -0500)]
x86: add hpet sanity checks

Some BIOSes advertise HPET at 0x0. We really do no want to
allocate a resource there. Check for it and leave early.

Other BIOSes tell us the HPET is at 0xfed0000000000000
instead of 0xfed00000. Add a check and fix it up with a warning
on user request.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: on x86_64, correct reading of PC RTC when update in progress in time_64.c
David P. Reed [Thu, 15 Nov 2007 01:14:50 +0000 (20:14 -0500)]
x86: on x86_64, correct reading of PC RTC when update in progress in time_64.c

Correct potentially unstable PC RTC time register reading in time_64.c

Stop the use of an incorrect technique for reading the standard PC RTC
timer, which is documented to "disconnect" time registers from the bus
while updates are in progress.  The use of UIP flag while interrupts
are disabled to protect a 244 microsecond window is one of the
Motorola spec sheet's documented ways to read the RTC time registers
reliably.

tglx: removed locking changes from original patch, as they gain nothing
(read_persistent_clock is only called during boot, suspend, resume - so
no hot path affected) and conflict with the paravirt locking scheme
(see 32bit code), which we do not want to complicate for no benefit.

Signed-off-by: David P. Reed <dpreed@reed.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: fix freeze in x86_64 RTC update code in time_64.c
David P. Reed [Wed, 14 Nov 2007 22:47:35 +0000 (17:47 -0500)]
x86: fix freeze in x86_64 RTC update code in time_64.c

Fix hard freeze on x86_64 when the ntpd service calls
update_persistent_clock()

A repeatable but randomly timed freeze has been happening in Fedora 6
and 7 for the last year, whenever I run the ntpd service on my AMD64x2
HP Pavilion dv9000z laptop.  This freeze is due to the use of
spin_lock(&rtc_lock) under the assumption (per a bad comment) that
set_rtc_mmss is called only with interrupts disabled.  The call from
ntp.c to update_persistent_clock is made with interrupts enabled.

Signed-off-by: David P. Reed <dpreed@reed.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agontp: fix typo that makes sync_cmos_clock erratic
David P. Reed [Wed, 14 Nov 2007 22:49:21 +0000 (17:49 -0500)]
ntp: fix typo that makes sync_cmos_clock erratic

Fix a typo in ntp.c that has caused updating of the persistent (RTC)
clock when synced to NTP to behave erratically.

When debugging a freeze that arises on my AMD64 machines when I
run the ntpd service, I added a number of printk's to monitor the
sync_cmos_clock procedure.  I discovered that it was not syncing to
cmos RTC every 11 minutes as documented, but instead would keep trying
every second for hours at a time.  The reason turned out to be a typo
in sync_cmos_clock, where it attempts to ensure that
update_persistent_clock is called very close to 500 msec. after a 1
second boundary (required by the PC RTC's spec). That typo referred to
"xtime" in one spot, rather than "now", which is derived from "xtime"
but not equal to it.  This makes the test erratic, creating a
"coin-flip" that decides when update_persistent_clock is called - when
it is called, which is rarely, it may be at any time during the one
second period, rather than close to 500 msec, so the value written is
needlessly incorrect, too.

Signed-off-by: David P. Reed
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agoRemove x86 merge artifact from top Makefile
Thomas Gleixner [Thu, 15 Nov 2007 06:11:12 +0000 (07:11 +0100)]
Remove x86 merge artifact from top Makefile

The x86 merge modified the tags target to handle the two separate
source directories. Remove it now that i386/x86_64 are gone completely.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: fixup cpu_info array conversion
Thomas Gleixner [Sat, 17 Nov 2007 12:18:42 +0000 (13:18 +0100)]
x86: fixup cpu_info array conversion

92cb7612aee39642d109b8d935ad265e602c0563 sets cpu_info->cpu_index to zero
for no reason. Referencing cpu_info->cpu_index now points always to CPU#0,
which is apparently not what we want.

Remove it.

Spotted-by: Zou Nan hai <nanhai.zou@intel.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: show cpuinfo only for online CPUs
Andreas Herrmann [Thu, 1 Nov 2007 18:32:17 +0000 (19:32 +0100)]
x86: show cpuinfo only for online CPUs

Fix regressions introduced with 92cb7612aee39642d109b8d935ad265e602c0563.

It can happen that cpuinfo is displayed for CPUs that are not online or
even worse for CPUs not present at all. As an example, following was
shown for a "second" CPU of a single core K8 variant:

    processor       : 0
    vendor_id       : unknown
    cpu family      : 0
    model           : 0
    model name      : unknown
    stepping        : 0
    cache size      : 0 KB
    fpu             : yes
    fpu_exception   : yes
    cpuid level     : 0
    wp              : yes
    flags           :
    bogomips        : 0.00
    clflush size    : 0
    cache_alignment : 0
    address sizes   : 0 bits physical, 0 bits virtual
    power management:

Signed-off-by: Andreas Herrmann <andreas.herrmann3@amd.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: fix cpu-hotplug regression
Andreas Herrmann [Wed, 7 Nov 2007 01:12:58 +0000 (02:12 +0100)]
x86: fix cpu-hotplug regression

Commit d435d862baca3e25e5eec236762a43251b1e7ffc
("cpu hotplug: mce: fix cpu hotplug error handling")
changed the error handling in mce_cpu_callback.

In cases where not all CPUs are brought up during
boot (e.g. using maxcpus and additional_cpus parameters)
mce_cpu_callback now returns NOTFIY_BAD because
for such CPUs cpu_data is not completely filled when
the notifier is called. Thus mce_create_device fails right
at its beginning:

        if (!mce_available(&cpu_data[cpu]))
                return -EIO;

As a quick fix I suggest to check boot_cpu_data for MCE.

To reproduce this regression:

(1) boot with maxcpus=2 addtional_cpus=2 on a 4 CPU x86-64 system
(2) # echo 1 >/sys/devices/system/cpu/cpu2/online
  -bash: echo: write error: Invalid argument

dmesg shows:

_cpu_up: attempt to bring up CPU 2 failed

Signed-off-by: Andreas Herrmann <andreas.herrmann3@amd.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: ignore the sys_getcpu() tcache parameter
Ingo Molnar [Wed, 7 Nov 2007 17:37:48 +0000 (18:37 +0100)]
x86: ignore the sys_getcpu() tcache parameter

dont use the vgetcpu tcache - it's causing problems with tasks
migrating, they'll see the old cache up to a jiffy after the
migration, further increasing the costs of the migration.

In the worst case they see a complete bogus information from
the tcache, when a sys_getcpu() call "invalidated" the cache
info by incrementing the jiffies _and_ the cpuid info in the
cache and the following vdso_getcpu() call happens after
vdso_jiffies have been incremented.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Ulrich Drepper <drepper@redhat.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: voyager use correct header file name
Randy Dunlap [Mon, 12 Nov 2007 05:06:02 +0000 (21:06 -0800)]
x86: voyager use correct header file name

Fix header file name for Voyager build.

In file included from arch/x86/kernel/setup_32.c:61:
include/asm-x86/mach-voyager/setup_arch.h:2:26: error: asm/setup_32.h: No such file or directory
make[1]: *** [arch/x86/kernel/setup_32.o] Error 1

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: fix smp init sections
Randy Dunlap [Mon, 12 Nov 2007 05:06:45 +0000 (21:06 -0800)]
x86: fix smp init sections

Fix Voyager section mismatch due to using __devinit instead of __cpuinit.

WARNING: vmlinux.o(.text+0xd943): Section mismatch: reference to .init.text:init_gdt (between 'voyager_smp_prepare_boot_cpu' and 'smp_vic_cmn_interrupt')

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: fix voyager_cat_init section
Randy Dunlap [Mon, 12 Nov 2007 05:06:23 +0000 (21:06 -0800)]
x86: fix voyager_cat_init section

Fix Voyager section mismatches:  voyager_cat_init() should be __init.

WARNING: vmlinux.o(.text+0xee83): Section mismatch: reference to .init.data:eprom_buf (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xeea6): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xeeac): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xeeb2): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xef4c): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xef56): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xf10f): Section mismatch: reference to .init.data:eprom_buf (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xf13b): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xf14b): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xf159): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xf1b1): Section mismatch: reference to .init.data:eprom_buf (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xf1bb): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xf1c1): Section mismatch: reference to .init.data:eprom_buf (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xf1c7): Section mismatch: reference to .init.data:eprom_buf (between 'voyager_cat_init' and 'aes_enc_blk')
WARNING: vmlinux.o(.text+0xf1e6): Section mismatch: reference to .init.data: (between 'voyager_cat_init' and 'aes_enc_blk')

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agox86: fix bogus memcpy in es7000_check_dsdt()
Thomas Gleixner [Wed, 14 Nov 2007 12:20:48 +0000 (13:20 +0100)]
x86: fix bogus memcpy in es7000_check_dsdt()

es7000_check_dst() contains a memcpy from 0, which probably should have been
a memset. Remove it and check the retunr value from acpi_get_table_header.

Noticed by: Joe Perches <joe@perches.com>

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
16 years agoLinux 2.6.24-rc3 v2.6.24-rc3
Linus Torvalds [Sat, 17 Nov 2007 05:16:36 +0000 (21:16 -0800)]
Linux 2.6.24-rc3

16 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris...
Linus Torvalds [Sat, 17 Nov 2007 02:32:28 +0000 (18:32 -0800)]
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/selinux-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/selinux-2.6:
  SELinux: return EOPNOTSUPP not ENOTSUPP

16 years agoMerge branch 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm
Linus Torvalds [Sat, 17 Nov 2007 02:32:08 +0000 (18:32 -0800)]
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:
  [ARM] 4638/1: pxa: use PXA3xx specific macros to define clks
  [ARM] remove useless setting of VM_RESERVED

16 years agoMerge master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq
Linus Torvalds [Sat, 17 Nov 2007 02:30:26 +0000 (18:30 -0800)]
Merge master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq

* master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq:
  [CPUFREQ] Fix up whitespace in conservative governor.
  [CPUFREQ] Make cpufreq_conservative handle out-of-sync events properly
  [CPUFREQ] architectural pstate driver for powernow-k8

16 years agoARM: OMAP2: PRCM: more init, and clear wakeup events.
Kevin Hilman [Thu, 1 Nov 2007 23:11:56 +0000 (16:11 -0700)]
ARM: OMAP2: PRCM: more init, and clear wakeup events.

More initialization of wake dependencies.
Clear PRCM wake-up events after coming out of full-retention.

Signed-off-by: Kevin Hilman <khilman@mvista.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoWatchdog: Fix for the watchdog reset issue on OMAP3
Reddy, Teerth [Fri, 16 Nov 2007 23:59:53 +0000 (15:59 -0800)]
Watchdog: Fix for the watchdog reset issue on OMAP3

Fix for the watchdog reset defect.The watchdog header file has been modified in the mainline merge due to which the watchdog was not functioning.
OMAP_WATCHDOG_BASE is being added twice so this patch is required for the watchdog to function.

Signed-off-by: Teerth Reddy <teerth@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: VMALLOC Size
Choraria, Rohit [Fri, 16 Nov 2007 23:51:26 +0000 (15:51 -0800)]
ARM: OMAP: VMALLOC Size

This patch increases the size of VMALLOC to accommodate the bigger DDR and
NOR flashes being used now. Since SRAM is allocated at the end of VMALLOC
area, moving the SRAM virtual address also.

Signed-off-by: Rohit Choraria <rohitkc@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: Fix compiler error when I2C_OMAP is not set
Kyungmin Park [Fri, 16 Nov 2007 00:36:49 +0000 (09:36 +0900)]
ARM: OMAP: Fix compiler error when I2C_OMAP is not set

Fix compiler error when I2C_OMAP is not set

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Acked-by: Jarkko Nikula <jarkko.nikula@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: implement CPUfreq frequency table based on PRCM table
Kevin Hilman [Fri, 16 Nov 2007 23:44:18 +0000 (15:44 -0800)]
ARM: OMAP: implement CPUfreq frequency table based on PRCM table

This patch adds a CPUfreq frequency-table implementation for OMAP2 by
walking the PRCM rate-table for available entries and adding them to a
CPUfreq table.

CPUfreq can then be used to manage switching between all the available
entries in the PRCM rate table.  Either use the CPUfreq sysfs
interface directly, (see Section 3 of Documentation/cpu-freq/user-guide.txt)
or use the cpufrequtils package:
http://www.kernel.org/pub/linux/utils/kernel/cpufreq/cpufrequtils.html

Signed-off-by: Kevin Hilman <khilman@mvista.com>
Updated to try to use cpufreq_table if it exists.

Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoSELinux: return EOPNOTSUPP not ENOTSUPP
Eric Paris [Fri, 16 Nov 2007 21:35:56 +0000 (16:35 -0500)]
SELinux: return EOPNOTSUPP not ENOTSUPP

ENOTSUPP is not a valid error code in the kernel (it is defined in some
NFS internal error codes and has been improperly used other places).  In
the !CONFIG_SECURITY_SELINUX case though it is possible that we could
return this from selinux_audit_rule_init().  This patch just returns the
userspace valid EOPNOTSUPP.

Signed-off-by: Eric Paris <eparis@redhat.com>
Signed-off-by: James Morris <jmorris@namei.org>
16 years agoSRAM patcher: convert omap2_set_prcm to use runtime SRAM patcher
Paul Walmsley [Wed, 14 Nov 2007 08:30:15 +0000 (01:30 -0700)]
SRAM patcher: convert omap2_set_prcm to use runtime SRAM patcher

Use the runtime SRAM patcher to set register addresses in
omap2_set_prcm.  The long symbol names are intended to help
disambiguate the symbols, now that they are global.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoSRAM patcher: convert sram_reprogram_sdrc to use runtime SRAM patcher
Paul Walmsley [Wed, 14 Nov 2007 08:30:14 +0000 (01:30 -0700)]
SRAM patcher: convert sram_reprogram_sdrc to use runtime SRAM patcher

Use the runtime SRAM patcher to set register addresses in
sram_reprogram_sdrc.  The long symbol names are intended to help
disambiguate the symbols, now that they are global.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoSRAM patcher: convert sram_ddr_init to use runtime SRAM patcher
Paul Walmsley [Wed, 14 Nov 2007 08:30:13 +0000 (01:30 -0700)]
SRAM patcher: convert sram_ddr_init to use runtime SRAM patcher

Use the runtime SRAM patcher to set register addresses in
sram_ddr_init.  The long symbol names are intended to help
disambiguate the symbols, now that they are global.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoSRAM patcher: convert omap24xx_sram_suspend to use runtime SRAM patcher
Paul Walmsley [Wed, 14 Nov 2007 08:30:12 +0000 (01:30 -0700)]
SRAM patcher: convert omap24xx_sram_suspend to use runtime SRAM patcher

Use the runtime SRAM patcher to set register addresses in
omap24xx_sram_suspend.  The long symbol names are intended to help
disambiguate the symbols, now that they are global.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoSRAM patcher: add SRAM virtual address patcher
Paul Walmsley [Wed, 14 Nov 2007 08:30:11 +0000 (01:30 -0700)]
SRAM patcher: add SRAM virtual address patcher

Add omap_sram_patch_va(), which patches a virtual address into SRAM
code at runtime.  This will be used in a future patch series to implement
part of multiboot support for OMAP2/3.

If CONFIG_OMAP_DEBUG_SRAM_PATCH is defined (the default), the code
will be very careful to ensure that the target location to patch is
valid.  It will only overwrite a location if the location contains a
32-bit magic number, defined as SRAM_VA_MAGIC.  Also, defining DEBUG
at the top of the file and enabling CONFIG_DEBUG_LL will log patch
locations and data via printk.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoTwl4030- Keypad support on OMAP 3430
Girish [Fri, 2 Nov 2007 15:25:02 +0000 (20:55 +0530)]
Twl4030- Keypad support on OMAP 3430

This patch supports Keypad on 3430

Signed-off-by: Girish S G <girishsg@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years ago[ARM] 4638/1: pxa: use PXA3xx specific macros to define clks
eric miao [Tue, 30 Oct 2007 07:10:18 +0000 (08:10 +0100)]
[ARM] 4638/1: pxa: use PXA3xx specific macros to define clks

PXA3xx uses its own clk_pxa3xx_cken_ops, modify the code to use the
PXA3xx specific macros to define its clocks

Signed-off-by: eric miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
16 years agoTouch Screen: support on OMAP 3430
Girish [Fri, 2 Nov 2007 15:24:55 +0000 (20:54 +0530)]
Touch Screen: support on OMAP 3430

This patch supports Touchscreen on 3430
Signed-off-by: Girish S G <girishsg@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoI2C and TWL4030 suport on 34xx
Chandra shekhar [Fri, 16 Nov 2007 13:48:26 +0000 (19:18 +0530)]
I2C and TWL4030 suport on 34xx

TWL4030 core support for 3430

Signed-off-by: chandra shekhar <x0044955@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoI2C and TWL4030 suport on 34xx
Chandra shekhar [Fri, 16 Nov 2007 13:46:52 +0000 (19:16 +0530)]
I2C and TWL4030 suport on 34xx

Resubmitting the I2C patch for 3430, after Jarkko's I2C registration helper changes.

Signed-off-by: chandra shekhar <x0044955@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agodirty page balancing: Get rid of broken unmapped_ratio logic
Linus Torvalds [Fri, 16 Nov 2007 00:41:52 +0000 (16:41 -0800)]
dirty page balancing: Get rid of broken unmapped_ratio logic

This code harks back to the days when we didn't count dirty mapped
pages, which led us to try to balance the number of dirty unmapped pages
by how much unmapped memory there was in the system.

That makes no sense any more, since now the dirty counts include the
mapped pages.  Not to mention that the math doesn't work with HIGHMEM
machines anyway, and causes the unmapped_ratio to potentially turn
negative (which we do catch thanks to clamping it at a minimum value,
but I mention that as an indication of how broken the code is).

The code also was written at a time when the default dirty ratio was
much larger, and the unmapped_ratio logic effectively capped that large
dirty ratio a bit.  Again, we've since lowered the dirty ratio rather
aggressively, further lessening the point of that code.

Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
16 years agoMerge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
Linus Torvalds [Fri, 16 Nov 2007 00:34:00 +0000 (16:34 -0800)]
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6

* 'master' of master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6:
  [NETFILTER]: Fix NULL pointer dereference in nf_nat_move_storage()
  [SUNHME]: VLAN support for sunhme
  [CHELSIO]: Fix skb->dev setting.
  [NETFILTER]: fix compat_nf_sockopt typo
  [INET]: Fix potential kfree on vmalloc-ed area of request_sock_queue
  [VIA_VELOCITY]: Don't oops on MTU change.
  iwl4965: fix not correctly dealing with hotunplug
  rt2x00: Fix chipset revision validation
  iwl3945: place CCK rates in front of OFDM for supported rates
  mac80211: Fix queuing of scan containing a SSID

16 years agoMerge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus
Linus Torvalds [Fri, 16 Nov 2007 00:08:49 +0000 (16:08 -0800)]
Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus

* 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
  [MIPS] N32 needs to use the compat version of sys_nfsservctl.
  [MIPS] irq_cpu: use handle_percpu_irq handler to avoid dropping interrupts.
  [MIPS] Sibyte: Fix name of clocksource.
  [MIPS] SNI: s/achknowledge/acknowledge/
  [MIPS] Makefile: Fix canonical system names
  [MIPS] vpe: handle halting TCs in an errata safe way.
  [MIPS] Sibyte: Stop timers before programming next even.
  [MIPS] Sibyte: Increase minimum oneshot timer interval to two ticks.
  [MIPS] Lasat: Fix overlap of interrupt number ranges.
  [MIPS] SNI PCIT CPLUS: workaround for b0rked irq wiring of onboard PCI bus 1
  [MIPS] Fix shadow register support.
  [MIPS] Change get_cycles to always return 0.
  [MIPS] Fix typo in R3000 TRACE_IRQFLAGS code
  [MIPS] Sibyte: Replace use of removed IO_SPACE_BASE with IOADDR.
  [MIPS] iounmap if in vr41xx_pciu_init() pci clock is over 33MHz
  [MIPS] BCM1480: Remove duplicate acknowledge of timer interrupt.
  [MIPS] Sibyte: pin timer interrupt to their cores.
  [MIPS] Qemu: Add early printk, your friend in a cold night.
  [MIPS] Convert reference to mem_map to pfn_to_page().
  [MIPS] Sibyte: resurrect old cache hack.

16 years ago[NETFILTER]: Fix NULL pointer dereference in nf_nat_move_storage()
Evgeniy Polyakov [Thu, 15 Nov 2007 23:52:32 +0000 (15:52 -0800)]
[NETFILTER]: Fix NULL pointer dereference in nf_nat_move_storage()

Reported by Chuck Ebbert as:

https://bugzilla.redhat.com/show_bug.cgi?id=259501#c14

This routine is called each time hash should be replaced, nf_conn has
extension list which contains pointers to connection tracking users
(like nat, which is right now the only such user), so when replace takes
place it should copy own extensions. Loop above checks for own
extension, but tries to move higer-layer one, which can lead to above
oops.

Signed-off-by: Evgeniy Polyakov <johnpol@2ka.mipt.ru>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years ago[SUNHME]: VLAN support for sunhme
Chris Poon [Thu, 15 Nov 2007 23:38:45 +0000 (15:38 -0800)]
[SUNHME]: VLAN support for sunhme

This patch enables VLAN support on sunhme by increasing BMAC_TXMAX/BMAC_RXMAX
and allocating extra space via skb_put for the VLAN header.

Signed-off-by: Chris Poon <dev-null@telus.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years ago[MIPS] N32 needs to use the compat version of sys_nfsservctl.
Ralf Baechle [Thu, 15 Nov 2007 22:20:33 +0000 (22:20 +0000)]
[MIPS] N32 needs to use the compat version of sys_nfsservctl.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] irq_cpu: use handle_percpu_irq handler to avoid dropping interrupts.
Ralf Baechle [Thu, 15 Nov 2007 19:37:15 +0000 (19:37 +0000)]
[MIPS] irq_cpu: use handle_percpu_irq handler to avoid dropping interrupts.

This matters to any sort of device that is wired to one of the CPU
interrupt pins on an SMP system.  Typically the scenario is most easily
triggered with the count/compare timer interrupt where the same interrupt
number and thus irq_desc is used on each processor.

   CPU A CPU B

   do_IRQ()
   generic_handle_irq()
   handle_level_irq()
   spin_lock(desc_lock)
   set IRQ_INPROGRESS
   spin_unlock(desc_lock)
do_IRQ()
generic_handle_irq()
handle_level_irq()
spin_lock(desc_lock)
IRQ_INPROGRESS set => bail out
   spin_lock(desc_lock)
   clear IRQ_INPROGRESS
   spin_unlock(desc_lock)

In case of the cp0 compare interrupt this means the interrupt will be
acked and not handled or re-armed on CPU b, so there won't be any timer
interrupt until the count register wraps around.

With kernels 2.6.20 ... 2.6.23 we usually were lucky that things were just
working right on VSMP because the count registers are synchronized on
bootup so it takes something that disables interrupts for a long time on
one processor to trigger this one.

For scenarios where an interrupt is multicasted or broadcasted over several
CPUs the existing code was safe and the fix will break it.  There is no
way to know in the interrupt controller code because it is abstracted from
the platform code.  I think we do not have such a setup currently, so this
should be ok.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Sibyte: Fix name of clocksource.
Ralf Baechle [Tue, 13 Nov 2007 00:35:13 +0000 (00:35 +0000)]
[MIPS] Sibyte: Fix name of clocksource.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] SNI: s/achknowledge/acknowledge/
Maciej W. Rozycki [Mon, 12 Nov 2007 17:32:48 +0000 (17:32 +0000)]
[MIPS] SNI: s/achknowledge/acknowledge/

Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Makefile: Fix canonical system names
Maciej W. Rozycki [Mon, 12 Nov 2007 17:30:52 +0000 (17:30 +0000)]
[MIPS] Makefile: Fix canonical system names

The GNU `config.guess' uses "linux-gnu" as the canonical system name.
Fix the list of compiler prefixes checked to spell it correctly.

Signed-off-by: Maciej W. Rozycki <macro@linux-mips.org>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] vpe: handle halting TCs in an errata safe way.
Nigel Stephens [Thu, 8 Nov 2007 13:25:51 +0000 (13:25 +0000)]
[MIPS] vpe: handle halting TCs in an errata safe way.

Adds a JR.HB after halting a TC, to ensure that the TC has really halted.
only modifies the TCSTATUS register when the TC is safely halted.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Sibyte: Stop timers before programming next even.
Ralf Baechle [Sun, 11 Nov 2007 17:33:55 +0000 (17:33 +0000)]
[MIPS] Sibyte: Stop timers before programming next even.

We have no guarantee by the generic time code that the timer is stopped
when the ->next_event method is called.  Modifying the Timer Initial Count
register while the timer is enabled has UNPREDICTABLE effect according to
the BCM1250/BCM1125/BCM1125H User Manual.  So stop the timer before
reprogramming.

This is a paranoia fix; no ill effects have been observed previously.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Sibyte: Increase minimum oneshot timer interval to two ticks.
Ralf Baechle [Sun, 11 Nov 2007 17:24:46 +0000 (17:24 +0000)]
[MIPS] Sibyte: Increase minimum oneshot timer interval to two ticks.

For the old minimum of a single tick a value of zero would be programmed
into the init value register which in the BCM1250/BCM1125/BCM1125H User
Manual in the Timer Special Cases section is documented to have
UNPREDICTABLE effect.

Observable sympthoms of this bug were hangs of several seconds on the
console during bootup and later if both dyntick and highres timer options
were activated.

In theory contiguous mode of the timers is also affected but in an act of
hopeless lack of realism I'll assume nobody will ever configure a KERNEL
for HZ > 500kHz but if so I leave that to evolution to sort out.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Lasat: Fix overlap of interrupt number ranges.
Yoichi Yuasa [Fri, 9 Nov 2007 09:42:35 +0000 (18:42 +0900)]
[MIPS] Lasat: Fix overlap of interrupt number ranges.

The range of MIPS_CPU IRQ and the range of LASAT IRQ overlap.

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] SNI PCIT CPLUS: workaround for b0rked irq wiring of onboard PCI bus 1
Thomas Bogendoerfer [Thu, 8 Nov 2007 21:09:11 +0000 (22:09 +0100)]
[MIPS] SNI PCIT CPLUS: workaround for b0rked irq wiring of onboard PCI bus 1

Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Fix shadow register support.
Ralf Baechle [Thu, 8 Nov 2007 18:02:29 +0000 (18:02 +0000)]
[MIPS] Fix shadow register support.

Shadow register support would not possibly have worked on multicore
systems.  The support code for it was also depending not on MIPS R2 but
VSMP or SMTC kernels even though it makes perfect sense with UP kernels.

SR sets are a scarce resource and the expected usage pattern is that
users actually hardcode the register set numbers in their code.  So fix
the allocator by ditching it.  Move the remaining CPU probe bits into
the generic CPU probe.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Change get_cycles to always return 0.
Ralf Baechle [Thu, 8 Nov 2007 11:37:47 +0000 (11:37 +0000)]
[MIPS] Change get_cycles to always return 0.

This avoids us executing an mfc0 c0_count instruction on processors which
don't have but also on certain R4000 and R4400 versions where reading from
the count register just in the very moment when its value equals
c0_compare will result in the timer interrupt getting lost.

There is still a number of users of get_cycles remaining outside the
arch code:

crypto/tcrypt.c:                start = get_cycles();
crypto/tcrypt.c:                end = get_cycles();
crypto/tcrypt.c:                start = get_cycles();
crypto/tcrypt.c:                end = get_cycles();
crypto/tcrypt.c:                start = get_cycles();
crypto/tcrypt.c:                end = get_cycles();
drivers/char/hangcheck-timer.c: return get_cycles();
drivers/char/hangcheck-timer.c: printk("Hangcheck: Using get_cycles().\n");
drivers/char/random.c:  sample.cycles = get_cycles();
drivers/input/joystick/analog.c:#define GET_TIME(x)     do { x = get_cycles(); }
include/linux/arcdevice.h:          _x = get_cycles(); \
include/linux/arcdevice.h:          _y = get_cycles(); \
mm/slub.c:      if (!s->defrag_ratio || get_cycles() % 1024 > s->defrag_ratio)
mm/slub.c:      p += 64 + (get_cycles() & 0xff) * sizeof(void *);

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Fix typo in R3000 TRACE_IRQFLAGS code
Atsushi Nemoto [Tue, 6 Nov 2007 16:08:48 +0000 (01:08 +0900)]
[MIPS] Fix typo in R3000 TRACE_IRQFLAGS code

Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Sibyte: Replace use of removed IO_SPACE_BASE with IOADDR.
Ralf Baechle [Tue, 6 Nov 2007 00:43:51 +0000 (00:43 +0000)]
[MIPS] Sibyte: Replace use of removed IO_SPACE_BASE with IOADDR.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] iounmap if in vr41xx_pciu_init() pci clock is over 33MHz
Roel Kluin [Sun, 4 Nov 2007 12:00:06 +0000 (13:00 +0100)]
[MIPS] iounmap if in vr41xx_pciu_init() pci clock is over 33MHz

iounmap if pci clock is over 33MHz.  Cosmetic because the iomap() in this
case is just a bit of address magic.

Signed-off-by: Roel Kluin <12o3l@tiscali.nl>
Acked-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] BCM1480: Remove duplicate acknowledge of timer interrupt.
Ralf Baechle [Mon, 5 Nov 2007 00:29:45 +0000 (00:29 +0000)]
[MIPS] BCM1480: Remove duplicate acknowledge of timer interrupt.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Sibyte: pin timer interrupt to their cores.
Ralf Baechle [Mon, 5 Nov 2007 00:18:05 +0000 (00:18 +0000)]
[MIPS] Sibyte: pin timer interrupt to their cores.

Or strange things will happen.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Qemu: Add early printk, your friend in a cold night.
Ralf Baechle [Sun, 4 Nov 2007 04:49:44 +0000 (04:49 +0000)]
[MIPS] Qemu: Add early printk, your friend in a cold night.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Convert reference to mem_map to pfn_to_page().
Ralf Baechle [Sun, 4 Nov 2007 04:42:03 +0000 (04:42 +0000)]
[MIPS] Convert reference to mem_map to pfn_to_page().

This was crashing the combination of highmem and sparsemem.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[MIPS] Sibyte: resurrect old cache hack.
Ralf Baechle [Sat, 3 Nov 2007 01:01:37 +0000 (01:01 +0000)]
[MIPS] Sibyte: resurrect old cache hack.

The recent switch of the Sibyte SOCs from the processor specific cache
managment code in c-sb1.c to c-r4k.c lost this old hack

    [MIPS] Hack for SB1 cache issues

    Removing flush_icache_page a while ago broke SB1 which was using an empty
    flush_data_cache_page function.  This glues things well enough so a more
    efficient but also more intrusive solution can be found later.

Signed-Off-By: Thiemo Seufer <ths@networkno.de>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
in the hope it was no longer needed.  As it turns it still is so resurrect
it until there is a better solution.

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
16 years ago[CHELSIO]: Fix skb->dev setting.
Divy Le Ray [Thu, 15 Nov 2007 23:06:32 +0000 (15:06 -0800)]
[CHELSIO]: Fix skb->dev setting.

eth_type_trans() now sets skb->dev.  Access skb->def after it gets
set.

Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years ago[NETFILTER]: fix compat_nf_sockopt typo
Patrick McHardy [Thu, 15 Nov 2007 22:29:21 +0000 (14:29 -0800)]
[NETFILTER]: fix compat_nf_sockopt typo

It should pass opt to the ->get/->set functions, not ops.

Tested-by: Luca Tettamanti <kronos.it@gmail.com>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
16 years ago3430: Make IO mapping names consistent
Amit Kucheria [Wed, 3 Oct 2007 13:54:33 +0000 (16:54 +0300)]
3430: Make IO mapping names consistent

Signed-off-by: Amit Kucheria <amit.kucheria@verdurent.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years ago3430 clock: add emulation clocks
Paul Walmsley [Mon, 12 Nov 2007 10:57:28 +0000 (03:57 -0700)]
3430 clock: add emulation clocks

Add clocks for the EMU domain for OMAP3430.  Richard Woodruff mentions that
documentation for these clocks, beyond the register bit settings found
in the main 3430 TRM, can be found in several other documents: the 3430
Emulation TRM; also SPRU893 and SPRU928; and some documents from
ARM Ltd including CoreSight, ETM, and ARM debug v5 architecture.
Some information is also available in the ARM Cortex-A8 TRM, section 10.1.

Also, rename existing emul_* clocks to emu_* to conform with recent TRMs.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years ago3430 clock: revise SmartReflex clocks
Paul Walmsley [Mon, 12 Nov 2007 10:57:27 +0000 (03:57 -0700)]
3430 clock: revise SmartReflex clocks

The two SmartReflex voltage controllers on OMAP3430 have one
functional clock each.  These clocks appear to be independent of each
other.  Encode them appropriately, replacing the previous 'sr_alwon_fck'
clock.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: N800: Use I2C bus registration helper
Jarkko Nikula [Wed, 7 Nov 2007 10:54:33 +0000 (12:54 +0200)]
ARM: OMAP: N800: Use I2C bus registration helper

Use 400 kHz bus clock for both busses since board components are rated
for it.

Signed-off-by: Jarkko Nikula <jarkko.nikula@nokia.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: Use I2C bus registration helper
Jarkko Nikula [Wed, 7 Nov 2007 10:54:32 +0000 (12:54 +0200)]
ARM: OMAP: Use I2C bus registration helper

This patch starts using introduced I2C bus registration helper by cleaning
up registration currently done in various places and by doing necessary
board file modifications.

Patch modifies those board files that are merged upstream. Most of the
boards except osk and 2430sdp are configured to use 100 kHz I2C clock
until they are verified for higher clock.

Signed-off-by: Jarkko Nikula <jarkko.nikula@nokia.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: Add helper module for board specific I2C bus registration
Jarkko Nikula [Wed, 7 Nov 2007 10:54:31 +0000 (12:54 +0200)]
ARM: OMAP: Add helper module for board specific I2C bus registration

This helper module simplifies I2C bus registration for different OMAP
platforms by doing registration in one place only and to allow board
specific bus configuration like clock rate and number of busses configured.

Helper should cover OMAP processors from first to third generation.

This patch just adds the feature and current implementation cleanup and
board file modifications will be done in following patches.

Signed-off-by: Jarkko Nikula <jarkko.nikula@nokia.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoCBUS: Do not BUG_ON in retu-headset in case of spurious release event
Jarkko Nikula [Tue, 13 Nov 2007 13:53:14 +0000 (15:53 +0200)]
CBUS: Do not BUG_ON in retu-headset in case of spurious release event

There is a small chance that retu_headset_detect_timer can run twice
and pressed flag being zero in second run. Do nothing in that case instead
of throwing BUG_ON.

Double run can happen under very busy system assuming following scenario

1. Hook interrupt (run in softirq context, pressed flag = 1)
2. First retu_headset_enable_timer call
3. Busy system, retu raises an interrupt but cannot run hook interrupt for
   300-350 ms
4. Second hook interrupt
5. First retu_headset_detect_timer call (pressed flag = 0)
6. Second retu_headset_enable_timer
7. Second retu_headset_detect_timer
   -> pressed flag == 0 => BUG_ON

Patch also removes two debug messages since they are not needed very much
and removal cleans up code a bit.

Signed-off-by: Jarkko Nikula <jarkko.nikula@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoV4L/DVB: Make Philips TEA5761 driver to compile
Jarkko Nikula [Tue, 13 Nov 2007 13:46:18 +0000 (15:46 +0200)]
V4L/DVB: Make Philips TEA5761 driver to compile

Signed-off-by: Jarkko Nikula <jarkko.nikula@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: Warm reset functionality for 34xx
Choraria, Rohit [Thu, 15 Nov 2007 21:27:03 +0000 (13:27 -0800)]
ARM: OMAP: Warm reset functionality for 34xx

This patch adds the implementation for warm reset functionality for OMAP3.

Signed-off-by: Rohit Choraria <rohitkc@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: Export more mcbsp functions
Luís Cargnini [Thu, 15 Nov 2007 21:24:13 +0000 (13:24 -0800)]
ARM: OMAP: Export more mcbsp functions

this patch only export two more functions to been used externally, for read
and write in polled mode.without the need of irqs.

Signed-off-by: Luis Vitorio Cargnini <lvcargnini@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoOMAP: Fix the BYTEBLOCK capability removal
Francisco Alecrim [Mon, 5 Nov 2007 14:54:21 +0000 (10:54 -0400)]
OMAP: Fix the BYTEBLOCK capability removal

According with commit 255d01af9a990fd5166f04ed0cc0b30b7b67e81e
from Linux-OMAP tree, the BYTEBLOCK capability was removed by Pierre Ossman.
MMC_CAP_BYTEBLOCK is not defined causing the compile error:

drivers/mmc/host/omap.c: In function `mmc_omap_probe':
drivers/mmc/host/omap.c:1077: error: `MMC_CAP_BYTEBLOCK' undeclared (first use in this function)
drivers/mmc/host/omap.c:1077: error: (Each undeclared identifier is reported only once
drivers/mmc/host/omap.c:1077: error: for each function it appears in.)

Signed-off-by: Francisco Alecrim <francisco.alecrim@indt.org.br>
Signed-off-by: Carlos Eduardo Aguiar <carlos.aguiar@indt.org.br>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agomach:omap: some correction in Clock 34XX
Chandra shekhar [Mon, 12 Nov 2007 13:46:23 +0000 (19:16 +0530)]
mach:omap: some correction in Clock 34XX

Resumbmitting the patch earlier sent by girish, after fixing review comments given by paul.

This patch modifies the I2C clock nodes as per LDM, corrects usage of DPLL mask and updates the flags of 96M clock nodes

Signed-off-by: Chandra Shekhar <x0044955@ti.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: clk_disable_unused: init section mismatch
Kevin Hilman [Fri, 2 Nov 2007 00:12:02 +0000 (17:12 -0700)]
ARM: OMAP: clk_disable_unused: init section mismatch

Fix the following warning when OMAP_RESET_CLOCKS is enabled:

WARNING: vmlinux.o(.data+0x33a0): Section mismatch: reference to .init.text:omap2_clk_disable_unused (between 'omap2_clk_functions' and 'osc_ck')

omap2_clk_disable_unused cannot be declared __init as it part of a
struct where the rest of the functions are not __init.

Signed-off-by: Kevin Hilman <khilman@mvista.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoRevert "ARM: OMAP: clk_disable_unused: init section mismatch"
Tony Lindgren [Thu, 15 Nov 2007 20:54:09 +0000 (12:54 -0800)]
Revert "ARM: OMAP: clk_disable_unused: init section mismatch"

This reverts commit 669bbebe52d3c3733deb3f1b1d4e3d77e859ce5b.

Using Kevin's resent patch instead.

Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agofix NULL pointer with MUSB and DMA on ISO ep
Hunyue Yau [Thu, 1 Nov 2007 22:40:49 +0000 (15:40 -0700)]
fix NULL pointer with MUSB and DMA on ISO ep

For the case of an isochonous endpoint, musb_write_fifo may be
called with a NULL buffer from musb_host_tx if DMA is enabled.
Remove DMA check and always supply a valid buffer as long as
the URB contains a valid buffer.

Signed-off-by: Hunyue Yau <hyau@mvista.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
16 years agoARM: OMAP: 2430: add serial console ATAG
Kevin Hilman [Thu, 1 Nov 2007 18:11:34 +0000 (11:11 -0700)]
ARM: OMAP: 2430: add serial console ATAG

Signed-off-by: Kevin Hilman <khilman@mvista.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: clk_disable_unused: init section mismatch
Kevin Hilman [Thu, 1 Nov 2007 17:18:14 +0000 (10:18 -0700)]
ARM: OMAP: clk_disable_unused: init section mismatch

Fix the following warning when OMAP_RESET_CLOCKS is enabled:

WARNING: vmlinux.o(.data+0x33a0): Section mismatch: reference to .init.text:omap2_clk_disable_unused (between 'omap2_clk_functions' and 'osc_ck')

omap2_clk_disable_unused cannot be declared __init as it part of a
struct where the rest of the functions are not __init.

Signed-off-by: Kevin Hilman <khilman@mvista.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoARM: OMAP: Fix usb gadget related compile error
Tony Lindgren [Thu, 15 Nov 2007 20:39:27 +0000 (12:39 -0800)]
ARM: OMAP: Fix usb gadget related compile error

As noted by Dirk Behme.

Signed-off-by: Tony Lindgren <tony@atomide.com>
16 years agoMerge git://git.kernel.org/pub/scm/linux/kernel/git/mingo/linux-2.6-sched
Linus Torvalds [Thu, 15 Nov 2007 20:14:52 +0000 (12:14 -0800)]
Merge git://git.kernel.org/pub/scm/linux/kernel/git/mingo/linux-2.6-sched

* git://git.kernel.org/pub/scm/linux/kernel/git/mingo/linux-2.6-sched:
  sched: reorder SCHED_FEAT_ bits
  sched: make sched_nr_latency static
  sched: remove activate_idle_task()
  sched: fix __set_task_cpu() SMP race
  sched: fix SCHED_FIFO tasks & FAIR_GROUP_SCHED
  sched: fix accounting of interrupts during guest execution on s390

16 years agosched: reorder SCHED_FEAT_ bits
Ingo Molnar [Thu, 15 Nov 2007 19:57:40 +0000 (20:57 +0100)]
sched: reorder SCHED_FEAT_ bits

reorder SCHED_FEAT_ bits so that the used ones come first. Makes
tuning instructions easier.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agosched: make sched_nr_latency static
Adrian Bunk [Thu, 15 Nov 2007 19:57:40 +0000 (20:57 +0100)]
sched: make sched_nr_latency static

sched_nr_latency can now become static.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agosched: remove activate_idle_task()
Dmitry Adamushko [Thu, 15 Nov 2007 19:57:40 +0000 (20:57 +0100)]
sched: remove activate_idle_task()

cpu_down() code is ok wrt sched_idle_next() placing the 'idle' task not
at the beginning of the queue.

So get rid of activate_idle_task() and make use of activate_task() instead.
It is the same as activate_task(), except for the update_rq_clock(rq) call
that is redundant.

Code size goes down:

   text    data     bss     dec     hex filename
  47853    3934     336   52123    cb9b sched.o.before
  47828    3934     336   52098    cb82 sched.o.after

Signed-off-by: Dmitry Adamushko <dmitry.adamushko@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agosched: fix __set_task_cpu() SMP race
Dmitry Adamushko [Thu, 15 Nov 2007 19:57:40 +0000 (20:57 +0100)]
sched: fix __set_task_cpu() SMP race

Grant Wilson has reported rare SCHED_FAIR_USER crashes on his quad-core
system, which crashes can only be explained via runqueue corruption.

there is a narrow SMP race in __set_task_cpu(): after ->cpu is set up to
a new value, task_rq_lock(p, ...) can be successfuly executed on another
CPU. We must ensure that updates of per-task data have been completed by
this moment.

this bug has been hiding in the Linux scheduler for an eternity (we never
had any explicit barrier for task->cpu in set_task_cpu() - so the bug was
introduced in 2.5.1), but only became visible via set_task_cfs_rq() being
accidentally put after the task->cpu update. It also probably needs a
sufficiently out-of-order CPU to trigger.

Reported-by: Grant Wilson <grant.wilson@zen.co.uk>
Signed-off-by: Dmitry Adamushko <dmitry.adamushko@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agosched: fix SCHED_FIFO tasks & FAIR_GROUP_SCHED
Oleg Nesterov [Thu, 15 Nov 2007 19:57:40 +0000 (20:57 +0100)]
sched: fix SCHED_FIFO tasks & FAIR_GROUP_SCHED

Suppose that the SCHED_FIFO task does

switch_uid(new_user);

Now, p->se.cfs_rq and p->se.parent both point into the old
user_struct->tg because sched_move_task() doesn't call set_task_cfs_rq()
for !fair_sched_class case.

Suppose that old user_struct/task_group is freed/reused, and the task
does

sched_setscheduler(SCHED_NORMAL);

__setscheduler() sets fair_sched_class, but doesn't update
->se.cfs_rq/parent which point to the freed memory.

This means that check_preempt_wakeup() doing

while (!is_same_group(se, pse)) {
se = parent_entity(se);
pse = parent_entity(pse);
}

may OOPS in a similar way if rq->curr or p did something like above.

Perhaps we need something like the patch below, note that
__setscheduler() can't do set_task_cfs_rq().

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agosched: fix accounting of interrupts during guest execution on s390
Christian Borntraeger [Thu, 15 Nov 2007 19:57:39 +0000 (20:57 +0100)]
sched: fix accounting of interrupts during guest execution on s390

Currently the scheduler checks for PF_VCPU to decide if this timeslice
has to be accounted as guest time. On s390 host interrupts are not
disabled during guest execution. This causes theses interrupts to be
accounted as guest time if CONFIG_VIRT_CPU_ACCOUNTING is set. Solution
is to check if an interrupt triggered account_system_time. As the tick
is timer interrupt based, we have to subtract hardirq_offset.

I tested the patch on s390 with CONFIG_VIRT_CPU_ACCOUNTING and on
x86_64. Seems to work.

CC: Avi Kivity <avi@qumranet.com>
CC: Laurent Vivier <Laurent.Vivier@bull.net>
Signed-off-by: Christian Borntraeger <borntraeger@de.ibm.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
16 years agoMerge branch 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6
Linus Torvalds [Thu, 15 Nov 2007 19:01:07 +0000 (11:01 -0800)]
Merge branch 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6

* 'i2c-for-linus' of git://jdelvare.pck.nerim.net/jdelvare-2.6:
  i2c/eeprom: Recognize VGN as a valid Sony Vaio name prefix
  i2c/eeprom: Hide Sony Vaio serial numbers
  i2c-pasemi: Fix NACK detection
  i2c-pasemi: Replace obsolete "driverfs" reference with "sysfs"
  i2c: Make i2c_check_addr static
  i2c-dev: Unbound new-style i2c clients aren't busy
  i2c-dev: "how does it work" comments

16 years agoi2c/eeprom: Recognize VGN as a valid Sony Vaio name prefix
Jean Delvare [Thu, 15 Nov 2007 18:24:03 +0000 (19:24 +0100)]
i2c/eeprom: Recognize VGN as a valid Sony Vaio name prefix

Recent (i.e. 2005 and later) Sony Vaio laptops have names beginning
with VGN rather than PCG. Update the eeprom driver so that it
recognizes these.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
16 years agoi2c/eeprom: Hide Sony Vaio serial numbers
Jean Delvare [Thu, 15 Nov 2007 18:24:03 +0000 (19:24 +0100)]
i2c/eeprom: Hide Sony Vaio serial numbers

The sysfs interface to DMI data takes care to not make the system
serial number and UUID world-readable, presumably due to privacy
concerns. For consistency, we should not let the eeprom driver
export these same strings to the world on Sony Vaio laptops.
Instead, only make them readable by root, as we already do for BIOS
passwords.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
16 years agoi2c-pasemi: Fix NACK detection
Olof Johansson [Thu, 15 Nov 2007 18:24:02 +0000 (19:24 +0100)]
i2c-pasemi: Fix NACK detection

Turns out we don't actually check the status to see if there was a
device out there to talk to, just if we had a timeout when doing so.

Add the proper check, so we don't falsly think there are devices
on the bus that are not there, etc.

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Jean Delvare <khali@linux-fr.org>