Commit Graph

3676 Commits

Author SHA1 Message Date
Mike Rapoport 9ba63c4fa1 [ARM] 5201/1: PXA3xx: Add support for power i2c bus
Add power I2C support for PXA3xx processors

Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-09 16:32:51 +01:00
Russell King 80cec14a83 [ARM] Add -march=all to assembly file build in arch/arm/boot/compressed
This allows assembly files to be crafted to cover all ARM CPU types
rather than erroring out on instructions only in later CPUs.  We
are careful in these files to only execute CPU specific code when
the CPU ID says we can.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-09 13:56:45 +01:00
Sascha Hauer 58a85f465f MX2: Add DMA support for mx2 and (eventually) mx1
This patch adds DMA support for Freescale i.MX27 SoCs. It is derived
from the i.MX1 port and should (though currently untested) still be
working for the i.MX1.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 12:13:56 +02:00
Paulius Zaleckas b72f92ff55 i.MX: Add FIQ support
Drivers which are going to use it will have to select it and use
imx_set_irq_fiq() to set FIQ mode for this interrupt.

Changes since V1:
- removed '#ifdef CONFIG_FIQ' from irqs.h
- renamed imx_set_irq_type() to imx_set_irq_fiq()
- made irqt unsigned
- fixed irq number check

Signed-off-by: Paulius Zaleckas <paulius.zaleckas@teltonika.lt>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 12:13:55 +02:00
Darius Augulis 8b69ac577e MXC: Remove WD IRQ priority setting
Remove WD IRQ priority setting from ARCH_MXC common init code, because
it's application specific.

Signed-off-by: Darius Augulis <augulis.darius@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 12:13:54 +02:00
Luotao Fu defa8c309d i.MX3: Fix compiler warnings
Fix some base address declaration by adding a cast.

Signed-off-by: Luotao Fu <l.fu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 12:13:53 +02:00
Luotao Fu 8b0171fad1 MXC: add RTCK alternate function definitions
This one adds definitions to configure RTCK pad (PE16) in primary and alternate
function. The RTCK Pin is used by one wire master controller and as JTAG Clock
return.

Signed-off-by: Luotao Fu <l.fu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 12:13:53 +02:00
Luotao Fu 2cf842b896 mxc: add cscr register defintions
This adds macros to get CSCR upper, lower and additional registers.
These registers are needed to configure a chip select line. The offset
layouts of these Registers are identical on mx27 and mx31, hence we can
use the macros in generic way

Signed-off-by: Luotao Fu <l.fu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 12:13:52 +02:00
Luotao Fu 7113cdcdc1 MX31: add macros to configure spi pins
this adds convenience values usable by mxc_iomux_mode() to configure Pins of the
spi interfaces on mx31.

Signed-off-by: Luotao Fu <l.fu@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 12:13:51 +02:00
Darius Augulis 479c901f59 MXC: Lets handle IRQ by priority, defined with exported API function
Signed-off-by: Darius Augulis <augulis.darius@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 12:13:50 +02:00
Gilles Chanteperdrix d7568f79d5 i.MX31ADS: Add CPLD interrupts demultiplexing (take 3).
Needed for 8250 serial port and CS89x0 ethernet interface.

Signed-off-by: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 10:19:42 +02:00
Gilles Chanteperdrix 0741794c0d i.MX31ADS: Enable the first IMX serial port. (take 3)
Signed-off-by: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 10:19:41 +02:00
Sascha Hauer cfc135632a i.MX27: add definitions for USB pins
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 10:19:41 +02:00
Sascha Hauer 7e90534a8f i.MX2: make SoC devices globally available
Make SoC devices globally available to boards rather than using
a device specific init function.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 10:19:41 +02:00
Sascha Hauer 5cf0942123 i.MX3: make SoC devices globally available
Make SoC devices globally available to boards rather than using
a device specific init function.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 10:19:41 +02:00
Sascha Hauer 282b13d066 MXC: add convenience function to register platform devices
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-09 10:19:40 +02:00
Linus Torvalds 4ced08b89f Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm:
  [ARM] 5241/1: provide ioremap_wc()
  [ARM] omap: fix virtual vs physical address space confusions
  [ARM] remove unused #include <version.h>
  [ARM] omap: fix build error in ohci-omap.c
  [ARM] omap: fix gpio.c build error
2008-09-08 15:50:19 -07:00
Manfred Spraul e545a6140b kernel/cpu.c: create a CPU_STARTING cpu_chain notifier
Right now, there is no notifier that is called on a new cpu, before the new
cpu begins processing interrupts/softirqs.
Various kernel function would need that notification, e.g. kvm works around
by calling smp_call_function_single(), rcu polls cpu_online_map.

The patch adds a CPU_STARTING notification. It also adds a helper function
that sends the message to all cpu_chain handlers.

Tested on x86-64.
All other archs are untested. Especially on sparc, I'm not sure if I got
it right.

Signed-off-by: Manfred Spraul <manfred@colorfullife.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2008-09-08 19:25:24 +02:00
Hartley Sweeten 7a1f370118 [ARM] 5243/1: ep93xx: bugfix, GPIO ports C and F are swapped
In the GPIOLIB support for EP93xx ports C anf F are swapped. This
patch correct it.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-07 17:39:36 +01:00
Hartley Sweeten f69162ae63 [ARM] 5242/1: ep93xx: bugfix, GPIO port F enable register offset
The GPIO port F enable register offset points to the wrong register,
0x5c is the IntStsF register. The correct offset is 0x58. This patch
corrects it.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-07 17:39:35 +01:00
David Woodhouse e17c6d5616 Introduce HAVE_AOUT symbol to remove hard-coded arch list for BINFMT_AOUT
HAVE_AOUT doesn't quite do the same thing as the recently removed
ARCH_SUPPORTS_AOUT config option. That was set even on platforms where
binfmt_aout isn't supported, although it's not entirely clear why.

So it's best just to introduce a new symbol, handled consistently with
other similar HAVE_xxx symbols; with a simple 'select' in the arch Kconfig.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-09-06 19:30:22 +01:00
David Woodhouse 6b213e1bc2 Remove redundant CONFIG_ARCH_SUPPORTS_AOUT
We don't need this any more; arguably we never really did.

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-09-06 19:30:20 +01:00
Lennert Buytenhek 1ad77a876d [ARM] 5241/1: provide ioremap_wc()
This patch provides an ARM implementation of ioremap_wc().

We use different page table attributes depending on which CPU we
are running on:

- Non-XScale ARMv5 and earlier systems: The ARMv5 ARM documents four
  possible mapping types (CB=00/01/10/11).  We can't use any of the
  cached memory types (CB=10/11), since that breaks coherency with
  peripheral devices.  Both CB=00 and CB=01 are suitable for _wc, and
  CB=01 (Uncached/Buffered) allows the hardware more freedom than
  CB=00, so we'll use that.

  (The ARMv5 ARM seems to suggest that CB=01 is allowed to delay stores
  but isn't allowed to merge them, but there is no other mapping type
  we can use that allows the hardware to delay and merge stores, so
  we'll go with CB=01.)

- XScale v1/v2 (ARMv5): same as the ARMv5 case above, with the slight
  difference that on these platforms, CB=01 actually _does_ allow
  merging stores.  (If you want noncoalescing bufferable behavior
  on Xscale v1/v2, you need to use XCB=101.)

- Xscale v3 (ARMv5) and ARMv6+: on these systems, we use TEXCB=00100
  mappings (Inner/Outer Uncacheable in xsc3 parlance, Uncached Normal
  in ARMv6 parlance).

  The ARMv6 ARM explicitly says that any accesses to Normal memory can
  be merged, which makes Normal memory more suitable for _wc mappings
  than Device or Strongly Ordered memory, as the latter two mapping
  types are guaranteed to maintain transaction number, size and order.
  We use the Uncached variety of Normal mappings for the same reason
  that we can't use C=1 mappings on ARMv5.

  The xsc3 Architecture Specification documents TEXCB=00100 as being
  Uncacheable and allowing coalescing of writes, which is also just
  what we need.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-06 13:13:44 +01:00
Russell King fbd3bdb213 [ARM] Convert asm/bitops.h to linux/bitops.h
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-06 12:13:59 +01:00
Russell King 8029db12ae [ARM] Convert asm/delay.h to linux/delay.h
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-06 12:11:37 +01:00
Russell King fced80c735 [ARM] Convert asm/io.h to linux/io.h
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-06 12:10:45 +01:00
Russell King 33fa9b1328 [ARM] Convert asm/uaccess.h to linux/uaccess.h
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-06 11:35:55 +01:00
Russell King 5ed5fdf50c [ARM] clean up a load of old declarations
... some of which are now in linux/*.h headers.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-06 11:23:30 +01:00
Russell King 012d1f4af1 [ARM] move initrd code from kernel/setup.c to mm/init.c
This quietens some sparse warnings about phys_initrd_start and
phys_initrd_size.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-06 10:57:03 +01:00
Russell King 446616dbb4 [ARM] sparse: quieten arch/arm/kernel/irq.c
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-06 10:56:27 +01:00
Russell King 1de765c1e9 [ARM] remove pc_pointer()
pc_pointer() was a function to mask the PC for 26-bit ARMs, which
we no longer support.  Remove it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-06 10:35:51 +01:00
Russell King c0fc18c5bf [ARM] omap: fix lots of 'Using plain integer as NULL pointer'
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 17:02:33 +01:00
Russell King 7c7095aa42 [ARM] omap: fix inappropriate casting in gpio.c
gpio.c wilfully casts physical addresses to void __iomem * and then
fixes them up at runtime using:

	bank->base = IO_ADDRESS(bank->base);

where accesses prior to this fixup are via omap_read/omap_write, and
after are by __raw_read/__raw_write.  This doesn't lend itself to
static checking, nor to easy understanding of the code.

And so, OMAP_MPUIO_BASE gets to be the right type - integer like since
it's a physical address, not a MMIO pointer.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 17:02:33 +01:00
Russell King 397fcaf717 [ARM] omap: DSP registers don't need to be casted
We're now assigning/comparing void __iomem pointers with
void __iomem pointer variables.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 17:02:32 +01:00
Russell King 0062f1048b [ARM] omap: make sure virtual mmio addresses are __iomem pointer-like
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 17:02:32 +01:00
Russell King e8a91c953f [ARM] omap: Fix IO_ADDRESS() macros
OMAP1_IO_ADDRESS(), OMAP2_IO_ADDRESS() and IO_ADDRESS() returns cookies
for use with __raw_{read|write}* for accessing registers.  Therefore,
these macros should return (void __iomem *) cookies, not integer values.

Doing this improves typechecking, and means we can find those places
where, eg, DMA controllers are incorrectly given virtual addresses to
DMA to, or physical addresses are thrown through a virtual to physical
address translation.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 17:02:31 +01:00
Russell King d592dd1adc [ARM] omap: convert mcbsp to use ioremap()
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 17:02:30 +01:00
Russell King 690b5a13b2 [ARM] omap: allow ioremap() to use our fixed IO mappings
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 17:02:29 +01:00
Russell King 5668545a08 [ARM] omap: improve is_omap_port()
Make is_omap_port() take the uart_8250_port structure so it can do
whatever test it desires.  Convert the test to compare the physical
addresses rather than virtual addresses.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 17:02:28 +01:00
David Woodhouse b35de672e7 Revert "[ARM] use the new byteorder headers"
This reverts commit ae82cbfc8b. It
needs the new byteorder headers to be exported to userspace, and
they aren't yet -- and probably shouldn't be, at this point in the
2.6.27 release cycle (or ever, for that matter).

Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Acked-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 17:01:50 +01:00
Russell King 09d9bae064 [ARM] sparse: fix several warnings
arch/arm/kernel/process.c:270:6: warning: symbol 'show_fpregs' was not declared. Should it be static?

This function isn't used, so can be removed.

arch/arm/kernel/setup.c:532:9: warning: symbol 'len' shadows an earlier one
arch/arm/kernel/setup.c:524:6: originally declared here

A function containing two 'len's.

arch/arm/mm/fault-armv.c:188:13: warning: symbol 'check_writebuffer_bugs' was not declared. Should it be static?
arch/arm/mm/mmap.c:122:5: warning: symbol 'valid_phys_addr_range' was not declared. Should it be static?
arch/arm/mm/mmap.c:137:5: warning: symbol 'valid_mmap_phys_addr_range' was not declared. Should it be static?

Missing includes.

arch/arm/kernel/traps.c:71:77: warning: Using plain integer as NULL pointer
arch/arm/mm/ioremap.c:355:46: error: incompatible types in comparison expression (different address spaces)

Sillies.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-05 14:11:24 +01:00
Lennert Buytenhek ac840605f3 mv643xx_eth: remove force_phy_addr field
Currently, there are two different fields in the
mv643xx_eth_platform_data struct that together describe the PHY
address -- one field (phy_addr) has the address of the PHY, but if
that address is zero, a second field (force_phy_addr) needs to be
set to distinguish the actual address zero from a zero due to not
having filled in the PHY address explicitly (which should mean
'use the default PHY address').

If we are a bit smarter about the encoding of the phy_addr field,
we can avoid the need for a second field -- this patch does that.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-09-05 06:33:59 +02:00
Lennert Buytenhek fc0eb9f226 mv643xx_eth: smi sharing is a per-unit property, not a per-port one
Which top-level unit's SMI interface to use should be a property of
the top-level unit, not of the individual ports.  This patch moves the
->shared_smi pointer from the per-port platform data to the global
platform data.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-09-05 06:33:58 +02:00
Russell King 65846909d6 [ARM] omap: fix virtual vs physical address space confusions
mcbsp is confused as to what takes a physical or virtual address.
Fix the two instances where it gets it wrong.

Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-04 22:21:19 +01:00
Huang Weiyi 8b540fdcb7 [ARM] remove unused #include <version.h>
The driver(s) below do not use LINUX_VERSION_CODE nor KERNEL_VERSION.
  arch/arm/plat-mxc/clock.c

This patch removes the said #include <version.h>.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-04 10:47:14 +01:00
David Woodhouse a5e48a28d0 ARM: Use <asm-generic/statfs.h>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-09-04 09:46:11 +01:00
Russell King 69114a47af [ARM] omap: fix gpio.c build error
arch/arm/plat-omap/gpio.c: In function '_omap_gpio_init':
arch/arm/plat-omap/gpio.c:1492: error: 'omap_mpuio_device' undeclared (first use in this function)

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-03 10:15:26 +01:00
Sascha Hauer 34f6e15786 [MTD] [NAND] Freescale i.MX2 NAND driver
This patch adds support for the integrated NAND flash controller of the
i.MX2 and i.MX3 family. It is tested on MX27 but should work on MX3
aswell.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Acked-by: Juergen Beisert <j.beisert@pengutronix.de>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-09-02 22:35:36 +01:00
Sascha Hauer a9b0623357 pcm037: add rts/cts support for serial port
We have rts/cts pins on the first serial port on the pcm037. Enable it.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-09-02 10:19:29 +02:00
Enrico Scholz c8c17c888d [MTD] [NAND] pxa3xx_nand: moved some helper variables out from platform data
This patch moves some attributes out from the platform data into the
dynamically created nand device.   This results into a cleaner interface
and allows to use constant pxa3xx_nand_flash definitions.

Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-09-01 21:38:34 +01:00
Enrico Scholz 7dad482ed0 [MTD] [NAND] pxa3xx_nand: added some 'const' annotations to the exported API
This patch marks some attributes as 'const' which are set only once and
never be modified by the driver.  There are some changes in parameter
list and variable declarations too which mark them as 'const'.

Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-09-01 21:37:51 +01:00
Enrico Scholz c8ac3f818e [MTD] [NAND] pxa3xx_nand: allow to define flash types in the platform data
This patch adds 'flash' and 'num_flash' attributes to the platform data.
There was added code in the driver to iterate across these attributes in the
detect-flash routine.  This is done similarly to the existing method
which uses a 'builtin_flash_types' field.

Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-09-01 21:31:34 +01:00
Enrico Scholz 43035338ad [MTD] [NAND] pxa3xx_nand: moved nand definitions into shared platform header
This patch moves the exported datastructures from the pxa3xx_nand.c driver
into the <mach/pxa3xx_nand.h> header. This is a plain movement without
any modification of the attributes.

This is the first one of a set of patches which:

 * allows to specify used NAND flash in the platform code and allows to turn
   off the old way to specify NAND characteristics in the driver.  This way did
   not worked well as these characteristics depend on the platform and can not be
   derived from NAND id alone.

   E.g.  some NAND chips share the same ID (e.g.  K9K8G08U0A and K9NBG08U5A) but
   have different timings (which are written in the common driver currently and
   must be modified there).

 * adds 'const' annotations at various places

Further patches will be sent to the mtd-list.

Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-09-01 21:27:32 +01:00
Marc Zyngier 57a7a62eb6 [ARM] 5233/1: Allow PXA to have ISA IRQs numbered 0-15
Allow PXA IRQs to be numbered starting at 16, leaving 0 to 15 for the
ISA IRQs, if needed.

This patch depends on RMK's PXA_HAVE_BOARD_IRQS patch.

Signed-off-by: Marc Zyngier <marc.zyngier@altran.com>
Acked-by: Russel King <linux@arm.linux.org.uk>
Acked-by: Eric Miao <eric.y.miao@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 17:13:26 +01:00
Russell King 7a5063d86e [ARM] pxa: introduce PXA_HAVE_BOARD_IRQS
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 17:13:08 +01:00
Catalin Marinas 22acc4e650 [ARM] 5231/1: Do not save the frame pointer in the csum_partial_copy_* functions
Since the other assembly functions do not seem to save the frame
pointer onto the stack, this patch changes the csum_partial_copy_*
functions to behave in the same way.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:35 +01:00
Catalin Marinas 4e6a0c397f [ARM] 5230/1: Replace post-indexed LDRT/STRT in uaccess.h
The post-index immediate value is optional if it is 0 and this patch
removes it. The reason is to allow such instructions to compile to
Thumb-2 where only pre-indexed LDRT/STRT instructions are allowed.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:35 +01:00
Catalin Marinas 9c23e5fefa [ARM] 5232/1: Do not post-index STRT instruction in clear_user.S
The last strnebt instruction has a post-index of 1 but the address
register is set to 0 in the next instruction, so no need for
post-indexing.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:34 +01:00
Catalin Marinas 93ed397011 [ARM] 5227/1: Add the ENDPROC declarations to the .S files
This declaration specifies the "function" type and size for various
assembly functions, mainly needed for generating the correct branch
instructions in Thumb-2.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:34 +01:00
Lennert Buytenhek 8d5796d2ec [ARM] 5222/1: Allow configuring user:kernel split via Kconfig
This patch adds a config option (CONFIG_VMSPLIT_*) to allow choosing
between 3:1, 2:2 and 1:3 user:kernel memory splits.

Tested-by: Riku Voipio <riku.voipio@iki.fi>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:33 +01:00
Nicolas Pitre 2d4b6c9aeb [ARM] 5221/1: fix ldm/stm emulation for kprobes
Logic for the p bit was reversed.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:33 +01:00
Nicolas Pitre d81030a1ba [ARM] 5211/2: fix a couple warnings from BUG() usage
When CONFIG_DEBUG_BUGVERBOSE is not set, we get warnings such as:

arch/arm/mm/ioremap.c: In function ‘remap_area_pte’:
arch/arm/mm/ioremap.c:67: warning: control reaches end of non-void function
mm/bootmem.c: In function ‘mark_bootmem’:
mm/bootmem.c:321: warning: control reaches end of non-void function
fs/dcache.c: In function ‘d_materialise_unique’:
fs/dcache.c:1875: warning: control reaches end of non-void function
fs/nfs/client.c: In function ‘nfs_sockaddr_match_ipaddr’:
fs/nfs/client.c:251: warning: control reaches end of non-void function
block/cfq-iosched.c: In function ‘cfq_async_queue_prio’:
block/cfq-iosched.c:1501: warning: control reaches end of non-void function

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:27 +01:00
Mikael Pettersson e589ed23dd [ARM] 5218/1: arm: improved futex support
Linux/ARM currently doesn't support robust or PI futexes.
The problem is that the kernel wants to perform certain ops
(cmpxchg, set, add, or, andn, xor) atomically on user-space
addresses, and ARM's futex.h doesn't support that.

This patch adds that support, but only for uniprocessor machines.
For UP it's enough to disable preemption to ensure mutual exclusion
with other software agents (futexes don't need to care about other
hardware agents, fortunately).

This patch is based on one posted by Khem Raj on 2007-08-01
<http://marc.info/?l=linux-arm-kernel&m=118599407413016&w=2>.
(That patch is included in the -RT kernel patches.)
My changes since that version include:
* corrected implementation of FUTEX_OP_ANDN (must complement oparg)
* added missing memory clobber to futex_atomic_cmpxchg_inatomic()
* removed spinlock because it's unnecessary for UP and insufficient
  for SMP, instead the code is restricted to UP and relies on the
  fact that pagefault_disable() also disables preemption
* coding style cleanups

Tested on ARMv5 XScales with the glibc-2.6 nptl test suite.

Tested-by: Bruce Ashfield <bruce.ashfield@windriver.com>

Signed-off-by: Mikael Pettersson <mikpe@it.uu.se>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:26 +01:00
Nicolas Pitre 3305a60795 [ARM] 5206/1: remove kprobe_trap_handler() hack
As mentioned in commit 796969104c,
and because of commit b03a5b7559,
the direct calling of kprobe_trap_handler() can be removed.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:26 +01:00
Russell King ac9d7efc7d [ARM] Update arch/arm/Kconfig for drivers/Kconfig changes, add cpuidle
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:25 +01:00
Jean PIHET d7ac4e28cc [ARM] 5195/1: ARMv7 Oprofile support
Add Oprofile kernel support for ARMv7.
Tested on OMAP3430 and OMAP3530 chipsets (Cortex-A8).

Signed-off-by: Jean Pihet <jpihet@mvista.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:25 +01:00
Russell King 46097c7dd8 [ARM] cachetype: move definitions to separate header
Rather than pollute asm/cacheflush.h with the cache type definitions,
move them to asm/cachetype.h, and include this new header where
necessary.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:24 +01:00
Russell King 0ba8b9b273 [ARM] cputype: separate definitions, use them
Add asm/cputype.h, moving functions and definitions from asm/system.h
there.  Convert all users of 'processor_id' to the more efficient
read_cpuid_id() function.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-09-01 12:06:23 +01:00
David Woodhouse 9d7548d4ca Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6 2008-09-01 11:32:13 +01:00
Jean-Christophe DUBOIS 212496fd9a [ARM] 5226/1: remove unmatched comment end.
remove unmatched comment end.

Signed-off-by: Jean-Christophe DUBOIS <jcd@tribudubois.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-28 17:12:29 +01:00
Russell King c8791088cf Merge branch 'omap-rmk' 2008-08-27 23:07:46 +01:00
Mel Gorman e80d6a2482 [ARM] Skip memory holes in FLATMEM when reading /proc/pagetypeinfo
Ordinarily, memory holes in flatmem still have a valid memmap and is safe
to use. However, an architecture (ARM) frees up the memmap backing memory
holes on the assumption it is never used. /proc/pagetypeinfo reads the
whole range of pages in a zone believing that the memmap is valid and that
pfn_valid will return false if it is not. On ARM, freeing the memmap breaks
the page->zone linkages even though pfn_valid() returns true and the kernel
can oops shortly afterwards due to accessing a bogus struct zone *.

This patch lets architectures say when FLATMEM can have holes in the
memmap. Rather than an expensive check for valid memory, /proc/pagetypeinfo
will confirm that the page linkages are still valid by checking page->zone
is still the expected zone. The lookup of page_zone is safe as there is a
limited range of memory that is accessed when calling page_zone.  Even if
page_zone happens to return the correct zone, the impact is that the counters
in /proc/pagetypeinfo are slightly off but fragmentation monitoring is
unlikely to be relevant on an embedded system.

Reported-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Mel Gorman <mel@csn.ul.ie>
Tested-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-27 20:09:28 +01:00
Adrian Bunk f1bcf7e3e7 [ARM] use bcd2bin/bin2bcd
This patch changes arm to use the new bcd2bin/bin2bcd functions instead
of the obsolete BCD_TO_BIN/BIN_TO_BCD macros.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-27 20:07:59 +01:00
Harvey Harrison ae82cbfc8b [ARM] use the new byteorder headers
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-27 20:05:27 +01:00
Russell King e4e4146ec5 Merge branch 'for-rmk' of git://git.marvell.com/orion 2008-08-27 19:30:13 +01:00
Russell King a814917058 [ARM] OMAP: Fix 2430 SMC91x ethernet IRQ
Taken from omap 97b705ad835f1481270c4b67b402d6e37fa8ad15:
  ARM: OMAP: Misc compile fixes after syncing with mainline

  Also fix 2430 smc91x to use IRQ_LOWLEVEL.

  Signed-off-by: Tony Lindgren <tony@atomide.com>

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-27 16:15:23 +01:00
Russell King 9c2d015712 [ARM] OMAP: Add and update OMAP default configuration files
Update omap_h2_1610 and omap_osk_5912 default configurations.

Add ams delta, n770, omap 2430sdp, apollon_2420, generic 1510, 1610,
1710, 2420, h4 2420, innovator 1510 and 1610, perseus2 730, palte,
palmtt, palmz71 and sx1 default configurations.

Pulled out of the omap zoom tree.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-27 16:12:38 +01:00
Russell King 9abc6461a3 Merge branch 's3c2410' of git://aeryn.fluff.org.uk/bjdooks/linux.git 2008-08-26 23:16:45 +01:00
Wei Shuai 78af473530 [ARM] S3C2443: Fix the S3C2443 clock register definitions
Fix the S3C2443 clock register definitions for selecting the EPLL
reference clock described by S3C2443_CLKSRC_EPLLREF.

Signed-off-by: Wei Shuai <cpuwolf@gmail.com>
[ben-linux@fluff.org: minor description fixes]
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-26 22:56:22 +01:00
Ben Dooks df9f17e20e [ARM] JIVE: Fix the spi bus numbering
The first spi bus is registered with number 0, but
the board data says that the device on it is registered
on bus 1.

Move the spi bus to bus 1 to keep the compatibility with the
original board-support patches.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-26 22:56:22 +01:00
Ben Dooks 66592eee16 [ARM] S3C24XX: pwm.c: stop debugging output
Move debugging output to dev_dbg() instead of dev_info().

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-26 22:56:21 +01:00
Ben Dooks 103895925f [ARM] S3C24XX: Fix sparse warnings in pwm.c
Fix the following sparse warnings in arch/arm/plat-s3c24xx/pwm.c:

warning: symbol 's3c_device_timer' was not declared. Should it be static?
warning: symbol 'pwm_calc_tin' was not declared. Should it be static?

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-26 22:56:21 +01:00
Ben Dooks 1442e662d8 [ARM] S3C24XX: Fix spare errors in pwm-clock driver
Fix the following sparse warnings in arch/arm/plat-s3c24xx/pwm-clock.c:

warning: symbol 'clk_timer_scaler' was not declared. Should it be static?
warning: symbol 'clk_timer_tclk' was not declared. Should it be static?
warning: symbol 'clk_timer_tdiv' was not declared. Should it be static?

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-26 22:56:21 +01:00
Ben Dooks f4cb1a8964 [ARM] S3C24XX: Fix sparse warnings in arch/arm/plat-s3c24xx/gpiolib.c
Fix the following problems spotted by sparse:

warning: symbol 's3c24xx_gpiolib_input' was not declared. Should it be static?
warning: symbol 's3c24xx_gpiolib_output' was not declared. Should it be static?
warning: symbol 's3c24xx_gpiolib_set' was not declared. Should it be static?
warning: symbol 's3c24xx_gpiolib_get' was not declared. Should it be static?
warning: symbol 'gpios' was not declared. Should it be static?

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-26 22:56:20 +01:00
Ben Dooks ec8292347b [ARM] S3C24XX: Fix nor-simtec driver sparse errors
Fix the following sparse errors in arch/arm/mach-s3c2410/nor-simtec.c:

53:27: warning: symbol 'simtec_nor_pdata' was not declared. Should it be static?
77:13: warning: symbol 'nor_simtec_init' was not declared. Should it be static?

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-26 22:56:20 +01:00
Mike Rapoport fb6ff9a6f9 [ARM] 5216/1: Add CM-X300 defconfig
Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-26 17:08:04 +01:00
Mike Rapoport cf75d8d213 [ARM] 5215/2: Add support for CM-X300 board
This patch adds core support for CM-X300 board based on PXA300 processor

Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-26 17:08:04 +01:00
Mark Brown a461a8d2df [ARM] 5223/1: zylonite: Staticise zylonite_i2c_board_info
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-26 17:02:01 +01:00
Mark Brown 58d27fcfe6 [ARM] 5111/2: zylonite: Configure SSP
SSP3 is connected to the voice PCM of the WM9713 audio codec on the
Zylonite so configure the MFPs appropriately and select SSP support.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-26 17:02:00 +01:00
Eric Miao ad826e22c1 [ARM] pxa: fix incorrect definitions of SSP3 on pxa320
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-26 17:02:00 +01:00
Robert Jarzmik eda6f6ecbb [ARM] 5202/1: pxa: Added Mitac Mio A701 smartphone support.
The Mio A701 support features :
 - GSM support
 - Bluetooth support
 - GPS support
 - LED/Vibrator support
 - Suspend/Resume support (very dependant on Mio FlashRam)
 - Screen/Backlight support
 - Keys/Keyboard support
 - USB udc support
 - MMC/SDIO support
 - Flash Memory support
 - Battery/AC plugin support

Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-26 17:01:37 +01:00
Jaya Kumar d8ad7859e2 [ARM] 5197/1: gumstix: conversion to MFP support and add bluetooth support
This patch converts gumstix over to the MFP configuration system and adds
bluetooth support.

Signed-off-by: Jaya Kumar <jayakumar.lkml@gmail.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-26 17:01:27 +01:00
Jaya Kumar 922613436a [ARM] 5200/1: am200epd: use fb notifiers and gpio api
The original am200epd driver was designed with bad assumptions. It
manipulated GPSR/GPLR registers directly. It relied on direct access to the
pxa LCDC registers which have since conflicted with commit
ce4fb7b892 . This patch moves it into mach-pxa
and overhauls it to use a fb obtained through fb notifiers. It now uses the
generic GPIO api.

Signed-off-by: Jaya Kumar <jayakumar.lkml@gmail.com>
Acked-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-26 17:01:14 +01:00
Mark Brown f8787fdcf6 [ARM] 5225/1: zaurus: Register I2C controller for audio codecs
corgi, spitz and poodle have audio codecs on their primary I2C bus so
need to call pxa_set_i2c_info() to set it up during init. Tested on
spitz by Stanislav.

Reported-by: Stanislav Brabec <utx@penguin.cz>

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Richard Purdie <rpurdie@rpsys.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-26 16:26:25 +01:00
Adrian Bunk 7a8fc9b248 removed unused #include <linux/version.h>'s
This patch lets the files using linux/version.h match the files that
#include it.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-08-23 12:14:12 -07:00
Nicolas Pitre 8e05de88cf [ARM] orion5x: update defconfig to v2.6.27-rc4
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2008-08-22 13:21:15 -04:00
Martin Michlmayr e45772b2c0 [ARM] Orion: register UART1 on QNAP TS-209 and TS-409
Register UART1 on QNAP TS-209 and TS-409 because the PIC controller
is connected to it.  This fixes a regression from 2.6.26.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-21 22:15:17 -04:00
Martin Michlmayr c0fe819baf [ARM] Orion: activate lm75 driver on DNS-323
The lm75 driver was recently converted to the new-style binding,
so now it can be loaded from the DNS-323 support code.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Tested-by: Tobias Poschwatta <tp@fonz.de>
Acked-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-21 22:15:17 -04:00
Martin Michlmayr 35228e840a [ARM] Orion: fix MAC detection on QNAP TS-209 and TS-409
Flash needs to be set up before we can try to read the MAC address
from there.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-21 22:15:17 -04:00
Per Andersson 7a6bb26226 [ARM] Orion: Fix boot crash on Kurobox Pro
The Kurobox Pro crashes when any of the PCI controller registers
are accessed.  This patch adds a function to the Orion PCI handling
code that board support code can call to disable enumerating the
PCI bus entirely, and makes the Kurobox Pro PCI-related init code
call this function.

Signed-off-by: Per Andersson <avtobiff@gmail.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-21 22:15:17 -04:00
Paul Walmsley e89087c99f [ARM] OMAP: clockdomain: add clkdm_get_pwrdm()
Add clkdm_get_pwrdm() to the clockdomain code.  It will return a
pointer to the powerdomain struct that the clockdomain is contained
within.  Used by the PM code.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-21 21:30:19 +01:00
Paul Walmsley 0b7cbfb5e1 [ARM] OMAP3 pwrdm: add hardware save-and-restore (SAR) support
OMAP3430ES2+ introduces a new feature: optional powerdomain context
hardware save-and-restore (SAR).  Currently, this feature only applies
to USBHOST and USBTLL module context when the USBHOST or CORE
powerdomains enter a low-power sleep state[1].  This feature avoids
re-enumeration of USB devices when the powerdomains return from idle,
which is potentially time-consuming.

This patch adds support for enabling and disabling hardware
save-and-restore to the powerdomain code.  Three new functions are
added, pwrdm_enable_hdwr_sar(), pwrdm_disable_hdwr_sar(), and
pwrdm_can_hdwr_sar().  A new struct powerdomain "flags" field is
added, with a PWRDM_HAS_HDWR_SAR flag to indicate powerdomains with
SAR support.

Thanks to Jouni Högander <jouni.hogander@nokia.com> for reviewing an
earlier version of these patches, and Richard Woodruff <r-woodruff2@ti.com>
for clarifying the purpose of these bits.

1.  For the USBHOST controller module, context loss occurs when the
    USBHOST powerdomain enters off-idle.  For USBTLL, context loss
    occurs either if CORE enters off-idle, or if the CORE logic is
    configured to turn off when CORE enters retention-idle (OSWR).
    34xx ES2 TRM 4.8.6.1.1, 4.8.6.1.2

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-21 21:26:39 +01:00
Mike Rapoport 55d8460c92 [ARM] 5212/1: pxa: fix build error when CPU_PXA310 is not defined
Fix
arch/arm/mach-pxa/pxa300.c:94: error: 'CKEN_MMC3' undeclared here (not in a function)
when building for PXA300.

Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-20 23:17:13 +01:00
Tomasz Chmielewski d90c1add96 [ARM] 5208/1: fsg-setup.c fixes
This patch against 2.6.27-rc3 does the following changes to FSG-3 setup code:

1) Enable RTC on FSG-3 (proper name is needed). This change is needed due to a recent change in i2c.

2) i variable is only used when compiling for big endian.
So move its declaration to ARMEB ifdef to silence the warning when compiling for LE.

Mailing list link:
http://lists.arm.linux.org.uk/lurker/message/20080813.091556.cae2917e.en.html

Signed-off-by: Tomasz Chmielewski <mangoo@wpkg.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-19 16:56:42 +01:00
Ian Molton ebcce7b13b [ARM] eseries: move UDC defs to machine files
This patchset moves the UDC definitons for e7xx compatible eseries machines
to a common location and moves the 'oddball' e800 definition to its machine
file.

Signed-off-by: Ian Molton <spyro@f2s.com>
2008-08-19 13:44:07 +01:00
Ian Molton 0ec3cf6930 [ARM] eseries: move LCD defs into machine files
This patch removes the seperate files used for the LCD definitions on
e-series and places the definitions into the machine specific files.

Signed-off-by: Ian Molton <spyro@f2s.com>
2008-08-19 13:44:07 +01:00
Ian Molton 7dc964148c [ARM] eseries: Split machine definitions
This patchset breaks out the e-series machine definitions into
one-per-machine.

Signed-off-by: Ian Molton <spyro@f2s.com>
2008-08-19 13:44:07 +01:00
Högander Jouni 5955902fb5 ARM: OMAP2: Clock: Combine 34xx l3_icks and l4_icks
E.g dss_l3_ick and dss_l4_ick have same gating control. Having own
clock for both of them causes race condition between enable / disable.

This patch combines this kind of clocks and names new clock as <module>_ick.

Signed-off-by: Jouni Hogander <jouni.hogander@nokia.com>
Acked-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:45 +03:00
Paul Walmsley 333943ba9e ARM: OMAP2: Clockdomain: Integrate OMAP3 clocks with clockdomain code
This patch integrates the OMAP3 clock tree with the clockdomain code.
This patch:

- marks OMAP34xx clocks with their corresponding clockdomain.

- adds code to convert the clockdomain name to a clockdomain pointer in the
  struct clk during clk_register().

- modifies OMAP2 clock usecounting to call into the clockdomain code
  when clocks are enabled or disabled.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:45 +03:00
Paul Walmsley d1b03f615a ARM: OMAP2: Clockdomain: Associate clocks with clockdomains
Associate each OMAP24xx clock in arch/arm/mach-omap2/clock24xx.h
with a clockdomain.

Also move the L4 clock up higher in the file in preparation to
define the SSI L4 iclk.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:44 +03:00
Paul Walmsley 801954d3de ARM: OMAP2: Clockdomain: Encode OMAP2/3 clockdomains
Add clockdomain definitions for OMAP24xx and OMAP34xx chips.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:44 +03:00
Paul Walmsley 8420bb1363 ARM: OMAP2: Clockdomain: Connect clockdomain code to powerdomain code
Thie patch adds code to the powerdomain layer to track the
clockdomains associated with each powerdomain.

It also modifies the clockdomain code to register clockdomains
with their corresponding powerdomain when the clockdomain is registered.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:44 +03:00
Paul Walmsley d459bfe01f ARM: OMAP2: Clockdomain: Add base OMAP2/3 clockdomain code
This patch creates an interface to the clockdomain registers in the
PRM/CM modules on OMAP2/3.  This interface is intended to be used by
PM code, e.g., pm.c; not by device drivers directly.

The patch also adds clockdomain usecount tracking.  This is intended
to be called whenever the first clock in a clockdomain is enabled, or
when the last enabled clock in a clockdomain is disabled.  If the
clockdomain is in software-supervised mode, the code will force-wakeup
or force-sleep the clockdomain.  If the clockdomain is in
hardware-supervised mode, the first clock enable will add sleep and
wakeup dependencies on a user-selectable set of parent domains (usually
MPU & IVA2), and the disable will remove them.

Each clockdomain will be defined in later patches as static
structures.  The clockdomain structures are linked into a list at boot
by clkdm_register(), similar to the OMAP clock code.

The patch adds a Kconfig option, CONFIG_OMAP_DEBUG_CLOCKDOMAIN, which
when enabled will emit verbose debug messages via pr_debug().

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:43 +03:00
Paul Walmsley ecb24aa129 ARM: OMAP: Powerdomain: Add OMAP3 powerdomains
Add OMAP3-specific powerdomains.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:43 +03:00
Paul Walmsley fe6a58f8f5 ARM: OMAP2: Powerdomain: Add OMAP2 powerdomains
Add OMAP2-specific powerdomains.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:42 +03:00
Paul Walmsley 9717100f77 ARM: OMAP2: Powerdomain: Add OMAP2/3 common powerdomains
Add powerdomains common to both OMAP2 and OMAP3 (WKUP and GFX/SGX).
Modify mach-omap2/io.c to initialize the powerdomain code on boot.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:40 +03:00
Paul Walmsley ad67ef6848 ARM: OMAP2: Powerdomain: Add base OMAP2/3 powerdomain code
This patch creates an interface to the powerdomain registers in the
PRM/CM modules on OMAP2/3.  This interface is intended to be used by
PM code, e.g., pm.c; not by device drivers directly.

Each powerdomain will be defined in later patches as static
structures.  Also defined are dependencies between powerdomains,
used for adding and removing PM_WKDEP and CM_SLEEPDEP bits.  The
powerdomain structures are linked into a list at boot by
pwrdm_register(), similar to the OMAP clock code.

The patch adds a Kconfig option, CONFIG_OMAP_DEBUG_POWERDOMAIN, which
when enabled will emit verbose debug messages via pr_debug().

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2008-08-19 11:08:40 +03:00
Russell King 1a1dc50442 Merge branch 'for_rmk_17' of git://git.mnementh.co.uk/linux-2.6-im 2008-08-18 22:17:37 +01:00
Russell King faa64c93ae [ARM] fix impd1.c build warning
CC      arch/arm/mach-integrator/impd1.o
arch/arm/mach-integrator/impd1.c: In function `impd1_probe':
arch/arm/mach-integrator/impd1.c:408: warning: too few arguments for format

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-18 13:52:07 +01:00
Linus Torvalds 9c0d2a20fe Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm: (38 commits)
  [ARM] 5191/1: ARM: remove CVS keywords
  [ARM] pxafb: fix the warning of incorrect lccr when lcd_conn is specified
  [ARM] pxafb: add flag to specify output format on LDD pins when base is RGBT16
  [ARM] pxafb: fix the incorrect configuration of GPIO77 as ACBIAS for TFT LCD
  [ARM] 5198/1: PalmTX: PCMCIA fixes
  [ARM] Fix a pile of broken watchdog drivers
  [ARM] update mach-types
  [ARM] 5196/1: fix inline asm constraints for preload
  [ARM] 5194/1: update .gitignore
  [ARM] add proc-macros.S include to proc-arm940 and proc-arm946
  [ARM] 5192/1: ARM TLB: add v7wbi_{possible,always}_flags to {possible,always}_tlb_flags
  [ARM] 5193/1: Wire up missing syscalls
  [ARM] traps: don't call undef hook functions with spinlock held
  [ARM] 5183/2: Provide Poodle LoCoMo GPIO names
  [ARM] dma-mapping: provide sync_range APIs
  [ARM] dma-mapping: improve type-safeness of DMA translations
  [ARM] Kirkwood: instantiate the orion_spi driver in the platform code
  [ARM] prevent crashing when too much RAM installed
  [ARM] Kirkwood: Instantiate mv_xor driver
  [ARM] Orion: Instantiate mv_xor driver for 5182
  ...
2008-08-16 16:48:45 -07:00
Adrian Bunk 66bfa2f031 [ARM] 5191/1: ARM: remove CVS keywords
This patch removes CVS keywords that weren't updated for a long time.

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-16 20:01:18 +01:00
Eric Miao 9a1ac7e498 [ARM] pxafb: add flag to specify output format on LDD pins when base is RGBT16
Another fix of inconsistent shift of the LCD_BIAS_ACTIVE_* and
LCD_PCLK_EDGE_* is also included.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-16 16:39:16 +01:00
Russell King da4d77cda0 [ARM] update mach-types
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-16 09:30:05 +01:00
Nicolas Pitre 16f719de62 [ARM] 5196/1: fix inline asm constraints for preload
With gcc 4.3 and later, a pointer that has already been dereferenced is
assumed not to be null since it should have caused a segmentation fault
otherwise, hence any subsequent test against NULL is optimized away.

Current inline asm constraint used in the implementation of prefetch()
makes gcc believe that the pointer is dereferenced even though the PLD
instruction does not load any data and does not cause a segmentation
fault on null pointers, which causes all sorts of interesting results
when reaching the end of a linked lists for example.

Let's use a better constraint to properly represent the actual usage of
the pointer value.

Problem reported by Chris Steel.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-16 09:30:05 +01:00
Huang Ying 163f6876f5 kexec jump: rename KEXEC_CONTROL_CODE_SIZE to KEXEC_CONTROL_PAGE_SIZE
Rename KEXEC_CONTROL_CODE_SIZE to KEXEC_CONTROL_PAGE_SIZE, because control
page is used for not only code on some platform.  For example in kexec
jump, it is used for data and stack too.

[akpm@linux-foundation.org: unbreak powerpc and arm, finish conversion]
Signed-off-by: Huang Ying <ying.huang@intel.com>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Vivek Goyal <vgoyal@redhat.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-08-15 08:35:42 -07:00
Felipe Balbi ca6d1b1333 usb: musb: pass configuration specifics via pdata
Use platform_data to pass musb configuration-specific
details to musb driver.

This patch will prevent that other platforms selecting
HAVE_CLK and enabling musb won't break tree building.

The other parts of it will come when linux-omap merge
up more omap2/3 board-files.

Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Acked-by: Paul Mundt <lethal@linux-sh.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-08-13 17:33:01 -07:00
Nicolas Pitre da1562af62 [ARM] 5194/1: update .gitignore
Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-12 19:54:09 +01:00
Russell King 8a5544c887 [ARM] add proc-macros.S include to proc-arm940 and proc-arm946
... otherwise these fail to build.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-12 19:54:08 +01:00
Paul Walmsley 61db7fb1c7 [ARM] 5192/1: ARM TLB: add v7wbi_{possible,always}_flags to {possible,always}_tlb_flags
Commit 2ccdd1e77d doesn't add
v7wbi_possible_flags and v7wbi_always_flags to possible_tlb_flags and
always_tlb_flags.  This causes the L2 cache flush in clean_pmd_entry()
(intended for Feroceon only) to execute on ARMv7, and the CPU hangs.

This patch is required for OMAP3 boards to boot.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Acked-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-12 19:54:08 +01:00
Stefan Schmidt 751a8ae95d [ARM] 5193/1: Wire up missing syscalls
Setup some missing syscall pointed out by the checksyscalls.sh script. Fix two
small whitespace issues while being there.

Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-12 19:54:07 +01:00
Russell King b03a5b7559 [ARM] traps: don't call undef hook functions with spinlock held
Calling the undefined instruction handler functions with a
spinlock held is a recipe for must_sleep() warnings.  Avoid it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-12 19:54:07 +01:00
Dmitry Baryshkov f64c0accea [ARM] 5183/2: Provide Poodle LoCoMo GPIO names
Fix Poodle ASoC compilation by providing Poodle LoCoMo GPIO names.

Cc: Richard Purdie <rpurdie@rpsys.net>
Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-12 19:54:06 +01:00
Ian Molton 908cbc1013 [ARM] e400 config use MFP
This patch updates e400 to use the new MFP GPIO setup code.

    Signed-off-by: Ian Molton <spyro@f2s.com>
2008-08-12 19:13:31 +01:00
Ian Molton 2836548826 [ARM] e740 config use MFP
This patch updates e740 to use the new MFP GPIO setup code.

Signed-off-by: Ian Molton <spyro@f2s.com>
2008-08-12 19:13:23 +01:00
Ian Molton dec5abe921 [ARM] Fix eseries IRQ limit
The max IRQ is too small for all e-series machines which have at least one
GPIO expander chip in them.

Signed-off-by: Ian Molton <spyro@f2s.com>
2008-08-12 12:54:31 +01:00
Ian Molton c1ed406c21 [ARM] clocklib: Update users of aliases to new API
This patch removes the hardcoded alias array from pxa25x.c and reimplements
its functionality using the new clock alias call.

Signed-off-by: Ian Molton <spyro@f2s.com>
2008-08-12 12:54:31 +01:00
Ian Molton 5fedd0afd6 [ARM] clocklib: Allow dynamic alias creation
This patch allows dynamic creation of clock aliases in order to
make it possible to have platform independent clock names for use in
device drivers.

Signed-off-by: Ian Molton <spyro@f2s.com>
2008-08-12 12:54:30 +01:00
Ian Molton 67a6e80ede [ARM] eseries: whitespace fixes and cleanup
Signed-off-by: Ian Molton
2008-08-12 12:54:30 +01:00
David Woodhouse 742c52533b Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Conflicts:

	include/asm-arm/arch-omap/onenand.h
2008-08-12 11:28:00 +01:00
Russell King 9dd4286805 [ARM] dma-mapping: provide sync_range APIs
Convert the existing dma_sync_single_for_* APIs to the new range based
APIs, and make the dma_sync_single_for_* API a superset of it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-10 14:05:14 +01:00
Russell King 98ed7d4b1a [ARM] dma-mapping: improve type-safeness of DMA translations
OMAP at least gets the return type(s) for the DMA translation functions
wrong, which can lead to subtle errors.  Avoid this by moving the DMA
translation functions to asm/dma-mapping.h, and converting them to
inline functions.

Fix the OMAP DMA translation macros to use the correct argument and
result types.

Also, remove the unnecessary casts in dmabounce.c.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-10 12:10:49 +01:00
Russell King 492c71dd54 Merge branch 'for-rmk' of git://git.marvell.com/orion 2008-08-09 18:03:13 +01:00
Lennert Buytenhek 18365d181f [ARM] Kirkwood: instantiate the orion_spi driver in the platform code
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 15:38:18 +02:00
Lennert Buytenhek 60296c71f6 [ARM] prevent crashing when too much RAM installed
This patch will truncate and/or ignore memory banks if their kernel
direct mappings would (partially) overlap with the vmalloc area or
the mappings between the vmalloc area and the address space top, to
prevent crashing during early boot if there happens to be more RAM
installed than we are expecting.

Since the start of the vmalloc area is not at a fixed address (but
the vmalloc end address is, via the per-platform VMALLOC_END define),
a default area of 128M is reserved for vmalloc mappings, which can
be shrunk or enlarged by passing an appropriate vmalloc= command line
option as it is done on x86.

On a board with a 3:1 user:kernel split, VMALLOC_END at 0xfe000000,
two 512M RAM banks and vmalloc=128M (the default), this patch gives:

	Truncating RAM at 20000000-3fffffff to -35ffffff (vmalloc region overlap).
	Memory: 512MB 352MB = 864MB total

On a board with a 3:1 user:kernel split, VMALLOC_END at 0xfe800000,
two 256M RAM banks and vmalloc=768M, this patch gives:

	Truncating RAM at 00000000-0fffffff to -0e7fffff (vmalloc region overlap).
	Ignoring RAM at 10000000-1fffffff (vmalloc region overlap).

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Tested-by: Riku Voipio <riku.voipio@iki.fi>
2008-08-09 15:38:15 +02:00
Saeed Bishara 09c0ed2e6e [ARM] Kirkwood: Instantiate mv_xor driver
Signed-off-by: Saeed Bishara <saeed@marvell.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 15:17:29 +02:00
Saeed Bishara 1d5a1a6e92 [ARM] Orion: Instantiate mv_xor driver for 5182
Signed-off-by: Saeed Bishara <saeed@marvell.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 15:17:28 +02:00
Martin Michlmayr 3af6b0440f [ARM] Orion: enable CONFIG_RTC_DRV_S35390A in the defconfg for QNAP devices
The QNAP TS-109/TS-209 and TS-409 devices need RTC_DRV_S35390A.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 15:17:28 +02:00
Martin Michlmayr 627ca2fe93 [ARM] Orion: enable RTC_DRV_PCF8563 in the defconfig for HP mv2120
Enable RTC_DRV_PCF8563 in the Orion defconfig since this driver is
needed by the HP mv2120.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 15:17:28 +02:00
Martin Michlmayr 94434ba09a [ARM] Orion: enable KEYBOARD_GPIO in the defconfg
Enable KEYBOARD_GPIO in the Orion defconfig because a number of Orion
devices, such as the HP mv2120, define gpio-keys buttons.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 15:17:28 +02:00
Martin Michlmayr 5cebbd09fc [ARM] Orion: Export the reset button of the QNAP TS-409
The reset button on the QNAP TS-409 is available through gpio.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 15:17:28 +02:00
Martin Michlmayr 28ca8c802f [ARM] Orion: use better key codes for the TS-209/TS-409 buttons
Use key codes for the buttons on the TS-209/TS-409 that make more
sense than the current values.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Acked-by: Byron Bradley <byron.bbradley@gmail.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 15:17:27 +02:00
Martin Michlmayr 4a4e30afef [ARM] Orion: export red SATA lights on TS-409, fix SATA presence/activity
Export the four red SATA LEDs on the QNAP TS-409 that are connected
through gpio.  Since the boot loader apparently sets the SATA LEDs 2-4
to red and the SATA LED can only be red or green (but not both),
exporting the red SATA LEDs (which automatically turns them off upon
boot) makes the green SATA presence/activity indication visible.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Acked-by: Sylver Bruneau <sylver.bruneau@googlemail.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 15:17:27 +02:00
Lennert Buytenhek ce72e36ed1 [ARM] Orion: support D0 5281 silicon
On D0 5281 SoCs, we need to disable the wait-for-interrupt
instruction due to an erratum.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
Acked-by: Martin Michlmayr <tbm@cyrius.com>
2008-08-09 15:17:27 +02:00
Ben Dooks ed414fb7b8 [ARM] S3C24XX: Fix section mismatch for s3c_lookup_cpu
s3c_lookup_cpu is only used at init time, so make
it __init.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-09 13:51:54 +01:00
Ben Dooks e38d523fd0 [ARM] CATS: Do not try and map bad PCI IRQ numbers
The cats_map_irq() function in the Simtec CATS support
code is mapping IRQ 255 (invalid IRQ) into what is a
supposedly valid interrupt numner which can cause problems
with other devices then seeing an interrupt they cannot
claim.

If the IRQ number if >= 255, then return -1 as this is not
something we can map.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-09 13:51:53 +01:00
Huang Weiyi 2921047594 [ARM] JIVE: Remove duplicated mtd includes
Removed duplicated include file <linux/mtd/mtd.h> and <linux/mtd/partitions.h>
in arch/arm/mach-s3c2412/mach-jive.c.

Signed-off-by: Huang Weiyi <weiyi.huang@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-08-09 13:51:52 +01:00
Lennert Buytenhek 6f088f1d21 [ARM] Move include/asm-arm/plat-orion to arch/arm/plat-orion/include/plat
This patch performs the equivalent include directory shuffle for
plat-orion, and fixes up all users.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-08-09 13:44:58 +02:00
Ben Dooks af7a535688 Merge http://ftp.arm.linux.org.uk/pub/linux/arm/kernel/git-cur/linux-2.6-arm into for-rmk 2008-08-08 21:10:12 +01:00
Adrian Bunk c41107c2d4 [ARM] 5177/1: arm/mach-sa1100/Makefile: remove CONFIG_SA1100_USB
This patch removes the commented out line for the not available
CONFIG_SA1100_USB option.

Reported-by: Robert P. J. Day <rpjday@crashcourse.ca>

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-08 16:06:37 +01:00
Russell King 2727f226a6 [ARM] fix pnx4008 build errors
include/linux/i2c-pnx.h was missed when moving the include files.
Fix it now; it doesn't really need to include mach/i2c.h at all.
Successfully build tested with pnx4008_defconfig, which had
failed in linux-next.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-08 15:13:27 +01:00
Russell King 058ddee562 [ARM] Fix SMP booting with non-zero PHYS_OFFSET
The existing code tries to get the pmd for the temporary page table
by doing:

        pgd = pgd_alloc(&init_mm);
        pmd = pmd_offset(pgd, PHYS_OFFSET);

Since we have a two level page table, pmd_offset() is a no-op, so
this just has a casting effect from a pgd to a pmd - the address
argument is unused.  So this can't work.

Normally, we'd do:

	pgd = pgd_offset(&init_mm, PHYS_OFFSET);
	...
	pmd = pmd_offset(pgd, PHYS_OFFSET);

to get the pmd you want.  However, pgd_offset() takes the mm_struct,
not the (unattached) pgd we just allocated.  So, instead use:

        pgd = pgd_alloc(&init_mm);
        pmd = pmd_offset(pgd + pgd_index(PHYS_OFFSET), PHYS_OFFSET);

Reported-by: Antti P Miettinen <ananaza@iki.fi>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-07 22:36:59 +01:00
Russell King afd2fc02ab Merge branch 'for-rmk' of git://git.kernel.org/pub/scm/linux/kernel/git/ycmiao/pxa-linux-2.6
Conflicts:

	arch/arm/mach-pxa/generic.c
	arch/arm/mach-pxa/pxa25x.c
	arch/arm/mach-pxa/pxa27x.c
	arch/arm/mach-pxa/pxa2xx.c
	arch/arm/mach-pxa/pxa3xx.c
	arch/arm/mach-pxa/reset.c
	arch/arm/mach-pxa/spitz.c
	arch/arm/mach-pxa/tosa.c
	drivers/watchdog/sa1100_wdt.c
2008-08-07 11:06:47 +01:00
Jonathan Cameron 1f4de5a0e3 [ARM] 5185/1: Fix spi num_chipselect for lubbock
Change num_chipselect for lubbock ssp master to reflect requirement
of spi subsystem that all buses have at least 1 chip select.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Eric Miao <eric.miao@marvell.com>
Acked-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-07 10:25:11 +01:00
Russell King a09e64fbc0 [ARM] Move include/asm-arm/arch-* to arch/arm/*/include/mach
This just leaves include/asm-arm/plat-* to deal with.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-07 09:55:48 +01:00
Russell King 4fb8af10d0 Merge git://git.kernel.org/pub/scm/linux/kernel/git/sam/kbuild-fixes 2008-08-07 09:55:03 +01:00
Russell King f44f82e8a2 [ARM] Add support for arch/arm/mach-*/include and arch/arm/plat-*/include
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-07 09:54:39 +01:00
Russell King be50972935 [ARM] Remove asm/hardware.h, use asm/arch/hardware.h instead
Remove includes of asm/hardware.h in addition to asm/arch/hardware.h.
Then, since asm/hardware.h only exists to include asm/arch/hardware.h,
update everything to directly include asm/arch/hardware.h and remove
asm/hardware.h.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-07 09:40:08 +01:00
Russell King 0f8469a54f [ARM] Eliminate useless includes of asm/mach-types.h
There are 43 includes of asm/mach-types.h by files that don't
reference anything from that file.  Remove these unnecessary
includes.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-07 09:40:04 +01:00
Russell King 897d85275d [ARM] Fix circular include dependency with IRQ headers
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-07 09:39:37 +01:00
Eric Miao 04fef228fb [ARM] pxa: introduce reset_status and clear_reset_status for driver's usage
Due to the problem of reset status bits being handled by different
registers between pxa2xx and pxa3xx, introduce a global reset_status
variable, initialized by SoC-specific code and later being used by
other drivers.

And also introduce clear_reset_status(), which is used to clear the
corresponding status bits. Pass RESET_STATUS_ALL to clear all bits.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
2008-08-05 09:26:02 +08:00
Eric Miao ab27712142 [ARM] pxa: introduce reset.h for reset specific header information
Signed-off-by: Eric Miao <eric.miao@marvell.com>
2008-08-05 09:25:19 +08:00
Linus Torvalds 7e31aa11fc 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] 5182/1: pxa: Fix pcm990 compilation
  [ARM] Fix explicit asm(-arm)?/arch-foo references
  [ARM] move include/asm-arm to arch/arm/include/asm
  [ARM] Remove explicit dependency for misc.o from compressed/Makefile
  [ARM] initrd: claim initrd memory exclusively
  [ARM] pxa: add support for L2 outer cache on XScale3 (attempt 2)
  [ARM] 5180/1: at91: Fix at91_nand -> atmel_nand rename fallout
  [ARM] add Sascha Hauer as Freescale i.MX Maintainer
  [ARM] i.MX: add missing clock functions exports
  [ARM] i.MX: remove set_imx_fb_info() export
  [ARM] mx1ads: make mmc platform data available for modules
  [ARM] mx2: add missing Kconfig dependency
2008-08-03 10:39:02 -07:00
Guennadi Liakhovetski 9cb7117fa4 [ARM] 5182/1: pxa: Fix pcm990 compilation
Compiling pcm990 produces an error:

In file included from arch/arm/mach-pxa/pcm990-baseboard.c:25:
include/linux/ide.h:645: error: 'CONFIG_IDE_MAX_HWIFS' undeclared here (not in a function)

Fix it by removing unneeded header include.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-03 10:17:59 +01:00
Russell King bccf650270 [ARM] Fix explicit asm(-arm)?/arch-foo references
No file should be explicitly referencing its own platform headers
by specifying an absolute include path.  Fix these paths to use
standard <asm/arch/...> includes.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-02 22:35:16 +01:00
Russell King 4baa992243 [ARM] move include/asm-arm to arch/arm/include/asm
Move platform independent header files to arch/arm/include/asm, leaving
those in asm/arch* and asm/plat* alone.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-02 21:32:35 +01:00
Russell King ff4db0a043 [ARM] Remove explicit dependency for misc.o from compressed/Makefile
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-02 15:27:44 +01:00
Linus Torvalds 9a5467fd60 Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (46 commits)
  tcp: MD5: Fix IPv6 signatures
  skbuff: add missing kernel-doc for do_not_encrypt
  net/ipv4/route.c: fix build error
  tcp: MD5: Fix MD5 signatures on certain ACK packets
  ipv6: Fix ip6_xmit to send fragments if ipfragok is true
  ipvs: Move userspace definitions to include/linux/ip_vs.h
  netdev: Fix lockdep warnings in multiqueue configurations.
  netfilter: xt_hashlimit: fix race between htable_destroy and htable_gc
  netfilter: ipt_recent: fix race between recent_mt_destroy and proc manipulations
  netfilter: nf_conntrack_tcp: decrease timeouts while data in unacknowledged
  irda: replace __FUNCTION__ with __func__
  nsc-ircc: default to dongle type 9 on IBM hardware
  bluetooth: add quirks for a few hci_usb devices
  hysdn: remove the packed attribute from PofTimStamp_tag
  isdn: use the common ascii hex helpers
  tg3: adapt tg3 to use reworked PCI PM code
  atm: fix direct casts of pointers to u32 in the InterPhase driver
  atm: fix const assignment/discard warnings in the ATM networking driver
  net: use the common ascii hex helpers
  random32: seeding improvement
  ...
2008-08-01 11:35:16 -07:00
Linus Torvalds 623fa579e6 Merge git://git.infradead.org/mtd-2.6
* git://git.infradead.org/mtd-2.6:
  [MTD] [NAND] drivers/mtd/nand/nandsim.c: fix printk warnings
  [MTD] [NAND] Blackfin NFC Driver: Cleanup the error exit path of bf5xx_nand_probe function
  [MTD] [NAND] Blackfin NFC Driver: use standard dev_err() rather than printk()
  [MTD] [NAND] Blackfin NFC Driver: enable Blackfin nand HWECC support by default
  [MTD] [NAND] Blackfin NFC Driver: add proper devinit/devexit markings to probe/remove functions
  [MTD] [NAND] Blackfin NFC Driver: add support for the ECC layout the Blackfin bootrom uses
  [MTD] [NAND] Blackfin NFC Driver: fix bug - hw ecc calc by making sure we extract 11 bits from each register instead of 10
  [MTD] [NAND] Blackfin NFC Driver: fix bug - do not clobber the status from the first 256 bytes if operating on 512 pages
  [MTD] [NAND] diskonchip.c fix sparse endian warnings
  [MTD] [NAND] drivers/mtd/nand/nandsim.c needs div64.h
  [JFFS2] Fix allocation of summary buffer
  Fix rename of at91_nand -> atmel_nand
  [MTD] [NOR] drivers/mtd/chips/jedec_probe.c: fix Am29DL800BB device ID
  [MTD] MTD_DEBUG always does compile-time typechecks
  [MTD] DataFlash: bugfix, binary page sizes now handled
  [MTD] [NAND] fsl_elbc_nand.c: fix printk warning
  [MTD] [NAND] nandsim: support random page read command
  [MTD] [NAND] fix subpage read for small page NAND
2008-08-01 11:29:54 -07:00
Pieter du Preez f6ed6f78d4 Fix rename of at91_nand -> atmel_nand
Structs called at91_nand_data where renamed to atmel_nand_data
and configs called *MTD_NAND_AT91* where renamed to
*MTD_NAND_ATMEL*. This was unfortunately not done consistently,
causing NAND chips not being initialised on several ARM boards.

I am aware that the author of the original change did not rename
MTD_NAND_AT91_BUSWIDTH to MTD_NAND_ATMEL_BUSWIDTH, for example.
All *MTD_NAND_AT91* where renamed to *MTD_NAND_ATMEL* in order
to keep naming consistency.

This patch was only tested on a MACH_SAM9_L9260, as this is the
only ARM board I have to my disposal.

Before this patch:

$ git-ls-files |xargs grep atmel_nand |wc -l
105
$ git-ls-files |xargs grep at91_nand |wc -l
4
$ git-ls-files |xargs grep MTD_NAND_ATMEL |wc -l
8
$ git-ls-files |xargs grep MTD_NAND_AT91 |wc -l
47

After this patch:

$ git-ls-files |xargs grep atmel_nand |wc -l
109
$ git-ls-files |xargs grep at91_nand |wc -l
0
$ git-ls-files |xargs grep MTD_NAND_ATMEL |wc -l
55
$ git-ls-files |xargs grep MTD_NAND_AT91 |wc -l
0

Signed-off-by: Pieter du Preez <pdupreez@gmail.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-08-01 10:06:40 +01:00
David S. Miller e62112c53a Merge branch 'upstream-davem' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6 2008-07-30 15:44:30 -07:00
Russell King b962a286e5 [ARM] initrd: claim initrd memory exclusively
Claim the initrd memory exclusively, and order other memory
reservations beforehand.  This allows us to determine whether
the initrd memory was overwritten, and disable the initrd in
that case.

This avoids a 'bad page state' bug.

Tested-by: Ralph Siemsen <ralphs@netwinder.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-30 21:24:56 +01:00
Liam Girdwood ba7e476343 regulator: core kbuild files
This patch adds kernel build support for the regulator core.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Liam Girdwood <lg@opensource.wolfsonmicro.com>
2008-07-30 10:10:22 +01:00
Jeff Garzik 16b237dc44 Merge branch 'for-2.6.27' of git://git.marvell.com/mv643xx_eth into upstream-fixes 2008-07-29 18:23:13 -04:00
Linus Torvalds 1d9b9f6a53 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jbarnes/pci-2.6: (21 commits)
  x86/PCI: use dev_printk when possible
  PCI: add D3 power state avoidance quirk
  PCI: fix bogus "'device' may be used uninitialized" warning in pci_slot
  PCI: add an option to allow ASPM enabled forcibly
  PCI: disable ASPM on pre-1.1 PCIe devices
  PCI: disable ASPM per ACPI FADT setting
  PCI MSI: Don't disable MSIs if the mask bit isn't supported
  PCI: handle 64-bit resources better on 32-bit machines
  PCI: rewrite PCI BAR reading code
  PCI: document pci_target_state
  PCI hotplug: fix typo in pcie hotplug output
  x86 gart: replace to_pages macro with iommu_num_pages
  x86, AMD IOMMU: replace to_pages macro with iommu_num_pages
  iommu: add iommu_num_pages helper function
  dma-coherent: add documentation to new interfaces
  Cris: convert to using generic dma-coherent mem allocator
  Sh: use generic per-device coherent dma allocator
  ARM: support generic per-device coherent dma mem
  Generic dma-coherent: fix DMA_MEMORY_EXCLUSIVE
  x86: use generic per-device dma coherent allocator
  ...
2008-07-28 18:14:24 -07:00
David Brownell 93686ae835 arm: fix HAVE_CLK merge goof
This fixes a merge goof whereby ARCH_EP93XX got the "select HAVE_CLK" line
which belongs instead with ARCH_AT91.

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-28 16:30:20 -07:00
Eric Miao 905a09d57a [ARM] pxa: add support for L2 outer cache on XScale3 (attempt 2)
(20072fd0c9 lost most of its changes
somehow, came from a mbox archive applied with git-am.  No idea
what happened.  This puts back the missing bits.  --rmk)

The initial patch from Lothar, and Lennert make it into a cleaner
one, modified and tested on PXA320 by Eric Miao.

This patch moves the L2 cache operations out of proc-xsc3.S into
dedicated outer cache support code.

CACHE_XSC3L2 can be deselected so no L2 cache specific code will be
linked in, and that L2 enable bit will not be set, this applies to
the following cases:

    a. _only_ PXA300/PXA310 support included and no L2 cache wanted
    b. PXA320 support included, but want L2 be disabled

So the enabling of L2 depends on two things:

    - CACHE_XSC3L2 is selected
    - and L2 cache is present

Where the latter is only a safeguard (previous testing shows it works
OK even when this bit is turned on).

IXP series of processors with XScale3 cannot disable L2 cache for the
moment since they depend on the L2 cache for its coherent memory, so
IXP may always select CACHE_XSC3L2.

Other L2 relevant bits are always turned on (i.e. the original code
enclosed by #if L2_CACHE_ENABLED .. #endif), as they showed no side
effects. Specifically, these bits are:

   - OC bits in TTBASE register (table walk outer cache attributes)
   - LLR Outer Cache Attributes (OC) in Auxiliary Control Register

Signed-off-by: Lothar WaÃ<9f>mann <LW@KARO-electronics.de>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-28 23:13:09 +01:00
Ingo Molnar cb28a1bbdb Merge branch 'linus' into core/generic-dma-coherent
Conflicts:

	arch/x86/Kconfig

Signed-off-by: Ingo Molnar <mingo@elte.hu>
2008-07-29 00:07:55 +02:00
Russell King e76e3ac69e Merge branch 'for-rmk' of git://pasiphae.extern.pengutronix.de/git/imx/linux-2.6 2008-07-28 18:45:57 +01:00
Haavard Skinnemoen 7c89683473 [ARM] 5180/1: at91: Fix at91_nand -> atmel_nand rename fallout
struct at91_nand has been renamed atmel_nand. Fix the four boards that
were added since the patch was created.

Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>
Acked-by: Andrew Victor <linux@maxim.org.za>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-28 17:00:02 +01:00
Paulius Zaleckas 79a13b2978 [ARM] i.MX: add missing clock functions exports
Export missing Clock API symbols.

Signed-off-by: Paulius Zaleckas <paulius.zaleckas@teltonika.lt>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-28 11:29:22 +02:00
Paulius Zaleckas d7098e3140 [ARM] i.MX: remove set_imx_fb_info() export
Remove not needed export and fix warning:

WARNING: vmlinux.o(__ksymtab+0x400): Section mismatch in reference from the variable __ksymtab_set_imx_fb_info to the function .init.text:set_imx_fb_info()
The symbol set_imx_fb_info is exported and annotated __init
Fix this by removing the __init annotation of set_imx_fb_info or drop the export.

Signed-off-by: Paulius Zaleckas <paulius.zaleckas@teltonika.lt>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-28 11:29:21 +02:00
Sascha Hauer 2809fc06f2 [ARM] mx1ads: make mmc platform data available for modules
Signed-off-by: Paulius Zaleckas <paulius.zaleckas@teltonika.lt>
Acked-by: Pavel Pisa <pisa@cmp.felk.cvut.cz>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-28 11:28:53 +02:00
Sascha Hauer 221d62c188 [ARM] mx2: add missing Kconfig dependency
It seems this small label was lost in the last merge. Without it
no CPU type is selected for the MX2 family of processors. And a build
will fail badly...

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-28 11:23:30 +02:00
Linus Torvalds 3e318b5b55 Merge master.kernel.org:/home/rmk/linux-2.6-arm
* master.kernel.org:/home/rmk/linux-2.6-arm:
  [ARM] Fix shared mmap when more than two maps of the same file exist
  [ARM] fix VIPT/VIVT macro optimisations, add comments
  [ARM] 5179/1: Replace obsolete IRQT_* and __IRQT_* values with IRQ_TYPE_*
  [ARM] update defconfig for eseries.
  [ARM] PXA: squash warning in pxafb
  [ARM] pxa: PXA25x UDC - Fix warning during build
  [ARM] fix nwflash.c: 6ee8928d94
  [ARM] fix IOP32x, IOP33x, MXC and Samsung builds
  [ARM] pci: provide dummy pci_get_legacy_ide_irq()
  [ARM] fix fls() for 64-bit arguments
  [ARM] fix mode for board-yl-9200.c
  [ARM] 5176/1: arm/Makefile: fix: ARM946T -> ARM946E
2008-07-27 16:46:08 -07:00
Russell King 53cdb27a93 [ARM] Fix shared mmap when more than two maps of the same file exist
The shared mmap code works fine for the test case, which only checked
for two shared maps of the same file.  However, three shared maps
result in one mapping remaining cached, resulting in stale data being
visible via that mapping.  Fix this.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-27 10:35:54 +01:00
Dmitry Baryshkov 6cab486029 [ARM] 5179/1: Replace obsolete IRQT_* and __IRQT_* values with IRQ_TYPE_*
IRQT_* and __IRQT_* were obsoleted long ago by patch [3692/1].
Remove them completely. Sed script for the reference:

s/__IRQT_RISEDGE/IRQ_TYPE_EDGE_RISING/g
s/__IRQT_FALEDGE/IRQ_TYPE_EDGE_FALLING/g
s/__IRQT_LOWLVL/IRQ_TYPE_LEVEL_LOW/g
s/__IRQT_HIGHLVL/IRQ_TYPE_LEVEL_HIGH/g
s/IRQT_RISING/IRQ_TYPE_EDGE_RISING/g
s/IRQT_FALLING/IRQ_TYPE_EDGE_FALLING/g
s/IRQT_BOTHEDGE/IRQ_TYPE_EDGE_BOTH/g
s/IRQT_LOW/IRQ_TYPE_LEVEL_LOW/g
s/IRQT_HIGH/IRQ_TYPE_LEVEL_HIGH/g
s/IRQT_PROBE/IRQ_TYPE_PROBE/g
s/IRQT_NOEDGE/IRQ_TYPE_NONE/g

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-27 09:46:18 +01:00
Linus Torvalds 9ee08c2df4 Merge git://git.infradead.org/mtd-2.6
* git://git.infradead.org/mtd-2.6: (57 commits)
  [MTD] [NAND] subpage read feature as a way to increase performance. 
  CPUFREQ: S3C24XX NAND driver frequency scaling support.
  [MTD][NAND] au1550nd: remove unused variable
  [MTD] jedec_probe: Fix SST 16-bit chip detection
  [MTD][MTDPART] Fix a division by zero bug
  [MTD][MTDPART] Cleanup and document the erase region handling
  [MTD][MTDPART] Handle most checkpatch findings
  [MTD][MTDPART] Seperate main loop from per-partition code in add_mtd_partition
  [MTD] physmap: resume already suspended chips on failure to suspend
  [MTD] physmap: Fix suspend/resume/shutdown bugs.
  [MTD] [NOR] Fix -ETIMEO errors in CFI driver
  [MTD] [NAND] fsl_elbc_nand: fix section mismatch with CONFIG_MTD_OF_PARTS=y
  [JFFS2] Use .unlocked_ioctl
  [MTD] Fix const assignment in the MTD command line partitioning driver
  [MTD] [NOR] gen_probe: No debug message when debugging is disabled
  [MTD] [NAND] remove __PPC__ hardcoded address from DiskOnChip drivers
  [MTD] [MAPS] Remove the bast-flash driver.
  [MTD] [NAND] fsl_elbc_nand: ecclayout cleanups
  [MTD] [NAND] fsl_elbc_nand: implement support for flash-based BBT
  [MTD] [NAND] fsl_elbc_nand: fix OOB workability for large page NAND chips
  ...
2008-07-26 20:30:56 -07:00
Russell King d9ecdb282c Merge branch 'for_rmk_13' of git://git.mnementh.co.uk/linux-2.6-im 2008-07-26 23:04:59 +01:00
Ian Molton 1d1f8b377c [ARM] update defconfig for eseries.
Signed-off-by: Ian Molton <spyro@f2s.com>
2008-07-26 22:39:58 +01:00
Alexey Dobriyan 51cc50685a SL*B: drop kmem cache argument from constructor
Kmem cache passed to constructor is only needed for constructors that are
themselves multiplexeres.  Nobody uses this "feature", nor does anybody uses
passed kmem cache in non-trivial way, so pass only pointer to object.

Non-trivial places are:
	arch/powerpc/mm/init_64.c
	arch/powerpc/mm/hugetlbpage.c

This is flag day, yes.

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Acked-by: Pekka Enberg <penberg@cs.helsinki.fi>
Acked-by: Christoph Lameter <cl@linux-foundation.org>
Cc: Jon Tollefson <kniht@linux.vnet.ibm.com>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>
Cc: Matt Mackall <mpm@selenic.com>
[akpm@linux-foundation.org: fix arch/powerpc/mm/hugetlbpage.c]
[akpm@linux-foundation.org: fix mm/slab.c]
[akpm@linux-foundation.org: fix ubifs]
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-26 12:00:07 -07:00
FUJITA Tomonori 8d8bb39b9e dma-mapping: add the device argument to dma_mapping_error()
Add per-device dma_mapping_ops support for CONFIG_X86_64 as POWER
architecture does:

This enables us to cleanly fix the Calgary IOMMU issue that some devices
are not behind the IOMMU (http://lkml.org/lkml/2008/5/8/423).

I think that per-device dma_mapping_ops support would be also helpful for
KVM people to support PCI passthrough but Andi thinks that this makes it
difficult to support the PCI passthrough (see the above thread).  So I
CC'ed this to KVM camp.  Comments are appreciated.

A pointer to dma_mapping_ops to struct dev_archdata is added.  If the
pointer is non NULL, DMA operations in asm/dma-mapping.h use it.  If it's
NULL, the system-wide dma_ops pointer is used as before.

If it's useful for KVM people, I plan to implement a mechanism to register
a hook called when a new pci (or dma capable) device is created (it works
with hot plugging).  It enables IOMMUs to set up an appropriate
dma_mapping_ops per device.

The major obstacle is that dma_mapping_error doesn't take a pointer to the
device unlike other DMA operations.  So x86 can't have dma_mapping_ops per
device.  Note all the POWER IOMMUs use the same dma_mapping_error function
so this is not a problem for POWER but x86 IOMMUs use different
dma_mapping_error functions.

The first patch adds the device argument to dma_mapping_error.  The patch
is trivial but large since it touches lots of drivers and dma-mapping.h in
all the architecture.

This patch:

dma_mapping_error() doesn't take a pointer to the device unlike other DMA
operations.  So we can't have dma_mapping_ops per device.

Note that POWER already has dma_mapping_ops per device but all the POWER
IOMMUs use the same dma_mapping_error function.  x86 IOMMUs use device
argument.

[akpm@linux-foundation.org: fix sge]
[akpm@linux-foundation.org: fix svc_rdma]
[akpm@linux-foundation.org: build fix]
[akpm@linux-foundation.org: fix bnx2x]
[akpm@linux-foundation.org: fix s2io]
[akpm@linux-foundation.org: fix pasemi_mac]
[akpm@linux-foundation.org: fix sdhci]
[akpm@linux-foundation.org: build fix]
[akpm@linux-foundation.org: fix sparc]
[akpm@linux-foundation.org: fix ibmvscsi]
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Cc: Muli Ben-Yehuda <muli@il.ibm.com>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Avi Kivity <avi@qumranet.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-26 12:00:03 -07:00
Russell King bb2b180ca0 [ARM] fix IOP32x, IOP33x, MXC and Samsung builds
7444a72eff caused these platforms to lose
their GPIOLIB configuration.  Convert the missed Kconfig symbols using:

  sed -i s/HAVE_GPIO_LIB/ARCH_REQUIRE_GPIOLIB/ arch/arm/Kconfig arch/arm/plat-s3c24xx/Kconfig

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-26 15:41:25 +01:00
Russell King 9d9fa83bea [ARM] fix mode for board-yl-9200.c
Xose Vazquez Perez points out that this file should not be marked
executable.

Reported-by: Xose Vazquez Perez <xose.vazquez@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-26 15:23:25 +01:00
Adrian Bunk e6bb83fd2f [ARM] 5176/1: arm/Makefile: fix: ARM946T -> ARM946E
This patch fixes a typo introduced by
commit f37f46eb1c
([ARM] nommu: add ARM946E-S core support).

Reported-by: Robert P. J. Day <rpjday@crashcourse.ca>

Signed-off-by: Adrian Bunk <bunk@kernel.org>
Acked-by: Hyok S. Choi <hyok.choi@samsung.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-26 15:23:25 +01:00
Michael Buesch 7444a72eff gpiolib: allow user-selection
This patch adds functionality to the gpio-lib subsystem to make it
possible to enable the gpio-lib code even if the architecture code didn't
request to get it built in.

The archtitecture code does still need to implement the gpiolib accessor
functions in its asm/gpio.h file.  This patch adds the implementations for
x86 and PPC.

With these changes it is possible to run generic GPIO expansion cards on
every architecture that implements the trivial wrapper functions.  Support
for more architectures can easily be added.

Signed-off-by: Michael Buesch <mb@bu3sch.de>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: David Brownell <david-b@pacbell.net>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Haavard Skinnemoen <hskinnemoen@atmel.com>
Cc: Jesper Nilsson <jesper.nilsson@axis.com>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Jean Delvare <khali@linux-fr.org>
Cc: Samuel Ortiz <sameo@openedhand.com>
Cc: Kumar Gala <galak@gate.crashing.org>
Cc: Sam Ravnborg <sam@ravnborg.org>
Cc: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-25 10:53:30 -07:00
David Brownell d8f388d8dc gpio: sysfs interface
This adds a simple sysfs interface for GPIOs.

    /sys/class/gpio
    	/export ... asks the kernel to export a GPIO to userspace
    	/unexport ... to return a GPIO to the kernel
        /gpioN ... for each exported GPIO #N
	    /value ... always readable, writes fail for input GPIOs
	    /direction ... r/w as: in, out (default low); write high, low
	/gpiochipN ... for each gpiochip; #N is its first GPIO
	    /base ... (r/o) same as N
	    /label ... (r/o) descriptive, not necessarily unique
	    /ngpio ... (r/o) number of GPIOs; numbered N .. N+(ngpio - 1)

GPIOs claimed by kernel code may be exported by its owner using a new
gpio_export() call, which should be most useful for driver debugging.
Such exports may optionally be done without a "direction" attribute.

Userspace may ask to take over a GPIO by writing to a sysfs control file,
helping to cope with incomplete board support or other "one-off"
requirements that don't merit full kernel support:

  echo 23 > /sys/class/gpio/export
	... will gpio_request(23, "sysfs") and gpio_export(23);
	use /sys/class/gpio/gpio-23/direction to (re)configure it,
	when that GPIO can be used as both input and output.
  echo 23 > /sys/class/gpio/unexport
	... will gpio_free(23), when it was exported as above

The extra D-space footprint is a few hundred bytes, except for the sysfs
resources associated with each exported GPIO.  The additional I-space
footprint is about two thirds of the current size of gpiolib (!).  Since
no /dev node creation is involved, no "udev" support is needed.

Related changes:

  * This adds a device pointer to "struct gpio_chip".  When GPIO
    providers initialize that, sysfs gpio class devices become children of
    that device instead of being "virtual" devices.

  * The (few) gpio_chip providers which have such a device node have
    been updated.

  * Some gpio_chip drivers also needed to update their module "owner"
    field ...  for which missing kerneldoc was added.

  * Some gpio_chips don't support input GPIOs.  Those GPIOs are now
    flagged appropriately when the chip is registered.

Based on previous patches, and discussion both on and off LKML.

A Documentation/ABI/testing/sysfs-gpio update is ready to submit once this
merges to mainline.

[akpm@linux-foundation.org: a few maintenance build fixes]
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Guennadi Liakhovetski <g.liakhovetski@pengutronix.de>
Cc: Greg KH <greg@kroah.com>
Cc: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-25 10:53:30 -07:00
Srinivasa D S ef53d9c5e4 kprobes: improve kretprobe scalability with hashed locking
Currently list of kretprobe instances are stored in kretprobe object (as
used_instances,free_instances) and in kretprobe hash table.  We have one
global kretprobe lock to serialise the access to these lists.  This causes
only one kretprobe handler to execute at a time.  Hence affects system
performance, particularly on SMP systems and when return probe is set on
lot of functions (like on all systemcalls).

Solution proposed here gives fine-grain locks that performs better on SMP
system compared to present kretprobe implementation.

Solution:

 1) Instead of having one global lock to protect kretprobe instances
    present in kretprobe object and kretprobe hash table.  We will have
    two locks, one lock for protecting kretprobe hash table and another
    lock for kretporbe object.

 2) We hold lock present in kretprobe object while we modify kretprobe
    instance in kretprobe object and we hold per-hash-list lock while
    modifying kretprobe instances present in that hash list.  To prevent
    deadlock, we never grab a per-hash-list lock while holding a kretprobe
    lock.

 3) We can remove used_instances from struct kretprobe, as we can
    track used instances of kretprobe instances using kretprobe hash
    table.

Time duration for kernel compilation ("make -j 8") on a 8-way ppc64 system
with return probes set on all systemcalls looks like this.

cacheline              non-cacheline             Un-patched kernel
aligned patch 	       aligned patch
===============================================================================
real    9m46.784s       9m54.412s                  10m2.450s
user    40m5.715s       40m7.142s                  40m4.273s
sys     2m57.754s       2m58.583s                  3m17.430s
===========================================================

Time duration for kernel compilation ("make -j 8) on the same system, when
kernel is not probed.
=========================
real    9m26.389s
user    40m8.775s
sys     2m7.283s
=========================

Signed-off-by: Srinivasa DS <srinivasa@in.ibm.com>
Signed-off-by: Jim Keniston <jkenisto@us.ibm.com>
Acked-by: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
Cc: Anil S Keshavamurthy <anil.s.keshavamurthy@intel.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Masami Hiramatsu <mhiramat@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-25 10:53:30 -07:00
Thomas Petazzoni 2d6ffcca62 inflate: refactor inflate malloc code
Inflate requires some dynamic memory allocation very early in the boot
process and this is provided with a set of four functions:
malloc/free/gzip_mark/gzip_release.

The old inflate code used a mark/release strategy rather than implement
free.  This new version instead keeps a count on the number of outstanding
allocations and when it hits zero, it resets the malloc arena.

This allows removing all the mark and release implementations and unifying
all the malloc/free implementations.

The architecture-dependent code must define two addresses:
 - free_mem_ptr, the address of the beginning of the area in which
   allocations should be made
 - free_mem_end_ptr, the address of the end of the area in which
   allocations should be made. If set to 0, then no check is made on
   the number of allocations, it just grows as much as needed

The architecture-dependent code can also provide an arch_decomp_wdog()
function call.  This function will be called several times during the
decompression process, and allow to notify the watchdog that the system is
still running.  If an architecture provides such a call, then it must
define ARCH_HAS_DECOMP_WDOG so that the generic inflate code calls
arch_decomp_wdog().

Work initially done by Matt Mackall, updated to a recent version of the
kernel and improved by me.

[akpm@linux-foundation.org: coding-style fixes]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Cc: Matt Mackall <mpm@selenic.com>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
Cc: Mikael Starvik <mikael.starvik@axis.com>
Cc: Jesper Nilsson <jesper.nilsson@axis.com>
Cc: Haavard Skinnemoen <hskinnemoen@atmel.com>
Cc: David Howells <dhowells@redhat.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Acked-by: Paul Mundt <lethal@linux-sh.org>
Acked-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-25 10:53:28 -07:00
David Woodhouse ff877ea80e Merge branch 'linux-next' of git://git.infradead.org/~dedekind/ubi-2.6 2008-07-25 10:40:14 -04:00
Linus Torvalds ecc8b655b3 Merge branch 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'timers-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  nohz: adjust tick_nohz_stop_sched_tick() call of s390 as well
  nohz: prevent tick stop outside of the idle loop
2008-07-24 12:55:01 -07:00
Linus Torvalds 7540081c6b Merge branch 'semaphore' of git://git.kernel.org/pub/scm/linux/kernel/git/willy/misc
* 'semaphore' of git://git.kernel.org/pub/scm/linux/kernel/git/willy/misc:
  Remove __DECLARE_SEMAPHORE_GENERIC
  Remove asm/semaphore.h
  Remove use of asm/semaphore.h
  Add missing semaphore.h includes
  Remove mention of semaphores from kernel-locking
2008-07-24 12:24:40 -07:00
Linus Torvalds c54554d388 Merge branch 'for-linus' of git://git.o-hand.com/linux-rpurdie-leds
* 'for-linus' of git://git.o-hand.com/linux-rpurdie-leds:
  leds: Ensure led->trigger is set earlier
  leds: Add support for Philips PCA955x I2C LED drivers
  leds: Fix sparse warnings in leds-h1940 driver
  leds: mark led_classdev.default_trigger as const
  leds: fix unsigned value overflow in atmel pwm driver
  leds: Add pca9532 platform data for Thecus N2100
  leds: Add pca9532 led driver
2008-07-24 12:16:02 -07:00
Andrea Righi 27ac792ca0 PAGE_ALIGN(): correctly handle 64-bit values on 32-bit architectures
On 32-bit architectures PAGE_ALIGN() truncates 64-bit values to the 32-bit
boundary. For example:

	u64 val = PAGE_ALIGN(size);

always returns a value < 4GB even if size is greater than 4GB.

The problem resides in PAGE_MASK definition (from include/asm-x86/page.h for
example):

#define PAGE_SHIFT      12
#define PAGE_SIZE       (_AC(1,UL) << PAGE_SHIFT)
#define PAGE_MASK       (~(PAGE_SIZE-1))
...
#define PAGE_ALIGN(addr)       (((addr)+PAGE_SIZE-1)&PAGE_MASK)

The "~" is performed on a 32-bit value, so everything in "and" with
PAGE_MASK greater than 4GB will be truncated to the 32-bit boundary.
Using the ALIGN() macro seems to be the right way, because it uses
typeof(addr) for the mask.

Also move the PAGE_ALIGN() definitions out of include/asm-*/page.h in
include/linux/mm.h.

See also lkml discussion: http://lkml.org/lkml/2008/6/11/237

[akpm@linux-foundation.org: fix drivers/media/video/uvc/uvc_queue.c]
[akpm@linux-foundation.org: fix v850]
[akpm@linux-foundation.org: fix powerpc]
[akpm@linux-foundation.org: fix arm]
[akpm@linux-foundation.org: fix mips]
[akpm@linux-foundation.org: fix drivers/media/video/pvrusb2/pvrusb2-dvb.c]
[akpm@linux-foundation.org: fix drivers/mtd/maps/uclinux.c]
[akpm@linux-foundation.org: fix powerpc]
Signed-off-by: Andrea Righi <righi.andrea@gmail.com>
Cc: <linux-arch@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24 10:47:21 -07:00
Johannes Weiner 3560e249ab bootmem: replace node_boot_start in struct bootmem_data
Almost all users of this field need a PFN instead of a physical address,
so replace node_boot_start with node_min_pfn.

[Lee.Schermerhorn@hp.com: fix spurious BUG_ON() in mark_bootmem()]
Signed-off-by: Johannes Weiner <hannes@saeureba.de>
Cc: <linux-arch@vger.kernel.org>
Signed-off-by: Lee Schermerhorn <lee.schermerhorn@hp.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24 10:47:20 -07:00
Johannes Weiner 9109fb7b35 mm: drop unneeded pgdat argument from free_area_init_node()
free_area_init_node() gets passed in the node id as well as the node
descriptor.  This is redundant as the function can trivially get the node
descriptor itself by means of NODE_DATA() and the node's id.

I checked all the users and NODE_DATA() seems to be usable everywhere
from where this function is called.

Signed-off-by: Johannes Weiner <hannes@saeurebad.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24 10:47:16 -07:00
Johannes Weiner b61bfa3c46 mm: move bootmem descriptors definition to a single place
There are a lot of places that define either a single bootmem descriptor or an
array of them.  Use only one central array with MAX_NUMNODES items instead.

Signed-off-by: Johannes Weiner <hannes@saeurebad.de>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Richard Henderson <rth@twiddle.net>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Tony Luck <tony.luck@intel.com>
Cc: Hirokazu Takata <takata@linux-m32r.org>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Kyle McMartin <kyle@parisc-linux.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: David S. Miller <davem@davemloft.net>
Cc: Yinghai Lu <yhlu.kernel@gmail.com>
Cc: Christoph Lameter <cl@linux-foundation.org>
Cc: Mel Gorman <mel@csn.ul.ie>
Cc: Andy Whitcroft <apw@shadowen.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24 10:47:14 -07:00
David Brownell 9483a578df add HAVE_CLK to Kconfig, for driver dependencies
Flag platforms as HAVE_CLK (or not) in Kconfig, based on whether they
support <linux/clk.h> calls, so that otherwise portable drivers which need
those calls can list that dependency.

Something like this is a prerequisite for merging the musb_hdrc driver,
currently used on platforms including Davinci, OMAP2430, OMAP3xx ...  and
the discrete TUSB6010 chip, which doesn't have a natural platform
dependency.  (Used with OMAP 2420 in current Nokia N8x0 tablets.)

Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: Russell King <rmk@arm.linux.org.uk>
Acked-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Paul Mundt <lethal@linux-sh.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24 10:47:13 -07:00
Matthew Wilcox 6310e47271 Remove use of asm/semaphore.h
Change to use linux/semaphore.h

Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
2008-07-24 08:31:00 -04:00
Lennert Buytenhek 81600eea98 mv643xx_eth: use auto phy polling for configuring (R)(G)MII interface
The mv643xx_eth hardware has a provision for polling the PHY's
MII management registers to obtain the (R)(G)MII interface speed
(10/100/1000) and duplex (half/full) and pause (off/symmetric)
settings to use to talk to the PHY.

The driver currently does not make use of this feature.  Instead,
whenever there is a link status change event, it reads the current
link parameters from the PHY, and programs those parameters into
the mv643xx_eth MAC by hand.

This patch switches the mv643xx_eth driver to letting the MAC
auto-determine the (R)(G)MII link parameters by PHY polling, if there
is a PHY present.  For PHYless ports (when e.g. the (R)(G)MII
interface is connected to a hardware switch), we keep hardcoding the
MII interface parameters.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-07-24 06:22:59 +02:00
Linus Torvalds 30d38542ec Merge branch 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm
* 'devel' of master.kernel.org:/home/rmk/linux-2.6-arm: (85 commits)
  [ARM] pxa: add base support for PXA930 Handheld Platform (aka SAAR)
  [ARM] pxa: add base support for PXA930 Evaluation Board (aka TavorEVB)
  [ARM] pxa: add base support for PXA930 (aka Tavor-P)
  [ARM] Update mach-types
  [ARM] pxa: make littleton to use the new smc91x platform data
  [ARM] pxa: make zylonite to use the new smc91x platform data
  [ARM] pxa: make mainstone to use the new smc91x platform data
  [ARM] pxa: make lubbock to use new smc91x platform data
  [NET] smc91x: prepare SMC_USE_PXA_DMA to be specified in platform data
  [NET] smc91x: prepare for SMC_IO_SHIFT to be a platform configurable variable
  [NET] smc91x: add SMC91X_NOWAIT flag to platform data
  [NET] smc91x: favor the use of SMC91X_USE_* instead of SMC_CAN_USE_*
  [NET] smc91x: remove "irq_flags" from "struct smc91x_platdata"
  [ARM] 5146/1: pxa2xx: convert all boards to call pxa2xx_transceiver_mode helper
  Support for LCD on e740 e750 e400 and e800 e-series PDAs
  E-series UDC support
  PXA UDC - allow use of inverted GPIO for pullup
  Add e350 support
  Fix broken e-series build
  E-series GPIO / IRQ definitions.
  ...
2008-07-23 18:24:08 -07:00
Jason Wessel 5cbad0ebf4 kgdb: support for ARCH=arm
This patch adds the ARCH=arm specific a kgdb backend, originally
written by Deepak Saxena <dsaxena@plexity.net> and George Davis
<gdavis@mvista.com>.  Geoff Levand <geoffrey.levand@am.sony.com>,
Nicolas Pitre, Manish Lachwani, and Jason Wessel have contributed
various fixups here as well.

The KGDB patch makes one change to the core ARM architecture such that
the traps are initialized early for use with the debugger or other
subsystems.

[ mingo@elte.hu: small cleanups. ]
[ ben-linux@fluff.org: fixed early_trap_init ]

Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
Acked-by: Deepak Saxena <dsaxena@plexity.net>
2008-07-23 11:30:15 -05:00
Riku Voipio 30be048679 leds: Add pca9532 platform data for Thecus N2100
Thecus N2100 has leds and a buzzer attached to a pca9532 controller.  Attach
the driver to the i2c bus and define the pca9532 pin coniguration for this
platform in n2100_leds.

With this patch, support for N2100 should be complete in mainline Linux.

Signed-off-by: Riku Voipio <riku.voipio@iki.fi>
Acked-by: Lennert Buytenhek <buytenh@wantstofly.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Richard Purdie <rpurdie@rpsys.net>
2008-07-23 09:49:56 +01:00
Kay Sievers 3f9787046e arm: bus_id -> dev_name() and dev_set_name() conversions
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-07-21 21:55:03 -07:00
Andi Kleen 4a0b2b4dbe sysdev: Pass the attribute to the low level sysdev show/store function
This allow to dynamically generate attributes and share show/store
functions between attributes. Right now most attributes are generated
by special macros and lots of duplicated code. With the attribute
passed it's instead possible to attach some data to the attribute
and then use that in shared low level functions to do different things.

I need this for the dynamically generated bank attributes in the x86
machine check code, but it'll allow some further cleanups.

I converted all users in tree to the new show/store prototype. It's a single
huge patch to avoid unbisectable sections.

Runtime tested: x86-32, x86-64
Compiled only: ia64, powerpc
Not compile tested/only grep converted: sh, arm, avr32

Signed-off-by: Andi Kleen <ak@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-07-21 21:55:02 -07:00
Greg Kroah-Hartman fc3a8828b1 driver core: fix a lot of printk usages of bus_id
We have the dev_printk() variants for this kind of thing, use them
instead of directly trying to access the bus_id field of struct device.

This is done in order to remove bus_id entirely.

Cc: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-07-21 21:54:53 -07:00
Kay Sievers aab0de2451 driver core: remove KOBJ_NAME_LEN define
Kobjects do not have a limit in name size since a while, so stop
pretending that they do.

Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-07-21 21:54:52 -07:00
Dmitry Baryshkov 1fe532685a ARM: support generic per-device coherent dma mem
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Cc: Russell King <rmk@arm.linux.org.uk>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2008-07-18 21:14:01 +02:00
Ingo Molnar 9b610fda0d Merge branch 'linus' into timers/nohz 2008-07-18 19:53:16 +02:00
Thomas Gleixner b8f8c3cf0a nohz: prevent tick stop outside of the idle loop
Jack Ren and Eric Miao tracked down the following long standing
problem in the NOHZ code:

	scheduler switch to idle task
	enable interrupts

Window starts here

	----> interrupt happens (does not set NEED_RESCHED)
	      	irq_exit() stops the tick

	----> interrupt happens (does set NEED_RESCHED)

	return from schedule()
	
	cpu_idle(): preempt_disable();

Window ends here

The interrupts can happen at any point inside the race window. The
first interrupt stops the tick, the second one causes the scheduler to
rerun and switch away from idle again and we end up with the tick
disabled.

The fact that it needs two interrupts where the first one does not set
NEED_RESCHED and the second one does made the bug obscure and extremly
hard to reproduce and analyse. Kudos to Jack and Eric.

Solution: Limit the NOHZ functionality to the idle loop to make sure
that we can not run into such a situation ever again.

cpu_idle()
{
	preempt_disable();

	while(1) {
		 tick_nohz_stop_sched_tick(1); <- tell NOHZ code that we
		 			          are in the idle loop

		 while (!need_resched())
		       halt();

		 tick_nohz_restart_sched_tick(); <- disables NOHZ mode
		 preempt_enable_no_resched();
		 schedule();
		 preempt_disable();
	}
}

In hindsight we should have done this forever, but ... 

/me grabs a large brown paperbag.

Debugged-by: Jack Ren <jack.ren@marvell.com>, 
Debugged-by: eric miao <eric.y.miao@gmail.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2008-07-18 18:10:28 +02:00
Ingo Molnar 1a781a777b Merge branch 'generic-ipi' into generic-ipi-for-linus
Conflicts:

	arch/powerpc/Kconfig
	arch/s390/kernel/time.c
	arch/x86/kernel/apic_32.c
	arch/x86/kernel/cpu/perfctr-watchdog.c
	arch/x86/kernel/i8259_64.c
	arch/x86/kernel/ldt.c
	arch/x86/kernel/nmi_64.c
	arch/x86/kernel/smpboot.c
	arch/x86/xen/smp.c
	include/asm-x86/hw_irq_32.h
	include/asm-x86/hw_irq_64.h
	include/asm-x86/mach-default/irq_vectors.h
	include/asm-x86/mach-voyager/irq_vectors.h
	include/asm-x86/smp.h
	kernel/Makefile

Signed-off-by: Ingo Molnar <mingo@elte.hu>
2008-07-15 21:55:59 +02:00
Ben Dooks 0c17e4ceed Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6 into for-rmk 2008-07-15 20:19:14 +01:00
Linus Torvalds af5329cdf5 Merge branch 'core/stacktrace' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip
* 'core/stacktrace' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip:
  generic-ipi: powerpc/generic-ipi tree build failure
  stacktrace: fix build failure on sparc64
  stacktrace: export save_stack_trace[_tsk]
  stacktrace: fix modular build, export print_stack_trace and save_stack_trace
  backtrace: replace timer with tasklet + completions
  stacktrace: add saved stack traces to backtrace self-test
  stacktrace: print_stack_trace() cleanup
  debugging: make stacktrace independent from DEBUG_KERNEL
  stacktrace: don't crash on invalid stack trace structs
2008-07-15 10:31:35 -07:00
Ben Dooks 2bc7509f62 [ARM] S3C24XX: s3c243xx_clock_register() data can be __initdata
Any data being passed to s3c243xx_clock_register() can be
marked as __initdata as it is an array of pointers to
'struct clk' that are to be registered on initialisation.

The s3c243xx_clock_register function uses this array to
register clocks and does not require it to stay around
after exit.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-15 17:17:48 +01:00
Linus Torvalds 85082fd7cb Merge branch 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm
* 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm: (241 commits)
  [ARM] 5171/1: ep93xx: fix compilation of modules using clocks
  [ARM] 5133/2: at91sam9g20 defconfig file
  [ARM] 5130/4: Support for the at91sam9g20
  [ARM] 5160/1: IOP3XX: gpio/gpiolib support
  [ARM] at91: Fix NAND FLASH timings for at91sam9x evaluation kits.
  [ARM] 5084/1: zylonite: Register AC97 device
  [ARM] 5085/2: PXA: Move AC97 over to the new central device declaration model
  [ARM] 5120/1: pxa: correct platform driver names for PXA25x and PXA27x UDC drivers
  [ARM] 5147/1: pxaficp_ir: drop pxa_gpio_mode calls, as pin setting
  [ARM] 5145/1: PXA2xx: provide api to control IrDA pins state
  [ARM] 5144/1: pxaficp_ir: cleanup includes
  [ARM] pxa: remove pxa_set_cken()
  [ARM] pxa: allow clk aliases
  [ARM] Feroceon: don't disable BPU on boot
  [ARM] Orion: LED support for HP mv2120
  [ARM] Orion: add RD88F5181L-FXO support
  [ARM] Orion: add RD88F5181L-GE support
  [ARM] Orion: add Netgear WNR854T support
  [ARM] s3c2410_defconfig: update for current build
  [ARM] Acer n30: Minor style and indentation fixes.
  ...
2008-07-14 16:06:58 -07:00
Russell King 53ffe3b440 [ARM] Merge most of the PXA work for initial merge
This includes PXA work up to the SPI changes for the initial merge,
since e172274ccc depends on the SPI
tree being merged.

Conflicts:

	arch/arm/configs/em_x270_defconfig
	arch/arm/configs/xm_x270_defconfig
2008-07-14 23:34:46 +01:00
Russell King 044e5f45e4 Merge branch 'pxa' into devel
Conflicts:

	arch/arm/configs/em_x270_defconfig
	arch/arm/configs/xm_x270_defconfig
2008-07-13 12:05:49 +01:00
Eric Miao faf64ed496 [ARM] pxa: add base support for PXA930 Handheld Platform (aka SAAR)
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-13 12:05:22 +01:00
Eric Miao bae033111c [ARM] pxa: add base support for PXA930 Evaluation Board (aka TavorEVB)
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-13 12:05:22 +01:00
Eric Miao 5d31e43589 [ARM] pxa: add base support for PXA930 (aka Tavor-P)
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-13 12:05:21 +01:00
Russell King 9d9f6d2733 [ARM] Update mach-types
This update is required for Tavor and SAAR

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-13 12:05:21 +01:00
Eric Miao e1719da689 [ARM] pxa: make littleton to use the new smc91x platform data
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Acked-by: Nicolas Pitre <nico@cam.org>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-12 21:52:41 +01:00
Eric Miao 88c36eb73e [ARM] pxa: make zylonite to use the new smc91x platform data
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Acked-by: Nicolas Pitre <nico@cam.org>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-12 21:52:41 +01:00
Eric Miao 38fd6c3846 [ARM] pxa: make mainstone to use the new smc91x platform data
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Acked-by: Nicolas Pitre <nico@cam.org>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-12 21:52:41 +01:00
Eric Miao 3aed74cdea [ARM] pxa: make lubbock to use new smc91x platform data
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Acked-by: Nicolas Pitre <nico@cam.org>
Acked-by: Jeff Garzik <jgarzik@pobox.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-12 21:52:41 +01:00
Russell King 37d7035da5 Merge branch 'pxa-devel' into pxa 2008-07-12 21:43:51 +01:00
Dmitry Baryshkov 0fc3ff31f1 [ARM] 5146/1: pxa2xx: convert all boards to call pxa2xx_transceiver_mode helper
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-12 21:43:45 +01:00
Russell King 5a58d4bb66 Merge branch 'eseries' into pxa
Conflicts:

	arch/arm/mach-pxa/Makefile
2008-07-12 21:43:36 +01:00
Russell King 7fecc34e07 Merge branch 'pxa-tosa' into pxa
Conflicts:

	arch/arm/mach-pxa/Kconfig
	arch/arm/mach-pxa/tosa.c
	arch/arm/mach-pxa/spitz.c
2008-07-12 21:43:01 +01:00
Russell King a9da4f7ed6 Merge branches 'pxa-ian' and 'pxa-xm270' into pxa
Conflicts:

	MAINTAINERS
2008-07-12 21:42:04 +01:00
David Woodhouse a8931ef380 Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6 2008-07-11 14:36:25 +01:00
Ian Molton ac25361098 Support for LCD on e740 e750 e400 and e800 e-series PDAs
Signed-off-by: Ian Molton <spyro@f2s.com>
2008-07-10 20:17:27 +01:00
Ian Molton 32584c86b2 E-series UDC support
Signed-off-by: IAn Molton <spyro@f2s.com>
2008-07-10 20:16:35 +01:00
Ian Molton b3d354b8d8 Add e350 support
Signed-off-by: Ian Molton <spyro@f2s.com>
2008-07-10 20:15:05 +01:00
Ian Molton 877e03d4ae Fix broken e-series build
Signed-off-by: Ian Molton <spyro@f2s.com>
2008-07-10 20:15:01 +01:00
Russell King 67f5cd0f6a Merge branches 'pxa-ezx', 'pxa-magician' and 'pxa-palm' into pxa 2008-07-10 19:50:38 +01:00
Mark Brown d6c47417a4 [ARM] 5112/1: PXA SSP: Strip in-code changelog
It's not been updated in quite some time and we now have git for
history.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 17:07:46 +01:00
Mark Brown 919dcb2111 [ARM] 5110/1: PXA SSP: Remember the platform device on probe()
pdev is used later on by dev_printk() so must be set.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 17:07:36 +01:00
Mark Brown bbae02035a [ARM] 5108/2: PXA SSP: Don't unconditionally free interrupt
Callers may stop the SSP core requesting the interrupt so it can't be
freed unconditionally.  Also use NO_IRQ like we should.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 17:07:36 +01:00
Russell King f0006314d3 Merge branch 'imx' into devel
Conflicts:

	arch/arm/mm/Kconfig
2008-07-10 16:41:50 +01:00
Russell King a177ba3b7a Merge branches 'at91', 'dyntick', 'ep93xx', 'iop', 'ixp', 'misc', 'orion', 'omap-reviewed', 'rpc', 'rtc' and 's3c' into devel 2008-07-10 16:38:50 +01:00
Dmitry Baryshkov 0c5d5b7044 [ARM] 5171/1: ep93xx: fix compilation of modules using clocks
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 14:50:21 +01:00
Stefan Schmidt 79c410db66 [ARM] 5169/1: Defconfig for the EZX machines
This defconfig enables all currently available features. It also builds one
zImage which runs on all machines.

Signed-off-by: Antonio Ospite <ao2@openezx.org>
Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 14:38:40 +01:00
Stefan Schmidt 9ab24e4ef0 [ARM] 5162/1: Common code for the Motorola EZX GSM phones
Common code for the different EZX GSM phones. Functions to control framebuffer,
backlight power, OHCI and UART init.

Signed-off-by: Stefan Schmidt <stefan@datenfreihafen.org>
Signed-off-by: Daniel Ribeiro <drwyrm@gmail.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 13:44:55 +01:00
Marek Vašut d4b19c42ca [ARM] 5155/1: PalmTX battery monitor
This patch adds battery monitoring driver for PalmTX.
It can read voltage from the battery and temperature.
It also monitors charging/discharging status.

Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 12:15:32 +01:00
Marek Vašut 359784084f [ARM] 5154/1: PalmTX PCMCIA
This patch adds PCMCIA support for PalmTX handheld computer.
There is one chip hard-soldered to slot0, another slot is
not in use and not accessible.

Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 12:15:32 +01:00
Marek Vašut b5e4ad57ee [ARM] 5153/1: Add support for PalmTX handheld computer
PalmTX is PXA27x based device with wifi, bluetooth,
touchscreen, sdio slot, irda, keypad, nand flash,
pxa framebuffer, serial and usb gadget interface.

Supported by this patch is pxafb, touchscreen, irda,
keypad and sdio slot.

Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 12:15:31 +01:00
sedji gaouaou 3ef8191f43 [ARM] 5133/2: at91sam9g20 defconfig file
at91sam9g20 defconfig file

Signed-off-by: Sedji Gaouaou <sedji.gaouaou@atmel.com>
Signed-off-by: Justin Waters <justin.waters@timesys.com>
Acked-by: Andrew Victor <linux@maxim.org.za>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 12:13:48 +01:00
sedji gaouaou 613526677a [ARM] 5130/4: Support for the at91sam9g20
Support for the at91sam9g20 : Atmel 400Mhz ARM 926ej-s SOC.

AT91sam9g20 is an evolution of the at91sam9260 with a faster clock
speed.
We created a new board for this device but based the chip support
directly on 9260 files with little updates.
Here is the chip page on Atmel wabsite:
http://atmel.com/dyn/products/product_card.asp?part_id=4337

Signed-off-by: Sedji Gaouaou <sedji.gaouaou@atmel.com>
Signed-off-by: Justin Waters <justin.waters@timesys.com>
Acked-by: Andrew Victor <linux@maxim.org.za>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-10 12:13:47 +01:00
Ingo Molnar bac0c9103b Merge branch 'tracing/ftrace' into auto-ftrace-next 2008-07-10 11:43:00 +02:00
Ian Molton 13f7558237 Clocklib: Fix SA1111 clock name mess.
This patch uses the ability of PXA's clocklib to alias clock to resolve the
problem caused by sharing the SA1111 IO controller between PXA and SA1100
architectures, which have differing GPIO numbering.

Signed-off-by: Ian Molton <spyro@f2s.com>
2008-07-10 10:28:49 +01:00
Ian Molton ed847782f6 Clocklib: Provide for GPIO 12 clock on PXA
Signed-off-by: Ian Molton <spyro@f2s.com>
2008-07-10 10:28:43 +01:00
Ian Molton aa9ae8eb1a Fix serial broken-ness on PXA250
PXA255 and 26x are the only PXA CPUs with HWUART. This patch prevents bogus
initialisation on other models.

Signed-off-by: Ian Molton <spyro@f2s.com>
2008-07-10 10:28:36 +01:00
Arnaud Patard 63f385cd1f [ARM] 5160/1: IOP3XX: gpio/gpiolib support
This patch brings support for gpio/gpiolib framework to Intel IOP3xx
platforms.

Signed-off-by: Arnaud Patard <arnaud.patard@rtp-net.org>
Acked-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 23:31:42 +01:00
Patrice Vilchez 16074b669e [ARM] at91: Fix NAND FLASH timings for at91sam9x evaluation kits.
New timings are based on application note
"NAND Flash Support on AT91SAM9 Microcontrollers" available at
http://atmel.com/dyn/resources/prod_documents/doc6255.pdf).

Signed-off-by: Patrice Vilchez <patrice.vilchez@atmel.com>
Acked-by: Andrew Victor <linux@maxim.org.za>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 22:16:00 +01:00
Eric Miao 20072fd0c9 [ARM] pxa: add support for L2 outer cache on XScale3
The initial patch from Lothar, and Lennert make it into a cleaner
one, modified and tested on PXA320 by Eric Miao.

This patch moves the L2 cache operations out of proc-xsc3.S into
dedicated outer cache support code.

CACHE_XSC3L2 can be deselected so no L2 cache specific code will be
linked in, and that L2 enable bit will not be set, this applies to
the following cases:

    a. _only_ PXA300/PXA310 support included and no L2 cache wanted
    b. PXA320 support included, but want L2 be disabled

So the enabling of L2 depends on two things:

    - CACHE_XSC3L2 is selected
    - and L2 cache is present

Where the latter is only a safeguard (previous testing shows it works
OK even when this bit is turned on).

IXP series of processors with XScale3 cannot disable L2 cache for the
moment since they depend on the L2 cache for its coherent memory, so
IXP may always select CACHE_XSC3L2.

Other L2 relevant bits are always turned on (i.e. the original code
enclosed by #if L2_CACHE_ENABLED .. #endif), as they showed no side
effects. Specifically, these bits are:

   - OC bits in TTBASE register (table walk outer cache attributes)
   - LLR Outer Cache Attributes (OC) in Auxiliary Control Register

Signed-off-by: Lothar WaÃ<9f>mann <LW@KARO-electronics.de>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:33 +01:00
Eric Miao 5c9f50e90e [ARM] pxa: add simple gpio debug LEDs support for zylonite
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:33 +01:00
Eric Miao a1f7fc48c1 [ARM] pxa: add GPIO expander (PCA9539) support for zylonite
And also reserve 32 IRQs for the two GPIO expanders.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:33 +01:00
Eric Miao 9c1db1a133 [ARM] pxa: add pxa3xx NAND support for littleton
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Cc: Sergey Podstavin <spodstavin@ru.mvista.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:33 +01:00
Eric Miao 481b55262e [ARM] pxa: add pxa3xx NAND support for zylonite
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Cc: Sergey Podstavin <spodstavin@ru.mvista.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:33 +01:00
Eric Miao 9ae819a819 [ARM] pxa: add pxa3xx NAND device and clock sources
A pxa3xx_set_nand_info() is also introduced to set the PXA3xx NAND
driver specific platform_data structure pointer.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Cc: Sergey Podstavin <spodstavin@ru.mvista.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:32 +01:00
Eric Miao 7c3ada4f7c [ARM] pxa: move pxa310 specific MMC3 clk out of generic pxa3xx.c
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:32 +01:00
eric miao 7a2c5cb0e2 [ARM] pxa: make PXA3xx_CK() and PXA3xx_CKEN() public in clock.h
So processor specific clock sources can be defined in pxa300.c
and pxa320.c.

Signed-off-by: eric miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:32 +01:00
Eric Miao 566b450c33 [ARM] pxa: add pxa2xx_mfp_set_lpm() to facilitate low power state change
Some boards want to change low power state of pins on-the-fly, this
function helps to facilitate that operation instead of switching
back-n-forth between two configurations with pxa2xx_mfp_config().

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Tested-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:32 +01:00
Eric Miao 0fedb0cad6 [ARM] pxa: introduce dedicated __mfp_validate() to check PXA2xx MFP
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Tested-by: Robert Jarzmik <robert.jarzmik@free.fr>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:32 +01:00
Eric Miao d4a678080e [ARM] pxa: embed body of pxa320_init_mfp()
pxa320_init_mfp() is simple enough to be embedded into pxa320_init()
to simplify the code a bit.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:32 +01:00
Eric Miao b18773d545 [ARM] pxa: remove WAKEUP_ON_LEVEL_HIGH from keypad direct keys
Setting PKWR bits on those pins will make the resuming from
low power state to fail.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:31 +01:00
Eric Miao 36caeb4ec1 [ARM] pxa: fix typo of CONFIG_*_MODULE
The correct macro name when a driver is built as a module is
CONFIG_*_MODULE instead of CONFIG_*_MODULES. This patch fixes
this in several places.

Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:31 +01:00
Eric Miao 8a6e887360 [ARM] pxa: use IORESOURCE_IRQ_* instead of IRQF_* for IRQ resource
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:31 +01:00
Eric Miao 043dd64e5d [ARM] pxa: add codename zylonite for PXA3xx Development Platform
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:38:31 +01:00
Russell King f974a8ec96 Merge branch 'machtypes' into pxa-palm 2008-07-09 21:34:25 +01:00
Mike Rapoport 2f01a97372 [ARM] 5103/2: CM-X270: update core platform support
Convert CM-X270 pin configuration to use MFP tables.
Make device initialization dependent on respective driver CONFIG_ value (like
in zylonite).
Cleanup includes

Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:33:49 +01:00
Mike Rapoport 3c85bce6f8 [ARM] 5101/2: EM-X270 updates
Convert EM-X270 pin configuration to use MFP tables and gpio library
Make device initialization dependent on respective driver CONFIG_ value (like
in zylonite)
Add keypad and gpio_key devices

Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:33:49 +01:00
Philipp Zabel 14d1012db8 [ARM] 5138/1: magician: set pwm-backlight .id = -1
There will always be only one pwm-backlight on this device.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:33:23 +01:00
Philipp Zabel d0f7f1dff0 [ARM] 5137/1: magician: MACH_MAGICIAN doesn't need to depend on ARCH_PXA
It is only defined inside an "if ARCH_PXA ... endif" block, so the
depends on is not needed.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>?
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:33:22 +01:00
Philipp Zabel e277479aba [ARM] 5126/1: magician: remove superfluous mtd includes
These were only needed for hardcoded flash partition tables, which were
never submitted. It is better to have the bootloader pass the partition
table to the kernel instead.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:33:22 +01:00
Philipp Zabel 7a97010eb4 [ARM] 5125/1: magician: move gpio pin configuration into __initdata section
The pin configuration array is only used during board init.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:33:20 +01:00
Philipp Zabel e181191acd [ARM] 5119/1: magician: include linux/gpio.h instead of asm/gpio.h
Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:32:52 +01:00
Philipp Zabel ff27920278 [ARM] 5042/1: magician: request GPIOs for pda_power
Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:32:52 +01:00
Guennadi Liakhovetski 6a566fbbcc [ARM] 5095/2: pcm990: switch from pxa_gpio_mode to pxa2xx_mfp_config
pxa_gpio_mode() is deprecated, use the new pxa2xx_mfp_config() function to
configure GPIOs in pcm990 platform code. Convert "array, ARRAY_SIZE(array)"
to "ARRAY_AND_SIZE(array)" while at it.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@pengutronix.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:32:52 +01:00
Dmitry Baryshkov c0b8556f2f [ARM] 5143/1: pxa: further cleanup PXA Kconfig by removing one
unnecessary menu level

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:31:52 +01:00
Dmitry Baryshkov c7b4f5ba07 [ARM] 5142/1: pxa: move move zaurus declarations to proper place
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:31:52 +01:00
Guennadi Liakhovetski e172274ccc [ARM] 5088/3: pxa2xx: add pxa2xx_set_spi_info to register pxa2xx-spi platform devices
Add a function to dynamically allocate and register pxa2xx-spi platform
devices, to be used by PXA2xx and PXA3xx based systems. Switch pcm027 and
lubbock to use it.

Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@pengutronix.de>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:31:52 +01:00
Mark Brown cabb352a64 [ARM] 5084/1: zylonite: Register AC97 device
The Zylonite has an AC97 subsystem on it so register the AC97 controller
device.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:31:51 +01:00
Mark Brown 9f19d63828 [ARM] 5085/2: PXA: Move AC97 over to the new central device declaration model
As well as moving all the device declarations to a single one in devices.c
this causes all platforms to register the I/O and interrupt resources for
the AC97 controller.

Cc: eric miao <eric.miao@marvell.com>
Cc: Mike Rapoport <mike@compulab.co.il>
Cc: Lennert Buytenhek <buytenh@wantstofly.org>
Cc: Jürgen Schindele <linux@schindele.name>
Cc: Juergen Beisert <jbe@pengutronix.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:31:51 +01:00
Philipp Zabel 7a85762043 [ARM] 5120/1: pxa: correct platform driver names for PXA25x and PXA27x UDC drivers
The pxa2xx_udc.c driver is renamed to pxa25x_udc.c (the platform
driver name changes from pxa2xx-udc to pxa25x-udc) and the
platform driver name of pxa27x_udc.c is fixed to pxa27x-udc.
pxa_device_udc in devices.c is split into pxa25x and pxa27x flavors
and the pxa27x_device_udc is enabled in pxa27x.c.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Acked-by: Nicolas Pitre <nico@cam.org>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>

Including from Ian Molton:

Fixes for mistakes left over from the PXA2{5,7}X UDC split.

Signed-off-by: Ian Molton <spyro@f2s.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 21:30:13 +01:00
Dmitry Baryshkov 918dbcba4e [ARM] 5145/1: PXA2xx: provide api to control IrDA pins state
Provide a set of functions to control state of pins dedicated to IrDA.

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 20:56:28 +01:00
Russell King 66a7f72d98 [ARM] pxa: remove pxa_set_cken()
pxa_set_cken() is now unused, remove it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 20:56:28 +01:00
Russell King fdc614e873 Merge branches 'pxa-misc', 'pxa-pwm' and 'pxa-multi' into pxa 2008-07-09 20:56:05 +01:00
Russell King bdb08cb2d3 [ARM] pxa: allow clk aliases
We need to support more than one name+device for a struct clk for a
small number of peripherals.  We do this by re-using struct clk alias
to another struct clk - IOW, if we find that the entry we're using is
an alias, we return the aliased entry not the one we found.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-09 20:54:14 +01:00
Saeed Bishara 188237e28d [ARM] Feroceon: don't disable BPU on boot
On Feroceon platforms that have a branch prediction unit, bit 11 of the
cp15 control register controls the BPU.  This patch keeps the old value
of this bit instead of always clearing it.

Signed-off-by: Saeed Bishara <saeed@marvell.com>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2008-07-07 18:38:24 -04:00
Martin Michlmayr 2e1117d307 [ARM] Orion: LED support for HP mv2120
The HP mv2120 has several LEDs that are controlled through gpio.
Export the health LED, the red SATA LEDs as well as two gpios
that control the brightness of _all_ LEDs to userland.  The
Ethernet and power LEDs can't be controlled through gpio and the
blue SATA LEDs are handled via the SATA driver.

Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2008-07-07 18:38:24 -04:00
Nicolas Pitre 6b5cdf0f6d [ARM] Orion: add RD88F5181L-FXO support
This patch adds support for the Marvell Orion-VoIP RD-88F5181L-FXO
Reference Design, and enables use of the ethernet, USB, Cardbus and
mini-PCIe ports.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
2008-07-07 18:38:24 -04:00
Lennert Buytenhek 7012913232 [ARM] Orion: add RD88F5181L-GE support
This patch adds support for the Marvell Orion-VoIP RD2-88F5181L-GE
Reference Design, and enables use of the ethernet, USB, Cardbus and
mini-PCIe ports.

Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-07-07 18:38:24 -04:00
Imre Kaloz 2f8209788d [ARM] Orion: add Netgear WNR854T support
Signed-off-by: Imre Kaloz <kaloz@openwrt.org>
Signed-off-by: Lennert Buytenhek <buytenh@marvell.com>
2008-07-07 18:38:23 -04:00
Russell King fa6868508a Merge branch 'machtypes' into orion 2008-07-07 22:21:34 +01:00
Ben Dooks 7ba06b17a1 [ARM] s3c2410_defconfig: update for current build
Update the s3c2410_defconfig for the current set of
added patches.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:05 +01:00
Ben Dooks a67557801a [ARM] Acer n30: Minor style and indentation fixes.
Minor style fixes.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:05 +01:00
Christer Weinigel 9a2ddb7866 [ARM] Acer n30: Hardware initialisation.
Initialise the hardware register settings on boot, to allow the
device to function correctly.

Signed-off-by: Christer Weinigel <christer@weinigel.se>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:04 +01:00
Christer Weinigel e43f238390 [ARM] Acer n30: LCD support.
This patch adds the configuration needed for the LCD display on the n30.

Signed-off-by: Christer Weinigel <christer@weinigel.se>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:04 +01:00
Christer Weinigel 9579087331 [ARM] Acer n30: Add support for n35 and related devices.
Add support for the Acer N35 and related devices.

Signed-off-by: Christer Weinigel <christer@weinigel.se>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:04 +01:00
Christer Weinigel 865cc639a6 [ARM] Acer n30: LED support.
Add support for the LEDs on the Acer N30.

Signed-off-by: Christer Weinigel <christer@weinigel.se>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:03 +01:00
Christer Weinigel 6206575002 [ARM] Acer n30: GPIO buttons support
Add support for the GPIO buttons on the Acer N30.

Signed-off-by: Christer Weinigel <christer@weinigel.se>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:03 +01:00
Christer Weinigel d088e5fe58 [ARM] Acer n30: USB bus pull-up support.
Add support for the USB D+ pull up on the Acer N30.  This is needed
for the USB gadget to work properly.

Signed-off-by: Christer Weinigel <christer@weinigel.se>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:03 +01:00
Christer Weinigel 196a047574 [ARM] Acer n30: Source file cleanups.
Clean up some junk from the official kernel.

The compile-command is something that's only useful for me personally
and doesn't belong in the mainstream kernel.

Signed-off-by: Christer Weinigel <christer@weinigel.se>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:02 +01:00
Ben Dooks 2e16c27aa3 [ARM] S3C2443: Add prediv clk and fix setting of h and p clocks
Update the S3C2443 clock support to add the prediv clock
that is sourced via a divider from msysclk. Also fix the
setting of p and h clocks from this prediv clock.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:02 +01:00
Ben Dooks ba7622a19f [ARM] S3C2443: Add armdiv and arm clocks
Add the armdiv and arm clocks to the S3C2443 clock
framework and ensure they are correctly setup.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:02 +01:00
Ben Dooks 29a7bcfd14 [ARM] S3C2443: Fix s3c2443_clkcon_enable_p() using wrong register.
s3c2443_clkcon_enable_p() was reading from the correct register
S3C2443_PCLKCON, but then writing the value back to the wrong
register S3C2443_HCLKCON.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:01 +01:00
Ramax Lo 66493c2d88 [ARM] AT2440EVB: Add DM9000A network controller support.
Add DM9000AEP network controller support for AT2440EVB.

Signed-off-by: Ramax Lo <ramaxlo@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-07 18:13:01 +01:00
Ramax Lo 4ab9897172 [ARM] S3C2440: Add AT2440EVB board support
Add basic support for AT2440EVB board based on Samsung S3C2440 SoC.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Ramax Lo <ramaxlo@gmail.com>
2008-07-07 18:13:01 +01:00
Russell King 66ee156078 Merge branches 'ns9x' and 'machtypes' into devel 2008-07-07 16:26:41 +01:00
Russell King 4ed4789693 [ARM] mach-types update
Update mach-types.  Remove invalid or incorrect entries.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 16:26:14 +01:00
Philipp Zabel f1b23586c1 [ARM] 5135/1: pxa: drop superfluous asm/arch/pxa2xx-gpio.h includes
Both i2c-pxa.c and irq.c still include pxa2xx-gpio.h although is is not
needed anymore.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:23:38 +01:00
Dmitry Baryshkov 0121702dba [ARM] 5151/1: Tosa: remove double inclusion of linux/delay.h
The patch applies to the linux-next tree.

Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com>
Acked-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:22:13 +01:00
Dmitry Baryshkov 16b32fd0a3 [ARM] 5150/1: Tosa: support built-in bluetooth power-up
The driver is pretty much generic and will be later shared with
a few other devices, like hx4700 ipaq.

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:22:10 +01:00
Dmitry Baryshkov 5289fecda0 [ARM] 5129/1: tosa: tmio-nand data
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:22:09 +01:00
Dmitry Baryshkov 53b14ea336 [ARM] 5099/1: Tosa: support AC-in detection.
Add support for ac-in via pda_power device.

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:22:05 +01:00
Dmitry Baryshkov bf0116e54e [ARM] 5097/1: Tosa: support TC6393XB device
Add definitions for Toshiba TC6393XB companion chip and register
the tc6393xb device.

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:22:02 +01:00
Dmitry Baryshkov b032fccca8 [ARM] 5083/2: Tosa: fix IrDA transciver powerup.
On tosa the tranciver LED isn't powered down if
the GPIO47 (STUART_TX) isn't configured as low-level.
Power it down if IrDA is off to save a bit of power.

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:21:59 +01:00
Dmitry Baryshkov debba222b2 [ARM] 5089/1: tosa: cleanup includes
Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:21:58 +01:00
Dmitry Baryshkov c4d5f8d43a [ARM] 5081/1: tosa: fix SD GPIOs
This changes SD-related GPIO names to be more informative,
and allocates two more SD-related GPIOs.

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:21:57 +01:00
eric miao c867155cde [ARM] 5064/1: pxa: explicitly specify tosa keyboard GPIOs' low power states to DRIVE_LOW
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Acked-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:21:56 +01:00
Dmitry Baryshkov 86159a98ad [ARM] 5048/2: Clean up tosa and spitz resetting
Use new reset_gpio to reset tosa and spitz PDAs.

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:21:54 +01:00
Philipp Zabel 4d1fe075e5 [ARM] 5069/1: pxa: include pxa2xx-regs.h in reset.c for RSCR
The RCSR definition was moved into pxa2xx-regs.h.

Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Acked-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:21:53 +01:00
Dmitry Baryshkov 75f10b465a [ARM] 5047/2: Support resetting by asserting GPIO pin
This adds support for resetting via assertion of GPIO pin.
This e.g. is used on Sharp Zaurus SL-6000.

Signed-off-by: Dmitry Baryshkov <dbaryshkov@gmail.com>
Acked-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-07 13:21:52 +01:00
Juergen Beisert 1bd55a436f i.MX2 family: Add basic mach support
This patch adds basic mach support for the mx2 processor family, based
on the original freescale code and adapted to mainline kernel coding
style.

This part adds the global build only.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:03:02 +02:00
Juergen Beisert ff6552e4f3 i.MX27 family: Add the Phytec PCM970 evaluation board
The Phytec phyCORE-i.MX27 CPU module is delivered with the PCM970
baseboard by default. This patch adds support for the hardware.

This code is only an empty stub; it is filled up with functionality
in a later patch series.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:03:01 +02:00
Juergen Beisert 7e5e9f5457 i.MX27: Adding PCM038 platform support
This patch adds support for the phyCORE-i.MX27 cpu module (aka pcm038).
It is as generic as possible in order to support any kind of baseboard.

Note: This CPU module implementation can't work without a baseboard
support. Baseboard support can be added by the PCM-970 (included in
this patch stack) or any custom variant.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:03:00 +02:00
Juergen Beisert 80eedae6f0 i.MX27: Add ADS platform support
This patch adds basic support for the Freescale MX27ADS reference board.
Currently only a serial console can be used.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:03:00 +02:00
Juergen Beisert c46f585651 i.MX2 family: Add clock handling for i.MX27 CPU
Internal clock path handling for the i.MX27 CPU.

Changed against the original Freescale code (and against clocklib for example):
 - clock rate is always calculated whenever one ask for the current rate.
   (means no "rate" member in the clock structure).
   So switching the PLL base frequency will propagate immediately to all
   other clocks that are depending on this frequency.

TODO:
 - Check if the i.MX21 CPU can share the same code.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:59 +02:00
Juergen Beisert f31405cc4c i.MX27 CPU: Add basic i.MX27 CPU support
Add basic i.MX27 CPU support

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:59 +02:00
Sascha Hauer 604cbadce2 MX2 add support for mx2 in i.MX serial driver
add support for mx2 in i.MX serial driver

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-05 10:02:58 +02:00
Juergen Beisert fc80a5e3d0 i.MX2 family: Add basic device support
This patch adds a few on-chip devices for i.MX21/i.MX27 procesors.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:57 +02:00
Juergen Beisert 32dc80c9cb i.MX2 family: Add basic mach support (headers)
This patch adds basic mach support for the mx2 processor family, based
on the original freescale code and adapted to mainline kernel coding
style.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:56 +02:00
Juergen Beisert eea643f7ff i.MX2 family: Add basic mach support (sources)
This patch adds basic mach support for the mx2 processor family, based
on the original freescale code and adapted to mainline kernel coding
style.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:56 +02:00
Juergen Beisert aa10abd381 i.MX2 family: Add GPIO multiplexing support
This patch adds GPIO multiplexing support for the imx1/mxc2
family of procesors.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:55 +02:00
Juergen Beisert 259bcaae9a MXC arch: Simplify architecture's irq sources
Simplify architecture's irq headers and sources, to share these files
between MXC3 and MXC2.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:54 +02:00
Juergen Beisert 9e8a30dce1 MX3: Adapt mx31lite to new timer init style
This patch converts the external "add_mx31lite-basic_defconfig.diff" to our
MXC implementation.

Note: This patch fixes a board reference only.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:53 +02:00
Daniel Mack 9a4cd7a5c8 MX3: Add basic support for LogicPD i.MX31 LiteKit
This patch adds basic support for i.MX31 LiteKit by LogicPD.
With printascii() in kernel/printk.c, it boots right into the
rootfs-panic.

Note: This is a modified version of Daniel's patch to fit into this patch
stack.

> On 09.06.2008, at 17:26, Russell King - ARM Linux wrote:
>
> > I would much prefer it if board specific includes were included by the
> > code which needs them rather than in asm/arch/hardware.h.  With the
> > device model, drivers shouldn't need to include any board specific
> > includes - only the board specific C file should need it.
>
> The new version of this patch (#5102) has been uploaded to the patch
> tracker this morning.

Signed-off-by: Daniel Mack <daniel@caiaq.de>

-- 
 arch/arm/configs/mx31litekit_defconfig    | 1100 ++++++++++++++++++++++++++++++
 arch/arm/mach-mx3/Kconfig                 |    7 
 arch/arm/mach-mx3/Makefile                |    1 
 arch/arm/mach-mx3/mx31lite.c              |   96 ++
 include/asm-arm/arch-mxc/board-mx31lite.h |   38 +
 include/asm-arm/arch-mxc/debug-macro.S    |    3 
 6 files changed, 1245 insertions(+)
2008-07-05 10:02:53 +02:00
Sascha Hauer ce8ffef0bf MX31: add basic pcm037 board support
This patch adds basic board support for phytecs pmc037 board.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-05 10:02:52 +02:00
Juergen Beisert 1b53218bfa i.MX3: Add a basic default config for the imx31ads (reference only)
Currently there is a mx31ads BSP file in the kernel, but no default
config file.

This patch adds a basic default config for the imx31ads but it is for test
purposes only to ensure the i.MX2 patch stack doesn't break the i.MX3.

Note: For reference only. This configuration is untested as I have
no access to an mx31ads.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:51 +02:00
Juergen Beisert d0f349fbce i.MXC family: Adding timer support
This patch adds timer support for the i.MX machine family. This code can
be used on the following machs:

 - i.MX1 (tested)
 - i.MX2 (i.MX21 (to be tested), i.MX27 (tested))
 - i.MX3 (i.MX31 (tested))

TODO: It seems impossible to build a kernel for more than one CPU because the
timer do not follow the platform device rules. So it does only work if
timer 1 can be accessed on all CPUs at the same address.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-05 10:02:50 +02:00
Sascha Hauer 90292ea60f MXC: add io multiplexing functions for mx3
This patch adds functions to use the io multiplexer on mx3 platforms.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-05 10:02:50 +02:00
Juergen Beisert 07bd1a6cc7 MXC arch: Add gpio support for the whole platform
This patch bases on the one from Daniel Mack. The most important change to
Daniel's patch is to be more generic. This gpio routine supports at least
the i.MX27 and i.MX31 processors.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
Acked-by: Daniel Mack <daniel@caiaq.de>
2008-07-05 10:02:49 +02:00
Sascha Hauer e3d13ff4b9 mxc: add MX3 support for i.MX internal UART driver
This patch adds MX3 support for the i.MX internal uart driver.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-05 10:02:48 +02:00
Sascha Hauer df1bf4bdb2 i.MX3: introduce clock API
This patch introduces the clock API for for arch-mxc

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-05 10:02:48 +02:00
Juergen Beisert c0db2ea4e3 MXC family: Add clock handling
Internal clock path handling for the mxc CPUs.

Changed against the original Freescale code (and against clocklib for example):
 - clock rate is always calculated whenever one ask for the current rate
   (means struct clk has no more a member called "rate"). So switching the PLL
   base frequency will propagate immediately to all other clocks that are
   depending on this frequency.

Signed-off-by: Juergen Beisert <j.beisert@pengutronix.de>
2008-07-05 10:02:47 +02:00
Sascha Hauer 38a41fdf94 IMX: introduce clock API
This patch introduces the clock API for i.MX and converts all
in-Kernel drivers to use it.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-05 10:02:46 +02:00
Sascha Hauer dbff4e9ea2 IMX UART: remove statically initialized tables
This patch removes the statically initialized tables from the i.MX serial
driver and makes the driver fully dependent on the information provided by
the platform_device.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-05 10:02:45 +02:00
Sascha Hauer 63dd10846d MXC: do not include board specific header from architecture include
do not include board-mx31ads.h from hardware.h, instead include it
directly only where needed.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-07-05 10:02:43 +02:00
Ben Dooks b497549a03 [ARM] S3C24XX: Split serial driver into core and per-cpu drivers
The S3C2410 serial driver in drivers/serial/s3c2410.c has been
growing bigger with the addition of more variants of this hardware
with the growing Samsung SoCs range. As such, it would be
easier to split this code up into a core and per-cpu drivers to
make driver addition easier, and the core smaller.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:31 +01:00
Ben Dooks 6fc601e37b [ARM] S3C24XX: PWM API support.
Add support for PWM in the S3C24XX series of SoC via the
PWM API.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:30 +01:00
Matthieu Castet d5c52922b6 [ARM] S3C2412: Correct parents for EREFCLK and UREFCLK
For s3c2412, set parent for clk_erefclk and clk_urefclk.
This allow for example to use xtal or extclk for i2s clock.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Signed-off-by: Matthieu Castet <matthieu.castet@parrot.com>
2008-07-03 16:51:30 +01:00
Ben Dooks 9c3871ca59 [ARM] VR1000: Add tmp101 to list of I2C devices on the board
Add tmp101 support via the new style I2C driver registration
on the VR1000.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:29 +01:00
Ben Dooks 7a28db6146 [ARM] ANUBIS: Add i2c device list to Simtec Anubis
Add i2c board info initialiser to setup the list of
I2C devices present on an Simtec Anubis.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:29 +01:00
Ben Dooks 60d6698bb3 [ARM] VR1000: Add i2c device list to Thorcom VR1000
Add i2c board intialisers to specify the I2C devices
attached on the Thorcom VR1000.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:29 +01:00
Ben Dooks 042cf0f21f [ARM] BAST: Add i2c device list on Simtec Bast
Add i2c boardinfo for the connected i2c devices on the
Simtec Bast.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:28 +01:00
Ben Dooks f337422147 [ARM] OSIRIS: Add i2c device list to Simtec Osiris
Add an i2c board information initialisers to the board
to define which devices are present.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:28 +01:00
Ben Dooks 9d529c6e7b [ARM] S3C24XX: Add physmap device for all Simtec NOR equiped boards.
Move to using the physmap platform device code to attached NOR
flash on Simtec boards so that the old bast-flash driver can be
safely removed.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:28 +01:00
Ben Dooks b9db83af69 [ARM] ANUBIS: Move to using ata_platform driver (libata)
Change the (as yet unused) IDE bus on the Simtec Anubis board
to use pata_platform and thus libata to provide IDE support.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:27 +01:00
Ben Dooks b7a12d1923 [ARM] BAST/VR1000: Move to using ata_platform (libata)
Use the pata_platform driver to provide the IDE port
drivers on the Simntec BAST and Thorcom VR1000 machines
as a precursor to removing drivers/ide/arm/bast-ide.c

This will mean that the system will need SCSI and SCSI disc
support as a minimum, and any references to hdX will be
changed to sdX.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:27 +01:00
Ben Dooks dd1086f43d [ARM] JIVE: Add power off on shutdown support
Add pm_power_off hook to allow the Logitech Jive to shutdown
when asked to halt.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:27 +01:00
Ben Dooks d10d8a5f79 [ARM] JIVE: Add i2c device info for LIS302DL sensor
Add i2c bus definition for the LIS302DL sensor driver
which is connected on the i2c bus.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:26 +01:00
Ben Dooks fd2de272b2 [ARM] JIVE: Add board definitions for audio
Add board definitions for the audio device connected
on the Logitech Jive.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:26 +01:00
Ben Dooks c2c1708f9d [ARM] JIVE: Add LCD display setup information
Add the setup information for the LCD display
connected to the device.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:25 +01:00
Ben Dooks a2ed406515 [ARM] JIVE: Add SPI bus definitions for LCD controller
Add the definitions for the VGG2432A4 intelligent
LCD display conneected via an GPIO-based SPI bus
on the Logitech Jive.

Signed-of-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:25 +01:00
Ben Dooks 0f99263cda [ARM] JIVE: Add setup information for the S3C2412 LCD controller
Setup the video controller information for the Jive.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:25 +01:00
Ben Dooks 54c272acd1 [ARM] JIVE: Initialise the sleep configuration registers
Ensure that the S3C2412 sleep configuration registers
are approriately setup so that the device can safely
go to sleep.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:24 +01:00
Ben Dooks 9db829f485 [ARM] JIVE: Initial machine support for Logitech Jive
This is the base machine support for the Logitech Jive
machine.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:24 +01:00
Ben Dooks b999f0db94 [ARM] S3C24XX: Support for PWM timer clocks via clk_* API
Add support for the PWM timer clock routing via the
standard clk_ API.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:23 +01:00
Ben Dooks f348a2a281 [ARM] S3C24XX: Add gpiolib support
Add support for gpilib on all S3C24XX platforms.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:23 +01:00
Ben Dooks ed9137f103 [ARM] S3C24XX: s3c2410_defconfig: enable USB subset of drivers
Enable a subset of USB drivers which are useful for
using on these devices.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:22 +01:00
Ben Dooks 328dce1fa0 [ARM] S3C24XX: s3c2410_defconfig: add SCSI support
Enable SCSI support, mainly to help with adding
USB storage support later and for the imminent
changes for libata.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:22 +01:00
Ben Dooks 186eb08b8b [ARM] S3C24XX: s3c2410_defconfig: update networking options
Add the following to the networking confgiuration:

1) Packet socket support (useful for userland dhcp)
2) Add bluetooth and USB bluetooth drivers as modules
3) Add basic IPv6 support as modules.
4) Add the wireless core as modules.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:21 +01:00
Ben Dooks d947ae5721 [ARM] S3C24XX: s3c2410_defconfig: update miscellaneous options
Add some basic config filesystem, ensure errors are verbose
by default.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:21 +01:00
Ben Dooks fa941dc986 [ARM] S3C24XX: s3c2410_defconfig: update filesystem options
Enable new filesystem options, such as:

- JFFS2 summary nodes
- Ext2/3 externed options
- Standard CDROM filesystems

Also add NTFS as a module.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:20 +01:00
Ben Dooks a373473a90 [ARM] S3C24XX: s3c2410_defconfig: enable useful NLS options
Enable some useful NLS codepages to be built into
the kernel, and build the rest as modules.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:20 +01:00
Ben Dooks d951f55d6a [ARM] S3C24XX: s3c2410_defconfig: update list of used drivers
Update the drivers built, such as the SM501 and
parallel port.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:20 +01:00
Ben Dooks 0acaff300f [ARM] S3C24XX: s3c2410_defconfig: update to rc8
Update the s3c2410_defconfig to rc8

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2008-07-03 16:51:19 +01:00
Ben Dooks 9cf345e399 [ARM] S3C2410: Fix flags on DM9000 resources on BAST and VR1000
Fix the flags entries for the DM9000 IRQ entries on both the
Simtec BAST and Thorcom VR1000 board. The current entries use
the IRQF_ flags, but we should be using the IORESOURCE_IRQ_
definitions.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
PATCH FOLLOWS
KernelVersion: 2.6.26-rc5
2008-07-03 16:51:18 +01:00
Paulius Zaleckas f7def13ed0 [ARM] 5122/1: imx_dma_request_by_prio simpilfication
imx_dma_request_by_prio can return channel number by itself.
No need to supply variable address through parameters.

Also converted all drivers using this function.

Signed-off-by: Paulius Zaleckas <paulius.zaleckas@teltonika.lt>
Acked-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-07-03 16:39:57 +01:00