Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

media: v4l2-subdev: Make struct v4l2_subdev_stream_config private

The v4l2_subdev_stream_config structure holds configuration data for a
stream. It was meant to be used internally only, but already found its
way into the ds90ub913 driver. Now that the driver has been fixed, make
the structure private to v4l2-subdev.c to avoid using it by accident.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>

authored by

Laurent Pinchart and committed by
Hans Verkuil
5195b777 49cec2b5

+25 -24
+24
drivers/media/v4l2-core/v4l2-subdev.c
··· 26 26 #include <media/v4l2-fh.h> 27 27 #include <media/v4l2-ioctl.h> 28 28 29 + /** 30 + * struct v4l2_subdev_stream_config - Used for storing stream configuration. 31 + * 32 + * @pad: pad number 33 + * @stream: stream number 34 + * @enabled: has the stream been enabled with v4l2_subdev_enable_streams() 35 + * @fmt: &struct v4l2_mbus_framefmt 36 + * @crop: &struct v4l2_rect to be used for crop 37 + * @compose: &struct v4l2_rect to be used for compose 38 + * @interval: frame interval 39 + * 40 + * This structure stores configuration for a stream. 41 + */ 42 + struct v4l2_subdev_stream_config { 43 + u32 pad; 44 + u32 stream; 45 + bool enabled; 46 + 47 + struct v4l2_mbus_framefmt fmt; 48 + struct v4l2_rect crop; 49 + struct v4l2_rect compose; 50 + struct v4l2_fract interval; 51 + }; 52 + 29 53 #if defined(CONFIG_VIDEO_V4L2_SUBDEV_API) 30 54 /* 31 55 * The Streams API is an experimental feature. To use the Streams API, set
+1 -24
include/media/v4l2-subdev.h
··· 36 36 struct v4l2_fh; 37 37 struct v4l2_subdev; 38 38 struct v4l2_subdev_fh; 39 + struct v4l2_subdev_stream_config; 39 40 struct tuner_setup; 40 41 struct v4l2_mbus_frame_desc; 41 42 struct led_classdev; ··· 679 678 */ 680 679 struct v4l2_subdev_pad_config { 681 680 struct v4l2_mbus_framefmt format; 682 - struct v4l2_rect crop; 683 - struct v4l2_rect compose; 684 - struct v4l2_fract interval; 685 - }; 686 - 687 - /** 688 - * struct v4l2_subdev_stream_config - Used for storing stream configuration. 689 - * 690 - * @pad: pad number 691 - * @stream: stream number 692 - * @enabled: has the stream been enabled with v4l2_subdev_enable_streams() 693 - * @fmt: &struct v4l2_mbus_framefmt 694 - * @crop: &struct v4l2_rect to be used for crop 695 - * @compose: &struct v4l2_rect to be used for compose 696 - * @interval: frame interval 697 - * 698 - * This structure stores configuration for a stream. 699 - */ 700 - struct v4l2_subdev_stream_config { 701 - u32 pad; 702 - u32 stream; 703 - bool enabled; 704 - 705 - struct v4l2_mbus_framefmt fmt; 706 681 struct v4l2_rect crop; 707 682 struct v4l2_rect compose; 708 683 struct v4l2_fract interval;