mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-16 17:23:55 +08:00
3aa78e0cb5
But we also have: - Support for the TPS659038 PMIC from the palmas driver. - Intel's Coleto Creek and Avoton SoCs support from the lpc_ich driver. - RTL8411B support from the rtsx driver. - More DT support for the Arizona, max8998, twl4030-power and the ti_am335x_tsadc drivers. - The SSBI driver move under MFD. - A conversion to the devm_* API for most of the MFD drivers. - The twl4030-power got split from twl-core into its own module. - A major ti_am335x_adc cleanup, leading to a proper DT support. - Our regular arizona and wm* updates and cleanups from the Wolfson folks. - A better error handling and initialization, and a regulator subdevice addition for the 88pm80x driver. - A bulk platform_set_drvdata() call removal that's no longer need since commit0998d063
. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iQIcBAABAgAGBQJR2zCaAAoJEIqAPN1PVmxK29EP/ieZf7Z7z7bg/0lEOvtOzACy WoCdSGFu5XcHOnlv0Fl1Rr/1AJFQoh4KugkGnVyrlztYVOFymj5VDdd8B43cxMLt 7ymK/3crIH7uJuOoeDoDr3glLuo0TGB9f5Kv4ITdVD3/+AuqY4VIAisEDb0aWghW +v0I3fYeGdwRv+IqO5wacvddSoLa4rmOhnpbVMB2O1Y/LCm/yHI6tAFx1+AfH7y8 zMHbGFc+gHg1xupJBCnRel0v8J+KNc02G/B1zNom/avL8b/mNXNI8JFxs3bMA0r8 NpTHJ49OVPbhBQTA4U+BPoG4nzOiAOj0czf9dkGa5cyR8t4C9mmK+s8QHwepzrSG qbhCgTqp4bomB1m0RAO+z4F6BHTpmoChpho2btrwN9ZmhMHQeTWnGjjhEwZngpBq F22DC6k5ipV0k4962ZHfZ76v2Vot1gfd6zQ5r+2oHMMfWaKgS4L5efP2/wsU9H58 BxMm84C7OWbgcTRmNn9jl4L9phBD31wvNANfUeMhLMyshnwPK5ZuUdX/+K2rq6h9 w26Hg62HtKZFv/TEsCBQqpB6zSZa4u/KZzvwEahllQSQGKxIHaNYGtLGzJj9sCM+ baT/82DFKuEvKfJpUKSBMznImp4WNGEz+8s2w4m/Ssuf30GN2GHjM9Q4gcHJu2mk 7fTrsSHWYN+EHVzh1Zb8 =RqMp -----END PGP SIGNATURE----- Merge tag 'mfd-3.11-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-next Pull MFD update from Samuel Ortiz: "For the 3.11 merge we only have one new MFD driver for the Kontron PLD. But we also have: - Support for the TPS659038 PMIC from the palmas driver. - Intel's Coleto Creek and Avoton SoCs support from the lpc_ich driver. - RTL8411B support from the rtsx driver. - More DT support for the Arizona, max8998, twl4030-power and the ti_am335x_tsadc drivers. - The SSBI driver move under MFD. - A conversion to the devm_* API for most of the MFD drivers. - The twl4030-power got split from twl-core into its own module. - A major ti_am335x_adc cleanup, leading to a proper DT support. - Our regular arizona and wm* updates and cleanups from the Wolfson folks. - A better error handling and initialization, and a regulator subdevice addition for the 88pm80x driver. - A bulk platform_set_drvdata() call removal that's no longer need since commit0998d06310
("device-core: Ensure drvdata = NULL when no driver is bound") * tag 'mfd-3.11-1' of git://git.kernel.org/pub/scm/linux/kernel/git/sameo/mfd-next: (102 commits) mfd: sec: Provide max_register to regmap mfd: wm8994: Remove duplicate check for active JACKDET MAINTAINERS: Add include directory to MFD file patterns mfd: sec: Remove fields not used since regmap conversion watchdog: Kontron PLD watchdog timer driver mfd: max8998: Add support for Device Tree regulator: max8998: Use arrays for specifying voltages in platform data mfd: max8998: Add irq domain support regulator: palmas: Add TPS659038 support mfd: Kontron PLD mfd driver mfd: palmas: Add TPS659038 PMIC support mfd: palmas: Add SMPS10_BOOST feature mfd: palmas: Check if irq is valid mfd: lpc_ich: iTCO_wdt patch for Intel Coleto Creek DeviceIDs mfd: twl-core: Change TWL6025 references to TWL6032 mfd: davinci_voicecodec: Fix build breakage mfd: vexpress: Make the driver optional for arm and arm64 mfd: htc-egpio: Use devm_ioremap_nocache() instead of ioremap_nocache() mfd: davinci_voicecodec: Convert to use devm_* APIs mfd: twl4030-power: Fix relocking on error ...
126 lines
3.4 KiB
C
126 lines
3.4 KiB
C
/*
|
|
* DaVinci Voice Codec Core Interface for TI platforms
|
|
*
|
|
* Copyright (C) 2010 Texas Instruments, Inc
|
|
*
|
|
* Author: Miguel Aguilar <miguel.aguilar@ridgerun.com>
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License as published by
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
* (at your option) any later version.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program; if not, write to the Free Software
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
*/
|
|
|
|
#ifndef __LINUX_MFD_DAVINCI_VOICECODEC_H_
|
|
#define __LINUX_MFD_DAVINIC_VOICECODEC_H_
|
|
|
|
#include <linux/kernel.h>
|
|
#include <linux/platform_device.h>
|
|
#include <linux/mfd/core.h>
|
|
#include <linux/platform_data/edma.h>
|
|
|
|
#include <mach/hardware.h>
|
|
|
|
/*
|
|
* Register values.
|
|
*/
|
|
#define DAVINCI_VC_PID 0x00
|
|
#define DAVINCI_VC_CTRL 0x04
|
|
#define DAVINCI_VC_INTEN 0x08
|
|
#define DAVINCI_VC_INTSTATUS 0x0c
|
|
#define DAVINCI_VC_INTCLR 0x10
|
|
#define DAVINCI_VC_EMUL_CTRL 0x14
|
|
#define DAVINCI_VC_RFIFO 0x20
|
|
#define DAVINCI_VC_WFIFO 0x24
|
|
#define DAVINCI_VC_FIFOSTAT 0x28
|
|
#define DAVINCI_VC_TST_CTRL 0x2C
|
|
#define DAVINCI_VC_REG05 0x94
|
|
#define DAVINCI_VC_REG09 0xA4
|
|
#define DAVINCI_VC_REG12 0xB0
|
|
|
|
/* DAVINCI_VC_CTRL bit fields */
|
|
#define DAVINCI_VC_CTRL_MASK 0x5500
|
|
#define DAVINCI_VC_CTRL_RSTADC BIT(0)
|
|
#define DAVINCI_VC_CTRL_RSTDAC BIT(1)
|
|
#define DAVINCI_VC_CTRL_RD_BITS_8 BIT(4)
|
|
#define DAVINCI_VC_CTRL_RD_UNSIGNED BIT(5)
|
|
#define DAVINCI_VC_CTRL_WD_BITS_8 BIT(6)
|
|
#define DAVINCI_VC_CTRL_WD_UNSIGNED BIT(7)
|
|
#define DAVINCI_VC_CTRL_RFIFOEN BIT(8)
|
|
#define DAVINCI_VC_CTRL_RFIFOCL BIT(9)
|
|
#define DAVINCI_VC_CTRL_RFIFOMD_WORD_1 BIT(10)
|
|
#define DAVINCI_VC_CTRL_WFIFOEN BIT(12)
|
|
#define DAVINCI_VC_CTRL_WFIFOCL BIT(13)
|
|
#define DAVINCI_VC_CTRL_WFIFOMD_WORD_1 BIT(14)
|
|
|
|
/* DAVINCI_VC_INT bit fields */
|
|
#define DAVINCI_VC_INT_MASK 0x3F
|
|
#define DAVINCI_VC_INT_RDRDY_MASK BIT(0)
|
|
#define DAVINCI_VC_INT_RERROVF_MASK BIT(1)
|
|
#define DAVINCI_VC_INT_RERRUDR_MASK BIT(2)
|
|
#define DAVINCI_VC_INT_WDREQ_MASK BIT(3)
|
|
#define DAVINCI_VC_INT_WERROVF_MASKBIT BIT(4)
|
|
#define DAVINCI_VC_INT_WERRUDR_MASK BIT(5)
|
|
|
|
/* DAVINCI_VC_REG05 bit fields */
|
|
#define DAVINCI_VC_REG05_PGA_GAIN 0x07
|
|
|
|
/* DAVINCI_VC_REG09 bit fields */
|
|
#define DAVINCI_VC_REG09_MUTE 0x40
|
|
#define DAVINCI_VC_REG09_DIG_ATTEN 0x3F
|
|
|
|
/* DAVINCI_VC_REG12 bit fields */
|
|
#define DAVINCI_VC_REG12_POWER_ALL_ON 0xFD
|
|
#define DAVINCI_VC_REG12_POWER_ALL_OFF 0x00
|
|
|
|
#define DAVINCI_VC_CELLS 2
|
|
|
|
enum davinci_vc_cells {
|
|
DAVINCI_VC_VCIF_CELL,
|
|
DAVINCI_VC_CQ93VC_CELL,
|
|
};
|
|
|
|
struct davinci_vcif {
|
|
struct platform_device *pdev;
|
|
u32 dma_tx_channel;
|
|
u32 dma_rx_channel;
|
|
dma_addr_t dma_tx_addr;
|
|
dma_addr_t dma_rx_addr;
|
|
};
|
|
|
|
struct cq93vc {
|
|
struct platform_device *pdev;
|
|
struct snd_soc_codec *codec;
|
|
u32 sysclk;
|
|
};
|
|
|
|
struct davinci_vc;
|
|
|
|
struct davinci_vc {
|
|
/* Device data */
|
|
struct device *dev;
|
|
struct platform_device *pdev;
|
|
struct clk *clk;
|
|
|
|
/* Memory resources */
|
|
void __iomem *base;
|
|
|
|
/* MFD cells */
|
|
struct mfd_cell cells[DAVINCI_VC_CELLS];
|
|
|
|
/* Client devices */
|
|
struct davinci_vcif davinci_vcif;
|
|
struct cq93vc cq93vc;
|
|
};
|
|
|
|
#endif
|