spi/s3c64xx: use clk_prepare_enable and clk_disable_unprepare

Convert clk_enable/clk_disable to clk_prepare_enable/clk_disable_unprepare
calls as required by common clock framework.

Signed-off-by: Thomas Abraham <thomas.abraham@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
spi/bcm63xx: remove driver version

As Grant Likely reported, this does not make any sense in a mainline kernel
remove that driver version string.

Reported-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
spi/bcm63xx: add missing spi_master_{resume,suspend} calls to PM callbacks

The PM callbacks implemented by the spi-bcm63xx driver don't call
spi_master_{resume,suspend}, fix that.

Signed-off-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
spi/bcm63xx: remove useless call to bcm63xx_spi_check_transfer()

Calling bcm63xx_spi_check_transfer() with a NULL argument does not do
anything useful that the core spi code is not doing already, remove
this superfluous call.

Signed-off-by: Florian Fainelli <florian@openwrt.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
spi/mcspi: allow configuration of pin directions

Allow D0 to be an input and D1 to be an output, configurable via
platform data and a new DT property.

Based on a patch from  Matus Ujhelyi <matus.ujhelyi@streamunlimited.com>

Signed-off-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
spi/pl022: Revert "spi/pl022: fix spi-pl022 pm enable at probe"

This reverts commit 6887237cd7da904184dab2750504040c68f3a080.

Commit "spi/pl022: enable runtime PM" introduced runtime PM issues.
Due to that commit, "spi/pl022: fix spi-pl022 pm enable at probe"
was merged to fix part of those issues.

Instead of adding another fix, let's clean up and revert everything
back to when it was already fine.

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Merge branch 'spi-linus', remote-tracking branches 'misc/spi/bcm63xx', 'misc/spi/mcspi', 'misc/spi/mxs' and 'misc/spi/s3c64xx' into spi-next
spi/pl022: Minor simplification for runtime pm

In probe pm_runtime_put_autosuspend has the same effect as doing
pm_runtime_put. This due to upper layer in driver core is preventing
the device from being runtime suspended by a pm_runtime_get*.

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
spi/pl022: Activate resourses before deactivate them in suspend

To be able to deactivate resourses in suspend, the resourses must
first be surely active. This is done with a pm_runtime_get_sync.
Once the resourses are restored to active state again in resume,
the runtime pm usage count can be decreased with a pm_runtime_put.

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
spi/pl022: add IDLE state pin management

This commit allow to put pins in IDLE state in
runtime_suspend and in SLEEP state in suspend, corresponding
to defined semantics in <linux/pinctrl/pinctrl-state.h>.

To do this, just add a boolean parameter runtime
to pl022_resume_resources/pl022_suspend_resources which
indicates if it's called from PM_RUNTIME callbacks or not.

Signed-off-by: Patrice Chotard <patrice.chotard@stericsson.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Merge branch 'spi-pl022' into spi-next
[media] siano: allow compiling it without RC support

Remote controller support should be optional on all drivers.

Make it optional at Siano's driver.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
[media] common/*/Kconfig: Remove unused helps

Those items don't have any menu anymore; they're auto-selected by
USB/PCI/MMC drivers. So, there's no sense on keeping any help
there anymore.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
[media] remove include/linux/dvb/dmx.h

The only reason for this header is to make sure that include
linux/time.h were added before uapi/*/dmx.h. Just push down the
time.h header on the few places where this is used, and drop
this new header.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
[media] Remove include/linux/dvb/ stuff

The only file left there is include/linux/dvb/video.h. The
only function for it is to include linux/compiler.h, but this
is already indirectly included. So, get rid of it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Merge tag 'spi-linus' into spi-next

spi: Fixes for v3.7

A bunch of fixes here, mostly minor except for the pl022 which has just
been a bit of a shambles all round, the recent runtime PM changes have
as far as I can tell never worked so they're just getting thrown out.

Conflicts:
	drivers/spi/spi-pl022.c
[media] em28xx: Better support for the Terratec Cinergy HTC USB XS

This intializes the card just like the windows driver does

- the "HTC USB XS HD" uses the same firmware as the "HTC Stick HD";
- both have different GPIO and reg init sequences;

Tested only with DVB-C.

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
[media] drxk: Use the #define instead of hardcoded values

Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
[media] drxk_hard: fix a few warnings

drivers/media/dvb-frontends/drxk_hard.c:68:6: warning: no previous prototype for 'IsA1WithPatchCode' [-Wmissing-prototypes]
drivers/media/dvb-frontends/drxk_hard.c:73:6: warning: no previous prototype for 'IsA1WithRomCode' [-Wmissing-prototypes]
drivers/media/dvb-frontends/drxk_hard.c:192:12: warning: no previous prototype for 'Frac28a' [-Wmissing-prototypes]
drivers/media/dvb-frontends/drxk_hard.c:590:5: warning: no previous prototype for 'PowerUpDevice' [-Wmissing-prototypes]

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
[media] s5p-mfc: Fix compilation warning

Added missing const qualifier.
Without this patch compiler gives the following warning:
drivers/media/platform/s5p-mfc/s5p_mfc_enc.c:1576:2: warning:
initialization from incompatible pointer type [enabled by default]
drivers/media/platform/s5p-mfc/s5p_mfc_enc.c:1576:2: warning:
(near initialization for ‘s5p_mfc_enc_ioctl_ops.vidioc_subscribe_event’)
[enabled by default]

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>