Commit Graph

190617 Commits

Author SHA1 Message Date
Ben Dooks 63b1f51b24 ARM: SAMSUNG: Update S3C2416 entry with S3C2450
These devices are so similar that they share the same SoC
ID code, so note this.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:47 +09:00
Ben Dooks eb90de4a2d ARM: S3C2413: Update GPIO pull-up support
Ensure the right get/set pull code is selected and assigned to the GPIO
core.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:46 +09:00
Ben Dooks e12ef7f02e ARM: S3C2416: Use s3c2440 style i2c controller
The s3c2416 i2c controllers are compatible with the s3c2440 style i2c
block, so change the device name appropriately.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>y
2010-05-10 11:44:45 +09:00
Ben Dooks a6e1ec7f69 ARM: S3C2416: Add support for OHCI on SMDK2416
Add device definition and ensure that the host port is powered up
at start time. Full power control can be added at a later date.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:44 +09:00
Ben Dooks c140c98ac1 ARM: S3C2416: Add support for second HSMMC channel
Add support for the second HSMMC channel on the S3C2416.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:44 +09:00
Ben Dooks 8d6f865830 ARM: S3C2416: Add basic clock support
Add basic clock support for the PLLs, HSMMC channels and
PWM clocks. This is enough to get a basic system up and
running.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:43 +09:00
Ben Dooks af337f3e63 ARM: S3C2443: Move parts of the clock code to common clock file
To share code with some of the newer parts such as the S3C2416, move
parts of arch/arm/mach-s3c2443/clock.c to a common file called
arch/arm/plat-s3c24xx/s3c2443-clock.c.

Update the build configuration to deal with this new file.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:42 +09:00
Ben Dooks d11a7d7100 ARM: S3C24XX: Identify S3C2416 if S3C2412/S3C2413 built in
Extend the ARMv5 ID code to deal with S3C2416 being built with
S3C2412/S3C2413 enabled, as these have their ID registers in a
different place.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:41 +09:00
Yauhen Kharuzhy d24131470f ARM: S3C2416: Add initial support of SMDK2416
Add support of SMDK2416 development board.

Signed-off-by: Yauhen Kharuzhy <jekhor@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:40 +09:00
Yauhen Kharuzhy f1290a49c5 ARM: S3C2416: Add arch support
Add arch/arm/mach-s3c2416 for support of the Samsung S3C2416 SoC.

This patch adds support of the S3C2416 SoC, clocks, timers,
and initial IRQ support (without support of secondary set of registers).

Signed-off-by: Yauhen Kharuzhy <jekhor@gmail.com>
[ben-linux@fluff.org: removed files to be reworked, fixed conflicts]
[ben-linux@fluff.org: use s3c2443 reset instead of specific reset code]
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:39 +09:00
Ben Dooks 4e04691bc6 ARM: SAMSUNG: Add s3c_disable_clocks() and tidy init+disable usage
Add s3c_disable_clocks() and change the clock registration code to use
the s3c_register_clocks() followed by s3c_disable_clocks() instead of
the loops it was using.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:38 +09:00
Ben Dooks e561aacc70 ARM: SAMSUNG: Move S3C6400 PLL code to <plat/pll.h> for re-use
The S3C6400 EPLL code matches the S3C2416 and compatible SoCs, so move
it from mach-s3c64xx into <plat/pll.h> for easy reuse.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:37 +09:00
Yauhen Kharuzhy 7cfdee9f67 ARM: S3C2416: Add S3C2416-specific registers definitions
Add macros for S3C2416 SoC support.

Signed-off-by: Yauhen Kharuzhy <jekhor@gmail.com>
[ben-linux@fluff.org: removed files that need changing]
[ben-linux@fluff.org: Fix S3C2416_GPH0_TXD0 definition]
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-10 11:44:03 +09:00
Yauhen Kharuzhy 4fcfce9f33 serial: Use s3c2440 driver for S3C2416 SoC
UARTs in the S3C2416 are almost same as in S3C2443 and can be handled by
s3c2440 serial driver.

Signed-off-by: Yauhen Kharuzhy <jekhor@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 11:37:18 +09:00
Yauhen Kharuzhy 5faf501184 ARM: S3C: Add S3C2416 detection to uncompress code
Add S3C2416 serial port setup to uncompress code.

Signed-off-by: Yauhen Kharuzhy <jekhor@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 11:37:17 +09:00
Ben Dooks 1d3ef014b5 ARM: S3C24XX: Remove _INP macros in <mach/regs-gpioj.h>
Remove the _INP definitions, they are all zero and also unused

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 11:32:14 +09:00
Ben Dooks 9772b7586e ARM: S3C24XX: Remove S3C2410_GPJ numbering
Remove the old S3C2410_GPJ as we will be moving to the new gpiolib
based driver code and these numbers will become invalid.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 11:23:35 +09:00
Ben Dooks 31da46d9f1 ARM: S3C24XX: Wrapper s3c2410_gpio_setpin and s3c2410_gpio_pullup()
Change s3c2410_gpio_setpin() and s3c2410_gpio_pullup() to use
the new s3c_ gpio configuration calls until all their users
are converted.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 11:21:05 +09:00
Ben Dooks fb3787470e ARM: S3C2410: Remove the users of s3c2410_gpio_pullup()
Remove the last s3c2410_gpio_pullup() users in arch/arm/mach-s3c2410

Note, since mach-h1940.c is setting output and a pull-up, the call
has vbeen chanerd to S3C_GPIO_PULL_NONE instead of S3C_GPIO_PULL_UP.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 11:03:50 +09:00
Ben Dooks 64f508da58 ARM: mini2440: Move to using gpiolib API and s3c_gpio functions
Move the mach-mini2440 to using the gpiolib API for GPIOS it
directly uses, and s3c_gpio calls for configuration.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 10:59:55 +09:00
Ben Dooks 9933847b29 ARM: S3C24XX: Remove s3c2410_gpio_getcfg(), implement s3c_gpio_getcfg()
Add s3c_gpio_getcfg() and change anything using s3c2410_gpio_getcfg() to
use this instead.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 10:50:42 +09:00
Ben Dooks 97a339995f ARM: SAMSUNG: Add GPIO configuration read calls
Add the necessary 1,2 and 4 bit configuration read calls for the new
gpio code to allow removal of the old s3c24xx gpio code.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 10:27:16 +09:00
Ben Dooks 5690a6267f ARM: S3C24XX: Remove s3c2410_gpio_getirq()
Remove s3c2410_gpio_getirq() as the only users is the pm code, and it
can be replicated by using gpio_to_irq().

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:32 +09:00
Ben Dooks e6528d5e87 ARM: S3C24XX: Remove s3c2410_gpio_getpull()
Remove the unused s3c2410_gpio_getpull()

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:31 +09:00
Ben Dooks eee2b94f01 ARM: S3C24XX: Remove s3c2410_gpio_setcfg()
Remove the implementation of s3c2410_gpio_setcfg() as it should now be
functionally equivalent to s3c_gpio_cfgpin(), and add a wrapper for those
drivers that are still using this call.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:30 +09:00
Ben Dooks 40b956f026 ARM: S3C24XX: Drop s3c2410 specific s3c2410_gpio_cfgpin()
The s3c_gpio_cfgpin() call should be functionally equivalent, so replace
the s3c2410_gpio_cfgpin() calls in the s3c24xx code with s3c_gpio_cfgpin
to allow moving away from a fixed GPIO number to register address mapping

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:29 +09:00
Ben Dooks 82a4b6dcc7 ARM: S3C24XX: Change s3c2410_gpio_pullupl(x, 1) to use s3c_gpio_cfgpull()
Start moving code that is using the old s3c2410_gpio API to using the
newer s3c_gpio variants by finding all the usages of s3c2410_gpio_pullup()
which disable the pin's pull up and replacing them.

 sed 's/s3c2410_gpio_pullup\(.*\), 1/s3c_gpio_cfgpull\1, S3C_GPIO_PULL_NONE/g'

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:28 +09:00
Ben Dooks 27da04049c ARM: S3C2410: Change s3c2410_gpio_pullupl(x, 1) to use s3c_gpio_cfgpull()
Start moving code that is using the old s3c2410_gpio API to using the
newer s3c_gpio variants by finding all the usages of s3c2410_gpio_pullup()
which disable the pin's pull up and replacing them.

sed 's/s3c2410_gpio_pullup\(.*\), 1/s3c_gpio_cfgpull\1, S3C_GPIO_PULL_NONE/g'

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:27 +09:00
Ben Dooks 7614e1d9b9 ARM: VR1000: Update mach-vr1000.c to use gpiolib API
Change mach-vr1000.c to use gpiolib for gpio control.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:26 +09:00
Ben Dooks 408c8b8ca4 ARM: BAST: Update mach-bast to use gpiolib API
Change mach-bast .c to use gpiolib for the GPIO lines that are directly
manipulated by it.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:25 +09:00
Ben Dooks 96efa8dac8 ARM: n30: Update mach-n30 to use gpiolib API
Change mach-n30.c to use gpiolib for the GPIO lines that are directly
manipulated by it.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:24 +09:00
Ben Dooks 2d2e0c8998 ARM: QT2410: Update mach-qt2410 to use gpiolib API
Change mach-qt2410.c to use gpiolib for the GPIO lines that are directly
manipulated by it.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:23 +09:00
Ben Dooks db61ac54c9 ARM: H1940: Change mach-h1940 to use gpiolib API
Change  mach-h1940 to use the gpiolib calls instead of s3c2410_gpio
directly.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:22 +09:00
Ben Dooks afc84ad11b ARM: JIVE: Update mach-jive to use gpiolib API
Change mach-jive to use gpiolib for the GPIO lines that are directly
manipulated by it.

Note, we ignore any errors from gpio_request(), unlikely to see any.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:21 +09:00
Ben Dooks f4146a65fb ARM: H1940: Change h1940-bluetooth to use gpiolib API
Change the h1940-bluetooth driver to use gpiolib to set the output state
of GPH1.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:20 +09:00
Ben Dooks 7ced5eab39 ARM: S3C24XX: Add extended GPIO used on S3C2443 and beyond
Add the GPIO banks that are used on the S3C2443 and above to the
list of available GPIOS.

Currently we do not have any limit on the SoC GPIO, so these are
being registered whether the SoC has them or not. It is currently
up to the user not to try and use them.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:32:13 +09:00
Ben Dooks 1ec7269fd8 ARM: S3C24XX: Add the gpio pull configuration for pull-up
Add the necessary gpio configuration helper for the devices which
have a single-bit pull-up resistor disabled.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:25:57 +09:00
Ben Dooks 9bbb851c70 ARM: S3C24XX: Add initial s3c_gpio configuration code
Add support for s3c_gpio_setcfg() and s3c_gpio_setpull() implementations
to get ready for removal of the specific code being used by s3c24xx.

Also rename the s3c_gpio_setcfg_s3c24xx_banka to s3c_gpio_setcfg_s3c24xx_a
as seen in the header file to correct a build warning.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-05-06 09:25:50 +09:00
Linus Torvalds 7ebd467551 Merge branch 'drm-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6
* 'drm-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
  drm/radeon/kms/legacy: only enable load detection property on DVI-I
  drm/radeon/kms: fix panel scaling adjusted mode setup
  drivers/gpu/drm/drm_sysfs.c: sysfs files error handling
  drivers/gpu/drm/radeon/radeon_atombios.c: range check issues
  gpu: vga_switcheroo, fix lock imbalance
  drivers/gpu/drm/drm_memory.c: fix check for end of loop
  drivers/gpu/drm/via/via_video.c: fix off by one issue
  drm/radeon/kms/agp The wrong AGP chipset can cause a NULL pointer dereference
  drm/radeon/kms: r300 fix CS checker to allow zbuffer-only fastfill
2010-05-04 19:08:12 -07:00
Linus Torvalds d7526f271f Merge branch 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip
* 'x86-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/x86/linux-2.6-tip:
  powernow-k8: Fix frequency reporting
  x86: Fix parse_reservetop() build failure on certain configs
  x86: Fix NULL pointer access in irq_force_complete_move() for Xen guests
  x86: Fix 'reservetop=' functionality
2010-05-04 19:07:35 -07:00
Linus Torvalds 67bff7c087 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6:
  KEYS: Fix RCU handling in key_gc_keyring()
  KEYS: Fix an RCU warning in the reading of user keys
2010-05-04 18:49:34 -07:00
David Howells cf8304e8f3 KEYS: Fix RCU handling in key_gc_keyring()
key_gc_keyring() needs to either hold the RCU read lock or hold the keyring
semaphore if it's going to scan the keyring's list.  Given that it only needs
to read the key list, and it's doing so under a spinlock, the RCU read lock is
the thing to use.

Furthermore, the RCU check added in e7b0a61b79 is
incorrect as holding the spinlock on key_serial_lock is not grounds for
assuming a keyring's pointer list can be read safely.  Instead, a simple
rcu_dereference() inside of the previously mentioned RCU read lock is what we
want.

Reported-by: Serge E. Hallyn <serue@us.ibm.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Acked-by: Serge Hallyn <serue@us.ibm.com>
Acked-by: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
Signed-off-by: James Morris <jmorris@namei.org>
2010-05-05 11:39:23 +10:00
David Howells d9a9b4aeea KEYS: Fix an RCU warning in the reading of user keys
Fix an RCU warning in the reading of user keys:

===================================================
[ INFO: suspicious rcu_dereference_check() usage. ]
---------------------------------------------------
security/keys/user_defined.c:202 invoked rcu_dereference_check() without protection!

other info that might help us debug this:

rcu_scheduler_active = 1, debug_locks = 0
1 lock held by keyctl/3637:
 #0:  (&key->sem){+++++.}, at: [<ffffffff811a80ae>] keyctl_read_key+0x9c/0xcf

stack backtrace:
Pid: 3637, comm: keyctl Not tainted 2.6.34-rc5-cachefs #18
Call Trace:
 [<ffffffff81051f6c>] lockdep_rcu_dereference+0xaa/0xb2
 [<ffffffff811aa55f>] user_read+0x47/0x91
 [<ffffffff811a80be>] keyctl_read_key+0xac/0xcf
 [<ffffffff811a8a06>] sys_keyctl+0x75/0xb7
 [<ffffffff81001eeb>] system_call_fastpath+0x16/0x1b

Signed-off-by: David Howells <dhowells@redhat.com>
Acked-by: Serge Hallyn <serue@us.ibm.com>
Signed-off-by: James Morris <jmorris@namei.org>
2010-05-05 11:38:52 +10:00
Alex Deucher 68b3adb429 drm/radeon/kms/legacy: only enable load detection property on DVI-I
DVI-D doesn't have analog.  This matches the avivo behavior.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-05 11:28:11 +10:00
Alex Deucher 3515387ba9 drm/radeon/kms: fix panel scaling adjusted mode setup
This should duplicate exactly what the ddx does for both
legacy and avivo.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-05 11:27:59 +10:00
Linus Torvalds 7572e56314 Merge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jlbec/ocfs2
* 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jlbec/ocfs2:
  ocfs2: Avoid a gcc warning in ocfs2_wipe_inode().
  ocfs2: Avoid direct write if we fall back to buffered I/O
  ocfs2_dlmfs: Fix math error when reading LVB.
  ocfs2: Update VFS inode's id info after reflink.
  ocfs2: potential ERR_PTR dereference on error paths
  ocfs2: Add directory entry later in ocfs2_symlink() and ocfs2_mknod()
  ocfs2: use OCFS2_INODE_SKIP_ORPHAN_DIR in ocfs2_mknod error path
  ocfs2: use OCFS2_INODE_SKIP_ORPHAN_DIR in ocfs2_symlink error path
  ocfs2: add OCFS2_INODE_SKIP_ORPHAN_DIR flag and honor it in the inode wipe code
  ocfs2: Reset status if we want to restart file extension.
  ocfs2: Compute metaecc for superblocks during online resize.
  ocfs2: Check the owner of a lockres inside the spinlock
  ocfs2: one more warning fix in ocfs2_file_aio_write(), v2
  ocfs2_dlmfs: User DLM_* when decoding file open flags.
2010-05-04 16:33:18 -07:00
David Howells a66f6375bd Fix the x86_64 implementation of call_rwsem_wait()
The x86_64 call_rwsem_wait() treats the active state counter part of the
R/W semaphore state as being 16-bit when it's actually 32-bit (it's half
of the 64-bit state).  It should do "decl %edx" not "decw %dx".

Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-05-04 15:24:14 -07:00
Linus Torvalds c81406d642 Merge branch 'i2c-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging
* 'i2c-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jdelvare/staging:
  i2c-core: Use per-adapter userspace device lists
  i2c: Fix probing of FSC hardware monitoring chips
  i2c-core: Erase pointer to clientdata on removal
2010-05-04 15:20:37 -07:00
Linus Torvalds f5fa05d972 Merge branch 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'perf-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  perf: Fix resource leak in failure path of perf_event_open()
2010-05-04 15:16:15 -07:00
Linus Torvalds f2809d61d6 Merge branch 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'core-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  rcu: Fix RCU lockdep splat on freezer_fork path
  rcu: Fix RCU lockdep splat in set_task_cpu on fork path
  mutex: Don't spin when the owner CPU is offline or other weird cases
2010-05-04 15:15:43 -07:00