aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorAndreas Oberritter <obi@linuxtv.org>2005-09-09 16:02:24 -0400
committerLinus Torvalds <torvalds@g5.osdl.org>2005-09-09 16:57:37 -0400
commit5d2cd1631e97f5eb9c8666ff9cd8011cd5c12e7d (patch)
tree7eabb376cdeb510392e8b699ec212a74e45b6f60 /drivers
parent218721b8ef334a7c778fe3bc033922edef911a1f (diff)
[PATCH] dvb: core: dvb_demux: remove more unused cruft
Removed more unused variables and constants. Signed-off-by: Andreas Oberritter <obi@linuxtv.org> Signed-off-by: Johannes Stezenbach <js@linuxtv.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/dvb/dvb-core/demux.h7
-rw-r--r--drivers/media/dvb/dvb-core/dmxdev.c4
-rw-r--r--drivers/media/dvb/dvb-core/dvb_demux.c18
-rw-r--r--drivers/media/dvb/dvb-core/dvb_demux.h7
-rw-r--r--drivers/media/dvb/dvb-core/dvb_net.c4
5 files changed, 6 insertions, 34 deletions
diff --git a/drivers/media/dvb/dvb-core/demux.h b/drivers/media/dvb/dvb-core/demux.h
index ee5be59759ee..9719a3b30f78 100644
--- a/drivers/media/dvb/dvb-core/demux.h
+++ b/drivers/media/dvb/dvb-core/demux.h
@@ -125,9 +125,7 @@ struct dmx_ts_feed {
125 u16 pid, 125 u16 pid,
126 int type, 126 int type,
127 enum dmx_ts_pes pes_type, 127 enum dmx_ts_pes pes_type,
128 size_t callback_length,
129 size_t circular_buffer_size, 128 size_t circular_buffer_size,
130 int descramble,
131 struct timespec timeout); 129 struct timespec timeout);
132 int (*start_filtering) (struct dmx_ts_feed* feed); 130 int (*start_filtering) (struct dmx_ts_feed* feed);
133 int (*stop_filtering) (struct dmx_ts_feed* feed); 131 int (*stop_filtering) (struct dmx_ts_feed* feed);
@@ -160,7 +158,6 @@ struct dmx_section_feed {
160 int (*set) (struct dmx_section_feed* feed, 158 int (*set) (struct dmx_section_feed* feed,
161 u16 pid, 159 u16 pid,
162 size_t circular_buffer_size, 160 size_t circular_buffer_size,
163 int descramble,
164 int check_crc); 161 int check_crc);
165 int (*allocate_filter) (struct dmx_section_feed* feed, 162 int (*allocate_filter) (struct dmx_section_feed* feed,
166 struct dmx_section_filter** filter); 163 struct dmx_section_filter** filter);
@@ -208,7 +205,6 @@ struct dmx_frontend {
208 struct list_head connectivity_list; /* List of front-ends that can 205 struct list_head connectivity_list; /* List of front-ends that can
209 be connected to a particular 206 be connected to a particular
210 demux */ 207 demux */
211 void* priv; /* Pointer to private data of the API client */
212 enum dmx_frontend_source source; 208 enum dmx_frontend_source source;
213}; 209};
214 210
@@ -226,8 +222,6 @@ struct dmx_frontend {
226#define DMX_MEMORY_BASED_FILTERING 8 /* write() available */ 222#define DMX_MEMORY_BASED_FILTERING 8 /* write() available */
227#define DMX_CRC_CHECKING 16 223#define DMX_CRC_CHECKING 16
228#define DMX_TS_DESCRAMBLING 32 224#define DMX_TS_DESCRAMBLING 32
229#define DMX_SECTION_PAYLOAD_DESCRAMBLING 64
230#define DMX_MAC_ADDRESS_DESCRAMBLING 128
231 225
232/* 226/*
233 * Demux resource type identifier. 227 * Demux resource type identifier.
@@ -246,7 +240,6 @@ struct dmx_demux {
246 u32 capabilities; /* Bitfield of capability flags */ 240 u32 capabilities; /* Bitfield of capability flags */
247 struct dmx_frontend* frontend; /* Front-end connected to the demux */ 241 struct dmx_frontend* frontend; /* Front-end connected to the demux */
248 void* priv; /* Pointer to private data of the API client */ 242 void* priv; /* Pointer to private data of the API client */
249 int users; /* Number of users */
250 int (*open) (struct dmx_demux* demux); 243 int (*open) (struct dmx_demux* demux);
251 int (*close) (struct dmx_demux* demux); 244 int (*close) (struct dmx_demux* demux);
252 int (*write) (struct dmx_demux* demux, const char* buf, size_t count); 245 int (*write) (struct dmx_demux* demux, const char* buf, size_t count);
diff --git a/drivers/media/dvb/dvb-core/dmxdev.c b/drivers/media/dvb/dvb-core/dmxdev.c
index 6059562f4d42..8028c3a5e287 100644
--- a/drivers/media/dvb/dvb-core/dmxdev.c
+++ b/drivers/media/dvb/dvb-core/dmxdev.c
@@ -571,7 +571,7 @@ static int dvb_dmxdev_filter_start(struct dmxdev_filter *filter)
571 return ret; 571 return ret;
572 } 572 }
573 573
574 ret=(*secfeed)->set(*secfeed, para->pid, 32768, 0, 574 ret=(*secfeed)->set(*secfeed, para->pid, 32768,
575 (para->flags & DMX_CHECK_CRC) ? 1 : 0); 575 (para->flags & DMX_CHECK_CRC) ? 1 : 0);
576 576
577 if (ret<0) { 577 if (ret<0) {
@@ -654,7 +654,7 @@ static int dvb_dmxdev_filter_start(struct dmxdev_filter *filter)
654 (*tsfeed)->priv = (void *) filter; 654 (*tsfeed)->priv = (void *) filter;
655 655
656 ret = (*tsfeed)->set(*tsfeed, para->pid, ts_type, ts_pes, 656 ret = (*tsfeed)->set(*tsfeed, para->pid, ts_type, ts_pes,
657 188, 32768, 0, timeout); 657 32768, timeout);
658 658
659 if (ret < 0) { 659 if (ret < 0) {
660 dmxdev->demux->release_ts_feed(dmxdev->demux, *tsfeed); 660 dmxdev->demux->release_ts_feed(dmxdev->demux, *tsfeed);
diff --git a/drivers/media/dvb/dvb-core/dvb_demux.c b/drivers/media/dvb/dvb-core/dvb_demux.c
index 6488206f54c8..b9cb671b938c 100644
--- a/drivers/media/dvb/dvb-core/dvb_demux.c
+++ b/drivers/media/dvb/dvb-core/dvb_demux.c
@@ -577,8 +577,7 @@ out:
577} 577}
578 578
579static int dmx_ts_feed_set (struct dmx_ts_feed* ts_feed, u16 pid, int ts_type, 579static int dmx_ts_feed_set (struct dmx_ts_feed* ts_feed, u16 pid, int ts_type,
580 enum dmx_ts_pes pes_type, size_t callback_length, 580 enum dmx_ts_pes pes_type, size_t circular_buffer_size,
581 size_t circular_buffer_size, int descramble,
582 struct timespec timeout) 581 struct timespec timeout)
583{ 582{
584 struct dvb_demux_feed *feed = (struct dvb_demux_feed *) ts_feed; 583 struct dvb_demux_feed *feed = (struct dvb_demux_feed *) ts_feed;
@@ -610,17 +609,10 @@ static int dmx_ts_feed_set (struct dmx_ts_feed* ts_feed, u16 pid, int ts_type,
610 609
611 feed->pid = pid; 610 feed->pid = pid;
612 feed->buffer_size = circular_buffer_size; 611 feed->buffer_size = circular_buffer_size;
613 feed->descramble = descramble;
614 feed->timeout = timeout; 612 feed->timeout = timeout;
615 feed->cb_length = callback_length;
616 feed->ts_type = ts_type; 613 feed->ts_type = ts_type;
617 feed->pes_type = pes_type; 614 feed->pes_type = pes_type;
618 615
619 if (feed->descramble) {
620 up(&demux->mutex);
621 return -ENOSYS;
622 }
623
624 if (feed->buffer_size) { 616 if (feed->buffer_size) {
625#ifdef NOBUFS 617#ifdef NOBUFS
626 feed->buffer=NULL; 618 feed->buffer=NULL;
@@ -819,7 +811,7 @@ static int dmx_section_feed_allocate_filter(struct dmx_section_feed* feed,
819 811
820static int dmx_section_feed_set(struct dmx_section_feed* feed, 812static int dmx_section_feed_set(struct dmx_section_feed* feed,
821 u16 pid, size_t circular_buffer_size, 813 u16 pid, size_t circular_buffer_size,
822 int descramble, int check_crc) 814 int check_crc)
823{ 815{
824 struct dvb_demux_feed *dvbdmxfeed = (struct dvb_demux_feed *) feed; 816 struct dvb_demux_feed *dvbdmxfeed = (struct dvb_demux_feed *) feed;
825 struct dvb_demux *dvbdmx = dvbdmxfeed->demux; 817 struct dvb_demux *dvbdmx = dvbdmxfeed->demux;
@@ -834,12 +826,6 @@ static int dmx_section_feed_set(struct dmx_section_feed* feed,
834 826
835 dvbdmxfeed->pid = pid; 827 dvbdmxfeed->pid = pid;
836 dvbdmxfeed->buffer_size = circular_buffer_size; 828 dvbdmxfeed->buffer_size = circular_buffer_size;
837 dvbdmxfeed->descramble = descramble;
838 if (dvbdmxfeed->descramble) {
839 up(&dvbdmx->mutex);
840 return -ENOSYS;
841 }
842
843 dvbdmxfeed->feed.sec.check_crc = check_crc; 829 dvbdmxfeed->feed.sec.check_crc = check_crc;
844 830
845#ifdef NOBUFS 831#ifdef NOBUFS
diff --git a/drivers/media/dvb/dvb-core/dvb_demux.h b/drivers/media/dvb/dvb-core/dvb_demux.h
index 20275a2f6ec6..d149f2a96d09 100644
--- a/drivers/media/dvb/dvb-core/dvb_demux.h
+++ b/drivers/media/dvb/dvb-core/dvb_demux.h
@@ -54,12 +54,9 @@ struct dvb_demux_filter {
54 int index; 54 int index;
55 int state; 55 int state;
56 int type; 56 int type;
57 int pesto;
58 57
59 u16 handle;
60 u16 hw_handle; 58 u16 hw_handle;
61 struct timer_list timer; 59 struct timer_list timer;
62 int ts_state;
63}; 60};
64 61
65 62
@@ -83,11 +80,9 @@ struct dvb_demux_feed {
83 u16 pid; 80 u16 pid;
84 u8 *buffer; 81 u8 *buffer;
85 int buffer_size; 82 int buffer_size;
86 int descramble;
87 83
88 struct timespec timeout; 84 struct timespec timeout;
89 struct dvb_demux_filter *filter; 85 struct dvb_demux_filter *filter;
90 int cb_length;
91 86
92 int ts_type; 87 int ts_type;
93 enum dmx_ts_pes pes_type; 88 enum dmx_ts_pes pes_type;
@@ -98,7 +93,7 @@ struct dvb_demux_feed {
98 u16 peslen; 93 u16 peslen;
99 94
100 struct list_head list_head; 95 struct list_head list_head;
101 int index; /* a unique index for each feed (can be used as hardware pid filter index) */ 96 unsigned int index; /* a unique index for each feed (can be used as hardware pid filter index) */
102}; 97};
103 98
104struct dvb_demux { 99struct dvb_demux {
diff --git a/drivers/media/dvb/dvb-core/dvb_net.c b/drivers/media/dvb/dvb-core/dvb_net.c
index 33a357c48a19..87935490bfb2 100644
--- a/drivers/media/dvb/dvb-core/dvb_net.c
+++ b/drivers/media/dvb/dvb-core/dvb_net.c
@@ -903,7 +903,7 @@ static int dvb_net_feed_start(struct net_device *dev)
903 return ret; 903 return ret;
904 } 904 }
905 905
906 ret = priv->secfeed->set(priv->secfeed, priv->pid, 32768, 0, 1); 906 ret = priv->secfeed->set(priv->secfeed, priv->pid, 32768, 1);
907 907
908 if (ret<0) { 908 if (ret<0) {
909 printk("%s: could not set section feed\n", dev->name); 909 printk("%s: could not set section feed\n", dev->name);
@@ -955,9 +955,7 @@ static int dvb_net_feed_start(struct net_device *dev)
955 priv->tsfeed->priv = (void *)dev; 955 priv->tsfeed->priv = (void *)dev;
956 ret = priv->tsfeed->set(priv->tsfeed, priv->pid, 956 ret = priv->tsfeed->set(priv->tsfeed, priv->pid,
957 TS_PACKET, DMX_TS_PES_OTHER, 957 TS_PACKET, DMX_TS_PES_OTHER,
958 188 * 100, /* nr. of bytes delivered per callback */
959 32768, /* circular buffer size */ 958 32768, /* circular buffer size */
960 0, /* descramble */
961 timeout); 959 timeout);
962 960
963 if (ret < 0) { 961 if (ret < 0) {