aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/platform/vivid/vivid-core.h
diff options
context:
space:
mode:
authorHans Verkuil <hans.verkuil@cisco.com>2015-10-20 23:52:40 +0200
committerHans Verkuil <hans.verkuil@cisco.com>2015-12-18 09:54:45 +0100
commitc0d2262161694c430037a39c143cbcbddc8ac703 (patch)
treed9ed070983d920a7ce5b4ef2687c7860194bb534 /drivers/media/platform/vivid/vivid-core.h
parent52d60eb7e6d6429a766ea1b8f67e01c3b2dcd3c5 (diff)
vivid: wip for sdr output
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Diffstat (limited to 'drivers/media/platform/vivid/vivid-core.h')
-rw-r--r--drivers/media/platform/vivid/vivid-core.h42
1 files changed, 30 insertions, 12 deletions
diff --git a/drivers/media/platform/vivid/vivid-core.h b/drivers/media/platform/vivid/vivid-core.h
index 8c7a5ba87c90..79cb7db1da48 100644
--- a/drivers/media/platform/vivid/vivid-core.h
+++ b/drivers/media/platform/vivid/vivid-core.h
@@ -66,7 +66,7 @@
#define MAX_TV_FREQ (958U * 16U)
/* The number of samples returned in every SDR buffer */
-#define SDR_CAP_SAMPLES_PER_BUF 0x4000
+#define SDR_SAMPLES_PER_BUF 0x4000
/* used by the threads to know when to resync internal counters */
#define JIFFIES_PER_DAY (3600U * 24U * HZ)
@@ -155,6 +155,8 @@ struct vivid_dev {
struct v4l2_ctrl_handler ctrl_hdl_radio_tx;
struct video_device sdr_cap_dev;
struct v4l2_ctrl_handler ctrl_hdl_sdr_cap;
+ struct video_device sdr_out_dev;
+ struct v4l2_ctrl_handler ctrl_hdl_sdr_out;
spinlock_t slock;
struct mutex mutex;
@@ -164,6 +166,7 @@ struct vivid_dev {
u32 vbi_cap_caps;
u32 vbi_out_caps;
u32 sdr_cap_caps;
+ u32 sdr_out_caps;
u32 radio_rx_caps;
u32 radio_tx_caps;
@@ -188,6 +191,7 @@ struct vivid_dev {
bool has_radio_rx;
bool has_radio_tx;
bool has_sdr_cap;
+ bool has_sdr_out;
bool has_fb;
bool can_loop_video;
@@ -449,14 +453,35 @@ struct vivid_dev {
/* SDR capture */
struct vb2_queue vb_sdr_cap_q;
struct list_head sdr_cap_active;
- u32 sdr_pixelformat; /* v4l2 format id */
- unsigned sdr_buffersize;
- unsigned sdr_adc_freq;
- unsigned sdr_fm_freq;
+ u32 sdr_cap_pixelformat; /* v4l2 format id */
+ unsigned sdr_cap_adc_freq;
+ unsigned sdr_cap_fm_freq;
unsigned sdr_fm_deviation;
int sdr_fixp_src_phase;
int sdr_fixp_mod_phase;
+ /* thread for generating SDR stream */
+ struct task_struct *kthread_sdr_cap;
+ unsigned long jiffies_sdr_cap;
+ u32 sdr_cap_seq_offset;
+ u32 sdr_cap_seq_count;
+ bool sdr_cap_seq_resync;
+
+ /* SDR output */
+ struct vb2_queue vb_sdr_out_q;
+ struct list_head sdr_out_active;
+ u32 sdr_out_pixelformat; /* v4l2 format id */
+ unsigned sdr_buffersize;
+ unsigned sdr_out_dac_freq;
+ unsigned sdr_out_fm_freq;
+
+ /* thread for SDR output stream */
+ struct task_struct *kthread_sdr_out;
+ unsigned long jiffies_sdr_out;
+ u32 sdr_out_seq_offset;
+ u32 sdr_out_seq_count;
+ bool sdr_out_seq_resync;
+
bool tstamp_src_is_soe;
bool has_crop_cap;
bool has_compose_cap;
@@ -465,13 +490,6 @@ struct vivid_dev {
bool has_compose_out;
bool has_scaler_out;
- /* thread for generating SDR stream */
- struct task_struct *kthread_sdr_cap;
- unsigned long jiffies_sdr_cap;
- u32 sdr_cap_seq_offset;
- u32 sdr_cap_seq_count;
- bool sdr_cap_seq_resync;
-
/* RDS generator */
struct vivid_rds_gen rds_gen;

Privacy Policy