Commit Graph

8180 Commits

Author SHA1 Message Date
Hartley Sweeten ba7c6a3bcc ARM: 5953/1: ep93xx: fix broken build of clock.c
Patch 5879/1: ep93xx: define magic numbers for pll1 and pll2 broke
the ep93xx build due to one missing rename of EP93XX_SYSCON_CLOCK_SET2.
The correct name should be EP93XX_SYSCON_CLKSET2.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Acked-by: Ryan Mallon <ryan@bluewatersys.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-24 21:08:35 +00:00
Kukjin Kim d6d502fa4b ARM: 5952/1: ARM: MM: Add ARM_L1_CACHE_SHIFT_6 for handle inside each ARCH Kconfig
Add ARM_L1_CACHE_SHIFT_6 to arch/arm/Kconfig to allow CPUs with
L1 cache lines which are 64bytes to indicate this without having to
alter the arch/arm/mm/Kconfig entry each time.

Update the mm Kconfig so that ARM_L1_CACHE_SHIFT default value
uses this and change OMAP3 and S5PC1XX to select ARM_L1_CACHE_SHIFT_6.

Acked-by: Ben Dooks <ben-linux@fluff.org>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-24 21:07:22 +00:00
Paul Walmsley 7359154e94 OMAP hwmod: convert header files with static allocations into C files
Code should be able to #include any header file without the fear that
the header file will go allocating memory.  This is a coding style
issue, similar to commit 82e9bd5885.
Move the existing hwmod data from .h files to .c files.

While here, convert "omap34xx" to "omap3xxx" in the hwmod files, since
most of these structures should be reusable across all OMAP3 chips.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-24 12:29:45 -07:00
Paul Walmsley 50ebdac2ec OMAP hwmod: convert hwmod to use hardware clock names rather than clkdev dev+con
The OMAP hwmod core code is intended to use SoC IP block description
structures that are autogenerated from TI's OMAP hardware database.
Currently the hwmod code uses clkdev device + connection addressing to
identify clocks.  This causes problems in the hwmod autogeneration
process, since the TI hardware database doesn't use platform_device or
clkdev addressing; it uses a single clock signal name string, which
tends to bear some resemblance to what is used in the OMAP TRMs.  This
patch converts the hwmod code and existing data to use omap_clk_get_by_name(),
introduced in the previous patch.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-24 12:29:44 -07:00
Paul Walmsley 74be842743 OMAP clock: add omap_clk_get_by_name() for use by OMAP hwmod core code
The OMAP hwmod core code is intended to use SoC IP block description
structures that are autogenerated from TI's OMAP hardware database.
Currently the hwmod code uses clkdev device + connection addressing to
identify clocks.  This causes problems in the hwmod autogeneration
process, since the TI hardware database doesn't use platform_device or
clkdev addressing; it uses a single clock signal name string, which
tends to bear some resemblance to what is used in the OMAP TRMs.  This
patch adds a non-exported function to the OMAP clock code,
omap_clk_get_by_name().  A subsequent patch will convert the hwmod
code to use this function.

This function is for use only by core code, and practically, no other
code outside the hwmod code should need it.  Device driver code in the
kernel must not use this function, which is why it is not exported.
Drivers should use the appropriate clock alias provided by the clkdev
data structures, so driver code can be completely SoC-independent.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-24 12:29:43 -07:00
Vimarsh Zutshi e8d373779e OMAP3: clock: add capability to change rate of dpll4_m5_ck_3630
Add necessary clk_sel definitions to clock framework to allow changing
dpll4_m5_ck_3630 rate. This is used by the ISP driver.

Signed-off-by: Vimarsh Zutshi <vimarsh.zutshi@nokia.com>
[paul@pwsan.com: updated to apply]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:29:43 -07:00
Paul Walmsley 53c92d8f20 OMAP4 clock: drop the ALWAYS_ENABLED clock flag
Get rid of the ALWAYS_ENABLED clock flag - it doesn't actually do anything.
(The OMAP4 clock autogeneration scripts have been updated accordingly.)

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Rajendra Nayak <rnayak@ti.com>
Cc: Benoît Cousson <b-cousson@ti.com>
2010-02-24 12:29:43 -07:00
Paul Walmsley 51c1954162 OMAP clock: drop RATE_FIXED clock flag
The RATE_FIXED clock flag is pointless.  In the OMAP1 clock code, it
simply causes the omap1_clk_round_rate() function to return the
current rate of the clock.  omap1_clk_round_rate(), however, should
never be called for a fixed-rate clock, since none of these clocks
have a .round_rate function pointer set in their struct clk records.
Similarly, in the OMAP2+ clock code, the RATE_FIXED flag just causes
the clock code to emit a warning if the OMAP clock maintainer was
foolish enough to add a .round_rate function pointer to a fixed-rate
clock.  "Doctor, it hurts when I pretend that a fixed-rate clock is
rate-changeable."  "Then don't pretend that a fixed-rate clock is
rate-changeable."  It has no functional value.  This patch drops the
RATE_FIXED clock flag, removing it from all clocks that are so marked.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:29:43 -07:00
Paul Walmsley 8c34974ab0 OMAP2 clock: drop DELAYED_APP clock flag
All of the clocks that are marked with DELAYED_APP are changed as part
of the virt_prcm_set OPP virtual clock.  On 24xx, these clocks all
need to be changed as part of a group to keep the clock tree
functional - hence the need for the VALID_CONFIG bit, which is not
present on later OMAPs.  These clocks should not be rate-changed
independently.  So prevent these clocks from being changed
independently by dropping their .round_rate and .set_rate function
pointers.  It then turns out that the DELAYED_APP clock flag is no
longer useful, so drop it and the associated code and renumber the
clock flags.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:29:42 -07:00
Paul Walmsley 5173804fbb OMAP2430 clock: make func_96m_ck parent-selectable
func_96m_ck was incorrectly marked as being rate-selectable, when in
fact it is only parent-selectable.  Remove the .set_rate and .round_rate
function pointers for this clk.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:29:42 -07:00
Paul Walmsley 81b34fbecb OMAP2 clock: split OMAP2420, OMAP2430 clock data into their own files
In preparation for multi-OMAP2 kernels, split
mach-omap2/clock2xxx_data.c into mach-omap2/clock2420_data.c and
mach-omap2/clock2430_data.c.  2430 uses a different device space
physical memory layout than past or future OMAPs, and we use a
different virtual memory layout as well, which causes trouble for
architecture-level code/data that tries to support both.  We tried
using offsets from the virtual base last year, but those patches never
made it upstream; so after some discussion with Tony about the best
all-around approach, we'll just grit our teeth and duplicate the
structures.  The maintenance advantages of a single kernel config that
can compile and boot on OMAP2, 3, and 4 platforms are simply too
compelling.

This approach does have some nice benefits beyond multi-OMAP 2 kernel
support.  The runtime size of OMAP2420-specific and OMAP2430-specific
kernels is smaller, since unused clocks for the other OMAP2 chip will
no longer be compiled in.  (At some point we will mark the clock data
__initdata and allocate it during registration, which will eliminate
the runtime memory advantage.)  It also makes the clock trees slightly
easier to read, since 2420-specific and 2430-specific clocks are no
longer mixed together.

This patch also splits 2430-specific clock code into its own file,
mach-omap2/clock2430.c, which is only compiled in for 2430 builds -
mostly for organizational clarity.

While here, fix a bug in the OMAP2430 clock tree: "emul_ck" was
incorrectly marked as being 2420-only, when actually it is present on
both OMAP2420 and OMAP2430.

Thanks to Tony for some good discussions about how to approach this
problem.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:29:42 -07:00
Paul Walmsley 657ebfadc1 OMAP3/4 clock: split into per-chip family files
clock34xx_data.c now contains data for the OMAP34xx family, the
OMAP36xx family, and the OMAP3517 family, so rename it to
clock3xxx_data.c.  Rename clock34xx.c to clock3xxx.c, and move the
chip family-specific clock functions to clock34xx.c, clock36xx.c, or
clock3517.c, as appropriate.  So now "clock3xxx.*" refers to the OMAP3
superset.

The main goal here is to prepare to compile chip family-specific clock
functions only for kernel builds that target that chip family.  To get to
that point, we also need to add CONFIG_SOC_* options for those other
chip families; that will be done in future patches, planned for 2.6.35.

OMAP4 is also affected by this.  It duplicated the OMAP3 non-CORE DPLL
clkops structure.  The OMAP4 variant of this clkops structure has been
removed, and since there was nothing else currently in clock44xx.c, it
too has been removed -- it can always be added back later when there
is some content for it.  (The OMAP4 clock autogeneration scripts have been
updated accordingly.)

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
Cc: Ranjith Lohithakshan <ranjithl@ti.com>
Cc: Tony Lindgren <tony@atomide.com>
2010-02-24 12:16:15 -07:00
Paul Walmsley b92c170d01 OMAP clock: drop .id field; ensure each clock has a unique name
After the clkdev conversion, the struct clk.id field became
superfluous, so, drop it.  Bring the clock names closer to the TRMs
and ensure they are unique for debugfs.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:16:13 -07:00
Paul Walmsley f71eddb158 OMAP clock: compress clock flags down to a u8
There are now only eight OMAP clock flags, so renumber the flags to
fit in a u8 and shrink the size of struct clk.flags from a u32 to a
u8.  The intention is to save memory.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:15:06 -07:00
Paul Walmsley 1a3377176b OMAP2 clock: drop CONFIG_PARTICIPANT clock flag
It turns out that the only purpose of the CONFIG_PARTICIPANT clock
flag is to prevent omap2_clk_set_rate() and omap2_clk_set_parent()
from being executed on clocks with that flag set.  The rate-changing
component can be more directly accomplished by dropping the .set_rate
and .round_rate function pointers from those CONFIG_PARTICIPANT struct
clks.  As far as the parent-changing component is concerned, it turns
out that none of the CONFIG_PARTICIPANT clocks have multiple parent
choices, so all that is necessary is for omap2_clk_set_parent() to
bail out early if the new parent is equal to the old parent.
Implement this change and get rid of the flag, which has always had a
confusing name (it appears to be a Kconfig option, falsely).

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:15:04 -07:00
Paul Walmsley 17d092733d OMAP2xxx clock: drop DELAYED_APP flag from non-clksel clocks
The DELAYED_APP flag is effective only with clksel clocks, so drop it from
clocks that are not rate-changeable or that use non-clksel rate changing code
(e.g., virt_prcm_set).

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:15:04 -07:00
Paul Walmsley 94297784ee OMAP2xxx clock: GFX functional clock rates are not independently changeable
According to the OMAP242x TRM Rev X Figure 5-15 "Clock Output Control
- Functional Clocks 2", the GFX functional clocks should be marked
both DELAYED_APP and CONFIG_PARTICIPANT, meaning that their rates must
be reprogrammed as part of a larger OPP set change.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Richard Woodruff <r-woodruff2@ti.com>
2010-02-24 12:15:04 -07:00
Paul Walmsley c78a05e8e4 OMAP4 clock: drop the CLOCK_IN_OMAP4430 clock flag
The CLOCK_IN_OMAP4430 clock flag is not currently needed in the OMAP4
ES1 clock tree, and platform discrimination via clock flags is
deprecated in favor of the clkdev mechanism, so, drop it.  (The OMAP4
clock tree autogeneration script has been updated accordingly.)

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
2010-02-24 12:15:04 -07:00
Paul Walmsley 93340a2294 OMAP2/3/4 clock: fix DPLL multiplier value errors; also copyrights, includes, documentation
The maximum DPLL multiplier (M) values for OMAP2xxx and OMAP3xxx are
one increment higher than they should be.  See for example the
OMAP242x TRM Rev X Section 5.10.6 "Clock Generator Registers" and the
OMAP36xx TRM Rev C Table 3-202 "CM_CLKSEL1_PLL".  Programming a 0 into
the DPLL's M register bitfield is valid for OMAP2/3 and indicates that
the DPLL should enter MN-bypass mode.  Also, increase the minimum
multiplier (M) value for the DPLL rate rounding code from 1 to 2, to
ensure that it does not inadvertently put the DPLL into bypass.

Note that the register documentation in the OMAP2xxx and OMAP3xxx TRMs
does not make clear that the actual DPLL divider value (the "N") is
the content of the appropriate register bitfield for the N value,
_plus one_.  (In other words, an N register bitfield of 0 indicates a
DPLL divider value of 1.)  This is only clearly documented in the
OMAP4430 TRM, in, for example, OMAP4430 TRM Rev A Table 3-1167
"CM_CLKSEL_DPLL_USB".

While here, update copyrights, add kerneldoc for struct dpll_data,
drop the unused struct dpll_data.max_tolerance field, remove some
unnecessary #includes in DPLL-related code, and replace the #include
of <linux/module.h> with <linux/list.h>, which is what was really
needed.  The OMAP4 clock autogenerator script has been updated
accordingly.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Cc: Benoît Cousson <b-cousson@ti.com>
Cc: Rajendra Nayak <rnayak@ti.com>
2010-02-24 12:15:03 -07:00
Vishwanath BS 7356f0b26b OMAP3 clock: add support for 192Mhz DPLL4M2 output
In 3630, DPLL4M2 output can be 96MHz or 192MHz (for SGX to run at
192). This patch has changes to support this feature. 96MHz clock is
generated by dividing 192Mhz clock by 2 using CM_CLKSEL_CORE register.
SGX can select Core Clock, 192MHz clock or CM_96M_FCLK as it's
functional clock. In summary changes done are:
1. Added a feature called omap3_has_192mhz_clk and enabled for 3630
2. Added a new clock node called omap_192m_alwon_ck
3. Made omap_96m_alwon_fck to derive its clock from omap_192m_alwon_ck

Signed-off-by: Vishwanath BS <Vishwanath.bs@ti.com>
[paul@pwsan.com: fixed whitespace]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:15:03 -07:00
Vishwanath BS 678bc9a2ea OMAP3 clock: Introduce 3630 DPLL4 HSDivider changes
Divider (M2, M3, M4, M5 and M6) field width has been increased by 1 bit
in 3630. This patch has changes to accommodate this in CM dynamically
based on chip version.
Basically new clock nodes have been added for 3630 DPLL4 M2,M3,M4,M5 and
M6 and value of these nodes are used if cpu type is 3630.

Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
[paul@pwsan.com: updated to apply on 2.6.34 queue; comments added]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:15:03 -07:00
Richard Woodruff 358965d7ba OMAP3 clock: introduce DPLL4 Jtype
DPLL4 for 3630 introduces a changed block called j type dpll, requiring
special divisor bits and additional reg fields. To allow for silicons to
use this, this is introduced as a flag and is enabled for 3630 silicon.
OMAP4 also has j type dpll for usb.

Tested with 3630 ZOOM3 and OMAP3430 ZOOM2

Signed-off-by: Richard Woodruff <r-woodruff2@ti.com>
Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Vishwanath BS <Vishwanath.bs@ti.com>
[paul@pwsan.com: added some comments; updated copyrights and credits; fixed
 some style issues]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:15:02 -07:00
Abhijit Pagare 91808a81fe ARM: OMAP4 clock domain: Add check for avoiding dependency related update.
A check is added for avoiding the sleep/wakeup dependency updates
for OMAP4 as the structures for the dependencies are currently absent.

Signed-off-by: Abhijit Pagare <abhijitpagare@ti.com>
[paul@pwsan.com: added warnings, explanatory comment, copyright update]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:14:59 -07:00
Mike Turquette a7e069fc5a OMAP3630: Clock: Workaround for DPLL HS divider limitation
This patch implements a workaround for the DPLL HS divider limitation
in OMAP3630 as given by Errata ID: i556.

Errata:
When PWRDN bit is set, it resets the internal HSDIVIDER divide-by value (Mx).
The reset value gets loaded instead of the previous value.
The following HSDIVIDERs exhibit above behavior:
. DPLL4 : M6 / M5 / M4 / M3 / M2 (CM_CLKEN_PLL[31:26] register bits)
. DPLL3 : M3 (CM_CLKEN_PLL[12] register bit).

Work Around:
It is mandatory to apply the following sequence to ensure the write
value will
be loaded in DPLL HSDIVIDER FSM:
The global sequence when using PWRDN bit is the following:
. Disable Mx HSDIVIDER clock output related functional clock enable bits
        (in CM_FCLKEN_xxx / CM_ICLKEN_xxx)
. Enable PWRDN bit of HSDIVIDER
. Disable PWRDN bit of HSDIVIDER
. Read current HSDIVIDER register value
. Write different value in HSDIVIDER register
. Write expected value in HSDIVIDER register
. Enable Mx HSDIVIDER clock output related functional clocks
        (CM_FCLKEN_xxx / CM_ICLKEN_xxx)

Signed-off-by: Mike Turquette <mturquette@ti.com>
Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
Signed-off-by: Vijaykumar GN <vijaykumar.gn@ti.com>
[paul@pwsan.com: updated patch to apply; made workaround function static;
 marked as being 36xx-specific]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:06:00 -07:00
Thara Gopinath c23a97d377 OMAP: HWMOD: Add support for early device register into omap device layer
This patch adds support in omap device layer to register devices
as early platform devices. Certain devices needed during system boot up
like timers, gpio etc can be registered as early devices. This will
allow for them to be probed very early on during system boot up.
This patch adds a parameter is_early_device in omap_device_build.
Depending on this parameter a call to early_platform_add_devices
or platform_register_device is made.

Signed-off-by: Thara Gopinath <thara@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:58 -07:00
Thara Gopinath 358f0e630d OMAP3: hwmod: support to specify the offset position of various SYSCONFIG register bits.
In OMAP3 Some modules like Smartreflex do not have the regular sysconfig
register.Instead clockactivity bits are part of another register at a
different bit position than the usual bit positions 8 and 9.

In OMAP4, a new scheme is available  due to the new protocol
between the PRCM and the IPs. Depending of the scheme, the SYSCONFIG
bitfields position will be different.
The IP_REVISION register should be at offset 0x00.
It should contain a SCHEME field. From this we can determine whether
the IP follows legacy scheme or the new scheme.

31:30 SCHEME  Used to distinguish between old scheme and current.
 Read 0x0:  Legacy protocol.
 Read 0x1:  New PRCM protocol defined for new OMAP4 IPs

For legacy IP
 13:12 MIDLEMODE
 11:8  CLOCKACTIVITY
 6     EMUSOFT
 5     EMUFREE
 4:3   SIDLEMODE
 2     ENAWAKEUP
 1     SOFTRESET
 0     AUTOIDLE

For new OMAP4 IP's, the bit position in SYSCONFIG is (for simple target):
 5:4   STANDBYMODE (Ex MIDLEMODE)
 3:2   IDLEMODE (Ex SIDLEMODE)
 1     FREEEMU (Ex EMUFREE)
 0     SOFTRESET

Unfortunately In OMAP4 also some IPs will not follow any of these
two schemes. This is the case at least for McASP, SmartReflex
and some security IPs.

This patch introduces a new field sysc_fields in omap_hwmod_sysconfig which
can be used by the hwmod structures to specify the offsets for the
sysconfig register of the IP.Also two static structures
omap_hwmod_sysc_type1 and omap_hwmod_sysc_type2 are defined
which can be used directly to populate the sysc_fields if the IP follows
legacy or new OMAP4 scheme. If the IP follows none of these two schemes
a new omap_hwmod_sysc_fields structure has to be defined and
passed as part of omap_hwmod_sysconfig.

Signed-off-by: Thara Gopinath <thara@ti.com>
Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:58 -07:00
Vishwanath BS 5eb75f5578 OMAP3 clock: Remove FreqSel for 3630
DPLL_FREQSEL field in CLKEN_PLL register is no longer valid for
OMAP3630. So remove references to that.

Signed-off-by: Vishwanath BS <vishwanath.bs@ti.com>
Cc: Sergei Shtylyov <sshtylyov@mvista.com>
[paul@pwsan.com: added comment fix from Sergei Shtylyov]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:57 -07:00
Kevin Hilman 0cc9314eaf OMAP2/3: PRCM: fix misc. compiler warnings
- missing return in omap_prcm_get_reset_sources()
- potential use of uninitialized variable in omap_prcm_arch_reset()

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:56 -07:00
Sanjeev Premi a51ba28407 OMAP3 clock: Check return values for clk_get()
This patch checks if clk_get() returned success for
the clocks used in function omap2_clk_arch_init().

This version incorporates review comments from
Kevin Hilman and Paul Walmsley.

Signed-off-by: Sanjeev Premi <premi@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:56 -07:00
Ranjith Lohithakshan 3cc4a2fc2e AM35xx: Add clock support for new modules on AM35xx
This patch adds clock support for the following AM35xx modules
	- Ethernet MAC
	- CAN Controller (HECC)
	- New MUSB OTG Controller with integrated Phy
	- Video Processing Front End (VPFE)
	- Additional UART (UART4)

Signed-off-by: Ranjith Lohithakshan <ranjithl@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:55 -07:00
Ranjith Lohithakshan 419cc97d36 OMAP2/3 clock: Extend find_idlest() to pass back idle state value
Current implementation defines clock idle state indicators based on the
cpu information (cpu_is_omap24xx() or cpu_is_omap34xx()) in a system wide
manner. This patch extends the find_idlest() function in clkops to pass
back the idle state indicator for that clock, thus allowing idle state
indicators to be defined on a per clock basis if required.

This is specifically needed on AM35xx devices as the new IPSS clocks
indicates the idle status (0 is idle, 1 is ready) in a way just
opposite to how its handled in OMAP3 (0 is ready, 1 is idle).

Signed-off-by: Ranjith Lohithakshan <ranjithl@ti.com>
[paul@pwsan.com: updated to apply after commit 98c45457 et seq.]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:54 -07:00
Thara Gopinath cde08f81b1 OMAP3 PM: Adding counters for power domain logic off and mem off during retention.
This patch adds counters to keep track of whether the powerdomain
logic or software controllable memory banks are turned off when
the power domain enters retention. During power domain retention
if logic gets turned off, the scenario is known as Open Switch Retention.
Also during retention s/w controllable memory banks of a power
domain can be chosen to be kept in retention or off.

This patch adds one counter per powerdomain to track the power domain
logic state during retention. Number of memory bank state counters
added depends on the number of software controllable memory banks
of the powerdomain. To view these counters do
	cat ../debug/pm_debug/count

Signed-off-by: Thara Gopinath <thara@ti.com>
[paul@pwsan.com: conditional expressions simplified; counter increment
 code moved to its own function]
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:50 -07:00
Thara Gopinath 4133a44e28 OMAP3 PM: Defining .pwrsts_logic_ret field for core power domain structure
This patch adds the flag .pwrsts_logic_ret info for the core power domain
in the associated powerdomain structure. This flag specifies the states
core domain logic can hit in event of the domain entering retention.

Signed-off-by: Thara Gopinath <thara@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:50 -07:00
Thara Gopinath 1e3d0d2ba9 OMAP2/3 PM: Adding powerdomain APIs for reading the next logic and mem state
This patch adds APIs pwrdm_read_logic_retst and
pwrdm_read_mem_retst for reading the next programmed
logic and memory state a powerdomain is to hit in event
of the next power domain state being retention.
These are needed for OSWR support.

Signed-off-by: Thara Gopinath <thara@ti.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:49 -07:00
Tero Kristo b024b542c3 OMAP3: Clock: Added IDLEST definitions for SGX
Added definitions for OMAP3430ES2_ST_SGX_SHIFT and OMAP3430ES2_ST_SGX_MASK
as these were missing.

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:48 -07:00
Kevin Hilman dfa6d6f892 OMAP3: clock: use std _MASK suffix for CM_FCLKEN_IVA2 defines
Add _MASK suffix to CM_FCLKEN_IVA2 bitfieds to conform with the rest
of the usage in cm-regbits-34xx.h of using _SHIFT and _MASK suffixes.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:48 -07:00
Kevin Hilman 24d82e3421 OMAP: omap_device: when 'called from invalid state', print state
The omap_device_[enable|idle|shutdown] functions print a warning
when called from an invalid state.  Print the invalid state in
the warning messages.  This also uses __func__ to get the function
name.

Also, move the entire print string onto a single line to facilitate
grepping or error messages.  Recent discussions on LKML show
strong preference for grep-able code vs. strict 80 column limit.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:45 -07:00
Kevin Hilman 0007122ad8 OMAP: omap_device: add omap_device_is_valid()
The omap_device struct contains a 'struct platform_device'.  Normally,
converting a platform_device pointer to an omap_device pointer
consists of simply doing a container_of(), as is done currently by the
to_omap_device() macro.

However, if this is attempted when using platform_device that has not
been created as part of the omap_device creation, the container_of()
will point to a memory location before the platform_device pointer
which will contain random data.

Therefore, we need a way to detect valid omap_device pointers.  This
patch solves this by using the simple magic number approach.

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
2010-02-24 12:05:45 -07:00
Tomi Valkeinen 69b2048f44 OMAP: DSS2: move timing functions
Move check/set/get_timings() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 3651131268 OMAP: DSS2: move set/get_wss()
Move set/get_wss() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 37ac60e414 OMAP: DSS2: move enable/disable/suspend/resume
Move enable/disable/suspend/resume from omap_dss_device to
omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 18946f62c6 OMAP: DSS2: move update() and sync()
Move update() and sync() from omap_dss_device to omap_dss_driver.

Also, update was hardcoded to use virtual channel 0. This patch adds a
parameter that specifies the VC.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 446f7bff70 OMAP: DSS2: move set/get_update_mode()
Move set/get_update_mode() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:28 +02:00
Tomi Valkeinen 225b650d41 OMAP: DSS2: move enable/get_te()
Move enable/get_te() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen a269950405 OMAP: DSS2: move get_recommended_bpp()
Move get_recommended_bpp() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 96adceceed OMAP: DSS2: move get_resolution()
Move get_resolution() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen a2faee84f6 OMAP: DSS2: move enable/disable_channel to overlay manager
Move enable/disable_channel() from omap_dss_device to overlay manager.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 3f71cbe736 OMAP: DSS2: move wait_vsync()
Move wait_vsync() from omap_dss_device to overlay manager.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 87424e1bff OMAP: DSS2: move get/set_rotate()
Move get/set_rotate() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 8d8aa61dcf OMAP: DSS2: move set/get_mirror()
Move set/get_mirror() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen c75d9464c1 OMAP: DSS2: move memory_read()
Move memory_read() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:27 +02:00
Tomi Valkeinen 1a75ef422d OMAP: DSS2: move run_test()
Move run_test() from omap_dss_device to omap_dss_driver.

This is part of a larger patch-set, which moves the control from omapdss
driver to the display driver.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-24 14:31:26 +02:00
Baruch Siach 08268b78d6 mx25: move ARCH_MXC_IOMUX_V3 to the ARCH level
ARCH_MXC_IOMUX_V3 is not specific to the i.MX25 PDK platform. Thus,
ARCH_MXC_IOMUX_V3 should be selected by ARCH_MX25.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-24 10:45:21 +01:00
Fabio Estevam 82d52a1948 mx51_babbage: Fix ckih2 parameter in mx51_clocks_init function
This patch is to be applied into Sascha's mxc-master branch.

Fix ckih2 parameter in mx51_clocks_init funtion. CKIH2 pin is left unconnected on Babbage.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Acked-by: Amit Kucheria <amit.kucheria@canonical.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-24 10:29:14 +01:00
Mark Brown cd6eb9808c mx31ads: Configure SSI5 pins in IOMUX for PMIC module audio support
SSI5 on the CPU is connected to the PMIC module to provide audio support
so unconditionally configure the relevant pins on the CPU to route out
the signals.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-24 10:23:42 +01:00
Uwe Kleine-König bac3fcfad5 arm/imx/iomux-v1: check for invalid modes in mxc_gpio_mode
mxc_gpio_mode checks for invalid pins and so it returns zero for
success, -EINVAL for invalid pins.

While at it, remove definitions of GPIO_PORT_MAX removed as they are
unused now.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:16 +01:00
Uwe Kleine-König e835d88e71 arm/imx: let platform files include the SoC-specific iomux header
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:15 +01:00
Uwe Kleine-König 111588f830 arm/imx/iomux-v1: rename header file
Addionally make iomux-mx*.h headers stand-alone and similar to iomux-v3
platform files should include their platform iomux header from now on.
For now iomux.h simply includes all iomux-v1 platform headers and so
provides compatibility until all files are converted.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:15 +01:00
Uwe Kleine-König 261f6f681c arm/mx25: don't include iomux.h which is for iomux-v1 machines
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:14 +01:00
Uwe Kleine-König 2f6c97c48e arm/imx/iomux-mx3.h: unify style and comments
- use __MACH_IOMUX_MX3_H__ as header protector analogous to
  <mach/mx...h>
- use tabs for indention

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:13 +01:00
Uwe Kleine-König 8902cbd9db arm/imx/iomux-mx2x: unify style
- use __MACH_IOMUX_MX2x_H__ as header protector analogous to
  <mach/mx...h>
- use tabs for indention

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:12 +01:00
Uwe Kleine-König 6056154145 arm/imx/iomux-mx27: unify style and comments
- use __MACH_IOMUX_MX27_H__ as header protector analogous to
  <mach/mx...h>
- use tabs for indention
- fix sorting

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:12 +01:00
Uwe Kleine-König e76feb8742 arm/imx/iomux-mx25: unify style and comment cleanup
- use __MACH_IOMUX_MX25_H__ as header protector analogous to
  <mach/mx...h>
- remove doxygen comments
- remove #error about mach/iomux.h which is unused on mx25
- remove #ifndef __ASSEMBLY__ which is unneeded here

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:11 +01:00
Uwe Kleine-König 6985a719f9 arm/imx/iomux-mx21: unify style
- use __MACH_IOMUX_MX21_H__ as header protector analogous to
  <mach/mx...h>
- use tabs for indention

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:10 +01:00
Uwe Kleine-König 6863f19810 arm/imx/iomux-mx1: unify style and comment cleanup
- use __MACH_IOMUX_MX1_H__ as header protector analogous to
  <mach/mx...h>
- use tabs for indention

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:10 +01:00
Uwe Kleine-König f021b5a1ef arm/imx/iomux-v1: make base address a runtime choice
While at it move register modification to static inlines and
so make the relevant code more readable.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:09 +01:00
Uwe Kleine-König 5e2e95f520 arm/imx/iomux-v1: rename source file and reorganize Kconfig stuff
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:08 +01:00
Uwe Kleine-König 8735fde2d0 arm/imx/dma-v1: protect #ifdef'd blocks additionally by cpu_is_...
This is necessary for a multi-SoC kernel.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:07 +01:00
Uwe Kleine-König e9f49d4183 arm/imx/dma-v1: don't use deprecated symbols DMA_BASE and MXC_INT_DMACH0
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:06 +01:00
Uwe Kleine-König 8e3a6e7fa7 arm/imx: choose sane CONSISTENT_DMA_SIZE if video is enabled for both mx1 and mx3
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:06 +01:00
Uwe Kleine-König abf6163288 arm/imx/irq: order definitions of MXC_GPIO_IRQS numerically
This is important for kernels supporting more than one SoC.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:05 +01:00
Uwe Kleine-König 220f7f3070 arm/imx: don't depend on ARCH_MXC twice
MXC_IRQ_PRIOR, MXC_PWM and ARCH_HAS_RNGA are all defined in an "if
ARCH_MXC" ... "endif" block, so they depend on ARCH_MXC anyhow.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:04 +01:00
Uwe Kleine-König a8e33260ce arm/imx: remove #ifndef CONFIG_COMMON_CLKDEV block
COMMON_CLKDEV is used on all imx platforms, so this isn't used.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:03 +01:00
Uwe Kleine-König 44fb5d1945 arm/imx: remove MTD_XIP support
This is broken since at least one year when

	ec996ba (mxc timer: make compile time independent)

removed the symbol MXC_TCN.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:03 +01:00
Uwe Kleine-König 9f69fdb36d arm/imx: don't explicitly select GENERIC_GPIO
ARCH_REQUIRE_GPIOLIB selects GPIOLIB which in turn selects GENERIC_GPIO

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:02 +01:00
Uwe Kleine-König 03e09cd890 arm/imx: let ARCH_MXC select COMMON_CLKDEV instead of each subfamily
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:01 +01:00
Uwe Kleine-König 401d87dd66 arm/imx: remove "NO_PAD_CTRL" from Copyright statements
I assume this was introduced by something like

	sed -i -e 's/)/, NO_PAD_CTRL)'

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:00 +01:00
Uwe Kleine-König 8e9980588c arm/imx/audmux-v2: use SoC-prefixed names
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:07:00 +01:00
Uwe Kleine-König 51918075d7 arm/imx/audmux-v1: use SoC-prefixed names
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:06:59 +01:00
Uwe Kleine-König 6574305b0e arm/imx/gpio: remove a BUG_ON in hot path
Now if the problem occurs that triggered the BUG_ON before, the machine
runs in a NULL pointer dereference.  So it wouldn't be much harder now
to debug the situation if it occured.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:06:58 +01:00
Uwe Kleine-König 3621f188b9 arm/imx/gpio: use fls to find set bits in the irq status register
As in most cases only few irqs are pending using fls is more effective
than looping over all bits.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:06:57 +01:00
Uwe Kleine-König 3244c3e779 arm/imx: use generic_handle_irq instead of open-coding it
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:06:57 +01:00
Uwe Kleine-König 3d40f7fef4 arm/imx/gpio: GPIO_INT_{HIGH,LOW}_LEV are not necessarily constant
GPIO_INT_LOW_LEV is defined as

	(cpu_is_mx1_mx2() ? 0x3 : 0x0)

so depending on compiler optimisation and enabled SoCs this doesn't
qualify as a constant expression as needed by a switch statement.
Ditto for GPIO_INT_HIGH_LEV.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:06:56 +01:00
Uwe Kleine-König 4a50d00cb9 arm/mx2: split generic.c into mm-imx2[17].c
This removes some #ifdefs and prepares moving the files in a directory
with more than imx21 and imx27 support.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:06:55 +01:00
Uwe Kleine-König 621b0e53b5 arm/mx2/devices: no need for IMX_NEEDS_DEPRECATED_SYMBOLS any more
The previous commits cleaned up arch/arm/mach-mx2/devices.c such that it
doesn't rely on deprecated symbols any more.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:06:52 +01:00
Uwe Kleine-König 897359d596 arm/mx2: define seperate gpio port descriptions for imx21 and imx27
As the gpio ports have different addresses on imx21 and imx27 there are
two different port descriptions needed if not relying on the overloaded
cpp macro IO_ADDRESS.  So some cpp magic is added to minimize code
duplication.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:06:51 +01:00
Uwe Kleine-König 3636a14532 arm/mx2: use per-SOC nand device
The previous commit introduced one nand device per SoC.  Use this
directly instead of the compatibility macro that will break for
multi-SoC kernels.  And while at it remove the compatibility macro now
that all in-tree users are fixed.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
2010-02-24 10:05:38 +01:00
Tony Lindgren 0fdc54b201 Merge branch 'pm-2.6.34' of git://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-omap-pm into omap-for-linus 2010-02-23 19:22:48 -08:00
Jassi Brar 2e5070bc11 ARM: S3C64XX: Declare IISv4 PCLK for S3C6410
[Updated the device ID to -1 since there's only one IISv4 device but the
S3C clock API tries to match based on the ID of the requesting device
(and not the name) -- broonie.]

Signed-Off-by: Jassi Brar <jassi.brar@samsung.com>
[ben-linux@fluff.org: Fixed Jassi's lastname]
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 02:08:15 +00:00
Jassi Brar de6985be18 ARM: S3C64XX: Add AC97 platform resources
This patch defines the platform device and the resources: IRQ, DMA and MEM,
needed by the AC97 controller driver.

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 02:01:40 +00:00
Mark Brown 1f1008684a ARM: SMDK6410: Register IISv4 device
The IISv4 controller is connected to the WM8580 on the board.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:58:48 +00:00
Mark Brown a7a81d0bbd ARM: SMDK6410: Add support for PMIC LED on WM1192-EV1 PMIC module
The PMIC LED on the SMDK6410 CPU board is driven by GPIO4 of the
WM8312 PMIC. Provide software control of this LED.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:58:41 +00:00
Mark Brown 60f9101a88 ARM: SMDK6410: Add initial support for WM1192-EV1 PMIC board
The Wolfson Microelectronics 1192-EV1 is a plug in module for the
SMDK6410 providing power using a WM8312 PMIC. This patch provides
initial hookup sufficient to initialise the board, though not all
features are fully described yet.

As part of this supplies for the system that are provided as a
single supply by one of the currently merged PMIC boards are
factored out so they can be reused between different regulators.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:58:41 +00:00
Jassi Brar bc449e5312 ARM: S3C2443: GPIO: Correct AC97 pin defines
GPIO_E-[5,9] pin functionality was defined incorrectly.
The patch corrects and adds missing pins.

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:58:17 +00:00
Jassi Brar c2b2c645db ARM: SMDK2443: Enable AC97 device
Add AC97 controller to platform devices and initialize the AC97 gpios.

Signed-off-by: Jassi Brar <jassi.brar@samsung.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:58:17 +00:00
Kukjin Kim 03843a1294 ARM: S5P6442: Add serial port support
This patch adds UART serial port support for S5P6442.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:19 +00:00
Kukjin Kim 7f7035f21c ARM: S5P6442: Add S5P6442 configuration file
This patch adds S5P6442 default configuration file.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:18 +00:00
Kukjin Kim 461859db1f ARM: S5P6442: Add SMDK6442 board support file
This patch adds SMDK6442 board support file.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:18 +00:00
Kukjin Kim 550db7f155 ARM: S5P6442: Update Kconfig and Makefiles
Updates arch/arm Kconfig and Makefile for building the S5P6442 support.
Also modifies the plat-s5p Kconfig file to include the support for plat-s5p
for S5P6442.

Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:17 +00:00
Ben Dooks d13de2ab8a ARM: S5P6442: Add <mach/*.h> files missing from original commit
The removal of plat-s3c has left these missing from the initial commit,
so add copies from elsewhere.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:17 +00:00
Kukjin Kim d9f18a981b ARM: S5P6442: Add IRQ support
This patch adds IRQ support for S5P6442. This patch adds interrupt
register definitions, IRQ definitions for various interrupt sources
and new VIC base for VIC2 in plat-s5p common irq code.

Signed-off-by: Adityapratap Sharma <aditya.ps@samsung.com>
Signed-off-by: Atul Dahiya <atul.dahiya@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:16 +00:00
Kukjin Kim b6f837575e ARM: S5P6442: Add clock support for S5P6442
This patch adds clock support for S5P6442. This patch adds the clock
register definitions and the various system clocks in S5P6442.

Signed-off-by: Adityapratap Sharma <aditya.ps@samsung.com>
Signed-off-by: Atul Dahiya <atul.dahiya@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:15 +00:00
Kukjin Kim 5f7f6a4a0d ARM: S5P6442: Add Samsung S5P6442 CPU support
This patch adds support for Samsung S5P6442 CPU. This patch also adds
an entry for S5P6442 cpu in plat-s5p cpu table.

Signed-off-by: Adityapratap Sharma <aditya.ps@samsung.com>
Signed-off-by: Atul Dahiya <atul.dahiya@samsung.com>
Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:15 +00:00
Vasily Khoruzhick a0af8b3c70 ARM: SAMSUNG: adc: disable/enable IRQ on suspend/resume
IRQ should be disabled on suspend and re-enabled on resume.

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:14 +00:00
Vasily Khoruzhick 0fe1309b4d ARM: SAMSUNG: Add resources description for s3c24xx ts driver
Without resources description driver fails during initialization.

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:14 +00:00
Ben Dooks 7965b214bf ARM: SAMSUNG: Eliminate plat-s3c
The plat-s3c directory is now clear, so remove the files in it and
expunge it from the build process.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:13 +00:00
Ben Dooks f94327f2ce ARM: SAMSUNG: Move include/mach files out of plat-s3c
Move the include/mach files out of plat-s3c and into the relevant
machine files. This does mean copying the files, but there is nowhere
else to put them.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:12 +00:00
Ben Dooks ae5fa355ec ARM: SAMSUNG: Select NO_IOPORT for plat-samsung
All these platforms select NO_IOPORT, so move it to plat-samsung Kconfig

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:12 +00:00
Ben Dooks 46ba2a7284 ARM: S3C24XX: Move audio-simtec.h to plat-s3c24xx
Continue the clearout of plat-s3c by moving audio-simtec.h to plat-s3c24xx
as there are no current implementations outside of this platform.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:11 +00:00
Ben Dooks 89f1fa080b ARM: SAMSUNG: Move plat-s3c Kconfig entries to plat-samsung and plat-s3c24xx
Move the Kconfig entries from plat-s3c to plat-samsung and plat-s3c24xx
as necessary. The S3C_BOOT entries and the DMA configuration can go to
plat-samsung. The low-level UART configurations are currently S3C2XX
specific and can go to plat-s3c24xx.

Eliminating plat-s3c from the build process will be submitted seperately.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-24 01:52:06 +00:00
Rob Clark 8250a5c381 omap2/3/4: mailbox: use dedicated work queue for handling mailbox rx interrupt
keventd_wq is a shared work-queue, and should not be used when we
need fast deterministic response.  Instead mailbox driver should
use it's own private work-queue, with it's own thread, to ensure
that handling of RX interrupts are not delayed by other drivers.

The tasklet is still used for transmission of mbox messages.

Signed-off-by: Rob Clark <rob@ti.com>
Signed-off-by: C A Subramaniam <subramaniam.ca@ti.com>
Signed-off-by: Suman Anna <s-anna@ti.com>
Acked-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 15:29:22 -08:00
Suman Anna 4499ce4293 omap: mailbox: correct OMAP4 SIDLEMODE logic
OMAP4 mailbox has a different MAILBOX_SYSCONFIG register.
There is now no AutoIdle. The SIDLEMODE bits have been
right-shifted by 1 bit and now occupy bits 2 & 3.

Signed-off-by: Suman Anna <s-anna@ti.com>
Acked-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 15:29:22 -08:00
Suman Anna a6a6022871 omap: mailbox: correct OMAP4 reset logic
OMAP4 mailbox has a different register set. There is
no MAILBOX_SYSSTATUS register. The reset is indicated
with the SOFTRESET bit of the MAILBOX_SYSCONFIG register
itself. This bit should read 0 for a successful Reset.
Also, the SOFTRESET bit occupies bit0 and not bit1 as with
previous generations.

Signed-off-by: Suman Anna <s-anna@ti.com>
Acked-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 15:29:21 -08:00
Santosh Shilimkar 5772ca7d78 omap4: Use irq line defines from irq-44xx.h
This patch removes all the omap4 specific irq line
defines from plat/irqs.h and includes auto-generated
irqs-44xx.h
All the legacy naming style defines are replaced with the one
from irqs-44xx.h

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
[tony@atomide.com: updated to compile with usb-musb.c]
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 15:29:08 -08:00
Sebastien Requiem c499546f43 [ARM] MV78xx0: Support for Buffalo WXL (Terastation Duo)
* Modification of Kconfig to add the Option
* 1 new file : buffalo-wxl-setup.c
This file is inspired from the db-78xx0-setup.c already present.
The following is done:
  - Configure MPP Lines for the plateform (see my patch for MPP)
This is taken from the stock kernel provided by buffalotech (the vendor)
  - GigaBit Ethernet
  - Sata
  - Uart are initiallized in a different way than on the dev board as we
have one core only.
  - USB

The kernel has been running for some days now on my plateform.

Signed-off-by: Sebastien Requiem <sebastien@kolios.dk>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-23 17:10:08 -05:00
Santosh Shilimkar a99db248af omap4: Use dma line defines from dma-44xx.h
This patch removes all the omap4 specific dma request
lines defines from plat/dma.h and includes dma-44xx.h

The defines are aligned so no driver should be impacted
because of this change.

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 14:02:53 -08:00
Santosh Shilimkar e927f8d04e omap4: Add auto-generated irq and dma headers
These files are generated along with the HWMOD and will eventually be
in the existing header files as soon as all drivers will be migrate to
omap_hwmod / omap_device.

The dma-44xx.h and irqs-44xx.h file should be in
'arch/arm/mach-omap2/include/mach/', but omap1 and omap2plus common devices
still share these defines and hence currently placed in plat-omap/include/plat/
directory.

Signed-off-by: Benoit Cousson <b-cousson@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 14:02:52 -08:00
Sebastien Requiem ee40ceab23 [ARM] MV78XX0: MPP routines and definitions
This patch is composed of two new files :

- mpp.c which is mainly inspired by the same file as in mach-kirkwood

- mpp.h that is written from the documentation provided by Marvell
http://www.marvell.com/products/processors/embedded/discovery_innovation/HW_MV78100_OpenSource.pdf

Moreover, due to some implementation problem, I have
defined some MPPX_UNUSED that offer developers the possibility
to SET MPP to some unused value (such as for Buffalo WXL).

Note: This patch doesn't support MV78200 yet (only 78100 MPP lines have
been written)

Signed-off-by: Sebastien Requiem <sebastien@kolios.dk>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
2010-02-23 16:44:01 -05:00
John Holland d5b5746bed [ARM] eSATA SheevaPlug: correlate MPP to SD CD and SD WP
Accept SD CD and SD WP in accordance to
http://plugcomputer.org/data/docs/Sheeva-PowerPlug-V1.3-GTI-090906.pdf
on MPP 47 and 44 respectively on the eSATA SheevaPlug

Signed-off-by: John Holland <john.holland@cellent-fs.de>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
--
2010-02-23 16:44:01 -05:00
John Holland d7b222d708 [ARM] eSATA SheevaPlug: configure SoC SATA interface
Enable the kirkwood SATA SoC interface on the eSATA SheevaPlug.

Signed-off-by: John Holland <john.holland@cellent-fs.de>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
--
2010-02-23 16:44:01 -05:00
John Holland d8ecb34900 [ARM] eSATA SheevaPlug basic board support
Allow basic eSATA SheevaPlug board configuration and build.

Signed-off-by: John Holland <john.holland@cellent-fs.de>
Signed-off-by: Nicolas Pitre <nico@marvell.com>
--
2010-02-23 16:44:00 -05:00
Tero Kristo 79dcfdd407 OMAP3: PM: Added support for L2 aux ctrl register save and restore
This patch adds a save and restore mechanism for ARM L2 auxiliary control
register. The feature is enabled by default for GP devices, but for HS/EMU
devices the user must enable the service and define the PPA service ID to
be used for setting L2 aux ctrl, as this is not currently supported by the
bootloader. If nobody alters the contents of L2 aux ctrl from its reset
value, this feature is not needed.

Kconfig option to enable HS/EMU L2 aux save and restore:
- OMAP3_L2_AUX_SECURE_SAVE_RESTORE
Kconfig option to select HS/EMU PPA service for setting L2 aux ctrl:
- OMAP3_L2_AUX_SECURE_SERVICE_SET_ID

Signed-off-by: Tero Kristo <tero.kristo@nokia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-23 11:05:07 -08:00
Rajendra Nayak a89b6f0062 OMAP3: PM: add scratchpad locking function
This patch implements locking using the semaphore in scratchpad
memory preventing any concurrent access to scratchpad from OMAP
and Baseband/Modem processor.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-23 11:05:05 -08:00
Kalle Jokiniemi 5a1b1d3a9e OMAP3: RX-51: Pass cpu idle parameters
Pass cpuidle parameters for RX-51. Numbers based on
measurements made in October 2009 for PM optimized
kernel with CPU freq enabled. Assumes OPP2 (main
idle OPP, and worst case latencies).

Signed-off-by: Kalle Jokiniemi <kalle.jokiniemi@digia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-23 11:05:04 -08:00
Kevin Hilman a4b41d8ed8 OMAP3: RX-51: support sleep indicator LEDs
The sleep indicator LEDs can be enabled/disabled by toggling GPIO162.
Use the LED GPIO class to export this LED functionality to userspace.

To enable:

  # echo 1 > /sys/class/leds/sleep_ind/brightness

To disable:

  # echo 0 > /sys/class/leds/sleep_ind/brightness

Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-23 11:05:04 -08:00
Kalle Jokiniemi 709731bb36 OMAP3: cpuidle: Add valid field into C-state parameter passing
Different boards benefit differently from the available
seven C-states for cpu idle. In most cases, only few,
properly spaced (in terms of consumption and latency)
C-states are required to make the power management
optimal. Hence we need a possibility to pass which
C-states are actually used for each board.

So added the valid field to cpuidle_params and added
support to 3430sdp, which uses the paramenter passing.

Signed-off-by: Kalle Jokiniemi <kalle.jokiniemi@digia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-23 11:05:02 -08:00
Kevin Hilman bb4de3df69 OMAP3: cpuidle: configure latencies/thresholds from board file
The CPUidle C state latencies and thresholds are dependent on various
board specific details.  This patch makes it possible to configure
these values from the respective board files.

omap3_pm_init_cpuidle() can now be optionally called from board files
to pass board specific cpuidle parameters.  If the board files do not
use this function to pass the params default values are used which
might cause higher consumption dur to wrong state selection by the
governor.

This patch only updates the 3430sdp board files to use
omap3_pm_init_cpuidle().

From Kalle, in addition to original patch from Rajendra:

Building without CONFIG_CPU_IDLE or CONFIG_PM causes build to fail if
cpu idle parameters are tried to pass using omap3_pm_init_cpuidle
function.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Kalle Jokiniemi <kalle.jokiniemi@digia.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-23 11:05:01 -08:00
Sanjeev Premi 6af83b3861 OMAP3: cpuidle: Update statistics for correct state
When 'enable_off_mode' is 0, the target power state for MPU
and CORE was locally changed to PWRDM_POWER_RET but, the
statistics are updated for idle state originally selected
by the governor.

This patch 'invalidates' the idle states that lead either of
MPU or Core to PWRDM_POWER_OFF state when 'enable_off_mode'
is '0'. The states are valid once 'enable_off_mode' is set
to '1'.

Added function next_valid_state() to check if current state
is valid; else get the next valid state. It is called from
omap3_enter_idle_bm().

Signed-off-by: Sanjeev Premi <premi@ti.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
2010-02-23 11:05:00 -08:00
Santosh Shilimkar 8ca4582218 omap3/4: Remove overlapping mapping of L4_WKUP io space
This patch removes the L4 wakeup io mapping section for omap3
and omap4. L4 wakeup space is part of 4MB L4 space which is
already mapped and hence remove the overlapped mapping.

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 10:57:41 -08:00
Santosh Shilimkar 737daa0360 omap4: Fix omap_type() for omap4
This patch fixes the omap_type function to detect whether the device
is GP or HS

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 10:57:41 -08:00
Santosh Shilimkar 35c0dc389d omap: sdma: Limit the secure reserve channel fix for omap3
The commit 'ba50ea7e' reserves DMA channels 0 and 1 on high
security devices, in order to avoid collision between kernel
dma transfers and ROM code dma transfers.

This fix is applicable only for OMAP3 so add an appropriate
check.

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
CC: Kalle Jokiniemi <kalle.jokiniemi@digia.com>
CC: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 10:57:40 -08:00
Santosh Shilimkar 1ce0f9d4a9 omap4: sdma: Enable the idle modes on omap4
This patch enables smart-idle idlemodes and autoidle for sDMA
on OMAP4

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 10:57:40 -08:00
Santosh Shilimkar b7ebb10b0a omap2/3/4: ioremap omap_globals module
This is a clean-up patch towards dynamic allocation of IO space
instead of using harcoded macros to calculate virtual addresses.

Also update the sdrc, prcm and control module to allocate
iospace dynamically

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Reviewed-by: Kevin Hilman <khilman@deeprootsystems.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 10:57:40 -08:00
Santosh Shilimkar e03d37d859 omap3/4: uart: fix full-fifo write abort
This patch is addition to the already merged commit on non-empty
uart fifo read abort. "ce13d4716a276f4331d78ba28a5093a63822ab95"

OMAP3630 and OMAP4430 UART IP blocks have a restriction on TX FIFO
too. If you try to write to the tx fifo when it is full, the system aborts.

More details on this thread are here:
http://www.mail-archive.com/linux-omap@vger.kernel.org/msg19447.html

This can be easily reproducible by not suppressing interconnect errors or
long duration testing where continuous prints over console from multiple
threads. This patch is addressing the issue by ensuring that write is
not issued while fifo is full. A timeout is added to avoid any hang
on fifo-full for 10 mS which is unlikely case.

Patch is validated on OMAP3630 and OMAP4 SDP.

V2 version removed the additional 1 uS on every TX as per
Tony's suggestion

Signed-off-by: Woodruff Richard <r-woodruff2@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
CC: Ghorai Sukumar <s-ghorai@ti.com>
Reviewed-by: Paul Walmsley <paul@pwsan.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 10:57:40 -08:00
Santosh Shilimkar ae46ec7731 omap4: multi-omap: Allow build to work
The musb support is enabled in omap3 platforms. For omap4 only board
support is available and the driver still isn't supported.
Because of this build with omap3_defconfig used for multi-omap
doesn't work on omap4430 sdp.

This patch avoids usb_musb_init() by adding a cpu check
in the board file.

Thanks to Anand Gadiyar and Mankad Maulik for the suggestion
of patching board file instead of musb driver.

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 10:57:40 -08:00
Eero Nurkkala d912fa9255 McBSP: OMAP3: Add sidetone feature
Add sidetone feature to McBSP instances 2 and 3 on OMAP3 based devices.

Signed-off-by: Ilkka Koskinen <ilkka.koskinen@nokia.com>
Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com>
Acked-by: Liam Girdwood <lrg@slimlogic.co.uk>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Tested-by: Jarkko Nikula <jhnikula@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 10:57:39 -08:00
Maulik Mankad bce0668366 omap: musb: Add USB support to 4430 SDP board file
This patch adds support for Mentor USB to 4430 SDP board
file.

It also defines the base address for HS USB OTG controller
in OMAP4.

Also updates platform specfic structure with base address
and IRQ details.

Signed-off-by: Maulik Mankad <x0082077@ti.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: Felipe Balbi <felipe.balbi@nokia.com>
Cc: David Brownell <david-b@pacbell.net>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Cc: Olof Johansson <olof@lixom.net>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-23 10:57:39 -08:00
Kuninori Morimoto 41dcc17c73 ARM: mach-shmobile: pfc-sh7377: modify KEYIN settings
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-23 11:17:30 +09:00
Dominik Brodowski 3b7a17fcda resource/PCI: mark struct resource as const
Now that we return the new resource start position, there is no
need to update "struct resource" inside the align function.
Therefore, mark the struct resource as const.

Cc: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2010-02-22 16:16:57 -08:00
Dominik Brodowski b26b2d494b resource/PCI: align functions now return start of resource
As suggested by Linus, align functions should return the start
of a resource, not void. An update of "res->start" is no longer
necessary.

Cc: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Yinghai Lu <yhlu.kernel@gmail.com>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2010-02-22 16:16:56 -08:00
Ben Dooks 6c6971dc4e ARM: SAMSUNG: Move the last build from plat-s3c to plat-samsung
Move the init.c and time.c files to plat-samsung from plat-s3c, thus
clearing the last files that are being built in here.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-23 00:03:43 +00:00
Ben Dooks 2c420fe22f ARM: SAMSUNG: Move DMA support to plat-samsung
Move the core of the DMA support to plat-samsung for everyone to use.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-23 00:03:43 +00:00
Ben Dooks 806c17b549 ARM: SAMSUNG: Move pm.c to plat-samsung
Move pm.c to plat-samsung, it should be usable by all Samsung systems

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-23 00:03:43 +00:00
Ben Dooks 7086a9df05 ARM: SAMSUNG: Move map-base to plat-samsung
Move the map-base file to plat-samsung. To make the move easier, we do not
change the S3C_ prefix on many of the items as this would involve going
through altering all the dependencies.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-23 00:03:43 +00:00
Ben Dooks c116c1d725 ARM: SAMSUNG: Move common headers from plat-s3c to plat-samsung
Move common headers from plat-s3c's include/plat directory into plat-samsung.

No need to fix any files, these are still included via <plat/>

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-23 00:03:42 +00:00
Ben Dooks 7f0ff702cd ARM: Merge next-samsung-s3c64xx-platdeletion
Merge branch 'next-samsung-s3c64xx-platdeletion' into next-samsung

Conflicts:

	arch/arm/mach-s3c64xx/Makefile (fixed)
2010-02-22 23:38:26 +00:00
Ben Dooks 110d85acd4 ARM: S3C64XX: Eliminate plat-s3c64xx
Now we've move the support out of plat-s3c64xx for everything, eliminate
the platform directory arch/arm/plat-s3c64xx and remove it from the ARM
build configuration.

Note, PLAT_S3C64XX is kept around for the moment until the drivers that
depend on it can be updated, so it is moved to the mach-s3c64xx Kconfig.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-22 23:26:47 +00:00
Kuninori Morimoto 8cb3a2ebc1 ARM: mach-shmobile: ap4evb: Add S6 debug switch support
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-22 19:19:21 +09:00
Kuninori Morimoto 5098280e01 ARM: mach-shmobile: ap4evb: Add LED support
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-22 19:19:20 +09:00
Ben Dooks 992426bfe9 ARM: SAMSUNG: Remove dma-plat.h to allow plat-s3c64xx to be removed
dma-plat.h is the last file left in plat-s3c64xx, but to remove it we
must also change the use of dma-plat.h by the core code and the s3c24xx
implementation.

Rename the s3c24xx dma-plat.h in the common plat-samsung directory as it
may be used for other ports. Move the specific dma bits into the
mach-s3c64xx directory and update the build as needed.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-21 23:10:35 +00:00
wanzongshun 6d636c68e9 ARM: 5949/1: NUC900 add gpio virtual memory map
NUC900 add gpio virtual memory map

Signed-off-by: Wang Qiang <rurality.linux@gmail.com>
Signed-off-by: Wang Zongshun <mcuos.com@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-21 22:22:23 +00:00
wanzongshun ce746e471f ARM: 5948/1: Enable timer0 to time4 clock support for nuc910
Enable timer0 to time4 clock support for nuc910

Signed-off-by: Wang Qiang <rurality.linux@gmail.com>
Signed-off-by: Wang Zongshun <mcuos.com@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-21 22:22:23 +00:00
Linus Torvalds c52042ba5c Merge branch 'omap-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6
* 'omap-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6:
  omap: Remove DEBUG_FS dependency for mux name checking
2010-02-20 16:55:41 -08:00
Ben Dooks 431fb7df24 ARM: SAMSUNG: Move pm-core.h to machine directory
Move the pm-core.h to the machine include directory in the process of
eliminating the plat-s3c64xx.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:34:03 +00:00
Ben Dooks 89f0ce721c ARM: S3C64XX: Remove plat-s3c64xx Kconfig and PLAT_S3C64XX
Remove the Kconfig and PLAT_S3C64XX defines for the previous S3C64XX
directory structure now that the code is moved into mach-s3c64xx.

Note, we cannot currently remove plat-s3c64xx directory as we have a
pair of include files used within plat-s3c and plat-samsung that need
to find a new home.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:34:03 +00:00
Ben Dooks 55bf9267dd ARM: S3C64XX: Combine the clock init code
Turn the init sequence of
	s3c24xx_register_baseclocks(xtal);
	s3c64xx_register_clocks();
	s3c6400_register_clocks(S3C6410_CLKDIV0_ARM_MASK);

into a single call as this is now contained within one file.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:34:02 +00:00
Ben Dooks 62acb2f82d ARM: S3C64XX: Merge s3c6400-clock.c and clock.c into mach-s3c64xx
Merge plat-s3c64xx/s3c6400-clock.c mach-s3c64xx/clock.c placing all the
clock code into one place.

Note, no effort is made in this patch to squash the init functions
together.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:34:01 +00:00
Ben Dooks 6ce8fde296 ARM: S3C64XX: Merge s3c6400-init.c into cpu.c
Since this file is small, and is compiled for both systems in this
architecture merge it into the cpu support file and remove the original
instead of moving it.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:34:01 +00:00
Ben Dooks f7be9abaa5 ARM: S3C64XX: Move core support to mach-s3c64xx
Move the core S3C64XX support to mach-s3c64xx as it is unlikely to be used
outside of this directory. Also move the SoC header files in with it.

This includes the clock, cpu, cpufreq, dma, gpiolib and pll support.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:33:54 +00:00
Ben Dooks 88fc68a280 ARM: S3C64XX: Move device and device setup into mach-s3c64xx
Move the S3C64XX specific device and setup files into mach-s3c64xx as
they are unlikely to be used outside of this code.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:32:01 +00:00
Ben Dooks ed618aff8a ARM: S3C64XX: Move IRQ support into mach-s3c64xx
Move IRQ support to mach-s3c64xx as it is unlikely to be re-used outside
this machine.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:32:00 +00:00
Ben Dooks 3501c9ae9f ARM: S3C64XX: Move headers into machine include directory
Move the register and GPIO definition files from plat-s3c64xx into the
machine include direcotry as they are unlikely to be reused outside
mach-s3c64xx.

This move includes removing the empty <mach/regs-clock.h> and replacing
it with the <plat/regs-clock.h> implementation.

Signed-off-by: Ben Dooks <ben-linux@fluff.org>
2010-02-20 22:31:17 +00:00
Russell King ae1402022e ARM: make_coherent(): fix problems with highpte, part 2
update_mmu_cache() is called with the page table for the faulted-in
page still mapped.  We need to modify the PTE for this page to ensure
coherency with other shared mappings when multiple shared mappings
exist within a MM.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-20 16:42:51 +00:00
Russell King 4b3073e1c5 MM: Pass a PTE pointer to update_mmu_cache() rather than the PTE itself
On VIVT ARM, when we have multiple shared mappings of the same file
in the same MM, we need to ensure that we have coherency across all
copies.  We do this via make_coherent() by making the pages
uncacheable.

This used to work fine, until we allowed highmem with highpte - we
now have a page table which is mapped as required, and is not available
for modification via update_mmu_cache().

Ralf Beache suggested getting rid of the PTE value passed to
update_mmu_cache():

  On MIPS update_mmu_cache() calls __update_tlb() which walks pagetables
  to construct a pointer to the pte again.  Passing a pte_t * is much
  more elegant.  Maybe we might even replace the pte argument with the
  pte_t?

Ben Herrenschmidt would also like the pte pointer for PowerPC:

  Passing the ptep in there is exactly what I want.  I want that
  -instead- of the PTE value, because I have issue on some ppc cases,
  for I$/D$ coherency, where set_pte_at() may decide to mask out the
  _PAGE_EXEC.

So, pass in the mapped page table pointer into update_mmu_cache(), and
remove the PTE value, updating all implementations and call sites to
suit.

Includes a fix from Stephen Rothwell:

  sparc: fix fallout from update_mmu_cache API change

  Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>

Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-20 16:41:46 +00:00
Russell King d944d549aa ARM: allow alignment fault mode to be configured at kernel boot
Some glibc versions intentionally create lots of alignment faults in
their gconv code, which if not fixed up, results in segfaults during
boot.  This can prevent systems booting properly.

There is no clear hard-configurable default for this; the desired
default depends on the nature of the userspace which is going to be
booted.

So, provide a way for the alignment fault handler to be configured via
the kernel command line.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-20 16:20:49 +00:00
Russell King 0fa11802e0 ARM: Update mach-types
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-20 14:17:16 +00:00
Abdoulaye Walsimou Gaye 1c8e170aaa ARM: 5950/1: ARM: Fix build error for arm1026ej-s processor
This patch fix the below build error for arm1026ej-s processor (IntegratorCP/arm1026ej-s board).
  CC      init/main.o
In file included from include/linux/highmem.h:8,
                 from include/linux/pagemap.h:10,
                 from include/linux/mempolicy.h:62,
                 from init/main.c:52:
arch/arm/include/asm/cacheflush.h:134:2: error: #error Unknown cache maintainence model
make[1]: *** [init/main.o] Erreur 1
make: *** [init] Erreur 2

Signed-off-by: Abdoulaye Walsimou Gaye <walsimou@walsimou.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-20 14:10:47 +00:00
Felipe Balbi bdfa35118c omap: musb: remove unnecessary return
trivial patch, no functional changes.

Cc: linux-usb@vger.kernel.org
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:18 -08:00
Felipe Balbi 9bdde53fa5 omap: musb: remove unused dma data
we don't use those anywhere on musb driver, so
let's remove those old stuff.

Cc: linux-usb@vger.kernel.org
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Felipe Balbi 7db51121b8 omap: musb: remove unused soft_con field
remove unused data.

Cc: linux-usb@vger.kernel.org
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Felipe Balbi bfc110ee65 arm: omap: musb: we can use clk framework
... in order to handle musb's clock. Let's start
removing the old musb-only set_clock function.

Cc: linux-usb@vger.kernel.org
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Felipe Balbi 68499cc571 omap: musb: remove unused data
eps_bits wasn't being used anywhere, let's remove it.

Cc: linux-usb@vger.kernel.org
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Maulik Mankad 884b8369ee omap: musb: Pass board specific data from board file
Pass board specific data for MUSB (like interface_type,
mode etc) from board file by defining board
specific structure.

Each board file can define this structure based on
its requirement and pass this information to the
driver.

Signed-off-by: Maulik Mankad <x0082077@ti.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: Felipe Balbi <felipe.balbi@nokia.com>
Cc: David Brownell <david-b@pacbell.net>
Cc: Greg Kroah-Hartman <gregkh@suse.de>
Cc: Gupta Ajay Kumar <ajay.gupta@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Felipe Balbi f9828552b9 arm: omap: musb: ioremap only what's ours
omap3430 TRM says the OTG address space is 4k, not 8k.

Cc: linux-usb@vger.kernel.org
Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Maulik Mankad 1a4f463749 omap: musb: Remove #ifdef from board-omap3evm.c
This patch removes #ifdef around usb_nop_xceiv_register()
from board-omap3evm.c

Signed-off-by: Maulik Mankad <x0082077@ti.com>
Acked-by: Olof Johansson <olof@lixom.net>
Acked-by: Felipe Balbi <felipe.balbi@nokia.com>
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Sanjeev Premi 5ebc86eda7 OMAP3EVM: PM: Update defconfig
This patch updates the omap3_evm_defconfig to
select these options:
  * CONFIG_PM_DEBUG
  * CONFIG_DEBUG_FS
  * CONFIG_OMAP_SMARTREFLEX

Signed-off-by: Sanjeev Premi <premi@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Thomas Weber 8a88b61b70 Add devkit8000_defconfig
This patch adds a default config for the Timll Devkit8000.

Signed-off-by: Thomas Weber <weber@corscience.de>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Thomas Weber 476544cad1 Add minimal support for DevKit8000
These patches add board support for the Timll DevKit8000.

The DevKit8000 is a beagle board clone from Timll, sold by
armkits.com. The DevKit8000 has RS232 serial port, LCD, DVI-D,
S-Video, Ethernet, SD/MMC, keyboard, camera, SPI, I2C, USB and
JTAG interface.

Signed-off-by: Thomas Weber <weber@corscience.de>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Vaibhav Hiremath 5d4292a524 AM3517: Enable I2C-GPIO Expander driver support for AM3517EVM
Add platform hook-up interface to support I2C based GPIo expander
(TCA6416).

There are 3 instances of I2C Expander on AM3517EVM,
	- One is over I2C-2 mounted on Base board
	- Two are over I2C3 mounted on UI Card

Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Vaibhav Hiremath f2afbbb82e AM3517: Enable RTC driver support for AM3517EVM
Add platform hook-up interface to support RTC driver (S35390A).

Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Vaibhav Hiremath 1f738dc306 AM3517: Enable basic I2C Support
Add basic I2C board Hook-up support, where all the 3 I2C instances
are getting registered.

Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Jonas Zetterberg b344d87a28 IGEPv2: Use Red Led1 as Heartbeat if configured
If not configured it will be exported as normal GPIO led.

Signed-off-by: Jonas Zetterberg <jozz@jozz.se>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Jonas Zetterberg c67b0d9870 IGEPv2: Added WIFI support
Enabled VMMC2 LDO voltage regulator on TWL4030.
Added GPIO's (power down and reset) for WIFI chip.

Signed-off-by: Anders Hedlund <anders.j.hedlund@gmail.com>
Signed-off-by: Jonas Zetterberg <jozz@jozz.se>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Enric Balletbo i Serra cd2b90d9f7 omap3: Update defconfig for IGEP v2 to allow new drivers andfeatures
Signed-off-by: Enric Balletbo i Serra <eballetbo@iseebcn.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Enric Balletbo i Serra 22f1baac70 omap3: Use timing data for omap2_init_common_hw on IGEP v2
Signed-off-by: Enric Balletbo i Serra <eballetbo@iseebcn.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-19 15:22:17 -08:00
Russell King 2b4f017579 Merge branch 'for-rmk' of git://gitorious.org/linux-gemini/mainline 2010-02-18 23:35:24 +00:00
Roel Kluin 079e1091a2 Gemini: wrong registers used to set reg_level in gpio_set_irq_type()
It appears the wrong GPIO registers were used

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Paulius Zaleckas <paulius.zaleckas@gmail.com>
2010-02-18 21:54:11 +02:00
Hartley Sweeten 6bd4b38266 ARM: 5945/1: ep93xx: include correct irq.h in core.c
Currently <asm/mach/irq.h> is included by core.c. This header
includes <linux/irq.h> and defines a number of internal functions.
These internal functions are not needed by this file. Change the
include so that we just get what is needed.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Acked-by: Ryan Mallon <ryan@bluewatersys.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-18 17:30:20 +00:00
Santosh Shilimkar 6c09f09d44 ARM: 5938/1: ARM: L2: export outer_cache_fns
The 'outer_cache' variable is needed by the outer_inv_range(),
outer_clean_range() and outer_flush_range() functions, which are
declared as inline in asm/cacheflush.h.  Otherwise drivers built
as a loadable module, which access these functions, will have
an undefined symbol.

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-18 16:27:39 +00:00
Tomi Valkeinen e020f9af6d OMAP: DSS2: remove sub-panel system
The system to allow panel drivers to exists as attached to ctrl drivers
did never work very well. It is not useed, and this patch removes it to
make the driver cleaner.

For now, controller drivers need to include also the panel driver code. In
the future a proper mechanism for this should be developed, perhaps by
creating busses for controllers.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
2010-02-18 13:19:41 +02:00
Kuninori Morimoto 02624a1789 ARM: mach-shmobile: ap4evb: Add tiny document
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-18 18:24:17 +09:00
Kuninori Morimoto b228b48e45 ARM: mach-shmobile: ap4evb: Add SCIFA0 support
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-18 18:24:17 +09:00
Baruch Siach 0f547dc1f6 mx25pdk: add LCD support
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-18 08:35:55 +01:00
Baruch Siach 04a03e5fe3 mx25: add platform support for imxfb
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-18 08:35:05 +01:00
Baruch Siach f601441916 imxfb: add support for i.MX25
The commit also introduces the HAVE_FB_IMX config that is to be selected from
the MX25 platform config. Once this commit gets merged, the two other i.MX
archs, ARCH_MX1 and ARCH_MX2, should follow this one.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-02-18 08:34:23 +01:00
Kuninori Morimoto 1b7e0677fb ARM: mach-shmobile: SMSC 9220 support for AP4EVB.
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-18 12:34:51 +09:00
Kuninori Morimoto b789b3fdcc ARM: mach-shmobile: Add sh7372 pinmux support
Signed-off-by: Kuninori Morimoto <morimoto.kuninori@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2010-02-18 12:32:59 +09:00
Enric Balletbo i Serra ec0947fa0f omap3: SDRC: add timing data for Numonyx M65KxxxxAM
Add timing data for the Numonyx M65KxxxxAM SDRAM chip, used on the
IGEP v2 board.

Signed-off-by: Enric Balletbo i Serra <eballetbo@iseebcn.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Enric Balletbo i Serra cddb483a74 omap3: Add support for flash on IGEP v2 board
This patch adds support for flashes on IGEP v2 boards. For now
only OneNAND is supported.

Signed-off-by: Enric Balletbo i Serra <eballetbo@iseebcn.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Enric Balletbo i Serra 691de27f3c omap3: Enable DSS2 for IGEP v2 board
Signed-off-by: Enric Balletbo i Serra <eballetbo@iseebcn.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Enric Balletbo i Serra d0885486d7 omap3: Add platform init code for EHCI driver on IGEP v2
Add platform init code for EHCI driver on IGEP v2

Signed-off-by: Enric Balletbo i Serra <eballetbo@iseebcn.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Enric Balletbo i Serra 28e0f13cd1 omap3: Fix typo on IGEP v2 board
Fix typo on IGEP v2 board

Signed-off-by: Enric Balletbo i Serra <eballetbo@iseebcn.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Enric Balletbo i Serra 7f5f23da82 omap3: Add platform data for the twl4030_codec MFD on IGEP v2
Add platform data for the twl4030_codec MFD on IGEP v2

Signed-off-by: Enric Balletbo i Serra <eballetbo@iseebcn.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Grazvydas Ignotas 3cca088d07 omap3: pandora: update defconfig
Enable DSS2 and update defconfig for current kernel.

Signed-off-by: Grazvydas Ignotas <notasas@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Grazvydas Ignotas f6873eedd9 omap3: pandora: update regulator setup
Update pandora's regulator setup:
- add new regulators: VAUX2, VAUX4 and VSIM
- add new consumers: ads7846, nub controllers, USB PHY, audio DAC
- use dev names instead of struct device pointers

Signed-off-by: Grazvydas Ignotas <notasas@gmail.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Grazvydas Ignotas 7b097896e4 OMAP: pandora: add DSS2 support and related regulators
This patch adds configuration data for DSS2 and sets up
display related regulators.

Signed-off-by: Grazvydas Ignotas <notasas@gmail.com>
Acked-by: Tomi Valkeinen <tomi.valkeinen@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Sanjeev Premi 87520aae7c omap3evm: Configure GPIO175 for touchscreen PEN_IRQ
GPIO175 is used for PEN_IRQ on the EVM. This patch
sets the mux settings for the same.

Signed-off-by: Sanjeev Premi <premi@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Sanjeev Premi 0621d75698 omap3evm: Fixes after moving to matrix_keypad
The keypad was not working properly after migrating
to matrix_keypad.

Swapped the row, col fields of the KEY() macro in
the keymap definition to get it working again.

Signed-off-by: Sanjeev Premi <premi@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
Sanjeev Premi aa6912d885 omap3evm: Add mux settings for keypad
This patch sets SYS_NIRQ for keypad input. It also
sets the same as a wakeup event from OFF mode.

Signed-off-by: Sanjeev Premi <premi@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 17:23:20 -08:00
vikram pandita 31e464cdbc omap: zoom3: enable ehci support
Zoom3 board has omap3630 EHCI port2 connected to a ULPI phy.
GPIO_64 is connected to the PHY reset pin.

Signed-off-by: Vikram Pandita <vikram.pandita@ti.com>
Cc: Anand Gadiyar <gadiyar@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 14:09:23 -08:00
Tony Lindgren 80c20d543d Merge branch 'omap-fixes-for-linus' into omap-for-linus 2010-02-17 14:08:58 -08:00
Ranjith Lohithakshan b72c7d5435 omap: Remove DEBUG_FS dependency for mux name checking
The check for a valid mux name should be performed regardless of whether
DEBUG_FS is enabled or not. Otherwise without DEBUG_FS, we get:

Unable to handle kernel NULL pointer dereference at virtual address 00000000
pgd = c0004000
[00000000] *pgd=00000000
Internal error: Oops: 5 [#1]
last sysfs file:
Modules linked in:
CPU: 0    Not tainted  (2.6.33-rc8 #10)
PC is at strcmp+0x18/0x40
LR is at omap_mux_init_signal+0x68/0x14c
...

This fixes the issue currently seen with boards not booting up
if DEBUG_FS is not enabled in defconfig.

Note that the earlier ifndef + ifdef now becomes simpler ifdef else:
If CONFIG_OMAP_MUX is selected, we use pin names. If it's not selected,
we only want the GPIO to mux register mapping.

Signed-off-by: Ranjith Lohithakshan <ranjithl@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-17 09:51:41 -08:00
Fenkart/Bostandzhyan a183927213 ARM: 5929/1: Add checks to detect overlap of memory regions.
Tested-by: H Hartley Sweeten <hsweeten@visionengravers.com>

Signed-off-by: Andreas Fenkart <andreas.fenkart@streamunlimited.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:40:33 +00:00
Fenkart/Bostandzhyan c931b4f655 ARM: 5928/1: Change type of VMALLOC_END to unsigned long.
Makes it consistent with VMALLOC_START

Tested-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Andreas Fenkart <andreas.fenkart@streamunlimited.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:40:33 +00:00
Fenkart/Bostandzhyan a7bd08c82e ARM: 5927/1: Make delimiters of DMA area globally visibly.
Adds DMA area to 'virtual memory map' startup message

Tested-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Andreas Fenkart <andreas.fenkart@streamunlimited.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:40:32 +00:00
Fenkart/Bostandzhyan db9ef1af48 ARM: 5926/1: Add "Virtual kernel memory..." printout.
Code based on parisc and x86_32.

Tested-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Signed-off-by: Andreas Fenkart <andreas.fenkart@streamunlimited.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:40:32 +00:00
Santosh Shilimkar 22192b37bb ARM: 5920/1: OMAP4: Enable L2 Cache
This patch enables L2 cache and associated Errata on the
OMAP4430 SDP.

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:55 +00:00
Santosh Shilimkar 9e65582a8e ARM: 5919/1: ARM: L2 : Errata 588369: Clean & Invalidate do not invalidate clean lines
This patch implements the work-around for the errata 588369.The secure
API is used to alter L2 debug register because of trust-zone.

This version updated with comments from Russell and Catalin and
generated against 2.6.33-rc6 mainline kernel. Detail
comments can be found:
http://www.spinics.net/lists/linux-omap/msg23431.html

Signed-off-by: Woodruff Richard <r-woodruff2@ti.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:55 +00:00
Santosh Shilimkar d309427e79 ARM: 5917/1: OMAP4: Add L2 Cache support
This patch adds L2 Cache support for OMAP4. External L2 cache
is used in OMAP4

CC: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:55 +00:00
Santosh Shilimkar 424d6b145f ARM: 5916/1: ARM: L2 : Add maintainace by line helper functions
This patch adds the cache maintainance by line helper functions.

Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:54 +00:00
Russell King ad187f9561 ARM: vfp ptrace: no point flushing hw context for PTRACE_GETVFPREGS
If we're only reading the VFP context via the ptrace call, there's
no need to invalidate the hardware context - we only need to do that
on PTRACE_SETVFPREGS.  This allows more efficient monitoring of a
traced task.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:53 +00:00
Russell King 54cb3dbb4a ARM: vfp: fix vfp_sync_state()
The more I look at vfp_sync_state(), the more I believe it's trying
to do its job in a really obscure way.

Essentially, last_VFP_context[] tracks who owns the state in the VFP
hardware.  If last_VFP_context[] is the context for the thread which
we're interested in, then the VFP hardware has context which is not
saved in the software state - so we need to bring the software state
up to date.

If last_VFP_context[] is for some other thread, we really don't care
what state the VFP hardware is in; it doesn't contain any information
pertinent to the thread we're trying to deal with - so don't touch
the hardware.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:53 +00:00
Russell King 462f39a8c7 ARM: ptrace: get rid of PTRACE_{PEEK,POKE}{TEXT,DATA}
The generic ptrace_request() handles these for us, so there's no
need to duplicate them in arch code.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:52 +00:00
Daniel Jacobowitz d23bc1b3a7 ARM: 5912/1: Define a 32-bit Thumb-2 breakpoint instruction
Recognize 0xf7f0 0xa000 as a 32-bit breakpoint instruction for
Thumb-2.

Signed-off-by: Daniel Jacobowitz <dan@codesourcery.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:52 +00:00
Tony Lindgren 1a28e3d977 ARM: 5911/1: ARM: Select CPU_32v6K for CPU_V7 only if ARCH_OMAP2 is not selected
Otherwise the kernel built with both CPU_V6 and CPU_V7 will not
boot on omap2.

Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:51 +00:00
Catalin Marinas 11805bcfa4 ARM: 5905/1: ARM: Global ASID allocation on SMP
The current ASID allocation algorithm doesn't ensure the notification
of the other CPUs when the ASID rolls over. This may lead to two
processes using the same ASID (but different generation) or multiple
threads of the same process using different ASIDs.

This patch adds the broadcasting of the ASID rollover event to the
other CPUs. To avoid a race on multiple CPUs modifying "cpu_last_asid"
during the handling of the broadcast, the ASID numbering now starts at
"smp_processor_id() + 1". At rollover, the cpu_last_asid will be set
to NR_CPUS.

Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:51 +00:00
Jeremy Kerr 48ab7e09e0 ARM: 5906/1: arm: change command_line to cmd_line
drivers/of/fdt expects a cmd_line symbol, while arm uses command_line.
Change to the former, so that we can eventually share with the fdt
code.

Signed-off-by: Jeremy Kerr <jeremy.kerr@canonical.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:50 +00:00
Rabin Vincent c5113b61ba ARM: 5897/1: spinlock: don't use deprecated barriers on ARMv7
On ARMv7, the use of the cp15 operations for barriers is deprecated
in favour of the isb, dsb, and dmb instructions.  Change the locking
functions to use the appropriate type of dsb for the architecture
being built for.

Signed-off-by: Rabin Vincent <rabin@rab.in>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:50 +00:00
Will Deacon 24b44a66fa ARM: 5889/1: Add atomic64 routines for ARMv6k and above.
In preparation for perf-events support, ARM needs to support atomic64_t
operations. v6k and above support the ldrexd and strexd instructions to
do just that.

This patch adds atomic64 support to the ARM architecture. v6k and above
make use of new instructions whilst older cores fall back on the generic
solution using spinlocks. If and when v7-M cores are supported by Linux,
they will need to fall back on the spinlock implementation too.

Signed-off-by: Will Deacon <will.deacon@arm.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:50 +00:00
Russell King a9221de66d ARM: add notify_die() support
Kernel debuggers want to be informed of die() events, so that they
can take some action to allow the problem to be inspected.  Provide
the hook in a similar manner to x86.

Note that we currently don't implement the individual trap hooks.

Acked-by: Jason Wessel <jason.wessel@windriver.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:14 +00:00
Jeremy Kerr 2b0d8c251b ARM: 5880/1: arm: use generic infrastructure for early params
The ARM setup code includes its own parser for early params, there's
also one in the generic init code.

This patch removes __early_init (and related code) from
arch/arm/kernel/setup.c, and changes users to the generic early_init
macro instead.

The generic macro takes a char * argument, rather than char **, so we
need to update the parser functions a little.

Signed-off-by: Jeremy Kerr <jeremy.kerr@canonical.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:13 +00:00
Russell King e119bfff1f ARM: Move creation of /proc/cpu out of alignment.c
Always creating this directory avoids other users having to jump
through silly hoops when they want to share this directory.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:12 +00:00
Russell King 373b32abf9 ARM: move LED support code out of arch/arm/kernel/time.c
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:12 +00:00
Russell King 7921fc4a25 ARM: remove old RTC support
All RTC drivers have been converted to rtclib, so the old code
providing the set_rtc function pointer, save_time_delta() and
restore_time_delta() functions is obsolete.  Remove it.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:12 +00:00
Russell King 31aa8fd6fd ARM: Add caller information to ioremap
This allows the procfs vmallocinfo file to show who created the ioremap
regions.  Note: __builtin_return_address(0) doesn't do what's expected
if its used in an inline function, so we leave __arm_ioremap callers
in such places alone.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 21:39:11 +00:00
Russell King 2f68ffd11a Merge branch 'arm/clock-event' of git://git.pengutronix.de/git/ukl/linux-2.6 into devel-stable 2010-02-15 21:20:33 +00:00
Russell King 56012808f4 Merge branch 'for-rmk' of git://git.marvell.com/orion into devel-stable
Conflicts:
	arch/arm/Makefile
2010-02-15 21:20:18 +00:00
Ryan Mallon dd2ac961e2 ARM: 5937/1: Add support for EP9315 based Snapper CL15 board
Add support for Bluewater Systems EP9315 based Snapper CL15 single board
computer module.

Signed-off-by: Ryan Mallon <ryan@bluewatersys.com>
Acked-by: Hartley Sweeten <hartleys@visionengravers.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2010-02-15 19:40:50 +00:00
Jorge Eduardo Candelaria d6a2d9b800 OMAP4: MCPDM: Register McPDM platform device
Add platform device for McPDM interface in OMAP4 and register
its memory and irq resources.

Signed-off-by: Jorge Eduardo Candelaria <x0107209@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:35 -08:00
Jorge Eduardo Candelaria 302720f3b7 ARM: OMAP4: Add McPDM base address
Define McPDM physical and L3 base address for OMAP4

Signed-off-by: Jorge Eduardo Candelaria <x0107209@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:35 -08:00
Jorge Eduardo Candelaria 57852d761a OMAP4: IRQ: Add McPDM IRQ definition
Support for McPDM IRQs in OMAP4

Signed-off-by: Jorge Eduardo Candelaria <x0107209@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:35 -08:00
Felipe Balbi 52abcbc9c4 arm: omap: kill compile warning on board-4430-sdp.c
sdp4430_uart_config isn't used anywhere, so remove it.

Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:35 -08:00
Vaibhav Hiremath 91fbb8c6d9 AM35xx: Update irq.h for AM35xx IPSS module interrupts
Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:35 -08:00
Vaibhav Hiremath 07dcbd0786 AM35xx: Add AM35xx intr_clr & sw_rst cntrl reg bit definition
AM3517/05 has few additional control module registers to control
the new IP's, like VPFE, USBOTG, CPGMAC.

This patch adds the bit defination for INTR_CLR and SW_RST control
register.

Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:35 -08:00
Vaibhav Hiremath e3d4d0a238 AM35xx: Introduce am35xx.h file
Add base address definations for new AM35xx IPSS modules, like
VPFE, USBOTG, CPGMAC.

Please note that the OMAP34xx IVA2 memory space is being used for
AM35xx IPSS modules.

Signed-off-by: Vaibhav Hiremath <hvaibhav@ti.com>
Signed-off-by: Sriramakrishnan <srk@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:35 -08:00
Lesly A M a1e63642a9 omap3: pm: Add T2 Keypad as a wakeup source
Changes for setting the padconf value for sys_nirq line which is
connected to T2 INTR1. This will fix the T2 keypad wakeup.

Signed-off-by: Lesly A M <x0080970@ti.com>
Signed-off-by: Teerth Reddy <teerth@ti.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:35 -08:00
Tony Lindgren 321cfc851d omap3: Clean-up for omap_mux_init
Get rid of the ifdeffery in omap_mux_init by creating
omap_mux_init_package and omap_mux_init_signals functions.

Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:35 -08:00
Adrian Hunter e0eb242446 omap_hsmmc: Allow for a shared VccQ
EMMC can have two voltage supplies, Vcc and VccQ
which are implemented in the code as consumer
supplies vmmc and vmmc_aux.

If the regulator that supplies vmmc_aux is shared
with other consumers, then sending it to sleep
will disrupt those consumers.  However, the
TWL4030-family regulators may have OFF remapped
to SLEEP, in which case 'regulator_disable()'
will put the regulator to sleep only when all
consumers are disabled - which is the desired
behaviour.

This patch adds a platform data field to allow
that option.

Signed-off-by: Adrian Hunter <adrian.hunter@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:34 -08:00
Adrian Hunter 1df58db8a2 omap_hsmmc: Allow for power saving without going off
An eMMC may be always powered on, so that the lowest
power saving state possible is sleeping. Add a field
to the platform data to indicate that.

Signed-off-by: Adrian Hunter <adrian.hunter@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:34 -08:00
Adrian Hunter ce6f00165d omap: RX51: Remux to pull eMMC lines down when powering off
It has been discovered that, when eMMC is powered off, current
will flow from OMAP eMMC data pull-ups to the eMMC voltage supply.
Configuring pads for OMAP off-mode does not help because eMMC is
powered off independently of OMAP off-mode.  Hence the pads are
now re-configured when eMMC is powered on or off.

Signed-off-by: Adrian Hunter <adrian.hunter@nokia.com>
Signed-off-by: Tony Lindgren <tony@atomide.com>
2010-02-15 10:03:34 -08:00