Michael Krufky | 04910bd | 2008-02-03 23:46:16 -0300 | [diff] [blame] | 1 | #ifndef __PVRUSB2_DVB_H__ |
| 2 | #define __PVRUSB2_DVB_H__ |
| 3 | |
| 4 | #include "dvb_frontend.h" |
| 5 | #include "dvb_demux.h" |
| 6 | #include "dvb_net.h" |
| 7 | #include "dmxdev.h" |
| 8 | #include "pvrusb2-context.h" |
| 9 | |
Mike Isely | a36416d | 2008-02-06 06:59:48 -0300 | [diff] [blame] | 10 | #define PVR2_DVB_BUFFER_COUNT 32 |
| 11 | #define PVR2_DVB_BUFFER_SIZE PAGE_ALIGN(0x4000) |
| 12 | |
Michael Krufky | 04910bd | 2008-02-03 23:46:16 -0300 | [diff] [blame] | 13 | struct pvr2_dvb_adapter { |
Mike Isely | a36416d | 2008-02-06 06:59:48 -0300 | [diff] [blame] | 14 | struct pvr2_channel channel; |
Michael Krufky | 04910bd | 2008-02-03 23:46:16 -0300 | [diff] [blame] | 15 | |
| 16 | struct dvb_adapter dvb_adap; |
| 17 | struct dmxdev dmxdev; |
| 18 | struct dvb_demux demux; |
| 19 | struct dvb_net dvb_net; |
| 20 | struct dvb_frontend *fe; |
| 21 | |
| 22 | int feedcount; |
| 23 | int max_feed_count; |
| 24 | |
Michael Krufky | d8abe97 | 2008-02-03 23:55:07 -0300 | [diff] [blame] | 25 | struct task_struct *thread; |
| 26 | struct mutex lock; |
| 27 | |
Mike Isely | a36416d | 2008-02-06 06:59:48 -0300 | [diff] [blame] | 28 | unsigned int stream_run:1; |
Mike Isely | a36416d | 2008-02-06 06:59:48 -0300 | [diff] [blame] | 29 | |
| 30 | wait_queue_head_t buffer_wait_data; |
| 31 | char *buffer_storage[PVR2_DVB_BUFFER_COUNT]; |
Michael Krufky | 04910bd | 2008-02-03 23:46:16 -0300 | [diff] [blame] | 32 | }; |
| 33 | |
| 34 | struct pvr2_dvb_props { |
| 35 | int (*frontend_attach) (struct pvr2_dvb_adapter *); |
| 36 | int (*tuner_attach) (struct pvr2_dvb_adapter *); |
| 37 | }; |
| 38 | |
Mike Isely | c5317b1 | 2008-02-09 19:47:07 -0300 | [diff] [blame] | 39 | struct pvr2_dvb_adapter *pvr2_dvb_create(struct pvr2_context *pvr); |
Michael Krufky | 04910bd | 2008-02-03 23:46:16 -0300 | [diff] [blame] | 40 | |
| 41 | #endif /* __PVRUSB2_DVB_H__ */ |