diff options
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/mmc/host.h | 2 | ||||
| -rw-r--r-- | include/media/msm_ba.h | 81 | ||||
| -rw-r--r-- | include/soc/qcom/minidump.h | 5 | ||||
| -rw-r--r-- | include/uapi/linux/v4l2-controls.h | 6 | ||||
| -rw-r--r-- | include/uapi/linux/videodev2.h | 32 |
5 files changed, 124 insertions, 2 deletions
diff --git a/include/linux/mmc/host.h b/include/linux/mmc/host.h index 279411c42ded..aea4c0f2ef5f 100644 --- a/include/linux/mmc/host.h +++ b/include/linux/mmc/host.h @@ -823,6 +823,8 @@ static inline bool mmc_card_hs400(struct mmc_card *card) return card->host->ios.timing == MMC_TIMING_MMC_HS400; } +void mmc_retune_enable(struct mmc_host *host); +void mmc_retune_disable(struct mmc_host *host); void mmc_retune_timer_stop(struct mmc_host *host); static inline void mmc_retune_needed(struct mmc_host *host) diff --git a/include/media/msm_ba.h b/include/media/msm_ba.h new file mode 100644 index 000000000000..1b51e3f754d8 --- /dev/null +++ b/include/media/msm_ba.h @@ -0,0 +1,81 @@ +/* Copyright (c) 2012-2015, The Linux Foundation. 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 version 2 and + * only version 2 as published by the Free Software Foundation. + * + * 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. + * + */ + +#ifndef _MSM_BA_H_ +#define _MSM_BA_H_ + +#include <linux/videodev2.h> +#include <media/v4l2-device.h> +#include <linux/poll.h> + +enum msm_ba_ip { + BA_IP_CVBS_0 = 0, + BA_IP_CVBS_1, + BA_IP_CVBS_2, + BA_IP_CVBS_3, + BA_IP_CVBS_4, + BA_IP_CVBS_5, + BA_IP_SVIDEO_0, + BA_IP_SVIDEO_1, + BA_IP_SVIDEO_2, + BA_IP_COMPONENT_0, + BA_IP_COMPONENT_1, + BA_IP_DVI_0, + BA_IP_DVI_1, + BA_IP_HDMI_1, + BA_IP_MHL_1, + BA_IP_TTL, + BA_IP_MAX = 0xffffffff +}; + +enum msm_ba_save_restore_ip { + BA_SR_RESTORE_IP = 0, + BA_SR_SAVE_IP, + BA_SR_MAX = 0xffffffff +}; + +struct msm_ba_ext_ops { + void (*msm_ba_cb)(void *instance, + unsigned int event_id, void *arg); +}; + +void *msm_ba_open(const struct msm_ba_ext_ops *ext_ops); +int msm_ba_close(void *instance); +int msm_ba_querycap(void *instance, struct v4l2_capability *cap); +int msm_ba_g_priority(void *instance, enum v4l2_priority *prio); +int msm_ba_s_priority(void *instance, enum v4l2_priority prio); +int msm_ba_enum_input(void *instance, struct v4l2_input *input); +int msm_ba_g_input(void *instance, unsigned int *index); +int msm_ba_s_input(void *instance, unsigned int index); +int msm_ba_enum_output(void *instance, struct v4l2_output *output); +int msm_ba_g_output(void *instance, unsigned int *index); +int msm_ba_s_output(void *instance, unsigned int index); +int msm_ba_enum_fmt(void *instance, struct v4l2_fmtdesc *f); +int msm_ba_s_fmt(void *instance, struct v4l2_format *f); +int msm_ba_g_fmt(void *instance, struct v4l2_format *f); +int msm_ba_s_ctrl(void *instance, struct v4l2_control *a); +int msm_ba_s_ext_ctrl(void *instance, struct v4l2_ext_controls *a); +int msm_ba_g_ctrl(void *instance, struct v4l2_control *a); +int msm_ba_streamon(void *instance, enum v4l2_buf_type i); +int msm_ba_streamoff(void *instance, enum v4l2_buf_type i); +int msm_ba_save_restore_input(void *instance, enum msm_ba_save_restore_ip sr); +int msm_ba_poll(void *instance, struct file *filp, + struct poll_table_struct *pt); +int msm_ba_subscribe_event(void *instance, + const struct v4l2_event_subscription *sub); +int msm_ba_unsubscribe_event(void *instance, + const struct v4l2_event_subscription *sub); +int msm_ba_s_parm(void *instance, struct v4l2_streamparm *a); +int msm_ba_register_subdev_node(struct v4l2_subdev *sd); +int msm_ba_unregister_subdev_node(struct v4l2_subdev *sd); +#endif diff --git a/include/soc/qcom/minidump.h b/include/soc/qcom/minidump.h index 2db61a40e2cc..5eb18cb1a365 100644 --- a/include/soc/qcom/minidump.h +++ b/include/soc/qcom/minidump.h @@ -37,12 +37,13 @@ struct md_region { */ #ifdef CONFIG_QCOM_MINIDUMP extern int msm_minidump_add_region(const struct md_region *entry); +/* Sets to true, if minidump table is initialized */ extern bool minidump_enabled; #else static inline int msm_minidump_add_region(const struct md_region *entry) { - return -ENODEV; + /* Return quietly, if minidump is not supported */ + return 0; } -static inline bool msm_minidump_enabled(void) { return false; } #endif #endif diff --git a/include/uapi/linux/v4l2-controls.h b/include/uapi/linux/v4l2-controls.h index 336d318c5187..2e4c02f24a47 100644 --- a/include/uapi/linux/v4l2-controls.h +++ b/include/uapi/linux/v4l2-controls.h @@ -1331,6 +1331,12 @@ enum v4l2_auto_focus_range { #define V4L2_CID_PAN_SPEED (V4L2_CID_CAMERA_CLASS_BASE+32) #define V4L2_CID_TILT_SPEED (V4L2_CID_CAMERA_CLASS_BASE+33) +/* User-class control IDs specific to the msm_ba driver */ + +#define MSM_BA_PRIV_BASE_START (V4L2_CID_USER_BASE | 0x7000) +#define MSM_BA_PRIV_SD_NODE_ADDR (MSM_BA_PRIV_BASE_START + 1) +#define MSM_BA_PRIV_FPS (MSM_BA_PRIV_BASE_START + 2) + /* FM Modulator class control IDs */ #define V4L2_CID_FM_TX_CLASS_BASE (V4L2_CTRL_CLASS_FM_TX | 0x900) diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h index 686fc6143010..bb2c4ebf9ff4 100644 --- a/include/uapi/linux/videodev2.h +++ b/include/uapi/linux/videodev2.h @@ -2187,6 +2187,31 @@ struct v4l2_streamparm { #define V4L2_EVENT_MSM_VIDC_MAX_CLIENTS (V4L2_EVENT_MSM_VIDC_START + 9) #define V4L2_EVENT_MSM_VIDC_HW_UNSUPPORTED (V4L2_EVENT_MSM_VIDC_START + 10) +#define V4L2_EVENT_MSM_BA_PRIVATE_EVENT_BASE \ + (V4L2_EVENT_PRIVATE_START + 0x00005000) +#define V4L2_EVENT_MSM_BA_START V4L2_EVENT_MSM_BA_PRIVATE_EVENT_BASE +#define V4L2_EVENT_MSM_BA_DEVICE_AVAILABLE (V4L2_EVENT_MSM_BA_START + 1) +#define V4L2_EVENT_MSM_BA_DEVICE_UNAVAILABLE \ + (V4L2_EVENT_MSM_BA_START + 2) +#define V4L2_EVENT_MSM_BA_PORT_SETTINGS_CHANGED \ + (V4L2_EVENT_MSM_BA_START + 3) +#define V4L2_EVENT_MSM_BA_SIGNAL_IN_LOCK \ + (V4L2_EVENT_MSM_BA_START + 4) +#define V4L2_EVENT_MSM_BA_SIGNAL_LOST_LOCK \ + (V4L2_EVENT_MSM_BA_START + 5) +#define V4L2_EVENT_MSM_BA_SOURCE_CHANGE \ + (V4L2_EVENT_MSM_BA_START + 6) +#define V4L2_EVENT_MSM_BA_HDMI_HPD \ + (V4L2_EVENT_MSM_BA_START + 7) +#define V4L2_EVENT_MSM_BA_HDMI_CEC_MESSAGE \ + (V4L2_EVENT_MSM_BA_START + 8) +#define V4L2_EVENT_MSM_BA_CP \ + (V4L2_EVENT_MSM_BA_START + 9) +#define V4L2_EVENT_MSM_BA_CABLE_DETECT \ + (V4L2_EVENT_MSM_BA_START + 10) +#define V4L2_EVENT_MSM_BA_ERROR \ + (V4L2_EVENT_MSM_BA_START + 11) + /* Payload for V4L2_EVENT_VSYNC */ struct v4l2_event_vsync { /* Can be V4L2_FIELD_ANY, _NONE, _TOP or _BOTTOM */ @@ -2442,4 +2467,11 @@ struct v4l2_create_buffers { #define BASE_VIDIOC_PRIVATE 192 /* 192-255 are private */ +/* HDMI rx provide ioctls */ +#define VIDIOC_HDMI_RX_CEC_S_LOGICAL _IOW('V', BASE_VIDIOC_PRIVATE + 0, int) +#define VIDIOC_HDMI_RX_CEC_CLEAR_LOGICAL _IO('V', BASE_VIDIOC_PRIVATE + 1) +#define VIDIOC_HDMI_RX_CEC_G_PHYSICAL _IOR('V', BASE_VIDIOC_PRIVATE + 2, int) +#define VIDIOC_HDMI_RX_CEC_G_CONNECTED _IOR('V', BASE_VIDIOC_PRIVATE + 3, int) +#define VIDIOC_HDMI_RX_CEC_S_ENABLE _IOR('V', BASE_VIDIOC_PRIVATE + 4, int) + #endif /* _UAPI__LINUX_VIDEODEV2_H */ |
