serial: xilinx_uartps: Force enable the UART in xuartps_console_write

We might enter xuartps_console_write with the UART disabled, in which case we'll
busy loop in xuartps_console_putchar until a timeout occurs. This timeout will
happen for each character to be printed and might take several seconds. Force
enable the UART for the duration of xuartps_console_write to avoid this.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
dmaegine: xilinx_dma: Add support for residue reporting

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
dmaengine: Add wrapper for device_tx_status callback

This patch adds a small inline wrapper for the devivce_tx_status callback of a
dma device. This makes the source code of users of this function a bit more
compact and a bit more legible.

E.g.:
-status = chan->device->device_tx_status(chan, cookie, &state)
+status = dmaengine_tx_status(chan, cookie, &state)

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
ASoC: dmaengine-pcm: Rename and deprecate snd_dmaengine_pcm_pointer

Currently the sound dmaengine pcm helper functions implement the pcm_pointer
callback by trying to count the number of elapsed periods. This is done by
advancing the stream position in the dmaengine callback by one period.
Unfortunately there is no guarantee that the callback will be called for each
elapsed period. It may be possible that under high system load it is only called
once for multiple elapsed periods. This patch renames the current implementation
and documents its shortcomings and that it should not be used anymore in new
drivers.

The next patch will introduce a new snd_dmaengine_pcm_pointer which will be
implemented based on querying the current stream position from the dma device.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>

---
I've added those people on Cc which maintain pcm drivers which use the dmaengine
pcm helper. Please check if you platform works with the new
snd_dmaengine_pcm_pointer implementation which is added in the next patch. And
if it does send a follow-up patch to convert your platform to the new
implementation.
ASoC: dmaengine-pcm: Add support for querying stream position from DMA driver

Currently the sound dmaengine pcm helper functions implement the pcm_pointer
callback by trying to count the number of elapsed periods. This is done by
advancing the stream position in the dmaengine callback by one period.
Unfortunately there is no guarantee that the callback will be called for each
elapsed period. It may be possible that under high system load it is only called
once for multiple elapsed periods. This patch addresses the issue by
implementing support for querying the current stream position directly from the
dmaengine driver. Since not all dmaengine drivers support reporting the stream
position yet the old period counting implementation is kept for now.

Furthermore the new mechanism allows to report the stream position with a
sub-period granularity, given that the dmaengine driver supports this.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
ASoC: Add ADAU1X61 and ADAU1X81 CODECs common code

The ADAU1X61 and ADAU1X81 are very similar in the digital domain of the CODECs,
but are quite different in the analog domain. This patch adds support for the
common parts of the ADAU161 and ADAU181 CODECs.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
ASoC: Add ADAU1X61 codec support

This patch adds support for the Ananlog Devices ADAU1361 and ADAU1761 codecs.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
ASoC: xilinx_pcm: Add support for individual subchannels

A DAI may support both capture and playback or just one of the two. Thus we need
to be able to specify DMA channels for capture and playback independently of each
other. Do this by adding a per direction subnode to the PCM device's node.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
debugfs: Constify reg32

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
ASoC: Add AXI I2S driver
ASoC: Add ZED ADAU1761 board file

Add support for the ADAU1761 found on the ZED board.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
drm: Move drm_format_num_planes() to drm_crtc.c

There will be a need for this function in drm_crtc.c later. This
avoids making drm_crtc.c depend on drm_crtc_helper.c.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drm: Add drm_format_plane_cpp() utility function

This function returns the bytes per pixel value based on the pixel
format and plane index.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
drm: Add drm_format_{horz, vert}_chroma_subsampling() utility functions

These functions return the chroma subsampling factors for the specified
pixel format.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
DRM: Sync DRM GEM helper to latest upstream version

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
DRM: drm_fb_cma_helper: Add size checks.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
drm: Update adv7511 documentation

Plus some minor code cleanups

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
drm: analog: Minor code cleanups and license headers

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
dmaengine: xilinx_dma: Make transfers more robust

Stoping a transfer wont stop it immediately, but will finish the current transfer
and will only stop afterward. Thus we have to careful to not reuse the
descriptor until this has happened. It is also possible that we try to start a
new transfer while the old one is still in progress. In this case we have to
wait until it has finished before we can start the new one.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
ASoC: ADAU1761 hardcode ZED platform data

This is a temporary hack for the ZED tree until we have proper device tree
support in the ADAU1761 driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>