Merge tag 'media/v4.6-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media
Pull media updates from Mauro Carvalho Chehab: - Added support for some new video formats - mn88473 DVB frontend driver got promoted from staging - several improvements at the VSP1 driver - several cleanups and improvements at the Media Controller - added Media Controller support to snd-usb-audio. Currently, enabled only for au0828-based V4L2/DVB boards - Several improvements at nuvoton-cir: it now supports wake up codes - Add media controller support to em28xx and saa7134 drivers - coda driver now accepts NXP distributed firmware files - Some legacy SoC camera drivers will be moving to staging, as they're outdated and nobody so far is willing to fix and convert them to use the current media framework - As usual, lots of cleanups, improvements and new board additions. * tag 'media/v4.6-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media: (381 commits) media: au0828 disable tuner to demod link in au0828_media_device_register() [media] touptek: cast char types on %x printk [media] touptek: don't DMA at the stack [media] mceusb: use %*ph for small buffer dumps [media] v4l: exynos4-is: Drop unneeded check when setting up fimc-lite links [media] v4l: vsp1: Check if an entity is a subdev with the right function [media] hide unused functions for !MEDIA_CONTROLLER [media] em28xx: fix Terratec Grabby AC97 codec detection [media] media: add prefixes to interface types [media] media: rc: nuvoton: switch attribute wakeup_data to text [media] v4l2-ioctl: fix YUV422P pixel format description [media] media: fix null pointer dereference in v4l_vb2q_enable_media_source() [media] v4l2-mc.h: fix yet more compiler errors [media] staging/media: add missing TODO files [media] media.h: always start with 1 for the audio entities [media] sound/usb: Use meaninful names for goto labels [media] v4l2-mc.h: fix compiler warnings [media] media: au0828 audio mixer isn't connected to decoder [media] sound/usb: Use Media Controller API to share media resources [media] dw2102: add support for TeVii S662 ...
This commit is contained in:
@@ -78,6 +78,22 @@ struct media_device_info {
|
||||
#define MEDIA_ENT_F_IO_VBI (MEDIA_ENT_F_BASE + 0x01002)
|
||||
#define MEDIA_ENT_F_IO_SWRADIO (MEDIA_ENT_F_BASE + 0x01003)
|
||||
|
||||
/*
|
||||
* Analog TV IF-PLL decoders
|
||||
*
|
||||
* It is a responsibility of the master/bridge drivers to create links
|
||||
* for MEDIA_ENT_F_IF_VID_DECODER and MEDIA_ENT_F_IF_AUD_DECODER.
|
||||
*/
|
||||
#define MEDIA_ENT_F_IF_VID_DECODER (MEDIA_ENT_F_BASE + 0x02001)
|
||||
#define MEDIA_ENT_F_IF_AUD_DECODER (MEDIA_ENT_F_BASE + 0x02002)
|
||||
|
||||
/*
|
||||
* Audio Entity Functions
|
||||
*/
|
||||
#define MEDIA_ENT_F_AUDIO_CAPTURE (MEDIA_ENT_F_BASE + 0x03001)
|
||||
#define MEDIA_ENT_F_AUDIO_PLAYBACK (MEDIA_ENT_F_BASE + 0x03002)
|
||||
#define MEDIA_ENT_F_AUDIO_MIXER (MEDIA_ENT_F_BASE + 0x03003)
|
||||
|
||||
/*
|
||||
* Connectors
|
||||
*/
|
||||
@@ -113,8 +129,12 @@ struct media_device_info {
|
||||
#define MEDIA_ENT_F_LENS (MEDIA_ENT_F_OLD_SUBDEV_BASE + 3)
|
||||
#define MEDIA_ENT_F_ATV_DECODER (MEDIA_ENT_F_OLD_SUBDEV_BASE + 4)
|
||||
/*
|
||||
* It is a responsibility of the entity drivers to add connectors and links
|
||||
* for the tuner entities.
|
||||
* It is a responsibility of the master/bridge drivers to add connectors
|
||||
* and links for MEDIA_ENT_F_TUNER. Please notice that some old tuners
|
||||
* may require the usage of separate I2C chips to decode analog TV signals,
|
||||
* when the master/bridge chipset doesn't have its own TV standard decoder.
|
||||
* On such cases, the IF-PLL staging is mapped via one or two entities:
|
||||
* MEDIA_ENT_F_IF_VID_DECODER and/or MEDIA_ENT_F_IF_AUD_DECODER.
|
||||
*/
|
||||
#define MEDIA_ENT_F_TUNER (MEDIA_ENT_F_OLD_SUBDEV_BASE + 5)
|
||||
|
||||
@@ -262,6 +282,7 @@ struct media_links_enum {
|
||||
|
||||
#define MEDIA_INTF_T_DVB_BASE 0x00000100
|
||||
#define MEDIA_INTF_T_V4L_BASE 0x00000200
|
||||
#define MEDIA_INTF_T_ALSA_BASE 0x00000300
|
||||
|
||||
/* Interface types */
|
||||
|
||||
@@ -277,6 +298,15 @@ struct media_links_enum {
|
||||
#define MEDIA_INTF_T_V4L_SUBDEV (MEDIA_INTF_T_V4L_BASE + 3)
|
||||
#define MEDIA_INTF_T_V4L_SWRADIO (MEDIA_INTF_T_V4L_BASE + 4)
|
||||
|
||||
#define MEDIA_INTF_T_ALSA_PCM_CAPTURE (MEDIA_INTF_T_ALSA_BASE)
|
||||
#define MEDIA_INTF_T_ALSA_PCM_PLAYBACK (MEDIA_INTF_T_ALSA_BASE + 1)
|
||||
#define MEDIA_INTF_T_ALSA_CONTROL (MEDIA_INTF_T_ALSA_BASE + 2)
|
||||
#define MEDIA_INTF_T_ALSA_COMPRESS (MEDIA_INTF_T_ALSA_BASE + 3)
|
||||
#define MEDIA_INTF_T_ALSA_RAWMIDI (MEDIA_INTF_T_ALSA_BASE + 4)
|
||||
#define MEDIA_INTF_T_ALSA_HWDEP (MEDIA_INTF_T_ALSA_BASE + 5)
|
||||
#define MEDIA_INTF_T_ALSA_SEQUENCER (MEDIA_INTF_T_ALSA_BASE + 6)
|
||||
#define MEDIA_INTF_T_ALSA_TIMER (MEDIA_INTF_T_ALSA_BASE + 7)
|
||||
|
||||
/*
|
||||
* MC next gen API definitions
|
||||
*
|
||||
@@ -296,7 +326,7 @@ struct media_links_enum {
|
||||
* later, before the adding this API upstream.
|
||||
*/
|
||||
|
||||
#if 0 /* Let's postpone it to Kernel 4.6 */
|
||||
|
||||
struct media_v2_entity {
|
||||
__u32 id;
|
||||
char name[64]; /* FIXME: move to a property? (RFC says so) */
|
||||
@@ -357,21 +387,12 @@ struct media_v2_topology {
|
||||
__u64 ptr_links;
|
||||
} __attribute__ ((packed));
|
||||
|
||||
static inline void __user *media_get_uptr(__u64 arg)
|
||||
{
|
||||
return (void __user *)(uintptr_t)arg;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* ioctls */
|
||||
|
||||
#define MEDIA_IOC_DEVICE_INFO _IOWR('|', 0x00, struct media_device_info)
|
||||
#define MEDIA_IOC_ENUM_ENTITIES _IOWR('|', 0x01, struct media_entity_desc)
|
||||
#define MEDIA_IOC_ENUM_LINKS _IOWR('|', 0x02, struct media_links_enum)
|
||||
#define MEDIA_IOC_SETUP_LINK _IOWR('|', 0x03, struct media_link_desc)
|
||||
|
||||
#if 0 /* Let's postpone it to Kernel 4.6 */
|
||||
#define MEDIA_IOC_G_TOPOLOGY _IOWR('|', 0x04, struct media_v2_topology)
|
||||
#endif
|
||||
|
||||
#endif /* __LINUX_MEDIA_H */
|
||||
|
@@ -10,19 +10,43 @@
|
||||
* Copyright (C) 2012 Nokia Corporation
|
||||
* Contact: Sakari Ailus <sakari.ailus@iki.fi>
|
||||
*
|
||||
* 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.
|
||||
* 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.
|
||||
* 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 St, Fifth Floor, Boston, MA
|
||||
* 02110-1301 USA
|
||||
* Alternatively you can redistribute this file under the terms of the
|
||||
* BSD license as stated below:
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
* 1. Redistributions of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in
|
||||
* the documentation and/or other materials provided with the
|
||||
* distribution.
|
||||
* 3. The names of its contributors may not be used to endorse or promote
|
||||
* products derived from this software without specific prior written
|
||||
* permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
|
||||
* TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
*/
|
||||
|
||||
|
@@ -390,6 +390,7 @@ enum v4l2_mpeg_video_multi_slice_mode {
|
||||
#define V4L2_CID_MPEG_VIDEO_REPEAT_SEQ_HEADER (V4L2_CID_MPEG_BASE+226)
|
||||
#define V4L2_CID_MPEG_VIDEO_MV_H_SEARCH_RANGE (V4L2_CID_MPEG_BASE+227)
|
||||
#define V4L2_CID_MPEG_VIDEO_MV_V_SEARCH_RANGE (V4L2_CID_MPEG_BASE+228)
|
||||
#define V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME (V4L2_CID_MPEG_BASE+229)
|
||||
|
||||
#define V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP (V4L2_CID_MPEG_BASE+300)
|
||||
#define V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP (V4L2_CID_MPEG_BASE+301)
|
||||
@@ -912,8 +913,18 @@ enum v4l2_dv_rgb_range {
|
||||
V4L2_DV_RGB_RANGE_FULL = 2,
|
||||
};
|
||||
|
||||
#define V4L2_CID_DV_TX_IT_CONTENT_TYPE (V4L2_CID_DV_CLASS_BASE + 6)
|
||||
enum v4l2_dv_it_content_type {
|
||||
V4L2_DV_IT_CONTENT_TYPE_GRAPHICS = 0,
|
||||
V4L2_DV_IT_CONTENT_TYPE_PHOTO = 1,
|
||||
V4L2_DV_IT_CONTENT_TYPE_CINEMA = 2,
|
||||
V4L2_DV_IT_CONTENT_TYPE_GAME = 3,
|
||||
V4L2_DV_IT_CONTENT_TYPE_NO_ITC = 4,
|
||||
};
|
||||
|
||||
#define V4L2_CID_DV_RX_POWER_PRESENT (V4L2_CID_DV_CLASS_BASE + 100)
|
||||
#define V4L2_CID_DV_RX_RGB_RANGE (V4L2_CID_DV_CLASS_BASE + 101)
|
||||
#define V4L2_CID_DV_RX_IT_CONTENT_TYPE (V4L2_CID_DV_CLASS_BASE + 102)
|
||||
|
||||
#define V4L2_CID_FM_RX_CLASS_BASE (V4L2_CTRL_CLASS_FM_RX | 0x900)
|
||||
#define V4L2_CID_FM_RX_CLASS (V4L2_CTRL_CLASS_FM_RX | 1)
|
||||
|
@@ -546,6 +546,10 @@ struct v4l2_pix_format {
|
||||
/* three non contiguous planes - Y, Cb, Cr */
|
||||
#define V4L2_PIX_FMT_YUV420M v4l2_fourcc('Y', 'M', '1', '2') /* 12 YUV420 planar */
|
||||
#define V4L2_PIX_FMT_YVU420M v4l2_fourcc('Y', 'M', '2', '1') /* 12 YVU420 planar */
|
||||
#define V4L2_PIX_FMT_YUV422M v4l2_fourcc('Y', 'M', '1', '6') /* 16 YUV422 planar */
|
||||
#define V4L2_PIX_FMT_YVU422M v4l2_fourcc('Y', 'M', '6', '1') /* 16 YVU422 planar */
|
||||
#define V4L2_PIX_FMT_YUV444M v4l2_fourcc('Y', 'M', '2', '4') /* 24 YUV444 planar */
|
||||
#define V4L2_PIX_FMT_YVU444M v4l2_fourcc('Y', 'M', '4', '2') /* 24 YVU444 planar */
|
||||
|
||||
/* Bayer formats - see http://www.siliconimaging.com/RGB%20Bayer.htm */
|
||||
#define V4L2_PIX_FMT_SBGGR8 v4l2_fourcc('B', 'A', '8', '1') /* 8 BGBG.. GRGR.. */
|
||||
@@ -621,6 +625,9 @@ struct v4l2_pix_format {
|
||||
#define V4L2_PIX_FMT_JPGL v4l2_fourcc('J', 'P', 'G', 'L') /* JPEG-Lite */
|
||||
#define V4L2_PIX_FMT_SE401 v4l2_fourcc('S', '4', '0', '1') /* se401 janggu compressed rgb */
|
||||
#define V4L2_PIX_FMT_S5C_UYVY_JPG v4l2_fourcc('S', '5', 'C', 'I') /* S5C73M3 interleaved UYVY/JPEG */
|
||||
#define V4L2_PIX_FMT_Y8I v4l2_fourcc('Y', '8', 'I', ' ') /* Greyscale 8-bit L/R interleaved */
|
||||
#define V4L2_PIX_FMT_Y12I v4l2_fourcc('Y', '1', '2', 'I') /* Greyscale 12-bit L/R interleaved */
|
||||
#define V4L2_PIX_FMT_Z16 v4l2_fourcc('Z', '1', '6', ' ') /* Depth data 16-bit */
|
||||
|
||||
/* SDR formats - used only for Software Defined Radio devices */
|
||||
#define V4L2_SDR_FMT_CU8 v4l2_fourcc('C', 'U', '0', '8') /* IQ u8 */
|
||||
|
Reference in New Issue
Block a user