ARM: dts: omap: Add reset/idle on init bindings for OMAP

On OMAP we have co-processor IPs, memory controllers,
GPIOs which control regulators and power switches to
PMIC, and SoC internal Bus IPs, some or most of which
should either not be reset or idled or both at init.
(In some cases there are erratas which prevent an IP
from being reset)
Have a way to pass this information from DT.

Update the am33xx/omap4 and omap5 dtsi files with the
new bindings for modules which either should not be
idled. reset or both. A later patch would cleanup the
same information that exists today as part of the hwmod
data files.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: am335x-evmsk: Do not reset gpio0

Do not reset GPIO0 at  boot-up because GPIO0 is used
on AM335x EVM-SK to control VTT regulators on DDR3.

Without this EVM-SK boards fail to boot-up because
of DDR3 corruption.

Signed-off-by: Rajendra Nayak <rnayak@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: omap4-panda-es: Do not reset gpio1

Do not reset GPIO1 at boot-up because GPIO 7 in GPIO1 block is used on
OMAP4460 PandaBoard-ES to select voltage register in TPS62361 which
supplies VDD_MPU.

Without this, OMAP4460 PandaBoard-ES boards fail to boot-up because
MPU voltage switches over to VSET0 voltage value (boot voltage) which
is not sufficient to operate the device at OPP100.

Signed-off-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: omap5-uevm: remove always_on, boot_on from smps10_out1

smps10 should be enabled only in the case of host mode. So stop
doing always_on, boot_on from smps10_out1. The driver will enable
it in host mode.

Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
Acked-by: Nishanth Menon <nm@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: OMAP5: Add dr_mode for dwc3

Added dr_mode property in dwc3 and set its default mode to device.

Signed-off-by: George Cherian <george.cherian@ti.com>
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: AM4372: Add L2, EDMA, mailbox, MMC and SHAM nodes

Populate nodes for l2-cache-controller, EDMA, mailbox,
mmc, sham.

Update as well DT properties for epwmss, aes, des.

Signed-off-by: Suman Anna <s-anna@ti.com>
Signed-off-by: Balaji T K <balajitk@ti.com>
Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: AM4372: Update Support for EPOS EVM

-> Adding pinmux for cpsw, i2c0.
-> Enabling the modules that are present in AM4372 EPOS EVM
These modules are tested on AM4372 EPOS EVM.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: Sourav Poddar <sourav.poddar@ti.com>
Signed-off-by: Mugunthan V N <mugunthanvnm@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: AM33XX: Add mcasp0 and mcasp1 device tree entries

Add missing mcasp entries in the am33xx.dtsi include file.

Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
Signed-off-by: Darren Etheridge <detheridge@ti.com>
Signed-off-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: AM33XX: mcasp: Add location for data port registers to reg-property

This patch adds a second tuple to reg property. The new property tuple
describes the memory location for data port registers mapped trough
L3 bus on am33xx. The both property tuples are named accordingly in
the reg-names property.

Signed-off-by: Hebbar, Gururaja <gururaja.hebbar@ti.com>
Signed-off-by: Darren Etheridge <detheridge@ti.com>
Signed-off-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: am335x-evm: Add audio support for am335x-evm.dts

Adds sound, tlv320aic3106, mcasp1, and am335x_evm_audio_pin nodes.

Signed-off-by: Darren Etheridge <detheridge@ti.com>
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: am335x-evmsk: Audio support

AM335x EVM-SK have only support for audio playback (stereo jack on the
board) via tlv320aic3106 codec connected to McASP1.
Enable the support for audio playback on the board:
- McASP1 configuration
- tlv320aic3106 configuration
- Machine driver.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Signed-off-by: Jyri Sarha <jsarha@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ARM: dts: omap3-beagle: Adapt USB OTG to generic PHY framework

The generic PHY framewrok expects different properties than the
old USB PHY framework. Supply those properties.

Fixes USB OTG port on beagle after the Generic PHY framework was
merged in greg/usb-next. [1]

[1] - https://lkml.org/lkml/2013/9/27/581

Signed-off-by: Roger Quadros <rogerq@ti.com>
Acked-by: Felipe Balbi <balbi@ti.com>
Signed-off-by: Benoit Cousson <bcousson@baylibre.com>
ALSA: dice: optimize bus reset handling

After a bus reset, do not stop the stream completely to avoid having to
reconfigure the device when restarting the stream.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
ALSA: dice: allow all sample rates

Instead of forcing a constant 44.1 kHz, read the current sample rate
from the device when opening the PCM device.

Actually changing the sample rate requires some separate controller
application.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
ALSA: dice: reduce noisy logging

The notification bits are not of general interest; log them only when
debugging.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
ALSA: dice, firewire-lib: add blocking mode

Allow AMDTP output streams to use blocking mode.

Use it for DICE devices, because the old DICE-II chip will in some cases
not be able to lock to non-blocking streams (erratum E7).

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
ALSA: dice: fix hang when unplugging a running device

When aborting a PCM stream, the xrun is signaled only if the stream is
running.  When disconnecting a PCM stream, calling snd_card_disconnect()
too early would change the stream into a non-running state and thus
prevent the xrun from being noticed by user space.

To prevent this, move the snd_card_disconnect() call after the xrun.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
ALSA: dice: implement hwdep device

Implement the hwdep locking and notification mechanisms.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
ALSA: dice: clear device lock when closing hwdep device

Ensure that misbehaving or aborted userspace programs do not
accidentally keep the lock.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
ALSA: firewire: introduce amdtp_out_stream_running()

Introduce the helper function amdtp_out_stream_running().  This makes
many checks in amdtp.c clearer and frees the device drivers from having
to track this with a separate variable.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>