summaryrefslogtreecommitdiffstats
path: root/include
AgeCommit message (Collapse)AuthorFilesLines
2017-12-29media: dvb kAPI docs: document dvb_vb2.hMauro Carvalho Chehab2-6/+179
Document the data structures and functions inside this kAPI header. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-29media: dvb_vb2: get rid of DVB_BUF_TYPE_OUTPUTMauro Carvalho Chehab1-1/+0
This is currently unused. So, get rid of it. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-29media: v4l2-async: better describe match union at async match structMauro Carvalho Chehab1-0/+25
Now that kernel-doc handles nested unions, better document the match union at struct v4l2_async_subdev. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-29media: v4l2-async: simplify v4l2_async_subdev structureMauro Carvalho Chehab1-6/+2
The V4L2_ASYNC_MATCH_FWNODE match criteria requires just one struct to be filled (struct fwnode_handle). The V4L2_ASYNC_MATCH_DEVNAME match criteria requires just a device name. So, it doesn't make sense to enclose those into structs, as the criteria can go directly into the union. That makes easier to document it, as we don't need to document weird senseless structs. At drivers, this makes even clearer about the match criteria. Acked-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Acked-by: Benoit Parrot <bparrot@ti.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Acked-by: Philipp Zabel <p.zabel@pengutronix.de> Acked-by: Hyun Kwon <hyun.kwon@xilinx.com> Acked-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se> Acked-by: Lad, Prabhakar <prabhakar.csengg@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-29media: v4l2-device.h: document helper macrosMauro Carvalho Chehab1-35/+211
There are several macros that aren't documented using kernel-docs markups. Document them. While here, add cross-references to structs on this file. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-29media: videodev2.h, v4l2-ioctl: add IPU3 raw10 color formatYong Zhi1-0/+6
Add IPU3 specific formats: V4L2_PIX_FMT_IPU3_SBGGR10 V4L2_PIX_FMT_IPU3_SGBRG10 V4L2_PIX_FMT_IPU3_SGRBG10 V4L2_PIX_FMT_IPU3_SRGGB10 Signed-off-by: Yong Zhi <yong.zhi@intel.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-29media: i2c: as3645a: Remove driverSakari Ailus1-66/+0
Remove the V4L2 AS3645A sub-device driver in favour of the LED flash class driver for the same hardware, drivers/leds/leds-as3645a.c. The latter uses the V4L2 flash LED class framework to provide V4L2 sub-device interface. Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Acked-by: Pavel Machek <pavel@ucw.cz> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-28media: move dvb kAPI headers to include/mediaMauro Carvalho Chehab13-11/+3462
Except for DVB, all media kAPI headers are at include/media. Move the headers to it. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-28media: dvb-core: get rid of mmap reserved fieldMauro Carvalho Chehab1-3/+0
The "reserved" field was a way, used at V4L2 API, to add new data to existing structs without breaking userspace. However, there are now clever ways of doing that, without needing to add an uneeded overhead. So, get rid of them. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-28media: videobuf2: Add new uAPI for DVB streaming I/OSatendra Singh Thakur1-1/+65
Adds a new uAPI for DVB to use streaming I/O which is implemented based on videobuf2, using those new ioctls: - DMX_REQBUFS: Request kernel to allocate buffers which count and size are dedicated by user. - DMX_QUERYBUF: Get the buffer information like a memory offset which will mmap() and be shared with user-space. - DMX_EXPBUF: Just for testing whether buffer-exporting success or not. - DMX_QBUF: Pass the buffer to kernel-space. - DMX_DQBUF: Get back the buffer which may contain TS data. Originally developed by: Junghak Sung <jh1009.sung@samsung.com>, as seen at: https://patchwork.linuxtv.org/patch/31613/ https://patchwork.kernel.org/patch/7334301/ The original patch was written before merging VB2-core functionalities upstream. When such series was added, several adjustments were made, fixing some issues with V4L2, causing the original patch to be non-trivially rebased. After rebased, a few bugs in the patch were fixed. The patch was also enhanced it and polling functionality got added. The main changes over the original patch are: dvb_vb2_fill_buffer(): - Set the size of the outgoing buffer after while loop using vb2_set_plane_payload; - Added NULL check for source buffer as per normal convention of demux driver, this is called twice, first time with valid buffer second time with NULL pointer, if its not handled, it will result in crash - Restricted spinlock for only list_* operations dvb_vb2_init(): - Restricted q->io_modes to only VB2_MMAP as its the only supported mode dvb_vb2_release(): - Replaced the && in if condiion with &, because otherwise it was always getting satisfied. dvb_vb2_stream_off(): - Added list_del code for enqueud buffers upon stream off dvb_vb2_poll(): - Added this new function in order to support polling dvb_demux_poll() and dvb_dvr_poll() - dvb_vb2_poll() is now called from these functions - Ported this patch and latest videobuf2 to lower kernel versions and tested auto scan. Co-developed-by: Junghak Sung <jh1009.sung@samsung.com> [mchehab@s-opensource.com: checkpatch fixes] Signed-off-by: Junghak Sung <jh1009.sung@samsung.com> Signed-off-by: Geunyoung Kim <nenggun.kim@samsung.com> Acked-by: Seung-Woo Kim <sw0312.kim@samsung.com> Acked-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Satendra Singh Thakur <satendra.t@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-22Merge branch 'docs-next' of git://git.lwn.net/linux into patchworkMauro Carvalho Chehab51-158/+234
* 'docs-next' of git://git.lwn.net/linux: (888 commits) w1_netlink.h: add support for nested structs scripts: kernel-doc: apply filtering rules to warnings scripts: kernel-doc: improve nested logic to handle multiple identifiers scripts: kernel-doc: handle nested struct function arguments scripts: kernel-doc: print the declaration name on warnings scripts: kernel-doc: get rid of $nested parameter scripts: kernel-doc: parse next structs/unions scripts: kernel-doc: replace tabs by spaces scripts: kernel-doc: change default to ReST format scripts: kernel-doc: improve argument handling scripts: kernel-doc: get rid of unused output formats docs: get rid of kernel-doc-nano-HOWTO.txt docs: kernel-doc.rst: add documentation about man pages docs: kernel-doc.rst: improve typedef documentation docs: kernel-doc.rst: improve structs chapter docs: kernel-doc.rst: improve function documentation section docs: kernel-doc.rst: improve private members description docs: kernel-doc.rst: better describe kernel-doc arguments docs: fix process/submit-checklist.rst Sphinx warning docs: ftrace-uses.rst fix varios code-block directives ...
2017-12-19media: dvb_frontend: add physical layer scrambling supportAthanasios Oikonomou2-2/+5
This commit adds a new property DTV_SCRAMBLING_SEQUENCE_INDEX. This 18 bit field, when present, carries the index of the DVB-S2 physical layer scrambling sequence as defined in clause 5.5.4 of EN 302 307. There is no explicit signalling method to convey scrambling sequence index to the receiver. If S2 satellite delivery system descriptor is available it can be used to read the scrambling sequence index (EN 300 468 table 41). By default, gold scrambling sequence index 0 is used. The valid scrambling sequence index range is from 0 to 262142. Increase the DVB API version in order userspace to be aware of the changes. Signed-off-by: Athanasios Oikonomou <athoik@gmail.com> Acked-by: Ralph Metzler <rjkm@metzlerbros.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: exynos4-is: Check pipe is valid before calling subdevSimon Shields1-1/+2
If the subdev is not yet present (probably because the subdev module has not yet been loaded), the pipe will be NULL. Make sure that this is not the case before attempting to call the op. Signed-off-by: Simon Shields <simon@lineageos.org> Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: vb2-core: fix descriptions for VB2-only functionsMauro Carvalho Chehab1-40/+49
When we split VB2 into an independent streaming module and a V4L2 one, some vb2-core functions started to have a wrong description: they're meant to be used only by the API-specific parts of VB2, like vb2-v4l2, as the functions that V4L2 drivers should use are all under videobuf2-v4l2.h. Correct their descriptions. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-subdev: convert frame description to enumMauro Carvalho Chehab1-12/+19
As kernel-doc doesn't support documenting #define values, and using enum makes easier to identify where the values are used, convert V4L2_MBUS_FRAME_DESC_FL_* to enum, and use BIT() macro. While here, fix the description at v4l2_mbus_frame_desc_entry, in order to match what's described for V4L2_MBUS_FRAME_DESC_FL_LEN_MAX. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-subdev: better document IO pin configuration flagsMauro Carvalho Chehab1-12/+21
Convert V4L2_SUBDEV_IO_PIN_* to enums, use BIT() and document via kernel-doc. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-subdev: fix a typoMauro Carvalho Chehab1-1/+1
ownner -> owner Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-tpg: use __u16 instead of int for struct tpg_rbg_color16Mauro Carvalho Chehab1-1/+1
Despite the struct says "color16", it was actually using 32 bits for each color. Fix it. Suggested-by: Hans Verkuil <hverkuil@xs4all.nl> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-tpg.h: rename color structsMauro Carvalho Chehab1-4/+4
The color structs right now are just "color" and "color16". That may lead into conflicts, and don't define precisely what they meant. As those are used by two drivers (vivid and vimc), this is even on a somewhat public header! So rename them to: color -> tpg_rbg_color8 color16 -> tpg_rbg_color16 Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-tpg*.h: move headers to include/media/tpg and merge themMauro Carvalho Chehab2-69/+44
The v4l2-tpg*.h headers are meant to be used only internally by vivid and vimc. There's no sense keeping them together with the V4L2 kAPI headers. Also, one header includes the other as they're meant to be used together. So, merge them. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: vb2: add cross references at memops and v4l2 kernel-doc markupsMauro Carvalho Chehab2-57/+63
Add cross-references where needed and add periods at the end of each kernel-doc paragraph, in order to make it coherent with other VB2 descriptions. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: vb2-core: document remaining functionsMauro Carvalho Chehab1-1/+53
There are several VB2 core functions that aren't documented. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: vb2-core: Improve kernel-doc markupsMauro Carvalho Chehab1-172/+204
There are several issues on the current markups: - lack of cross-references; - wrong cross-references; - lack of a period of the end of several phrases; - Some descriptions can be enhanced. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: vb2-core: use bitops for bitsMauro Carvalho Chehab1-5/+6
Use the existing macros to identify vb2_io_modes bits. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-subdev: fix description of tuner.s_radio opsMauro Carvalho Chehab1-1/+20
The description there is completely broken and it mentions an ioctl that doesn't exist. Fix it. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-subdev: create cross-references for ioctlsMauro Carvalho Chehab1-31/+34
When generating Sphinx output, create cross-references for the callbacks for each ioctl. While here, fix a few wrong names for ioctls. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-dev: document video_device flagsMauro Carvalho Chehab1-7/+18
Convert #defines to enums and add kernel-doc markups for V4L2 video_device flags. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-dev: document VFL_DIR_* direction definesMauro Carvalho Chehab1-6/+16
The V4L_DIR_* direction flags document the direction for a V4L2 device node. Convert them to enum and document. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: get rid of i2c-addr.hMauro Carvalho Chehab2-37/+16
In the past, the same I2C address were used on multiple places. After I2C rebinding changes, this is no longer needed. So, we can just get rid of this header, placing the I2C address where they belong, e. g. either at bttv driver or at tvtuner. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: i2c-addr.h: get rid of now unused definesMauro Carvalho Chehab1-7/+0
Some of the previously used I2C addresses there aren't used anymore. So, get rid of them. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-dev: convert VFL_TYPE_* into an enumMauro Carvalho Chehab2-26/+63
Using enums makes easier to document, as it can use kernel-doc markups. It also allows cross-referencing, with increases the kAPI readability. Please notice that now cx88_querycap() has to have a default for the VFL type, as there are more types than supported by the driver. Acked-By: Mike Isely <isely@pobox.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-mediabus: use BIT() macro for flagsMauro Carvalho Chehab1-24/+26
Instead of using (1 << n) for bits, use the BIT() macro, as it makes a difference from documentation point of view. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-flash-led-class.h: add kernel-doc to two helper funcsMauro Carvalho Chehab1-0/+12
There are two helper functions at v4l2-flash-led-class.h that aren't documented. Document them. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-dev.h: add kernel-doc to two macrosMauro Carvalho Chehab1-3/+15
There are two macros at v4l2-dev.h that aren't documented. Document them, for completeness. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-event.rst: improve events descriptionMauro Carvalho Chehab1-34/+0
Both v4l2-event.rst and v4l2-event.h have an overview of events, but there are some inconsistencies there: - at v4l2-event, the event's ring buffer is called kevent. Its name is, instead, v4l2_kevent; - Some things are mentioned on both places (with different words), others are either on one of the files. In order to cleanup this mess, put everything at v4l2-event.rst and improve it to be a little more coherent and to have cross references. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: media-entity.h: add kernel-doc markups for nested structsMauro Carvalho Chehab1-0/+5
Now that nested structs are parsed by kernel-doc, add markups to them. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: videobuf2-core: improve kernel-doc markupsMauro Carvalho Chehab1-30/+29
Now that nested structs are supported, change the documentation to use it. While here, add cross-references where pertinent and use monotonic fonts where pertinent, using the right markup tags. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Acked-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-ctrls: document nested members of structsMauro Carvalho Chehab1-1/+8
There are a few nested members at v4l2-ctrls.h. Now that kernel-doc supports, document them. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-fwnode.h: better describe bus union at fwnode endpoint structMauro Carvalho Chehab1-1/+11
Better document the bus union at struct v4l2_fwnode_endpoint. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: rc-core.h: minor adjustments at rc_driver_type docMauro Carvalho Chehab1-2/+2
The description of this enum doesn't match what it actually represents. Adjust it. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-dv-timings.h: convert comment into kernel-doc markupMauro Carvalho Chehab1-7/+9
The can_reduce_fps() is already documented, but it is not using the kernel-doc markup. Convert it, in order to generate documentation from it. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-common.h: document helper functionsMauro Carvalho Chehab1-11/+96
There are several helper functions that aren't documented. Document them. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-common: get rid of struct v4l2_discrete_probeMauro Carvalho Chehab1-8/+4
This struct is there just two store two arguments of v4l2_find_nearest_format(). The other two arguments are passed as parameter. IMHO, there isn't much sense on doing that, and that will just add one more struct to document ;) So, let's get rid of the struct, passing the parameters directly. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: v4l2-common: get rid of v4l2_routing dead structMauro Carvalho Chehab1-9/+5
This struct is not used anymore. Get rid of it and update the documentation about what should still be converted. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: tuner-types: add kernel-doc markups for struct tunertypeMauro Carvalho Chehab1-0/+15
This struct is lacking documentation. Add it. Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-18media: frontend: describe nested structsMauro Carvalho Chehab1-18/+17
There are some nested structs on this header, with aren't properly document them. This should solve some warnings after the addition of a patche at kernel-doc adding support for nested structs/unions. Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-14media: cec: move cec autorepeat handling to rc-coreSean Young2-5/+3
CEC autorepeat is different than other protocols. Autorepeat is triggered by the first repeated user control pressed CEC message, rather than a fixed REP_DELAY. This change also does away with the KEY_UP event directly after the first KEY_DOWN event, which was used to stop autorepeat from starting. See commit a9a249a2c997 ("media: cec: fix remote control passthrough") for the original change. Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-14media: lirc: allow lirc device to be opened more than onceSean Young1-19/+31
This makes it possible for lircd to read from a lirc chardev, and not keep it busy. Note that this changes the default for timeout reports to on. lircd already enables timeout reports when it opens a lirc device, leaving them on until the next reboot. Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-14media: rc: include <uapi/linux/lirc.h> rather than <media/lirc.h>Sean Young1-1/+0
This removes the need for include/media/lirc.h, which just includes the uapi file. Signed-off-by: Sean Young <sean@mess.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
2017-12-14kfifo: DECLARE_KIFO_PTR(fifo, u64) does not work on arm 32 bitSean Young1-1/+2
If you try to store u64 in a kfifo (or a struct with u64 members), then the buf member of __STRUCT_KFIFO_PTR will cause 4 bytes padding due to alignment (note that struct __kfifo is 20 bytes on 32 bit). That in turn causes the __is_kfifo_ptr() to fail, which is caught by kfifo_alloc(), which now returns EINVAL. So, ensure that __is_kfifo_ptr() compares to the right structure. Signed-off-by: Sean Young <sean@mess.org> Acked-by: Stefani Seibold <stefani@seibold.net> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>