drm: xilinx: dp: Return -ETIMEDOUT after waiting 2ms for aux reply

Return -ETIMEDOUT if there's no aux reply for 2ms.

Signed-off-by: Hyun Kwon <hyunk@xilinx.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drm: xilinx: dp: Replace spinlock with mutex for aux communication

Use mutex for aux communication synchronization. User thread and
the threaded interrupt context can call aux functions, and calling
thread may sleep and wait after acquiring the lock. This patch
replaces spinlock with mutex for such synchronization process.

Signed-off-by: Hyun Kwon <hyunk@xilinx.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drm: xilinx: dp: Replace udelay() with usleep_range()

Change the 1ms delay (udelay(1000)) to sleep (usleep_range(1000, 1100)),
since 1ms is too long to be a delay and there's no need to do busy wait.

Signed-off-by: Hyun Kwon <hyunk@xilinx.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drm: xilinx: dp: Use 'for' loop for PHY ready iteration

Simplify the PHY ready function using the 'for' loop. This also removes
the unneccessary wait when PHY is ready right away.

Signed-off-by: Hyun Kwon <hyunk@xilinx.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drm: xilinx: dp: Use DRM_ERROR() instead of dev_err()

Use DRM_ERROR() for errors after the drm encoder operation is attached.

Signed-off-by: Hyun Kwon <hyunk@xilinx.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drm: xilinx: dp: Add documentation for aux synchronization

Add documentation for aux communication synchronization. More function
description is added for xilinx_drm_dp_aux_cmd_submit(), and aux_lock
documentation is more detailed.

Signed-off-by: Hyun Kwon <hyunk@xilinx.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
drm: xilinx: dp: Clean up the mutex

Clean up the mutex when error-exiting and when driver is removed.

Signed-off-by: Hyun Kwon <hyunk@xilinx.com>
Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
[media] axi-hdmi-rx: Adopt to adv7611 driver changes

Adopt the axi-hdmi-rx bridge driver to the latest adv7611 driver changes.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Merge remote-tracking branch 'xilinx/master-next' into xcomm_zynq
iio: cf_axi_dds: Properly register only 2 channels for the ad9364

The ad9364 has only 2 channels (one I and one Q).

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
drivers/iio/frequency/cf_axi_dds: SW updates for HDL PCORE Version 8.00.a

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
drivers/iio/adc/cf_axi_adc_core: SW updates for HDL PCORE Version 8.00.a

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
drivers/iio/adc/ad9467: Unprepare only prepared clocks

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Merge branch 'xcomm_zynq_new_pcore_regmap' of https://github.com/analogdevicesinc/linux into xcomm_zynq_new_pcore_regmap
drivers/iio/adc/cf_axi_adc_core: Allow older HDL PCORE Versions

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
arch/arm/boot/dts: Added devicetrees for Mini-ITX.
zynq.dtsi: Fix devcfg compatible string

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
spi: Fix handling of cs_change in core implementation

The core implementation of cs_change didn't follow the documentation
which says that cs_change in the middle of the transfer means to briefly
deassert chip select, instead it followed buggy drivers which change the
polarity of chip select.  Use a delay of 10us between deassert and
reassert simply from pulling numbers out of a hat.

Reported-by: Gerhard Sittig <gsi@denx.de>
Signed-off-by: Mark Brown <broonie@linaro.org>