summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorZhang Jiejing <jiejing.zhang@freescale.com>2011-11-04 16:36:58 +0800
committerZhang Jiejing <jiejing.zhang@freescale.com>2011-11-04 16:36:58 +0800
commitca10fff87ce88406729bcc40f72a728fc05c37ac (patch)
tree7ee861949cdcf507844672e30725d628b16a935b /include
parentc8cbd6d47526509df522df3065eecc44e01ed70e (diff)
parent68d44cdfe680069122d4bd7ebcf8da750d24fe3f (diff)
Merge branch 'imx_2.6.38' into imx_2.6.38_android
Conflicts: arch/arm/mach-mx6/board-mx6q_sabreauto.c arch/arm/mach-mx6/cpu_op-mx6.c arch/arm/plat-mxc/dvfs_core.c drivers/cpufreq/cpufreq_stats.c
Diffstat (limited to 'include')
-rw-r--r--include/linux/fec.h3
-rw-r--r--include/linux/fsl_devices.h11
-rwxr-xr-xinclude/linux/mfd/mc-pmic.h143
-rw-r--r--include/linux/mfd/mxc-hdmi-core.h12
-rw-r--r--include/linux/regulator/anatop-regulator.h82
-rw-r--r--include/sound/soc-dai.h2
-rw-r--r--include/sound/soc.h2
7 files changed, 251 insertions, 4 deletions
diff --git a/include/linux/fec.h b/include/linux/fec.h
index bcff455d1d53..d6a07048f842 100644
--- a/include/linux/fec.h
+++ b/include/linux/fec.h
@@ -3,7 +3,7 @@
* Copyright (c) 2009 Orex Computed Radiography
* Baruch Siach <baruch@tkos.co.il>
*
- * Copyright (C) 2010 Freescale Semiconductor, Inc.
+ * Copyright (C) 2010-2011 Freescale Semiconductor, Inc.
*
* Header file for the FEC platform data
*
@@ -17,6 +17,7 @@
#include <linux/phy.h>
struct fec_platform_data {
+ int (*init) (struct phy_device *);
phy_interface_t phy;
unsigned char mac[ETH_ALEN];
};
diff --git a/include/linux/fsl_devices.h b/include/linux/fsl_devices.h
index 4f9e869a4fae..cb2bcc1a47c0 100644
--- a/include/linux/fsl_devices.h
+++ b/include/linux/fsl_devices.h
@@ -65,6 +65,7 @@ enum fsl_usb2_phy_modes {
FSL_USB2_PHY_UTMI,
FSL_USB2_PHY_UTMI_WIDE,
FSL_USB2_PHY_SERIAL,
+ FSL_USB2_PHY_HSIC,
};
enum usb_wakeup_event {
@@ -117,6 +118,7 @@ struct fsl_usb2_platform_data {
void (*platform_driver_vbus)(bool on); /* for vbus shutdown/open */
enum usb_wakeup_event (*is_wakeup_event)(struct fsl_usb2_platform_data *);
void (*wakeup_handler)(struct fsl_usb2_platform_data *);
+ void (*hsic_post_ops)(void);
struct fsl_usb2_wakeup_platform_data *wakeup_pdata;
struct platform_device *pdev;
@@ -236,6 +238,9 @@ struct fsl_mxc_hdmi_platform_data {
void (*put_pins) (void);
void (*enable_pins) (void);
void (*disable_pins) (void);
+};
+
+struct fsl_mxc_hdmi_core_platform_data {
int ipu_id;
int disp_id;
};
@@ -325,7 +330,11 @@ struct mxc_spdif_platform_data {
int spdif_rx; /* S/PDIF rx enabled for this board */
int spdif_clk_44100; /* tx clk mux in SPDIF_REG_STC; -1 for none */
int spdif_clk_48000; /* tx clk mux in SPDIF_REG_STC; -1 for none */
- int spdif_clkid; /* rx clk mux select in SPDIF_REG_SRPC */
+ int spdif_div_44100; /* tx clk div in SPDIF_REG_STC */
+ int spdif_div_48000; /* tx clk div in SPDIF_REG_STC */
+ int spdif_div_32000; /* tx clk div in SPDIF_REG_STC */
+ int spdif_rx_clk; /* rx clk mux select in SPDIF_REG_SRPC */
+ int (*spdif_clk_set_rate) (struct clk *clk, unsigned long rate);
struct clk *spdif_clk;
struct clk *spdif_core_clk;
struct clk *spdif_audio_clk;
diff --git a/include/linux/mfd/mc-pmic.h b/include/linux/mfd/mc-pmic.h
new file mode 100755
index 000000000000..2256913b094b
--- /dev/null
+++ b/include/linux/mfd/mc-pmic.h
@@ -0,0 +1,143 @@
+/* For mc34708's pmic driver
+ * Copyright (C) 2004-2011 Freescale Semiconductor, Inc.
+ *
+ * based on:
+ * Copyright 2009-2010 Pengutronix, Uwe Kleine-Koenig
+ * <u.kleine-koenig@pengutronix.de>
+ *
+ * This program is free software; you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License version 2 as published by the
+ * Free Software Foundation.
+ */
+#ifndef __LINUX_MFD_MC_PMIC_H
+#define __LINUX_MFD_MC_PMIC_H
+
+#include <linux/interrupt.h>
+
+struct mc_pmic;
+
+void mc_pmic_lock(struct mc_pmic *mc_pmic);
+void mc_pmic_unlock(struct mc_pmic *mc_pmic);
+
+int mc_pmic_reg_read(struct mc_pmic *mc_pmic, unsigned int offset, u32 * val);
+int mc_pmic_reg_write(struct mc_pmic *mc_pmic, unsigned int offset, u32 val);
+int mc_pmic_reg_rmw(struct mc_pmic *mc_pmic, unsigned int offset,
+ u32 mask, u32 val);
+
+int mc_pmic_get_flags(struct mc_pmic *mc_pmic);
+
+int mc_pmic_irq_request(struct mc_pmic *mc_pmic, int irq,
+ irq_handler_t handler, const char *name, void *dev);
+int mc_pmic_irq_request_nounmask(struct mc_pmic *mc_pmic, int irq,
+ irq_handler_t handler, const char *name,
+ void *dev);
+int mc_pmic_irq_free(struct mc_pmic *mc_pmic, int irq, void *dev);
+
+int mc_pmic_irq_mask(struct mc_pmic *mc_pmic, int irq);
+int mc_pmic_irq_unmask(struct mc_pmic *mc_pmic, int irq);
+int mc_pmic_irq_status(struct mc_pmic *mc_pmic, int irq,
+ int *enabled, int *pending);
+int mc_pmic_irq_ack(struct mc_pmic *mc_pmic, int irq);
+
+int mc_pmic_get_flags(struct mc_pmic *mc_pmic);
+
+#ifdef CONFIG_MFD_MC34708
+#define MC34708_SW1A 0
+#define MC34708_SW1B 1
+#define MC34708_SW2 2
+#define MC34708_SW3 3
+#define MC34708_SW4A 4
+#define MC34708_SW4B 5
+#define MC34708_SW5 6
+#define MC34708_SWBST 7
+#define MC34708_VPLL 8
+#define MC34708_VREFDDR 9
+#define MC34708_VUSB 10
+#define MC34708_VUSB2 11
+#define MC34708_VDAC 12
+#define MC34708_VGEN1 13
+#define MC34708_VGEN2 14
+#define MC34708_REGU_NUM 15
+
+#define MC34708_REG_INT_STATUS0 0
+#define MC34708_REG_INT_MASK0 1
+#define MC34708_REG_INT_STATUS1 3
+#define MC34708_REG_INT_MASK1 4
+#define MC34708_REG_IDENTIFICATION 7
+#define MC_PMIC_REG_INT_MASK0 MC34708_REG_INT_MASK0
+#define MC_PMIC_REG_INT_MASK1 MC34708_REG_INT_MASK1
+#define MC_PMIC_REG_INT_STATUS0 MC34708_REG_INT_STATUS0
+#define MC_PMIC_REG_INT_STATUS1 MC34708_REG_INT_STATUS1
+#define MC_PMIC_REG_IDENTIFICATION MC34708_REG_IDENTIFICATION
+#endif
+
+#define MC_PMIC_IRQ_ADCDONE 0
+#define MC_PMIC_IRQ_TSDONE 1
+#define MC_PMIC_IRQ_TSPENDET 2
+#define MC_PMIC_IRQ_USBDET 3
+#define MC_PMIC_IRQ_AUXDET 4
+#define MC_PMIC_IRQ_USBOVP 5
+#define MC_PMIC_IRQ_AUXOVP 6
+#define MC_PMIC_IRQ_CHRTIMEEXP 7
+#define MC_PMIC_IRQ_BATTOTP 8
+#define MC_PMIC_IRQ_BATTOVP 9
+#define MC_PMIC_IRQ_CHRCMPL 10
+#define MC_PMIC_IRQ_WKVBUSDET 11
+#define MC_PMIC_IRQ_WKAUXDET 12
+#define MC_PMIC_IRQ_LOWBATT 13
+#define MC_PMIC_IRQ_VBUSREGMI 14
+#define MC_PMIC_IRQ_ATTACH 15
+#define MC_PMIC_IRQ_DETACH 16
+#define MC_PMIC_IRQ_KP 17
+#define MC_PMIC_IRQ_LKP 18
+#define MC_PMIC_IRQ_LKR 19
+#define MC_PMIC_IRQ_UKNOW_ATTA 20
+#define MC_PMIC_IRQ_ADC_CHANGE 21
+#define MC_PMIC_IRQ_STUCK_KEY 22
+#define MC_PMIC_IRQ_STUCK_KEY_RCV 23
+#define MC_PMIC_IRQ_1HZ 24
+#define MC_PMIC_IRQ_TODA 25
+#define MC_PMIC_IRQ_UNUSED1 26
+#define MC_PMIC_IRQ_PWRON1 27
+#define MC_PMIC_IRQ_PWRON2 28
+#define MC_PMIC_IRQ_WDIRESET 29
+#define MC_PMIC_IRQ_SYSRST 30
+#define MC_PMIC_IRQ_RTCRST 31
+#define MC_PMIC_IRQ_PCI 32
+#define MC_PMIC_IRQ_WARM 33
+#define MC_PMIC_IRQ_MEMHLD 34
+#define MC_PMIC_IRQ_UNUSED2 35
+#define MC_PMIC_IRQ_THWARNL 36
+#define MC_PMIC_IRQ_THWARNH 37
+#define MC_PMIC_IRQ_CLK 38
+#define MC_PMIC_IRQ_UNUSED3 39
+#define MC_PMIC_IRQ_SCP 40
+#define MC_PMIC_NUMREGS 0x3f
+#define MC_PMIC_NUM_IRQ 46
+
+struct regulator_init_data;
+
+struct mc_pmic_regulator_init_data {
+ int id;
+ struct regulator_init_data *init_data;
+};
+
+struct mc_pmic_regulator_platform_data {
+ int num_regulators;
+ struct mc_pmic_regulator_init_data *regulators;
+};
+
+struct mc_pmic_platform_data {
+#define MC_PMIC_USE_TOUCHSCREEN (1 << 0)
+#define MC_PMIC_USE_CODEC (1 << 1)
+#define MC_PMIC_USE_ADC (1 << 2)
+#define MC_PMIC_USE_RTC (1 << 3)
+#define MC_PMIC_USE_REGULATOR (1 << 4)
+#define MC_PMIC_USE_LED (1 << 5)
+ unsigned int flags;
+
+ int num_regulators;
+ struct mc_pmic_regulator_init_data *regulators;
+};
+
+#endif /* ifndef __LINUX_MFD_MC_PMIC_H */
diff --git a/include/linux/mfd/mxc-hdmi-core.h b/include/linux/mfd/mxc-hdmi-core.h
index f5021c7acb44..f449946a50f6 100644
--- a/include/linux/mfd/mxc-hdmi-core.h
+++ b/include/linux/mfd/mxc-hdmi-core.h
@@ -19,13 +19,21 @@
#ifndef __LINUX_MXC_HDMI_CORE_H_
#define __LINUX_MXC_HDMI_CORE_H_
+#define IRQ_DISABLE_SUCCEED 0
+#define IRQ_DISABLE_FAIL 1
+
u8 hdmi_readb(unsigned int reg);
void hdmi_writeb(u8 value, unsigned int reg);
void hdmi_mask_writeb(u8 data, unsigned int addr, u8 shift, u8 mask);
unsigned int hdmi_read4(unsigned int reg);
void hdmi_write4(unsigned int value, unsigned int reg);
+void hdmi_irq_init(void);
+void hdmi_irq_enable(int irq);
+unsigned int hdmi_irq_disable(int irq);
+void hdmi_set_sample_rate(unsigned int rate);
+void hdmi_set_clk_regenerator(void);
-extern int mxc_hdmi_pixel_clk;
-extern int mxc_hdmi_ratio;
+extern int mxc_hdmi_ipu_id;
+extern int mxc_hdmi_disp_id;
#endif
diff --git a/include/linux/regulator/anatop-regulator.h b/include/linux/regulator/anatop-regulator.h
new file mode 100644
index 000000000000..a1d98ed42c25
--- /dev/null
+++ b/include/linux/regulator/anatop-regulator.h
@@ -0,0 +1,82 @@
+/*
+ * Copyright (C) 2011 Freescale Semiconductor, Inc. All Rights Reserved.
+ */
+
+/*
+ * 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.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+ */
+
+#ifndef __ANATOP_REGULATOR_H
+#define __ANATOP_REGULATOR_H
+#include <linux/regulator/driver.h>
+
+/* regulator supplies for Anatop */
+enum anatop_regulator_supplies {
+ ANATOP_VDDPU,
+ ANATOP_VDDCORE,
+ ANATOP_VDDSOC,
+ ANATOP_VDD2P5,
+ ANATOP_VDD1P1,
+ ANATOP_VDD3P0,
+ ANATOP_SUPPLY_NUM
+};
+
+struct anatop_regulator {
+ struct regulator_desc regulator;
+ struct anatop_regulator *parent;
+ struct anatop_regulator_data *rdata;
+ struct completion done;
+
+ spinlock_t lock;
+ wait_queue_head_t wait_q;
+ struct notifier_block nb;
+
+ int mode;
+ int cur_voltage;
+ int cur_current;
+ int next_current;
+};
+
+
+struct anatop_regulator_data {
+ char name[80];
+ char *parent_name;
+ int (*reg_register)(struct anatop_regulator *sreg);
+ int (*set_voltage)(struct anatop_regulator *sreg, int uv);
+ int (*get_voltage)(struct anatop_regulator *sreg);
+ int (*set_current)(struct anatop_regulator *sreg, int uA);
+ int (*get_current)(struct anatop_regulator *sreg);
+ int (*enable)(struct anatop_regulator *sreg);
+ int (*disable)(struct anatop_regulator *sreg);
+ int (*is_enabled)(struct anatop_regulator *sreg);
+ int (*set_mode)(struct anatop_regulator *sreg, int mode);
+ int (*get_mode)(struct anatop_regulator *sreg);
+ int (*get_optimum_mode)(struct anatop_regulator *sreg,
+ int input_uV, int output_uV, int load_uA);
+ u32 control_reg;
+ int vol_bit_shift;
+ int vol_bit_mask;
+ int min_bit_val;
+ int min_voltage;
+ int max_voltage;
+ int max_current;
+ struct regulation_constraints *cnstraints;
+};
+
+int anatop_register_regulator(
+ struct anatop_regulator *reg_data, int reg,
+ struct regulator_init_data *initdata);
+
+#endif /* __ANATOP_REGULATOR_H */
diff --git a/include/sound/soc-dai.h b/include/sound/soc-dai.h
index 1bafe95dcf41..dc60e5e07226 100644
--- a/include/sound/soc-dai.h
+++ b/include/sound/soc-dai.h
@@ -172,6 +172,8 @@ struct snd_soc_dai_ops {
struct snd_soc_dai *);
int (*trigger)(struct snd_pcm_substream *, int,
struct snd_soc_dai *);
+ int (*ioctl)(struct snd_pcm_substream *, unsigned int, void *,
+ struct snd_soc_dai *);
/*
* For hardware based FIFO caused delay reporting.
* Optional.
diff --git a/include/sound/soc.h b/include/sound/soc.h
index 74921f20a1d8..a002ae218047 100644
--- a/include/sound/soc.h
+++ b/include/sound/soc.h
@@ -430,6 +430,7 @@ struct snd_soc_ops {
int (*hw_free)(struct snd_pcm_substream *);
int (*prepare)(struct snd_pcm_substream *);
int (*trigger)(struct snd_pcm_substream *, int);
+ int (*ioctl)(struct snd_pcm_substream *, unsigned int, void *);
};
/* SoC cache ops */
@@ -693,6 +694,7 @@ struct snd_soc_pcm_runtime {
struct snd_soc_dai *cpu_dai;
struct delayed_work delayed_work;
+ struct snd_pcm_ops *ops;
};
/* mixer control */