This patch adds support for passing platform data to ac97 bus devices
from PXA2xx-AC97 driver..
Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Extend set_tdm_slot to allow the user to arbitrarily set the frame width
and active TX/RX slots.
Updates magician.c and wm9081.c for the new set_tdm_slot(). wm9081.c
still doesn't handle the slot_width override.
While being there, correct an incorrect use of SlotsPerFrm(7) use in
bitmask on pxa-ssp.c (SSCR0_SlotsPerFrm(x) is (((x) - 1) << 24)) ).
(this series is meant for Mark's for-2.6.32 branch)
Signed-off-by: Daniel Ribeiro <drwyrm@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This patch removes the old method of jack detection from palm27x-asoc
driver and adds jack detection api. It also removes some other (now)
useless stuff from the driver and corrects pin configuration for the
codec.
Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The clock API can't cope with unbalanced enables and disables and
we only enable in hw_params() but try to disable in shutdown.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The wm8731 driver has been converted to register using the standard I2C
device registration mechanism so we can now do the registration in the
arch/arm code as normal.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
This patch mostly follows commit 5998102b90
"ASoC: Refactor WM8731 device registration" to make UDA1380 use standard
device instantiation. Similarly, the I2C device registration temporarily
moves into the magician machine driver before it will find its final
resting place in the board file.
At the same time, platform specific configuration is moved to platform data
and common power/reset GPIO handling moves into the codec driver.
Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* 'for-linus' of master.kernel.org:/home/rmk/linux-2.6-arm: (417 commits)
MAINTAINERS: EB110ATX is not ebsa110
MAINTAINERS: update Eric Miao's email address and status
fb: add support of LCD display controller on pxa168/910 (base layer)
[ARM] 5552/1: ep93xx get_uart_rate(): use EP93XX_SYSCON_PWRCNT and EP93XX_SYSCON_PWRCN
[ARM] pxa/sharpsl_pm: zaurus needs generic pxa suspend/resume routines
[ARM] 5544/1: Trust PrimeCell resource sizes
[ARM] pxa/sharpsl_pm: cleanup of gpio-related code.
[ARM] pxa/sharpsl_pm: drop set_irq_type calls
[ARM] pxa/sharpsl_pm: merge pxa-specific code into generic one
[ARM] pxa/sharpsl_pm: merge the two sharpsl_pm.c since it's now pxa specific
[ARM] sa1100: remove unused collie_pm.c
[ARM] pxa: fix the conflicting non-static declarations of global_gpios[]
[ARM] 5550/1: Add default configure file for w90p910 platform
[ARM] 5549/1: Add clock api for w90p910 platform.
[ARM] 5548/1: Add gpio api for w90p910 platform
[ARM] 5551/1: Add multi-function pin api for w90p910 platform.
[ARM] Make ARM_VIC_NR depend on ARM_VIC
[ARM] 5546/1: ARM PL022 SSP/SPI driver v3
ARM: OMAP4: SMP: Update defconfig for OMAP4430
ARM: OMAP4: SMP: Enable SMP support for OMAP4430
...
Follow-up fix needed since "ASoC: pxa-ssp.c fix clock/frame invert".
Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* We don't need to write the registers twice, remove the first write.
* DAIFMT_INV switch is duplicated inside DAIFMT_FORMAT switch, move it
out.
(This patch is for Mark's for-2.6.32 branch, I have not checked if the
code is duplicated on current 2.6.30)
Signed-off-by: Daniel Ribeiro <drwyrm@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Unsigned variables should use `%u' rather than `%d'.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Use default to optimize the switch/case in magicial_playback_hw_params(),
which also fixes the compile warnings below:
sound/soc/pxa/magician.c:89: warning: 'acds' may be used uninitialized in this function
sound/soc/pxa/magician.c:89: warning: 'acps' may be used uninitialized in this function
Signed-off-by: Takashi Iwai <tiwai@suse.de>
pxa2xx_i2s_resume is :
- unconditionnaly setting SACR0_ENB
- unsetting SACR0_ENB in saved SACR0 pxa_i2s.sacr0
fix these.
In pxa2xx_i2s_{resume,suspend}, save/restore registers even
when !dai->active.
Signed-off-by: Karl Beldan <karl.beldan@mobile-devices.fr>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
i2s_clk is 'put' for no reason in pxa2xx_i2s_shutdown.
Now we 'get' i2s_clk at probe and 'put' it at driver removal or when
probe fails.
Signed-off-by: Karl Beldan <karl.beldan@mobile-devices.fr>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
- hw_params enables both RPL and REC functions each time : Enable the
appropriate function in pxa2xx_i2s_trigger.
- pxa2xx_i2s_shutdown disables i2s anytime one of RPL or REC function is
off : Turn it off only when both functions are off.
Signed-off-by: Karl Beldan <karl.beldan@mobile-devices.fr>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Make sure we are in a know good state at end of probe :
Reset FIFO logic and registers, and make sure REC and RPL functions
along with FIFO service are disabled (SACR0_RST enables REC and RPL).
Resetting loses current settings so remove reset from stream startup.
Now reset occurs only at probe.
Signed-off-by: Karl Beldan <karl.beldan@mobile-devices.fr>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This patch adds the ASoC side of the board support for the Crossbow
IMB400 daughter board.
Thanks to Crossbow for considerable assistance.
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The original idea came from pHilipp, and this makes the code looks
more consistent.
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
The SSP DMA parameters can actually be easily generated at run-time since
they are almost similar except for the FIFO width and direction. Another
benefit is the re-use of information from 'struct ssp_device', like SSDR
physical FIFO address and DRCMR register index for both directions.
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Reviewed-by: pHilipp Zabel <philipp.zabel@gmail.com>
Firstly, this patch makes the palm27x asoc driver a little more sane. Also,
since all affected devices use GPIO95 as AC97_nRESET, this patch sets that
properly. Affected are PalmT5, TX and LifeDrive.
Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Those macros are just screwed as soon as CONFIG_PXA25x is enabled.
This patch
- changes ssp_set_scr to take an ssp_dev pointer instead of ssp_device
- adds a corresponding ssp_get_scr function.
Signed-off-by: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
pxa_ssp_set_dai_fmt() currently has an early exit if the desired format
equals the current configuration. This is correct behaviour unless this
function is called with a zero value parameter for the first time.
Zero is a valid value for this function, but the early exit is bogus in
this case.
Hence, set priv->dai_fmt to -1 in the beginning so we can configure the
port.
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Cc: pHilipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
SCMODE(0): Data Driven (Falling), Data Sampled (Rising), Idle State (Low)
SCMODE(1): Data Driven (Rising), Data Sampled (Falling), Idle State (Low)
SCMODE(2): Data Driven (Rising), Data Sampled (Falling), Idle State (High)
SCMODE(3): Data Driven (Falling), Data Sampled (Rising), Idle State (High)
SCMODE(3) does not invert the clock polarity compared to the default SCMODE(0).
This patch also adds all possible NF/IF, NB/IB combinations to the DSP_A and
DSP_B modes.
Signed-off-by: Daniel Ribeiro <drwyrm@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Eric Miao <eric.miao@marvell.com>
Cc: Philipp Zabel <philipp.zabel@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound-2.6: (36 commits)
ALSA: hda - Add VREF powerdown sequence for another board
ALSA: oss - volume control for CSWITCH and CROUTE
ALSA: hda - add missing comma in ad1884_slave_vols
sound: usb-audio: allow period sizes less than 1 ms
sound: usb-audio: save data packet interval in audioformat structure
sound: usb-audio: remove check_hw_params_convention()
sound: usb-audio: show sample format width in proc file
ASoC: fsl_dma: Pass the proper device for dma mapping routines
ASoC: Fix null dereference in ak4535_remove()
ALSA: hda - enable SPDIF output for Intel DX58SO board
ALSA: snd-atmel-abdac: increase periods_min to 6 instead of 4
ALSA: snd-atmel-abdac: replace bus_id with dev_name()
ALSA: snd-atmel-ac97c: replace bus_id with dev_name()
ALSA: snd-atmel-ac97c: cleanup registers when removing driver
ALSA: snd-atmel-ac97c: do a proper reset of the external codec
ALSA: snd-atmel-ac97c: enable interrupts to catch events for error reporting
ALSA: snd-atmel-ac97c: set correct size for buffer hardware parameter
ALSA: snd-atmel-ac97c: do not overwrite OCA and ICA when assigning channels
ALSA: snd-atmel-ac97c: remove dead break statements after return in switch case
ALSA: snd-atmel-ac97c: cleanup register definitions
...
Replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32)
Signed-off-by: Yang Hongyang<yanghy@cn.fujitsu.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>