Tony Lindgren [Wed, 4 Aug 2010 13:10:38 +0000 (16:10 +0300)]
Merge branch 'v2.6.35-omap-mailbox-for-next' of git://gitorious.org/~doyu/lk/mainline into omap-for-linus
Conflicts:
arch/arm/mach-omap1/devices.c
Felipe Contreras [Fri, 11 Jun 2010 15:51:49 +0000 (15:51 +0000)]
omap: mailbox: reorganize headers
Remove kernel.h and module.h since they are not used correctly anyway.
Also, remove device.h since it comes along with platform_device.h
(always will I guess).
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:48 +0000 (15:51 +0000)]
omap: mailbox: standarize on 'omap-mailbox'
omap{1,2}-mailbox are modules that provide the 'omap-mailbox' driver.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:47 +0000 (15:51 +0000)]
omap: mailbox: only compile for configured archs
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:46 +0000 (15:51 +0000)]
omap: mailbox: simplify omap_mbox_register()
No need to dynamically register mailboxes one by one.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:45 +0000 (15:51 +0000)]
omap: mailbox: reorganize registering
It's more extensible this way.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:44 +0000 (15:51 +0000)]
omap: mailbox: add IRQ names
Will be useful to identify them later.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:43 +0000 (15:51 +0000)]
omap: mailbox: remove unecessary fields
Nobody is using them.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:42 +0000 (15:51 +0000)]
omap: mailbox: don't export unecessary symbols
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:41 +0000 (15:51 +0000)]
omap: mailbox: update omap1 probing
Based on omap2 code.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:40 +0000 (15:51 +0000)]
omap: mailbox: use correct config for omap1
CONFIG_OMAP_DSP is not in mainline, CONFIG_OMAP_MBOX_FWK is.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:39 +0000 (15:51 +0000)]
omap: mailbox: 2420 should be detected at run-time
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:38 +0000 (15:51 +0000)]
omap: mailbox: reorganize structures
OMAP4 ones messed up the organization.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Felipe Contreras [Fri, 11 Jun 2010 15:51:37 +0000 (15:51 +0000)]
omap: mailbox: trivial cleanups
And fix a few compilation warnings.
Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Hiroshi DOYU [Tue, 18 May 2010 13:15:32 +0000 (16:15 +0300)]
omap mailbox: Set a device in logical mbox instance for traceability
With this patch, you'll get the following sysfs directories. This
structure implies that a single platform device, "omap2-mailbox" holds
multiple logical mbox instances. This could be the base to add sysfs
files for each logical mboxes. Then userland application can access a
mbox through sysfs entries if necessary(ex: setting kfifo size
dynamically)
~# tree -d -L 2 /sys/devices/platform/omap2-mailbox/
/sys/devices/platform/omap2-mailbox/
|-- driver -> ../../../bus/platform/drivers/omap2-mailbox
|-- mbox
| |-- dsp <- they are each instances of logical mailbox.
| |-- ducati
| |-- iva2
| |-- mbox01
| |-- mbox02
| |-- mbox03
| |-- .....
| `-- tesla
|-- power
`-- subsystem -> ../../../bus/platform
This was wrongly dropped by:
commit
c7c158e57bce6220644f2bcd65d82e1468aa40ec
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Ohad Ben-Cohen [Wed, 5 May 2010 15:33:09 +0000 (15:33 +0000)]
omap: mailbox: convert block api to kfifo
The underlying buffering implementation of mailbox
is converted from block API to kfifo due to the simplicity
and speed of kfifo.
The default size of the kfifo buffer is set to 256 bytes.
This value is configurable at compile time (via
CONFIG_OMAP_MBOX_KFIFO_SIZE), and can be changed at
runtime (via the mbox_kfifo_size module parameter).
Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
Signed-off-by: Hari Kanigeri <h-kanigeri2@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Ohad Ben-Cohen [Wed, 5 May 2010 15:33:08 +0000 (15:33 +0000)]
omap: mailbox: remove (un)likely macros from cold paths
Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Ohad Ben-Cohen [Wed, 5 May 2010 15:33:07 +0000 (15:33 +0000)]
omap: mailbox cleanup: split MODULE_AUTHOR line
use multiple MODULE_AUTHOR lines for multiple authors
Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Ohad Ben-Cohen [Wed, 5 May 2010 15:33:06 +0000 (15:33 +0000)]
omap: mailbox: convert rwlocks to spinlock
rwlocks are slower and have potential starvation issues
therefore spinlocks are generally preferred.
see also: http://lwn.net/Articles/364583/
Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
Signed-off-by: Kanigeri Hari <h-kanigeri2@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Fernando Guzman Lugo [Mon, 8 Feb 2010 19:35:40 +0000 (13:35 -0600)]
Mailbox: disable mailbox interrupt when request queue
when blk_get_request fails to get the request it is returning
without read the message from the mailbox fifo, then when it
leaves the isr and interruption is trigger again and again and
the workqueue which get elements from the request queue is never
executed and the kernel is stuck and shows a softlockup message.
Now the mailbox interrupt is disabled when request queue is full
and enabled when it pop a elememt form the request queue.
Signed-off-by: Fernando Guzman Lugo <x0095840@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Hiroshi DOYU [Thu, 18 Feb 2010 06:48:55 +0000 (00:48 -0600)]
Mailbox: new mutext lock for h/w mailbox configuration
mailbox startup and shutdown are being executed against
a single H/W module, and a mailbox H/W module is totally
__independent__ of the registration of logical mailboxes.
So, an independent mutext should be used for startup and
shutdown.
Signed-off-by: Fernando Guzman Lugo <x0095840@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Fernando Guzman Lugo [Thu, 28 Jan 2010 02:04:02 +0000 (20:04 -0600)]
Mailbox: Check valid registered callback before calling
This patch checks if the mailbox user has assinged a valid
callback fuction before calling it.
Signed-off-by: Fernando Guzman Lugo <x0095840@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Fernando Guzman Lugo [Sat, 13 Feb 2010 01:07:14 +0000 (19:07 -0600)]
Mailbox: flush pending deferred works before freeing blk queue
flush pending deferred works before freeing blk_queue to prevent
any attempt of access to blk_queue after it was freed
Signed-off-by: Fernando Guzman Lugo <x0095840@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Fernando Guzman Lugo [Sat, 13 Feb 2010 01:02:32 +0000 (19:02 -0600)]
Mailbox: free mailbox interrupt before freeing blk queue
Free interrupt before freeing blk_queue to avoid
any attempt of access to blk_queue after it was freed.
Signed-off-by: Fernando Guzman Lugo <x0095840@ti.com>
Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Vincent Sanders [Tue, 3 Aug 2010 20:19:21 +0000 (21:19 +0100)]
Remove ARM default configurations which duplicate omap3_defconfig
These configurations are no longer useful as the systems they support
are covered by the generic omap3_defconfig
Signed-off-by:Vincent Sanders <vince@simtec.co.uk>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Anand Gadiyar [Wed, 14 Jul 2010 13:38:49 +0000 (13:38 +0000)]
omap: 3630: disable TLL SAR on 3630 ES1
USBTLL Save-and-Restore is broken in 3630 ES1.0. Having it
enabled could result in incorrect register restores as
the OMAP exits off-mode. This could potentially result in
unexpected wakeup events.
(Refer 3630 errata ID i579)
This is fixed in ES1.1. So disable it for ES1.0s.
Signed-off-by: Anand Gadiyar <gadiyar@ti.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Anand Gadiyar [Tue, 3 Aug 2010 19:59:24 +0000 (19:59 +0000)]
OMAP3630: Add ES1.1 and ES1.2 detection
Add revision detection for ES1.1 and ES1.2. Set default
revision as ES1.2.
Add CHIP_GE_OMAP3630ES1_1 to detect revisions 1.1 and later.
This is needed for at least one feature that is broken in
3630ES1.0 but exists on older (3430 ES3.1) and newer revisions.
Additionally, update some of the CHIP_GE_* macros to use other
macros for ease of maintenance.
Signed-off-by: Anand Gadiyar <gadiyar@ti.com>
Cc: Nishanth Menon <nm@ti.com>
Cc: Manjunatha GK <manjugk@ti.com>
[tony@atomide.com: update to remove fallthrough handling]
Signed-off-by: Tony Lindgren <tony@atomide.com>
Artem Bityutskiy [Mon, 12 Jul 2010 13:38:07 +0000 (13:38 +0000)]
omap: device: improve errors handling
Do not forget to check the 'platform_device_add_data()' error code
in 'omap_device_build_ss()'.
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
Acked-by: Nishanth Menon <nm@ti.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Tony Lindgren [Wed, 4 Aug 2010 11:43:45 +0000 (14:43 +0300)]
Merge branch 'devel-map-io' into omap-for-linus
Mike Rapoport [Wed, 4 Aug 2010 11:43:18 +0000 (14:43 +0300)]
omap3: introduce omap3_map_io
Most OMAP3-based boards use exactly the same code for .map_io method in
the machine_desc structure.
This patch introduces omap3_map_io and updates board-* files to use it
as .map_io method.
Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Sergio Aguirre [Wed, 4 Aug 2010 11:43:18 +0000 (14:43 +0300)]
omap3: Unify omap2_set_globals_3[43,6x]x functions
The only difference between them is the physical address of the
uart4 port, which is only present in 36xx chips.
We don't really need to care about keeping these 2 functions, since
the decision to use uart4 is more cleanly done later when we do have
access to omap_revision variable.
Signed-off-by: Sergio Aguirre <saaguirre@ti.com>
Acked-by: Kevin Hilman <khilman@deeprootsystems.com>
[tony@atomide.com: added comment for the uart4_phys]
Signed-off-by: Tony Lindgren <tony@atomide.com>
Jason Wang [Tue, 3 Aug 2010 03:44:18 +0000 (11:44 +0800)]
omap: Fix DEBUG_LL uart to access phys addr when MMU isn't enable
Now we use a memory address to store the debug port info, So we need
to read/write this address when we choose DEBUG_LL. When MMU isn't
enable(I.E. the begining part of init stage of the linux kernel boot),
we need to access physical address instead of virtual address,
otherwise the kernel will crash.
Signed-off-by: Jason Wang <jason77.wang@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Tony Lindgren [Wed, 4 Aug 2010 05:46:24 +0000 (08:46 +0300)]
Merge branch 'for_2.6.36' of git://git.pwsan.com/linux-2.6 into omap-for-linus
Linus Torvalds [Tue, 3 Aug 2010 21:31:24 +0000 (14:31 -0700)]
Merge branch 'devel' of /home/rmk/linux-2.6-arm
* 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm: (291 commits)
ARM: AMBA: Add pclk support to AMBA bus infrastructure
ARM: 6278/2: fix regression in RealView after the introduction of pclk
ARM: 6277/1: mach-shmobile: Allow users to select HZ, default to 128
ARM: 6276/1: mach-shmobile: remove duplicate NR_IRQS_LEGACY
ARM: 6246/1: mmci: support larger MMCIDATALENGTH register
ARM: 6245/1: mmci: enable hardware flow control on Ux500 variants
ARM: 6244/1: mmci: add variant data and default MCICLOCK support
ARM: 6243/1: mmci: pass power_mode to the translate_vdd callback
ARM: 6274/1: add global control registers definition header file for nuc900
mx2_camera: fix type of dma buffer virtual address pointer
mx2_camera: Add soc_camera support for i.MX25/i.MX27
arm/imx/gpio: add spinlock protection
ARM: Add support for the LPC32XX arch
ARM: LPC32XX: Arch config menu supoport and makefiles
ARM: LPC32XX: Phytec 3250 platform support
ARM: LPC32XX: Misc support functions
ARM: LPC32XX: Serial support code
ARM: LPC32XX: System suspend support
ARM: LPC32XX: GPIO, timer, and IRQ drivers
ARM: LPC32XX: Clock driver
...
Helge Deller [Mon, 2 Aug 2010 20:46:41 +0000 (22:46 +0200)]
PARISC: led.c - fix potential stack overflow in led_proc_write()
avoid potential stack overflow by correctly checking count parameter
Reported-by: Ilja <ilja@netric.org>
Signed-off-by: Helge Deller <deller@gmx.de>
Acked-by: Kyle McMartin <kyle@mcmartin.ca>
Cc: James E.J. Bottomley <jejb@parisc-linux.org>
Cc: stable@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Thomas Weber [Fri, 9 Jul 2010 07:40:53 +0000 (07:40 +0000)]
OMAP2: powerdomain: Add break in switch statement
Add a missing break at end of switch statement. At the moment it is a
fall through to WARN_ON(1) and return -EEXIST.
Signed-off-by: Thomas Weber <weber@corscience.de>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Sukumar Ghorai [Fri, 9 Jul 2010 14:27:51 +0000 (14:27 +0000)]
omap3: add support for NAND on LDP board
patch adds NAND support to LDP board.
Signed-off-by: Vimal Singh <vimalsingh@ti.com>
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Sukumar Ghorai [Fri, 9 Jul 2010 14:27:50 +0000 (14:27 +0000)]
omap-3630-sdp : Add support for Flash
add support for NAND, OneNAND, NOR on omap 3630-sdp board.
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Sukumar Ghorai [Fri, 9 Jul 2010 14:27:49 +0000 (14:27 +0000)]
omap3: add support for NAND on zoom3 board
patch adds NAND support to zoom3 board.
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Vimal Singh <vimalsingh@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Sukumar Ghorai [Fri, 9 Jul 2010 14:27:48 +0000 (14:27 +0000)]
omap3: add support for NAND on zoom2 board
This patch adds NAND support to ZOOM2 board.
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Vimal Singh <vimalsingh@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Sukumar Ghorai [Fri, 9 Jul 2010 14:27:47 +0000 (14:27 +0000)]
omap3 flash: rename board-sdp-flash.c to be use by other boards
rename board-sdp-flash.c(board-flash.c) and board-sdp.h(board-flash.h) to
used by other board e.g. zoom
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Sukumar Ghorai [Fri, 9 Jul 2010 09:14:46 +0000 (09:14 +0000)]
omap3 nand: fix issue in board file to detect nand
Board file modified for not to provide gpmc phys_base address to nand driver.
The gpmc_nand_init funciton is now used to detect the nand and required to
adopt _prob function as in nand/omap2.c
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Sukumar Ghorai [Fri, 9 Jul 2010 09:14:45 +0000 (09:14 +0000)]
omap3 nand: cleanup virtual address usages
This patch removes direct reference of gpmc address from generic nand platform code.
Nand platform code now uses wrapper functions which are implemented in gpmc module.
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Sukumar Ghorai [Fri, 9 Jul 2010 09:14:44 +0000 (09:14 +0000)]
omap3 gpmc: functionality enhancement
few functions added in gpmc module and to be used by other drivers like NAND.
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Tony Lindgren [Mon, 2 Aug 2010 11:23:38 +0000 (14:23 +0300)]
Merge branch 'devel-misc' into omap-for-linus
Grazvydas Ignotas [Mon, 2 Aug 2010 10:18:28 +0000 (13:18 +0300)]
omap: mux: fix multipath gpio handling
OMAP3530 CBB package can have GPIO126 muxed on 2 pins: mmc1_dat4 and
cam_strobe. This causes a problem with current multipath GPIO mux
handling, which muxes both pins as GPIO126 and makes the GPIO unusable.
Fix this by not muxing any pins if multipath GPIO is detected and
just print a warning instead. It's up to board files to set correct
mux using omap_mux_init_signal and pin name.
Signed-off-by: Grazvydas Ignotas <notasas@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Kan-Ru Chen [Mon, 2 Aug 2010 11:21:41 +0000 (14:21 +0300)]
omap: Devkit8000: Use DIE id to initialize dm9000 MAC address
The devkit8000 boards often come with empty EEPROM thus without
valid ethernet MAC address. The DIE id to MAC formula is copied from
u-boot.
Signed-off-by: Kan-Ru Chen <kanru@0xlab.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Kan-Ru Chen [Mon, 2 Aug 2010 11:21:41 +0000 (14:21 +0300)]
omap: Use omap_get_die_id() to get the DIE ids
Signed-off-by: Kan-Ru Chen <kanru@0xlab.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Kan-Ru Chen [Mon, 2 Aug 2010 11:21:41 +0000 (14:21 +0300)]
omap: Add new interface omap_get_die_id
Allow DIE id to be get and used by others.
Signed-off-by: Kan-Ru Chen <kanru@0xlab.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
stanley.miao [Mon, 2 Aug 2010 11:21:40 +0000 (14:21 +0300)]
OMAP3: AM3505/3517 do not have IO wakeup capability
AM3505/3517 doesn't have IO wakeup capability, so we do not need to set
the bit OMAP3430_EN_IO and the bit OMAP3430_EN_IO_CHAIN in the register
PM_WKEN_WKUP when the system enters suspend state.
Tested on AM3517EVM and OMAP3530EVM.
Signed-off-by: Stanley.Miao <stanley.miao@windriver.com>
Acked-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Samu Onkalo [Mon, 2 Aug 2010 11:21:40 +0000 (14:21 +0300)]
omap: dma: Support for prefetch in destination synchronizedtransfer
Omap DMA controller can prefetch data in advance in case of
destination synchronized data transfer. This may increase
performance when target HW block doesn't have fifo.
Data is waiting for transfer request in DMA fifo instead of read from memory.
Signed-off-by: Samu Onkalo <samu.p.onkalo@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Nishanth Menon [Mon, 2 Aug 2010 11:21:40 +0000 (14:21 +0300)]
omap2/3: id: fix sparse warning
omap24xx_check_revision, omap3_check_features,
omap3_check_revision, omap4_check_revision, omap3_cpuinfo
are not used elsewhere, it should be static
Also fixes the following sparse warnings:
arch/arm/mach-omap2/id.c:105:13: warning: symbol 'omap24xx_check_revision'
was not declared. Should it be static?
arch/arm/mach-omap2/id.c:167:13: warning: symbol 'omap3_check_features'
was not declared. Should it be static?
arch/arm/mach-omap2/id.c:189:13: warning: symbol 'omap3_check_revision'
was not declared. Should it be static?
arch/arm/mach-omap2/id.c:270:13: warning: symbol 'omap4_check_revision'
was not declared. Should it be static?
arch/arm/mach-omap2/id.c:300:13: warning: symbol 'omap3_cpuinfo'
was not declared. Should it be static?
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Steve Sakoman [Mon, 2 Aug 2010 11:21:39 +0000 (14:21 +0300)]
omap: Overo: Fix support for second ethernet port
The original patch got truncated when applied from patchwork.kernel.org
as discussed at:
http://www.mail-archive.com/linux-omap@vger.kernel.org/msg28953.html
This patch supplies the missing chunks.
Signed-off-by: Steve Sakoman <sakoman@gmail.com>
[tony@atomide.com: added more info to the patch description]
Signed-off-by: Tony Lindgren <tony@atomide.com>
Tony Lindgren [Mon, 2 Aug 2010 11:21:39 +0000 (14:21 +0300)]
omap2: Fix GPIO numbers and smc91x for 2430sdp
Fix GPIO numbers and smc91x for 2430sdp. The earlier code
had cut and paste errors from 3430sdp code. Also, 2430
has five GPIO banks for a total of 160 GPIO lines.
Signed-off-by: Tony Lindgren <tony@atomide.com>
Cory Maccarrone [Mon, 2 Aug 2010 11:21:39 +0000 (14:21 +0300)]
omap1: omap7xx clocks, mux, serial fixes
This change adds in the necessary clocks and mux pins for UART
control on omap7xx devices. I also made a change in the serial
code to only try and initialize two UARTs in omap_serial_init, as
these devices don't have three.
Signed-off-by: Cory Maccarrone <darkstar6262@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Tony Lindgren [Mon, 2 Aug 2010 11:21:39 +0000 (14:21 +0300)]
omap: Add back UART MDR1 check into uncompress.h
Recent DEBUG_LL and uncompress.h changes removed the check_port()
as pointed out by Cory Maccarrone <darkstar6262@gmail.com>.
This causes some boards to not boot, so add back the MDR1 register
check. The MDR1 register tells the mode of omap uart. Based on
an earlier patch by Cory Maccarrone <darkstar6262@gmail.com>.
Tested-by: Cory Maccarrone <darkstar6262@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Santosh Shilimkar [Mon, 2 Aug 2010 10:18:19 +0000 (13:18 +0300)]
omap4: hotplug: Add basic CPU hotplug support
This patch adds cpu hotplug support for OMAP4430. Only CPU inactive
state is supported as a low power state in the basic hot-plug support
Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Santosh Shilimkar [Mon, 2 Aug 2010 10:18:18 +0000 (13:18 +0300)]
omap4: Add smc API to read AuxCoreBoot0 register
This patch adds a secure API to read AuxCoreBoot0 register to
check the cpu boot status. It also moves the other smc APIs
to common omap44xx-smc.S. This APIs should not be marked as
__INIT because we need these to be present for CPU hotplug
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Rajendra Nayak [Mon, 2 Aug 2010 10:18:18 +0000 (13:18 +0300)]
omap4: suspend: Add basic system suspend support
This patch adds support for basic suspend doing a CPUx wfi
for OMAP4. All powerdomains are for now are kept programmed
in ON state.
Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Deepak K [Mon, 2 Aug 2010 10:18:12 +0000 (13:18 +0300)]
omap2/3/4: serial: errata i202: fix for MDR1 access
Errata i202 (OMAP3430 - 1.12, OMAP3630 - 1.6):
UART module MDR1 register access can cause a dummy underrun
condition which could result in a freeze in the case of IrDA
communication or if used as UART, corrupted data.
Workaround is as follows for everytime MDR1 register is changed:
* setup all required UART registers
* setup MDR1.MODE_SELECT bit field
* Wait 5 L4 clk cycles + 5 UART functional clock cycles
* Clear the Tx and RX fifo using FCR register
Note: The following step is not done as I am assuming it is not
needed due to reconfiguration being done and there is no halted
operation perse.
* Read if required, the RESUME register to resume halted operation
Based on an earlier patch at:
http://git.omapzoom.org/?p=kernel/omap.git;a=commitdiff;h=
42d4a342c009bd9727c100abc8a4bc3063c22f0c
Signed-off-by: Deepak K <deepak.k@ti.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Nishanth Menon [Mon, 2 Aug 2010 10:18:12 +0000 (13:18 +0300)]
omap2/3/4: serial: introduce errata handling
introduce silicon specific quirks as a errata handling mechanism
as a start UART_ERRATA_FIFO_FULL_ABORT is used to handle the override
for fifo full condition for rx and tx.
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Nishanth Menon [Mon, 2 Aug 2010 10:18:12 +0000 (13:18 +0300)]
omap2/3/4: serial: kill dev_attr_sleep_timeout sparse warn
Remove the following sparse warnings by declaring attr as static:
arch/arm/mach-omap2/serial.c:627:1: warning: symbol 'dev_attr_sleep_timeout'
was not declared. Should it be static?
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Nishanth Menon [Mon, 2 Aug 2010 10:18:11 +0000 (13:18 +0300)]
omap2/3/4: serial: remove initialization sparse warnings
Initialization of pointer should be done with NULL. Removes sparse
warnings:
arch/arm/mach-omap2/serial.c:566:17: warning: Using plain integer as NULL pointer
arch/arm/mach-omap2/serial.c:567:17: warning: Using plain integer as NULL pointer
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Govindraj R [Mon, 2 Aug 2010 10:18:11 +0000 (13:18 +0300)]
omap3: serial: Add context save and restore for mcr
Adds context save/restore for mcr register as state of mcr register
is lost after core off.
Signed-off-by: Govindraj R <govindraj.raja@ti.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
David Anders [Mon, 2 Aug 2010 10:18:05 +0000 (13:18 +0300)]
omap4: Add OMAP4 Panda Support
Add initial support for the OMAP4 based Panda Board.
Signed-off-by: David Anders <x0132446@ti.com>
[tony@atomide.com: selected board by default in Kconfig]
Signed-off-by: Tony Lindgren <tony@atomide.com>
Hemanth V [Mon, 2 Aug 2010 10:18:04 +0000 (13:18 +0300)]
OMAP4: Add GPIO LED support for SDP board
This patch adds support for GPIO LEDs present on OMAP4
SDP and Blaze boards. This basically adds platform data
required by leds-gpio driver
Signed-off-by: Hemanth V <hemanthv@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Shubhrajyoti Datta [Mon, 2 Aug 2010 10:18:04 +0000 (13:18 +0300)]
omap4: Board changes for 4430sdp tmp105 temperature sensor
Adding board configuration for the tmp105
temperature sensor. The interface to the sensor
is I2C.
Signed-off-by: Shubhrajyoti D <shubhrajyoti@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Santosh Shilimkar [Mon, 2 Aug 2010 10:18:03 +0000 (13:18 +0300)]
omap4: mmc: Fix the regulator resource for MMC2 on 4430sdp
The MMC1 and MMC2 cards have seperate LDO supplies. Current code assumes
that they are powered by same LDO.
This patch fixes the same and has VAUX1 as supply to MMC2 card.
Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Sukumar Ghorai <s-ghorai@ti.com>
Signed-off-by: Kishore Kadiyala <kishore.kadiyala@ti.com>
Tested-by: Kishore Kadiyala <kishore.kadiyala@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Mathias Nyman [Mon, 2 Aug 2010 10:18:03 +0000 (13:18 +0300)]
omap: tsl2563 ALS support for Nokia N900
This commit will enable usage of tsl2563 ambient light sensor on Nokia N900.
Signed-off-by: Ameya Palande <ameya.palande@nokia.com>
Signed-off-by: Mathias Nyman <mathias.nyman@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Jarkko Nikula [Mon, 2 Aug 2010 10:18:03 +0000 (13:18 +0300)]
omap: rx51: Add supply and data for the tpa6130a2 headphoneamplifier
With these and upcoming change to tpa6130a2 driver it's possible to add
support for the TPA6130A2 headphone amplifier.
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Jarkko Nikula [Mon, 2 Aug 2010 10:18:02 +0000 (13:18 +0300)]
omap: rx51: Use REGULATOR_SUPPLY macro when initializingregulator consumers
There is REGULATOR_SUPPLY macro available for initializing the struct
regulator_consumer_supply so use it where applicable (all other supplies
than vdds_sdi) as it improves the readability.
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Acked-by: Eduardo Valentin <eduardo.valentin@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Jarkko Nikula [Mon, 2 Aug 2010 10:18:02 +0000 (13:18 +0300)]
omap: rx51: Add platform_data for tlv320aic3x with reset gpionumber
Proper operation of the tlv320aic3x audio codec requires that reset
sequencing is done in pair with supply voltages when using the regulator
framework. Add the codec reset gpio used in Nokia RX51 to tlv320aic3x
data.
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Jarkko Nikula [Mon, 2 Aug 2010 10:18:02 +0000 (13:18 +0300)]
omap: rx51: Set regulator V28 always on
It seems that the battery cover sensor in Nokia N900 is powered from the
V28 domain. Now if this regulator is disabled it causes that the gpio 160
reads only zero which effectively causes uSD removal detection.
Currently the bootloader enabled V28 is kept on but this may change in the
future according to comment in
drivers/regulator/core.c: regulator_has_full_constraints.
Also if there are any consumers on the V28 domain doing regulator_enable
regulator_disable cycle the V28 will be disabled after that.
Prepare for these by defining the V28 as always_on regulator.
Signed-off-by: Jarkko Nikula <jhnikula@gmail.com>
Cc: Adrian Hunter <adrian.hunter@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Grazvydas Ignotas [Mon, 2 Aug 2010 10:18:01 +0000 (13:18 +0300)]
omap3: pandora: add NAND and wifi support
Add platform data for NAND and wifi, also setup all GPIOs
needed to use the wifi chip.
Signed-off-by: Grazvydas Ignotas <notasas@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Grazvydas Ignotas [Mon, 2 Aug 2010 10:18:01 +0000 (13:18 +0300)]
omap3: pandora: update gpio-keys data
Update gpio-keys setup so it matches what is on default firmware.
Also make use of debounce feature in gpio-keys instead of setting it
explicitly, as gpio-keys is now capable of using hardware debounce on
OMAPs thanks to recent gpiolib changes.
Also fix a sparce warning along the way.
Signed-off-by: Grazvydas Ignotas <notasas@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Ohad Ben-Cohen [Mon, 2 Aug 2010 10:18:00 +0000 (13:18 +0300)]
omap: zoom3: wlan board muxing
Add board muxing to support the wlan wl1271 chip that is
hardwired to mmc2 (third mmc controller) on the ZOOM3.
Signed-off-by: Ohad Ben-Cohen <ohadb@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Ohad Ben-Cohen [Mon, 2 Aug 2010 10:18:00 +0000 (13:18 +0300)]
omap: zoom2: wlan board muxing
Add board muxing to support the wlan wl1271 chip that is
hardwired to mmc2 (third mmc controller) on the ZOOM2.
Signed-off-by: Ohad Ben-Cohen <ohadb@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Linus Torvalds [Sun, 1 Aug 2010 22:11:14 +0000 (15:11 -0700)]
Linux 2.6.35
Trond Myklebust [Sun, 1 Aug 2010 17:40:40 +0000 (13:40 -0400)]
NFS: Fix a typo in include/linux/nfs_fs.h
nfs_commit_inode() needs to be defined irrespectively of whether or not
we are supporting NFSv3 and NFSv4.
Allow the compiler to optimise away code in the NFSv2-only case by
converting it into an inlined stub function.
Reported-and-tested-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Russell King [Sat, 31 Jul 2010 13:20:16 +0000 (14:20 +0100)]
Merge branch 'devel-stable' into devel
Conflicts:
arch/arm/kernel/entry-armv.S
arch/arm/kernel/setup.c
arch/arm/mm/init.c
Russell King [Sat, 31 Jul 2010 13:20:02 +0000 (14:20 +0100)]
Merge branch 'misc' into devel
Conflicts:
arch/arm/mm/init.c
Russell King [Sat, 31 Jul 2010 13:19:35 +0000 (14:19 +0100)]
Merge branches 'at91', 'ep93xx', 'kexec', 'iop', 'lmb', 'nomadik', 'nuc', 'pl', 'spear' and 'versatile' into devel
Russell King [Sat, 31 Jul 2010 13:19:22 +0000 (14:19 +0100)]
Merge branch 'shmobile' into devel
Russell King [Thu, 15 Jul 2010 09:47:14 +0000 (10:47 +0100)]
ARM: AMBA: Add pclk support to AMBA bus infrastructure
Some platforms gate the pclk (APB - the bus - clock) to the peripherals
for power saving, along with the functional clock. When devices are
accessed without pclk enabled, the kernel will oops.
This gives them two options:
1. Leave all clocks on all the time.
2. Attempt to gate pclk along with the functional clock.
(With some hardware, pclk and the functional clock are gated by a single
bit in a register.)
(1) has the disadvantage that it causes increased power usage, which is
bad news for battery operated devices. (2) can lead to kernel oops if
registers are accessed without the functional clock being enabled.
So, introduce the apb_pclk signal in such a way existing drivers don't
need to be updated. Essentially, this means we guarantee that:
1. pclk will be enabled whenever the driver is bound to a device -
from probe() to remove() time.
2. pclk will also be enabled when reading the primecell IDs from the device.
In order to allow drivers to be incrementally updated to achieve greater
power savings, we provide two additional calls to allow drivers to
manage the pclk - amba_pclk_enable()/amba_pclk_disable().
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Linus Walleij [Fri, 30 Jul 2010 15:36:25 +0000 (16:36 +0100)]
ARM: 6278/2: fix regression in RealView after the introduction of pclk
The patch to add the apb_pclk to the AMBA/PrimeCell bus broke
RealView, since the clockdevice is not registered at probe() time.
This moves clock initialization to a core_initcall()
[rmk:moved before the problematical commit to avoid bisect problems]
Signed-off-by: Linus Walleij <linus.walleij@stericsson.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Linus Torvalds [Sat, 31 Jul 2010 02:02:51 +0000 (19:02 -0700)]
Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm:
cyber2000fb: fix console in truecolor modes
cyber2000fb: fix machine hang on module load
SA1111: Eliminate use after free
ARM: Fix Versatile/Realview/VExpress MMC card detection sense
ARM: 6279/1: highmem: fix SMP preemption bug in kmap_high_l1_vipt
ARM: Add barriers to io{read,write}{8,16,32} accessors as well
ARM: 6273/1: Add barriers to the I/O accessors if ARM_DMA_MEM_BUFFERABLE
ARM: 6272/1: Convert L2x0 to use the IO relaxed operations
ARM: 6271/1: Introduce *_relaxed() I/O accessors
ARM: 6275/1: ux500: don't use writeb() in uncompress.h
ARM: 6270/1: clean files in arch/arm/boot/compressed/
ARM: Fix csum_partial_copy_from_user()
Linus Torvalds [Sat, 31 Jul 2010 02:02:21 +0000 (19:02 -0700)]
Merge branch 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6
* 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6:
NFS: Ensure that writepage respects the nonblock flag
NFS: kswapd must not block in nfs_release_page
nfs: include space for the NUL in root path
Linus Torvalds [Sat, 31 Jul 2010 02:01:11 +0000 (19:01 -0700)]
Merge branch 'drm-fixes' of git://git./linux/kernel/git/airlied/drm-2.6
* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
drm/edid: Fix the HDTV hack sync adjustment
drm/radeon/kms: fix radeon mid power profile reporting
Hugh Dickins [Fri, 30 Jul 2010 17:58:26 +0000 (10:58 -0700)]
mm: fix ia64 crash when gcore reads gate area
Debian's ia64 autobuilders have been seeing kernel freeze or reboot
when running the gdb testsuite (Debian bug 588574): dannf bisected to
2.6.32
62eede62dafb4a6633eae7ffbeb34c60dba5e7b1 "mm: ZERO_PAGE without
PTE_SPECIAL"; and reproduced it with gdb's gcore on a simple target.
I'd missed updating the gate_vma handling in __get_user_pages(): that
happens to use vm_normal_page() (nowadays failing on the zero page),
yet reported success even when it failed to get a page - boom when
access_process_vm() tried to copy that to its intermediate buffer.
Fix this, resisting cleanups: in particular, leave it for now reporting
success when not asked to get any pages - very probably safe to change,
but let's not risk it without testing exposure.
Why did ia64 crash with 16kB pages, but succeed with 64kB pages?
Because setup_gate() pads each 64kB of its gate area with zero pages.
Reported-by: Andreas Barth <aba@not.so.argh.org>
Bisected-by: dann frazier <dannf@debian.org>
Signed-off-by: Hugh Dickins <hughd@google.com>
Tested-by: dann frazier <dannf@dannf.org>
Cc: stable@kernel.org
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
David Howells [Fri, 30 Jul 2010 14:25:19 +0000 (15:25 +0100)]
CIFS: Remove __exit mark from cifs_exit_dns_resolver()
Remove the __exit mark from cifs_exit_dns_resolver() as it's called by the
module init routine in case of error, and so may have been discarded during
linkage.
Signed-off-by: David Howells <dhowells@redhat.com>
Acked-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Ondrej Zary [Thu, 29 Jul 2010 20:40:54 +0000 (22:40 +0200)]
cyber2000fb: fix console in truecolor modes
Return value was not set to 0 in setcolreg() with truecolor modes. This causes
fb_set_cmap() to abort after first color, resulting in blank palette - and
blank console in 24bpp and 32bpp modes.
Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Ondrej Zary [Thu, 29 Jul 2010 20:32:20 +0000 (22:32 +0200)]
cyber2000fb: fix machine hang on module load
I was testing two CyberPro 2000 based PCI cards on x86 and the machine always
hanged completely when the cyber2000fb module was loaded. It seems that the
card hangs when some registers are accessed too quickly after writing RAMDAC
control register. With this patch, both card work.
Add delay after RAMDAC control register write to prevent hangs on module load.
Signed-off-by: Ondrej Zary <linux@rainbow-software.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Julia Lawall [Fri, 30 Jul 2010 15:17:28 +0000 (17:17 +0200)]
SA1111: Eliminate use after free
__sa1111_remove always frees its argument, so the subsequent reference to
sachip->saved_state represents a use after free. __sa1111_remove does not
appear to use the saved_state field, so the patch simply frees it first.
A simplified version of the semantic patch that finds this problem is as
follows: (http://coccinelle.lip6.fr/)
// <smpl>
@@
expression E,E2;
@@
__sa1111_remove(E)
...
(
E = E2
|
* E
)
// </smpl>
Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Russell King [Thu, 29 Jul 2010 14:58:59 +0000 (15:58 +0100)]
ARM: Fix Versatile/Realview/VExpress MMC card detection sense
The MMC card detection sense has become really confused with negations
at various levels, leading to some platforms not detecting inserted
cards. Fix this by converting everything to positive logic throughout,
thereby getting rid of these negations.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Gary King [Thu, 29 Jul 2010 16:37:20 +0000 (17:37 +0100)]
ARM: 6279/1: highmem: fix SMP preemption bug in kmap_high_l1_vipt
smp_processor_id() must not be called from a preemptible context (this
is checked by CONFIG_DEBUG_PREEMPT). kmap_high_l1_vipt() was doing so.
This lead to a problem where the wrong per_cpu kmap_high_l1_vipt_depth
could be incremented, causing a BUG_ON(*depth <= 0); in
kunmap_high_l1_vipt().
The solution is to move the call to smp_processor_id() after the call
to preempt_disable().
Originally by: Andrew Howe <ahowe@nvidia.com>
Signed-off-by: Gary King <gking@nvidia.com>
Acked-by: Nicolas Pitre <nico.as.pitre@linaro.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Trond Myklebust [Fri, 30 Jul 2010 19:31:57 +0000 (15:31 -0400)]
NFS: Ensure that writepage respects the nonblock flag
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Trond Myklebust [Fri, 30 Jul 2010 19:31:54 +0000 (15:31 -0400)]
NFS: kswapd must not block in nfs_release_page
See https://bugzilla.kernel.org/show_bug.cgi?id=16056
If other processes are blocked waiting for kswapd to free up some memory so
that they can make progress, then we cannot allow kswapd to block on those
processes.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Cc: stable@kernel.org
Dan Carpenter [Tue, 13 Jul 2010 11:34:59 +0000 (13:34 +0200)]
nfs: include space for the NUL in root path
In root_nfs_name() it does the following:
if (strlen(buf) + strlen(cp) > NFS_MAXPATHLEN) {
printk(KERN_ERR "Root-NFS: Pathname for remote directory too long.\n");
return -1;
}
sprintf(nfs_export_path, buf, cp);
In the original code if (strlen(buf) + strlen(cp) == NFS_MAXPATHLEN)
then the sprintf() would lead to an overflow. Generally the rest of the
code assumes that the path can have NFS_MAXPATHLEN (1024) characters and
a NUL terminator so the fix is to add space to the nfs_export_path[]
buffer.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Linus Torvalds [Thu, 29 Jul 2010 22:23:28 +0000 (15:23 -0700)]
Merge branch 'for-linus' of git://git390.marist.edu/linux-2.6
* 'for-linus' of git://git390.marist.edu/pub/scm/linux-2.6:
[S390] etr: fix clock synchronization race
[S390] Fix IRQ tracing in case of PER
Linus Torvalds [Thu, 29 Jul 2010 22:21:44 +0000 (15:21 -0700)]
Merge git://git./linux/kernel/git/wim/linux-2.6-watchdog
* git://git.kernel.org/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog:
watchdog: update MAINTAINERS entry