1 /* SPDX-License-Identifier: GPL-2.0+ */ 2 /* 3 * vimc-streamer.h Virtual Media Controller Driver 4 * 5 * Copyright (C) 2018 Lucas A. M. Magalhães <lucmaga@gmail.com> 6 * 7 */ 8 9 #ifndef _VIMC_STREAMER_H_ 10 #define _VIMC_STREAMER_H_ 11 12 #include <media/media-device.h> 13 14 #include "vimc-common.h" 15 16 #define VIMC_STREAMER_PIPELINE_MAX_SIZE 16 17 18 struct vimc_stream { 19 struct media_pipeline pipe; 20 struct vimc_ent_device *ved_pipeline[VIMC_STREAMER_PIPELINE_MAX_SIZE]; 21 unsigned int pipe_size; 22 u8 *frame; 23 struct task_struct *kthread; 24 }; 25 26 /** 27 * vimc_streamer_s_streamer - start/stop the stream 28 * 29 * @stream: the pointer to the stream to start or stop 30 * @ved: The last entity of the streamer pipeline 31 * @enable: any non-zero number start the stream, zero stop 32 * 33 */ 34 int vimc_streamer_s_stream(struct vimc_stream *stream, 35 struct vimc_ent_device *ved, 36 int enable); 37 38 #endif //_VIMC_STREAMER_H_ 39