summaryrefslogtreecommitdiff
path: root/linux
diff options
context:
space:
mode:
authorHolger Waechtler <devnull@localhost>2002-10-17 15:11:21 +0000
committerHolger Waechtler <devnull@localhost>2002-10-17 15:11:21 +0000
commit95d5045270cb2eb2cabb7d1c30ae319dde5ad58a (patch)
tree5df17cf8b8f77ded25a763b881f6924c1d869e29 /linux
parente26547d9163739d43ced0bcc60b3248d7b496221 (diff)
downloadmediapointer-dvb-s2-95d5045270cb2eb2cabb7d1c30ae319dde5ad58a.tar.gz
mediapointer-dvb-s2-95d5045270cb2eb2cabb7d1c30ae319dde5ad58a.tar.bz2
- more coding style paranoia
Diffstat (limited to 'linux')
-rw-r--r--linux/drivers/media/dvb/av7110/av7110.c72
-rw-r--r--linux/drivers/media/dvb/av7110/av7110.h2
-rw-r--r--linux/drivers/media/dvb/dvb-core/dmxdev.c150
-rw-r--r--linux/drivers/media/dvb/dvb-core/dmxdev.h4
-rw-r--r--linux/drivers/media/dvb/dvb-core/dvb_demux.c54
-rw-r--r--linux/drivers/media/dvb/dvb-core/dvb_demux.h6
-rw-r--r--linux/drivers/media/dvb/dvb-core/dvb_filter.c32
-rw-r--r--linux/drivers/media/dvb/dvb-core/dvb_filter.h24
-rw-r--r--linux/drivers/media/dvb/dvb-core/dvb_ksyms.c24
9 files changed, 184 insertions, 184 deletions
diff --git a/linux/drivers/media/dvb/av7110/av7110.c b/linux/drivers/media/dvb/av7110/av7110.c
index fa9c3671f..1261070a8 100644
--- a/linux/drivers/media/dvb/av7110/av7110.c
+++ b/linux/drivers/media/dvb/av7110/av7110.c
@@ -392,7 +392,7 @@ static int arm_thread(void *data)
static int
-record_cb(pes2ts_t *p2t, u8 *buf, size_t len)
+record_cb(dvb_filter_dvb_filter_pes2ts_t *p2t, u8 *buf, size_t len)
{
dvb_demux_feed_t *dvbdmxfeed=(dvb_demux_feed_t *) p2t->priv;
@@ -404,11 +404,11 @@ record_cb(pes2ts_t *p2t, u8 *buf, size_t len)
return dvbdmxfeed->cb.ts(buf, len, 0, 0,
&dvbdmxfeed->feed.ts, DMX_OK);
else
- return pes2ts(p2t, buf, len);
+ return dvb_filter_dvb_filter_pes2ts(p2t, buf, len);
}
static int
-pes2ts_cb(void *priv, unsigned char *data)
+dvb_filter_dvb_filter_pes2ts_cb(void *priv, unsigned char *data)
{
dvb_demux_feed_t *dvbdmxfeed=(dvb_demux_feed_t *) priv;
@@ -432,20 +432,20 @@ AV_StartRecord(av7110_t *av7110, int av,
switch (av7110->rec_mode) {
case RP_AUDIO:
- pes2ts_init(&av7110->p2t[0], dvbdmx->pesfilter[0]->pid,
- pes2ts_cb, (void *)dvbdmx->pesfilter[0]);
+ dvb_filter_dvb_filter_pes2ts_init(&av7110->p2t[0], dvbdmx->pesfilter[0]->pid,
+ dvb_filter_dvb_filter_pes2ts_cb, (void *)dvbdmx->pesfilter[0]);
outcom(av7110, COMTYPE_REC_PLAY, __Record, 2, AudioPES, 0);
break;
case RP_VIDEO:
- pes2ts_init(&av7110->p2t[1], dvbdmx->pesfilter[1]->pid,
- pes2ts_cb, (void *)dvbdmx->pesfilter[1]);
+ dvb_filter_dvb_filter_pes2ts_init(&av7110->p2t[1], dvbdmx->pesfilter[1]->pid,
+ dvb_filter_dvb_filter_pes2ts_cb, (void *)dvbdmx->pesfilter[1]);
outcom(av7110, COMTYPE_REC_PLAY, __Record, 2, VideoPES, 0);
break;
case RP_AV:
- pes2ts_init(&av7110->p2t[0], dvbdmx->pesfilter[0]->pid,
- pes2ts_cb, (void *)dvbdmx->pesfilter[0]);
- pes2ts_init(&av7110->p2t[1], dvbdmx->pesfilter[1]->pid,
- pes2ts_cb, (void *)dvbdmx->pesfilter[1]);
+ dvb_filter_dvb_filter_pes2ts_init(&av7110->p2t[0], dvbdmx->pesfilter[0]->pid,
+ dvb_filter_dvb_filter_pes2ts_cb, (void *)dvbdmx->pesfilter[0]);
+ dvb_filter_dvb_filter_pes2ts_init(&av7110->p2t[1], dvbdmx->pesfilter[1]->pid,
+ dvb_filter_dvb_filter_pes2ts_cb, (void *)dvbdmx->pesfilter[1]);
outcom(av7110, COMTYPE_REC_PLAY, __Record, 2, AV_PES, 0);
break;
}
@@ -463,8 +463,8 @@ AV_StartPlay(av7110_t *av7110, int av)
outcom(av7110, COMTYPE_REC_PLAY, __Stop, 0);
if (av7110->playing == RP_NONE) {
- reset_ipack(&av7110->ipack[0]);
- reset_ipack(&av7110->ipack[1]);
+ dvb_filter_ipack_reset(&av7110->ipack[0]);
+ dvb_filter_ipack_reset(&av7110->ipack[1]);
}
av7110->playing|=av;
@@ -896,7 +896,7 @@ static void fidbirq(struct saa7146* saa, void *data)
// FIXME: use bottom half or tasklet
if (av7110->feeding && mem[0]==0x47)
- DvbDmxSWFilterPackets(&av7110->demux, mem, 512);
+ dvb_dmx_swfilter_packets(&av7110->demux, mem, 512);
}
#else
static
@@ -922,7 +922,7 @@ void fidbirq (unsigned long data)
} else {
if (av7110->ttbp>1000*188 && av7110->ttbp<1024*188) {
if (av7110->feeding)
- DvbDmxSWFilterPackets(&av7110->demux,
+ dvb_dmx_swfilter_packets(&av7110->demux,
mem+av7110->ttbp,
1024- av7110->ttbp / 188);
}
@@ -937,7 +937,7 @@ void fidbirq (unsigned long data)
// FIXME: use bottom half or tasklet
if (av7110->feeding && mem[0]==0x47)
- DvbDmxSWFilterPackets(&av7110->demux, mem, num);
+ dvb_dmx_swfilter_packets(&av7110->demux, mem, num);
}
#endif
@@ -1001,7 +1001,7 @@ void debiirq (unsigned long data)
switch (type&0xff) {
case DATA_TS_RECORD:
- DvbDmxSWFilterPackets(&av7110->demux,
+ dvb_dmx_swfilter_packets(&av7110->demux,
(const u8 *)av7110->debi_virt,
av7110->debilen/188);
spin_lock(&av7110->debilock);
@@ -2483,9 +2483,9 @@ dvb_play(av7110_t *av7110, const u8 *buf,
if (umem) {
if (copy_from_user(av7110->kbuf[type], buf, n))
return -EFAULT;
- instant_repack(av7110->kbuf[type], n, &av7110->ipack[type]);
+ dvb_filter_dvb_filter_instant_repack(av7110->kbuf[type], n, &av7110->ipack[type]);
} else
- instant_repack((u8 *)buf, n, &av7110->ipack[type]);
+ dvb_filter_dvb_filter_instant_repack((u8 *)buf, n, &av7110->ipack[type]);
todo -= n;
buf += n;
}
@@ -2517,7 +2517,7 @@ dvb_aplay(av7110_t *av7110, const u8 *buf,
n=IPACKS*2;
if (copy_from_user(av7110->kbuf[type], buf, n))
return -EFAULT;
- instant_repack(av7110->kbuf[type], n, &av7110->ipack[type]);
+ dvb_filter_dvb_filter_instant_repack(av7110->kbuf[type], n, &av7110->ipack[type]);
// memcpy(dvb->kbuf[type], buf, n);
todo -= n;
buf += n;
@@ -3277,7 +3277,7 @@ dvb_write_to_decoder(dvb_demux_feed_t *dvbdmxfeed, u8 *buf, size_t count)
return -1;
}
if (buf[1]&0x40)
- send_ipack_rest(ipack);
+ dvb_filter_ipack_flush(ipack);
if (buf[3]&0x20) { // adaptation field?
count-=buf[4]+1;
@@ -3287,7 +3287,7 @@ dvb_write_to_decoder(dvb_demux_feed_t *dvbdmxfeed, u8 *buf, size_t count)
}
}
- instant_repack(buf+4, count-4, &av7110->ipack[dvbdmxfeed->pes_type]);
+ dvb_filter_dvb_filter_instant_repack(buf+4, count-4, &av7110->ipack[dvbdmxfeed->pes_type]);
return 0;
}
@@ -3716,7 +3716,7 @@ dvb_ca_ioctl(struct inode *inode, struct file *file,
case CA_GET_CAP:
{
- ca_cap_t cap;
+ ca_caps_t cap;
cap.slot_num=2;
#ifdef NEW_CI
@@ -3876,7 +3876,7 @@ play_iframe(av7110_t *av7110, u8 *buf, unsigned int len, int nonblock)
for (i=0; i<n; i++)
dvb_play(av7110, buf, len, 0, 1, 1);
- send_ipack_rest(&av7110->ipack[1]);
+ dvb_filter_ipack_flush(&av7110->ipack[1]);
}
@@ -4041,7 +4041,7 @@ dvb_video_ioctl(struct inode *inode, struct file *file,
case VIDEO_CLEAR_BUFFER:
ring_buffer_flush(&av7110->avout);
- reset_ipack(&av7110->ipack[1]);
+ dvb_filter_ipack_reset(&av7110->ipack[1]);
if (av7110->playing==RP_AV) {
outcom(av7110, COMTYPE_REC_PLAY,
@@ -4164,7 +4164,7 @@ dvb_audio_ioctl(struct inode *inode, struct file *file,
case AUDIO_CLEAR_BUFFER:
ring_buffer_flush(&av7110->aout);
- reset_ipack(&av7110->ipack[0]);
+ dvb_filter_ipack_reset(&av7110->ipack[0]);
if (av7110->playing==RP_AV)
outcom(av7110, COMTYPE_REC_PLAY,
__Play, 2, AV_PES, 0);
@@ -4409,7 +4409,7 @@ dvb_register(av7110_t *av7110)
DMX_SECTION_FILTERING|
DMX_MEMORY_BASED_FILTERING);
- DvbDmxInit(&av7110->demux);
+ dvb_dmx_init(&av7110->demux);
dvbfront->id="hw_frontend";
@@ -4421,7 +4421,7 @@ dvb_register(av7110_t *av7110)
av7110->dmxdev.demux=&dvbdemux->dmx;
av7110->dmxdev.capabilities=0;
- DmxDevInit(&av7110->dmxdev, av7110->dvb_adapter);
+ dvb_dmxdev_init(&av7110->dmxdev, av7110->dvb_adapter);
}
if (av7110->saa->card_type>=DVB_CARD_TT_BUDGET) {
@@ -4438,7 +4438,7 @@ dvb_register(av7110_t *av7110)
DMX_SECTION_FILTERING|
DMX_MEMORY_BASED_FILTERING);
- DvbDmxInit(&av7110->demux);
+ dvb_dmx_init(&av7110->demux);
dvbfront->id="hw_frontend";
dvbfront->vendor="VLSI";
@@ -4449,7 +4449,7 @@ dvb_register(av7110_t *av7110)
av7110->dmxdev.demux=&dvbdemux->dmx;
av7110->dmxdev.capabilities=0;
- DmxDevInit(&av7110->dmxdev, av7110->dvb_adapter);
+ dvb_dmxdev_init(&av7110->dmxdev, av7110->dvb_adapter);
}
ret=dvbdemux->dmx.add_frontend(&dvbdemux->dmx,
@@ -4511,8 +4511,8 @@ dvb_unregister(av7110_t *av7110)
dvbdemux->dmx.remove_frontend(&dvbdemux->dmx, &av7110->hw_frontend);
dvbdemux->dmx.remove_frontend(&dvbdemux->dmx, &av7110->mem_frontend);
- DmxDevRelease(&av7110->dmxdev);
- DvbDmxRelease(&av7110->demux);
+ dvb_dmxdev_release(&av7110->dmxdev);
+ dvb_dmx_release(&av7110->demux);
if (av7110->saa->card_type==DVB_CARD_TT_SIEMENS)
dvb_remove_frontend_notifier (av7110->dvb_adapter,
@@ -4579,9 +4579,9 @@ int av7110_attach (struct saa7146 *saa, void **av7110_ptr)
av7110->vidmode=VIDEO_MODE_PAL;
- init_ipack(&av7110->ipack[0], IPACKS, play_audio_cb);
+ dvb_filter_ipack_init(&av7110->ipack[0], IPACKS, play_audio_cb);
av7110->ipack[0].data=(void *) av7110;
- init_ipack(&av7110->ipack[1], IPACKS, play_video_cb);
+ dvb_filter_ipack_init(&av7110->ipack[1], IPACKS, play_video_cb);
av7110->ipack[1].data=(void *) av7110;
@@ -4700,8 +4700,8 @@ int av7110_detach (struct saa7146 *saa, void** av7110_ptr)
saa7146_write(av7110->saa_mem, ISR,(MASK_19 | MASK_03));
ci_ll_release(&av7110->ci_rbuffer, &av7110->ci_wbuffer);
- free_ipack(&av7110->ipack[0]);
- free_ipack(&av7110->ipack[1]);
+ dvb_filter_ipack_free(&av7110->ipack[0]);
+ dvb_filter_ipack_free(&av7110->ipack[1]);
vfree(av7110->iobuf);
pci_free_consistent(av7110->saa->device, 8192, av7110->debi_virt,
av7110->debi_bus);
diff --git a/linux/drivers/media/dvb/av7110/av7110.h b/linux/drivers/media/dvb/av7110/av7110.h
index 4ba483dea..4b996e40c 100644
--- a/linux/drivers/media/dvb/av7110/av7110.h
+++ b/linux/drivers/media/dvb/av7110/av7110.h
@@ -582,7 +582,7 @@ typedef struct av7110_s {
dvb_demux_filter_t *handle2filter[32];
p2t_t p2t_filter[MAXFILT];
- pes2ts_t p2t[2];
+ dvb_filter_dvb_filter_pes2ts_t p2t[2];
struct ipack_s ipack[2];
u8 *kbuf[2];
diff --git a/linux/drivers/media/dvb/dvb-core/dmxdev.c b/linux/drivers/media/dvb/dvb-core/dmxdev.c
index b92f31d54..3081b1925 100644
--- a/linux/drivers/media/dvb/dvb-core/dmxdev.c
+++ b/linux/drivers/media/dvb/dvb-core/dmxdev.c
@@ -40,19 +40,19 @@ static int debug = 0;
#define dprintk if (debug) printk
inline dmxdev_filter_t *
-DmxDevFile2Filter(struct file *file)
+dvb_dmxdev_file_to_filter(struct file *file)
{
return (dmxdev_filter_t *) file->private_data;
}
inline dmxdev_dvr_t *
-DmxDevFile2DVR(dmxdev_t *dmxdev, struct file *file)
+dvb_dmxdev_file_to_dvr(dmxdev_t *dmxdev, struct file *file)
{
return (dmxdev_dvr_t *) file->private_data;
}
static inline void
-DmxDevBufferInit(dmxdev_buffer_t *buffer)
+dvb_dmxdev_buffer_init(dmxdev_buffer_t *buffer)
{
buffer->data=0;
buffer->size=8192;
@@ -63,7 +63,7 @@ DmxDevBufferInit(dmxdev_buffer_t *buffer)
}
static inline int
-DmxDevBufferWrite(dmxdev_buffer_t *buf, uint8_t *src, int len)
+dvb_dmxdev_buffer_write(dmxdev_buffer_t *buf, uint8_t *src, int len)
{
int split;
int free;
@@ -98,7 +98,7 @@ DmxDevBufferWrite(dmxdev_buffer_t *buf, uint8_t *src, int len)
}
static ssize_t
-DmxDevBufferRead(dmxdev_buffer_t *src, int non_blocking,
+dvb_dmxdev_buffer_read(dmxdev_buffer_t *src, int non_blocking,
char *buf, size_t count, loff_t *ppos)
{
unsigned long todo=count;
@@ -172,7 +172,7 @@ get_fe(dmx_demux_t *demux, int type)
}
static inline void
-DmxDevDVRStateSet(dmxdev_dvr_t *dmxdevdvr, int state)
+dvb_dmxdev_dvr_state_set(dmxdev_dvr_t *dmxdevdvr, int state)
{
spin_lock_irq(&dmxdevdvr->dev->lock);
dmxdevdvr->state=state;
@@ -198,7 +198,7 @@ static int dvb_dvr_open(struct inode *inode, struct file *file)
}
if ((file->f_flags&O_ACCMODE)==O_RDONLY) {
- DmxDevBufferInit(&dmxdev->dvr_buffer);
+ dvb_dmxdev_buffer_init(&dmxdev->dvr_buffer);
dmxdev->dvr_buffer.size=DVR_BUFFER_SIZE;
dmxdev->dvr_buffer.data=vmalloc(DVR_BUFFER_SIZE);
if (!dmxdev->dvr_buffer.data) {
@@ -281,7 +281,7 @@ dvb_dvr_read(struct file *file, char *buf, size_t count, loff_t *ppos)
int ret;
//down(&dmxdev->mutex);
- ret= DmxDevBufferRead(&dmxdev->dvr_buffer,
+ ret= dvb_dmxdev_buffer_read(&dmxdev->dvr_buffer,
file->f_flags&O_NONBLOCK,
buf, count, ppos);
//up(&dmxdev->mutex);
@@ -289,7 +289,7 @@ dvb_dvr_read(struct file *file, char *buf, size_t count, loff_t *ppos)
}
static inline void
-DmxDevFilterStateSet(dmxdev_filter_t *dmxdevfilter, int state)
+dvb_dmxdev_filter_state_set(dmxdev_filter_t *dmxdevfilter, int state)
{
spin_lock_irq(&dmxdevfilter->dev->lock);
dmxdevfilter->state=state;
@@ -297,7 +297,7 @@ DmxDevFilterStateSet(dmxdev_filter_t *dmxdevfilter, int state)
}
static int
-DmxDevSetBufferSize(dmxdev_filter_t *dmxdevfilter, unsigned long size)
+dvb_dmxdev_set_buffer_size(dmxdev_filter_t *dmxdevfilter, unsigned long size)
{
dmxdev_buffer_t *buf=&dmxdevfilter->buffer;
void *mem;
@@ -327,7 +327,7 @@ DmxDevSetBufferSize(dmxdev_filter_t *dmxdevfilter, unsigned long size)
}
static void
-DmxDevFilterTimeout(unsigned long data)
+dvb_dmxdev_filter_timeout(unsigned long data)
{
dmxdev_filter_t *dmxdevfilter=(dmxdev_filter_t *)data;
@@ -339,13 +339,13 @@ DmxDevFilterTimeout(unsigned long data)
}
static void
-DmxDevFilterTimer(dmxdev_filter_t *dmxdevfilter)
+dvb_dmxdev_filter_timer(dmxdev_filter_t *dmxdevfilter)
{
struct dmx_sct_filter_params *para=&dmxdevfilter->params.sec;
del_timer(&dmxdevfilter->timer);
if (para->timeout) {
- dmxdevfilter->timer.function=DmxDevFilterTimeout;
+ dmxdevfilter->timer.function=dvb_dmxdev_filter_timeout;
dmxdevfilter->timer.data=(unsigned long) dmxdevfilter;
dmxdevfilter->timer.expires=jiffies+1+(HZ/2+HZ*para->timeout)/1000;
add_timer(&dmxdevfilter->timer);
@@ -353,7 +353,7 @@ DmxDevFilterTimer(dmxdev_filter_t *dmxdevfilter)
}
static int
-DmxDevSectionCallback(u8 *buffer1, size_t buffer1_len,
+dvb_dmxdev_section_callback(u8 *buffer1, size_t buffer1_len,
u8 *buffer2, size_t buffer2_len,
dmx_section_filter_t *filter,
dmx_success_t success)
@@ -375,9 +375,9 @@ DmxDevSectionCallback(u8 *buffer1, size_t buffer1_len,
buffer1[0], buffer1[1],
buffer1[2], buffer1[3],
buffer1[4], buffer1[5]);
- ret=DmxDevBufferWrite(&dmxdevfilter->buffer, buffer1, buffer1_len);
+ ret=dvb_dmxdev_buffer_write(&dmxdevfilter->buffer, buffer1, buffer1_len);
if (ret==buffer1_len) {
- ret=DmxDevBufferWrite(&dmxdevfilter->buffer, buffer2, buffer2_len);
+ ret=dvb_dmxdev_buffer_write(&dmxdevfilter->buffer, buffer2, buffer2_len);
}
if (ret<0) {
dmxdevfilter->buffer.pwrite=dmxdevfilter->buffer.pread;
@@ -391,7 +391,7 @@ DmxDevSectionCallback(u8 *buffer1, size_t buffer1_len,
}
static int
-DmxDevTSCallback(u8 *buffer1, size_t buffer1_len,
+dvb_dmxdev_ts_callback(u8 *buffer1, size_t buffer1_len,
u8 *buffer2, size_t buffer2_len,
dmx_ts_feed_t *feed,
dmx_success_t success)
@@ -415,9 +415,9 @@ DmxDevTSCallback(u8 *buffer1, size_t buffer1_len,
wake_up(&buffer->queue);
return 0;
}
- ret=DmxDevBufferWrite(buffer, buffer1, buffer1_len);
+ ret=dvb_dmxdev_buffer_write(buffer, buffer1, buffer1_len);
if (ret==buffer1_len)
- ret=DmxDevBufferWrite(buffer, buffer2, buffer2_len);
+ ret=dvb_dmxdev_buffer_write(buffer, buffer2, buffer2_len);
if (ret<0) {
buffer->pwrite=buffer->pread;
buffer->error=-EOVERFLOW;
@@ -431,9 +431,9 @@ DmxDevTSCallback(u8 *buffer1, size_t buffer1_len,
/* stop feed but only mark the specified filter as stopped (state set) */
static int
-DmxDevFeedStop(dmxdev_filter_t *dmxdevfilter)
+dvb_dmxdev_feed_stop(dmxdev_filter_t *dmxdevfilter)
{
- DmxDevFilterStateSet(dmxdevfilter, DMXDEV_STATE_SET);
+ dvb_dmxdev_filter_state_set(dmxdevfilter, DMXDEV_STATE_SET);
switch (dmxdevfilter->type) {
case DMXDEV_TYPE_SEC:
@@ -453,9 +453,9 @@ DmxDevFeedStop(dmxdev_filter_t *dmxdevfilter)
/* start feed associated with the specified filter */
static int
-DmxDevFeedStart(dmxdev_filter_t *dmxdevfilter)
+dvb_dmxdev_feed_start(dmxdev_filter_t *dmxdevfilter)
{
- DmxDevFilterStateSet(dmxdevfilter, DMXDEV_STATE_GO);
+ dvb_dmxdev_filter_state_set(dmxdevfilter, DMXDEV_STATE_GO);
switch (dmxdevfilter->type) {
case DMXDEV_TYPE_SEC:
@@ -475,7 +475,7 @@ DmxDevFeedStart(dmxdev_filter_t *dmxdevfilter)
otherwise release the feed */
static int
-DmxDevFeedRestart(dmxdev_filter_t *dmxdevfilter)
+dvb_dmxdev_feed_restart(dmxdev_filter_t *dmxdevfilter)
{
int i;
dmxdev_t *dmxdev=dmxdevfilter->dev;
@@ -485,7 +485,7 @@ DmxDevFeedRestart(dmxdev_filter_t *dmxdevfilter)
if (dmxdev->filter[i].state>=DMXDEV_STATE_GO &&
dmxdev->filter[i].type==DMXDEV_TYPE_SEC &&
dmxdev->filter[i].pid==pid) {
- DmxDevFeedStart(&dmxdev->filter[i]);
+ dvb_dmxdev_feed_start(&dmxdev->filter[i]);
return 0;
}
@@ -497,7 +497,7 @@ DmxDevFeedRestart(dmxdev_filter_t *dmxdevfilter)
}
static int
-DmxDevFilterStop(dmxdev_filter_t *dmxdevfilter)
+dvb_dmxdev_filter_stop(dmxdev_filter_t *dmxdevfilter)
{
if (dmxdevfilter->state<DMXDEV_STATE_GO)
return 0;
@@ -506,18 +506,18 @@ DmxDevFilterStop(dmxdev_filter_t *dmxdevfilter)
case DMXDEV_TYPE_SEC:
if (!dmxdevfilter->feed.sec)
break;
- DmxDevFeedStop(dmxdevfilter);
+ dvb_dmxdev_feed_stop(dmxdevfilter);
if (dmxdevfilter->filter.sec)
dmxdevfilter->feed.sec->
release_filter(dmxdevfilter->feed.sec,
dmxdevfilter->filter.sec);
- DmxDevFeedRestart(dmxdevfilter);
+ dvb_dmxdev_feed_restart(dmxdevfilter);
dmxdevfilter->feed.sec=0;
break;
case DMXDEV_TYPE_PES:
if (!dmxdevfilter->feed.ts)
break;
- DmxDevFeedStop(dmxdevfilter);
+ dvb_dmxdev_feed_stop(dmxdevfilter);
dmxdevfilter->dev->demux->
release_ts_feed(dmxdevfilter->dev->demux,
dmxdevfilter->feed.ts);
@@ -533,19 +533,19 @@ DmxDevFilterStop(dmxdev_filter_t *dmxdevfilter)
}
static inline int
-DmxDevFilterReset(dmxdev_filter_t *dmxdevfilter)
+dvb_dmxdev_filter_reset(dmxdev_filter_t *dmxdevfilter)
{
if (dmxdevfilter->state<DMXDEV_STATE_SET)
return 0;
dmxdevfilter->type=DMXDEV_TYPE_NONE;
dmxdevfilter->pid=0xffff;
- DmxDevFilterStateSet(dmxdevfilter, DMXDEV_STATE_ALLOCATED);
+ dvb_dmxdev_filter_state_set(dmxdevfilter, DMXDEV_STATE_ALLOCATED);
return 0;
}
static int
-DmxDevFilterStart(dmxdev_filter_t *dmxdevfilter)
+dvb_dmxdev_filter_start(dmxdev_filter_t *dmxdevfilter)
{
dmxdev_t *dmxdev=dmxdevfilter->dev;
void *mem;
@@ -554,7 +554,7 @@ DmxDevFilterStart(dmxdev_filter_t *dmxdevfilter)
if (dmxdevfilter->state<DMXDEV_STATE_SET)
return -EINVAL;
if (dmxdevfilter->state>=DMXDEV_STATE_GO)
- DmxDevFilterStop(dmxdevfilter);
+ dvb_dmxdev_filter_stop(dmxdevfilter);
mem=dmxdevfilter->buffer.data;
if (!mem) {
@@ -591,7 +591,7 @@ DmxDevFilterStart(dmxdev_filter_t *dmxdevfilter)
ret=dmxdev->demux->
allocate_section_feed(dmxdev->demux,
secfeed,
- DmxDevSectionCallback);
+ dvb_dmxdev_section_callback);
if (ret<0) {
printk ("DVB (%s): could not alloc feed\n",
__FUNCTION__);
@@ -604,16 +604,16 @@ DmxDevFilterStart(dmxdev_filter_t *dmxdevfilter)
if (ret<0) {
printk ("DVB (%s): could not set feed\n",
__FUNCTION__);
- DmxDevFeedRestart(dmxdevfilter);
+ dvb_dmxdev_feed_restart(dmxdevfilter);
return ret;
}
}
else
- DmxDevFeedStop(dmxdevfilter);
+ dvb_dmxdev_feed_stop(dmxdevfilter);
ret=(*secfeed)->allocate_filter(*secfeed, secfilter);
if (ret<0) {
- DmxDevFeedRestart(dmxdevfilter);
+ dvb_dmxdev_feed_restart(dmxdevfilter);
dmxdevfilter->feed.sec->
start_filtering(*secfeed);
dprintk ("could not get filter\n");
@@ -638,7 +638,7 @@ DmxDevFilterStart(dmxdev_filter_t *dmxdevfilter)
dmxdevfilter->todo=0;
dmxdevfilter->feed.sec->
start_filtering(dmxdevfilter->feed.sec);
- DmxDevFilterTimer(dmxdevfilter);
+ dvb_dmxdev_filter_timer(dmxdevfilter);
break;
}
@@ -670,7 +670,7 @@ DmxDevFilterStart(dmxdev_filter_t *dmxdevfilter)
ret=dmxdev->demux->allocate_ts_feed(dmxdev->demux,
tsfeed,
- DmxDevTSCallback);
+ dvb_dmxdev_ts_callback);
if (ret<0)
return ret;
@@ -688,7 +688,7 @@ DmxDevFilterStart(dmxdev_filter_t *dmxdevfilter)
default:
return -EINVAL;
}
- DmxDevFilterStateSet(dmxdevfilter, DMXDEV_STATE_GO);
+ dvb_dmxdev_filter_state_set(dmxdevfilter, DMXDEV_STATE_GO);
return 0;
}
@@ -714,9 +714,9 @@ static int dvb_demux_open(struct inode *inode, struct file *file)
dmxdevfilter->dvbdev=dmxdev->dvbdev;
file->private_data=dmxdevfilter;
- DmxDevBufferInit(&dmxdevfilter->buffer);
+ dvb_dmxdev_buffer_init(&dmxdevfilter->buffer);
dmxdevfilter->type=DMXDEV_TYPE_NONE;
- DmxDevFilterStateSet(dmxdevfilter, DMXDEV_STATE_ALLOCATED);
+ dvb_dmxdev_filter_state_set(dmxdevfilter, DMXDEV_STATE_ALLOCATED);
dmxdevfilter->feed.ts=0;
init_timer(&dmxdevfilter->timer);
@@ -725,13 +725,13 @@ static int dvb_demux_open(struct inode *inode, struct file *file)
}
int
-DmxDevFilterFree(dmxdev_t *dmxdev, dmxdev_filter_t *dmxdevfilter)
+dvb_dmxdev_filter_free(dmxdev_t *dmxdev, dmxdev_filter_t *dmxdevfilter)
{
if (down_interruptible(&dmxdev->mutex))
return -ERESTARTSYS;
- DmxDevFilterStop(dmxdevfilter);
- DmxDevFilterReset(dmxdevfilter);
+ dvb_dmxdev_filter_stop(dmxdevfilter);
+ dvb_dmxdev_filter_reset(dmxdevfilter);
if (dmxdevfilter->buffer.data) {
void *mem=dmxdevfilter->buffer.data;
@@ -741,7 +741,7 @@ DmxDevFilterFree(dmxdev_t *dmxdev, dmxdev_filter_t *dmxdevfilter)
spin_unlock_irq(&dmxdev->lock);
vfree(mem);
}
- DmxDevFilterStateSet(dmxdevfilter, DMXDEV_STATE_FREE);
+ dvb_dmxdev_filter_state_set(dmxdevfilter, DMXDEV_STATE_FREE);
wake_up(&dmxdevfilter->buffer.queue);
up(&dmxdev->mutex);
return 0;
@@ -758,33 +758,33 @@ invert_mode(dmx_filter_t *filter)
static int
-DmxDevFilterSet(dmxdev_t *dmxdev,
+dvb_dmxdev_filter_set(dmxdev_t *dmxdev,
dmxdev_filter_t *dmxdevfilter,
struct dmx_sct_filter_params *params)
{
dprintk ("function : %s\n", __FUNCTION__);
- DmxDevFilterStop(dmxdevfilter);
+ dvb_dmxdev_filter_stop(dmxdevfilter);
dmxdevfilter->type=DMXDEV_TYPE_SEC;
dmxdevfilter->pid=params->pid;
memcpy(&dmxdevfilter->params.sec,
params, sizeof(struct dmx_sct_filter_params));
invert_mode(&dmxdevfilter->params.sec.filter);
- DmxDevFilterStateSet(dmxdevfilter, DMXDEV_STATE_SET);
+ dvb_dmxdev_filter_state_set(dmxdevfilter, DMXDEV_STATE_SET);
if (params->flags&DMX_IMMEDIATE_START)
- return DmxDevFilterStart(dmxdevfilter);
+ return dvb_dmxdev_filter_start(dmxdevfilter);
return 0;
}
static int
-DmxDevPesFilterSet(dmxdev_t *dmxdev,
+dvb_dmxdev_pes_filter_set(dmxdev_t *dmxdev,
dmxdev_filter_t *dmxdevfilter,
struct dmx_pes_filter_params *params)
{
- DmxDevFilterStop(dmxdevfilter);
+ dvb_dmxdev_filter_stop(dmxdevfilter);
if (params->pes_type>DMX_PES_OTHER || params->pes_type<0)
return -EINVAL;
@@ -793,16 +793,16 @@ DmxDevPesFilterSet(dmxdev_t *dmxdev,
dmxdevfilter->pid=params->pid;
memcpy(&dmxdevfilter->params, params, sizeof(struct dmx_pes_filter_params));
- DmxDevFilterStateSet(dmxdevfilter, DMXDEV_STATE_SET);
+ dvb_dmxdev_filter_state_set(dmxdevfilter, DMXDEV_STATE_SET);
if (params->flags&DMX_IMMEDIATE_START)
- return DmxDevFilterStart(dmxdevfilter);
+ return dvb_dmxdev_filter_start(dmxdevfilter);
return 0;
}
static ssize_t
-DmxDevReadSec(dmxdev_filter_t *dfil, struct file *file,
+dvb_dmxdev_read_sec(dmxdev_filter_t *dfil, struct file *file,
char *buf, size_t count, loff_t *ppos)
{
int result, hcount;
@@ -812,7 +812,7 @@ DmxDevReadSec(dmxdev_filter_t *dfil, struct file *file,
hcount=3+dfil->todo;
if (hcount>count)
hcount=count;
- result=DmxDevBufferRead(&dfil->buffer, file->f_flags&O_NONBLOCK,
+ result=dvb_dmxdev_buffer_read(&dfil->buffer, file->f_flags&O_NONBLOCK,
buf, hcount, ppos);
if (result<0) {
dfil->todo=0;
@@ -832,7 +832,7 @@ DmxDevReadSec(dmxdev_filter_t *dfil, struct file *file,
}
if (count>dfil->todo)
count=dfil->todo;
- result=DmxDevBufferRead(&dfil->buffer, file->f_flags&O_NONBLOCK,
+ result=dvb_dmxdev_buffer_read(&dfil->buffer, file->f_flags&O_NONBLOCK,
buf, count, ppos);
if (result<0)
return result;
@@ -844,16 +844,16 @@ DmxDevReadSec(dmxdev_filter_t *dfil, struct file *file,
ssize_t
dvb_demux_read(struct file *file, char *buf, size_t count, loff_t *ppos)
{
- dmxdev_filter_t *dmxdevfilter=DmxDevFile2Filter(file);
+ dmxdev_filter_t *dmxdevfilter=dvb_dmxdev_file_to_filter(file);
//dmxdev_t *dmxdev=dmxdevfilter->dev;
int ret=0;
// semaphore should not be necessary (I hope ...)
//down(&dmxdev->mutex);
if (dmxdevfilter->type==DMXDEV_TYPE_SEC)
- ret=DmxDevReadSec(dmxdevfilter, file, buf, count, ppos);
+ ret=dvb_dmxdev_read_sec(dmxdevfilter, file, buf, count, ppos);
else
- ret=DmxDevBufferRead(&dmxdevfilter->buffer,
+ ret=dvb_dmxdev_buffer_read(&dmxdevfilter->buffer,
file->f_flags&O_NONBLOCK,
buf, count, ppos);
//up(&dmxdev->mutex);
@@ -864,7 +864,7 @@ dvb_demux_read(struct file *file, char *buf, size_t count, loff_t *ppos)
static int dvb_demux_do_ioctl(struct inode *inode, struct file *file,
unsigned int cmd, void *parg)
{
- dmxdev_filter_t *dmxdevfilter=DmxDevFile2Filter(file);
+ dmxdev_filter_t *dmxdevfilter=dvb_dmxdev_file_to_filter(file);
dmxdev_t *dmxdev=dmxdevfilter->dev;
unsigned long arg=(unsigned long) parg;
int ret=0;
@@ -877,25 +877,25 @@ static int dvb_demux_do_ioctl(struct inode *inode, struct file *file,
if (dmxdevfilter->state<DMXDEV_STATE_SET)
ret=-EINVAL;
else
- ret=DmxDevFilterStart(dmxdevfilter);
+ ret=dvb_dmxdev_filter_start(dmxdevfilter);
break;
case DMX_STOP:
- ret=DmxDevFilterStop(dmxdevfilter);
+ ret=dvb_dmxdev_filter_stop(dmxdevfilter);
break;
case DMX_SET_FILTER:
- ret=DmxDevFilterSet(dmxdev, dmxdevfilter,
+ ret=dvb_dmxdev_filter_set(dmxdev, dmxdevfilter,
(struct dmx_sct_filter_params *)parg);
break;
case DMX_SET_PES_FILTER:
- ret=DmxDevPesFilterSet(dmxdev, dmxdevfilter,
+ ret=dvb_dmxdev_pes_filter_set(dmxdev, dmxdevfilter,
(struct dmx_pes_filter_params *)parg);
break;
case DMX_SET_BUFFER_SIZE:
- ret=DmxDevSetBufferSize(dmxdevfilter, arg);
+ ret=dvb_dmxdev_set_buffer_size(dmxdevfilter, arg);
break;
case DMX_GET_EVENT:
@@ -925,7 +925,7 @@ static int dvb_demux_ioctl(struct inode *inode, struct file *file,
static unsigned int dvb_demux_poll(struct file *file, poll_table *wait)
{
- dmxdev_filter_t *dmxdevfilter=DmxDevFile2Filter(file);
+ dmxdev_filter_t *dmxdevfilter=dvb_dmxdev_file_to_filter(file);
if (!dmxdevfilter)
return -EINVAL;
@@ -958,10 +958,10 @@ static unsigned int dvb_demux_poll(struct file *file, poll_table *wait)
static int dvb_demux_release(struct inode *inode, struct file *file)
{
- dmxdev_filter_t *dmxdevfilter=DmxDevFile2Filter(file);
+ dmxdev_filter_t *dmxdevfilter=dvb_dmxdev_file_to_filter(file);
dmxdev_t *dmxdev=dmxdevfilter->dev;
- return DmxDevFilterFree(dmxdev, dmxdevfilter);
+ return dvb_dmxdev_filter_free(dmxdev, dmxdevfilter);
}
static struct file_operations dvb_demux_fops = {
@@ -1056,7 +1056,7 @@ static dvb_device_t dvbdev_dvr = {
};
int
-DmxDevInit(dmxdev_t *dmxdev, dvb_adapter_t *dvb_adapter)
+dvb_dmxdev_init(dmxdev_t *dmxdev, dvb_adapter_t *dvb_adapter)
{
int i;
@@ -1078,22 +1078,22 @@ DmxDevInit(dmxdev_t *dmxdev, dvb_adapter_t *dvb_adapter)
for (i=0; i<dmxdev->filternum; i++) {
dmxdev->filter[i].dev=dmxdev;
dmxdev->filter[i].buffer.data=0;
- DmxDevFilterStateSet(&dmxdev->filter[i], DMXDEV_STATE_FREE);
+ dvb_dmxdev_filter_state_set(&dmxdev->filter[i], DMXDEV_STATE_FREE);
dmxdev->dvr[i].dev=dmxdev;
dmxdev->dvr[i].buffer.data=0;
- DmxDevFilterStateSet(&dmxdev->filter[i], DMXDEV_STATE_FREE);
- DmxDevDVRStateSet(&dmxdev->dvr[i], DMXDEV_STATE_FREE);
+ dvb_dmxdev_filter_state_set(&dmxdev->filter[i], DMXDEV_STATE_FREE);
+ dvb_dmxdev_dvr_state_set(&dmxdev->dvr[i], DMXDEV_STATE_FREE);
}
dvb_register_device(dvb_adapter, &dmxdev->dvbdev, &dvbdev_demux, dmxdev, DVB_DEVICE_DEMUX);
dvb_register_device(dvb_adapter, &dmxdev->dvr_dvbdev, &dvbdev_dvr, dmxdev, DVB_DEVICE_DVR);
- DmxDevBufferInit(&dmxdev->dvr_buffer);
+ dvb_dmxdev_buffer_init(&dmxdev->dvr_buffer);
MOD_INC_USE_COUNT;
return 0;
}
void
-DmxDevRelease(dmxdev_t *dmxdev)
+dvb_dmxdev_release(dmxdev_t *dmxdev)
{
dvb_unregister_device(dmxdev->dvbdev);
dvb_unregister_device(dmxdev->dvr_dvbdev);
diff --git a/linux/drivers/media/dvb/dvb-core/dmxdev.h b/linux/drivers/media/dvb/dvb-core/dmxdev.h
index c5fa89d51..2ce28656e 100644
--- a/linux/drivers/media/dvb/dvb-core/dmxdev.h
+++ b/linux/drivers/media/dvb/dvb-core/dmxdev.h
@@ -122,7 +122,7 @@ typedef struct dmxdev_s {
} dmxdev_t;
-int DmxDevInit(dmxdev_t *dmxdev, dvb_adapter_t *);
-void DmxDevRelease(dmxdev_t *dmxdev);
+int dvb_dmxdev_init(dmxdev_t *dmxdev, dvb_adapter_t *);
+void dvb_dmxdev_release(dmxdev_t *dmxdev);
#endif /* _DMXDEV_H_ */
diff --git a/linux/drivers/media/dvb/dvb-core/dvb_demux.c b/linux/drivers/media/dvb/dvb-core/dvb_demux.c
index 3a3e3834a..4920d3f6f 100644
--- a/linux/drivers/media/dvb/dvb-core/dvb_demux.c
+++ b/linux/drivers/media/dvb/dvb-core/dvb_demux.c
@@ -182,7 +182,7 @@ void dvb_set_crc32(u8 *data, int length)
******************************************************************************/
static inline int
-DvbDmxSWFilterPayload(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
+dvb_dmx_swfilter_payload(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
{
int p, count;
//int ccok;
@@ -208,7 +208,7 @@ DvbDmxSWFilterPayload(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
static int
-DvbDmxSWFilterSectionFilter(dvb_demux_feed_t *dvbdmxfeed,
+dvb_dmx_swfilter_sectionfilter(dvb_demux_feed_t *dvbdmxfeed,
dvb_demux_filter_t *f)
{
dmx_section_filter_t *filter=&f->filter;
@@ -229,7 +229,7 @@ DvbDmxSWFilterSectionFilter(dvb_demux_feed_t *dvbdmxfeed,
}
static inline int
-DvbDmxSWFilterSectionFeed(dvb_demux_feed_t *dvbdmxfeed)
+dvb_dmx_swfilter_section_feed(dvb_demux_feed_t *dvbdmxfeed)
{
u8 *buf=dvbdmxfeed->secbuf;
dvb_demux_filter_t *f;
@@ -241,7 +241,7 @@ DvbDmxSWFilterSectionFeed(dvb_demux_feed_t *dvbdmxfeed)
if (!(f=dvbdmxfeed->filter))
return 0;
do
- if (DvbDmxSWFilterSectionFilter(dvbdmxfeed, f)<0)
+ if (dvb_dmx_swfilter_sectionfilter(dvbdmxfeed, f)<0)
return -1;
while ((f=f->next) && dvbdmxfeed->feed.sec.is_filtering);
@@ -251,7 +251,7 @@ DvbDmxSWFilterSectionFeed(dvb_demux_feed_t *dvbdmxfeed)
}
static inline int
-DvbDmxSWFilterSectionPacket(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
+dvb_dmx_swfilter_section_packet(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
{
int p, count;
int ccok, rest;
@@ -286,7 +286,7 @@ DvbDmxSWFilterSectionPacket(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
memcpy(dvbdmxfeed->secbuf+dvbdmxfeed->secbufp,
buf+p+1, buf[p]);
dvbdmxfeed->secbufp+=buf[p];
- DvbDmxSWFilterSectionFeed(dvbdmxfeed);
+ dvb_dmx_swfilter_section_feed(dvbdmxfeed);
}
}
p+=buf[p]+1; // skip rest of last section
@@ -301,7 +301,7 @@ DvbDmxSWFilterSectionPacket(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
dvbdmxfeed->secbufp=dvbdmxfeed->seclen;
p+=dvbdmxfeed->seclen;
count=188-p;
- DvbDmxSWFilterSectionFeed(dvbdmxfeed);
+ dvb_dmx_swfilter_section_feed(dvbdmxfeed);
// filling bytes until packet end?
if (count && buf[p]==0xff)
@@ -337,7 +337,7 @@ DvbDmxSWFilterSectionPacket(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
if (rest<=count) { // section completed in this TS packet
memcpy(dvbdmxfeed->secbuf+dvbdmxfeed->secbufp, buf+p, rest);
dvbdmxfeed->secbufp+=rest;
- DvbDmxSWFilterSectionFeed(dvbdmxfeed);
+ dvb_dmx_swfilter_section_feed(dvbdmxfeed);
} else { // section continues in following ts packet
memcpy(dvbdmxfeed->secbuf+dvbdmxfeed->secbufp, buf+p, count);
dvbdmxfeed->secbufp+=count;
@@ -346,7 +346,7 @@ DvbDmxSWFilterSectionPacket(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
}
static inline void
-DvbDmxSWFilterPacketType(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
+dvb_dmx_swfilter_packet_type(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
{
switch(dvbdmxfeed->type) {
case DMX_TYPE_TS:
@@ -354,7 +354,7 @@ DvbDmxSWFilterPacketType(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
break;
if (dvbdmxfeed->ts_type & TS_PACKET) {
if (dvbdmxfeed->ts_type & TS_PAYLOAD_ONLY)
- DvbDmxSWFilterPayload(dvbdmxfeed, buf);
+ dvb_dmx_swfilter_payload(dvbdmxfeed, buf);
else
dvbdmxfeed->cb.ts((u8 *)buf, 188, 0, 0,
&dvbdmxfeed->feed.ts, DMX_OK);
@@ -368,7 +368,7 @@ DvbDmxSWFilterPacketType(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
case DMX_TYPE_SEC:
if (!dvbdmxfeed->feed.sec.is_filtering)
break;
- if (DvbDmxSWFilterSectionPacket(dvbdmxfeed, buf)<0)
+ if (dvb_dmx_swfilter_section_packet(dvbdmxfeed, buf)<0)
dvbdmxfeed->seclen=dvbdmxfeed->secbufp=0;
break;
@@ -378,17 +378,17 @@ DvbDmxSWFilterPacketType(dvb_demux_feed_t *dvbdmxfeed, const u8 *buf)
}
void inline
-DvbDmxSWFilterPacket(dvb_demux_t *dvbdmx, const u8 *buf)
+dvb_dmx_swfilter_packet(dvb_demux_t *dvbdmx, const u8 *buf)
{
dvb_demux_feed_t *dvbdmxfeed;
if (!(dvbdmxfeed=dvbdmx->pid2feed[ts_pid(buf)]))
return;
- DvbDmxSWFilterPacketType(dvbdmxfeed, buf);
+ dvb_dmx_swfilter_packet_type(dvbdmxfeed, buf);
}
void
-DvbDmxSWFilterPackets(dvb_demux_t *dvbdmx, const u8 *buf, int count)
+dvb_dmx_swfilter_packets(dvb_demux_t *dvbdmx, const u8 *buf, int count)
{
dvb_demux_feed_t *dvbdmxfeed;
@@ -397,7 +397,7 @@ DvbDmxSWFilterPackets(dvb_demux_t *dvbdmx, const u8 *buf, int count)
dvbdmxfeed->cb.ts((u8 *)buf, count*188, 0, 0,
&dvbdmxfeed->feed.ts, DMX_OK);
while (count) {
- DvbDmxSWFilterPacket(dvbdmx, buf);
+ dvb_dmx_swfilter_packet(dvbdmx, buf);
count--;
buf+=188;
}
@@ -405,7 +405,7 @@ DvbDmxSWFilterPackets(dvb_demux_t *dvbdmx, const u8 *buf, int count)
}
static inline void
-DvbDmxSWFilter(dvb_demux_t *dvbdmx, const u8 *buf, size_t count)
+dvb_dmx_swfilter(dvb_demux_t *dvbdmx, const u8 *buf, size_t count)
{
int p=0,i, j;
@@ -416,7 +416,7 @@ DvbDmxSWFilter(dvb_demux_t *dvbdmx, const u8 *buf, size_t count)
return;
}
memcpy(&dvbdmx->tsbuf[i], buf, j);
- DvbDmxSWFilterPacket(dvbdmx, dvbdmx->tsbuf);
+ dvb_dmx_swfilter_packet(dvbdmx, dvbdmx->tsbuf);
dvbdmx->tsbufp=0;
p+=j;
}
@@ -424,7 +424,7 @@ DvbDmxSWFilter(dvb_demux_t *dvbdmx, const u8 *buf, size_t count)
while (p<count) {
if (buf[p]==0x47) {
if (count-p>=188) {
- DvbDmxSWFilterPacket(dvbdmx, buf+p);
+ dvb_dmx_swfilter_packet(dvbdmx, buf+p);
p+=188;
} else {
i=count-p;
@@ -445,7 +445,7 @@ DvbDmxSWFilter(dvb_demux_t *dvbdmx, const u8 *buf, size_t count)
******************************************************************************/
static dvb_demux_filter_t *
-DvbDmxFilterAlloc(dvb_demux_t *dvbdmx)
+dvb_dmx_filter_alloc(dvb_demux_t *dvbdmx)
{
int i;
@@ -459,7 +459,7 @@ DvbDmxFilterAlloc(dvb_demux_t *dvbdmx)
}
static dvb_demux_feed_t *
-DvbDmxFeedAlloc(dvb_demux_t *dvbdmx)
+dvb_dmx_feed_alloc(dvb_demux_t *dvbdmx)
{
int i;
@@ -643,7 +643,7 @@ static int dvbdmx_allocate_ts_feed(dmx_demux_t *demux,
if (down_interruptible (&dvbdmx->mutex))
return -ERESTARTSYS;
- if (!(dvbdmxfeed=DvbDmxFeedAlloc(dvbdmx))) {
+ if (!(dvbdmxfeed=dvb_dmx_feed_alloc(dvbdmx))) {
up(&dvbdmx->mutex);
return -EBUSY;
}
@@ -663,7 +663,7 @@ static int dvbdmx_allocate_ts_feed(dmx_demux_t *demux,
(*feed)->stop_filtering=dmx_ts_feed_stop_filtering;
- if (!(dvbdmxfeed->filter=DvbDmxFilterAlloc(dvbdmx))) {
+ if (!(dvbdmxfeed->filter=dvb_dmx_filter_alloc(dvbdmx))) {
dvbdmxfeed->state=DMX_STATE_FREE;
up(&dvbdmx->mutex);
return -EBUSY;
@@ -722,7 +722,7 @@ dmx_section_feed_allocate_filter(struct dmx_section_feed_s* feed,
if (down_interruptible (&dvbdemux->mutex))
return -ERESTARTSYS;
- dvbdmxfilter=DvbDmxFilterAlloc(dvbdemux);
+ dvbdmxfilter=dvb_dmx_filter_alloc(dvbdemux);
if (!dvbdmxfilter) {
up(&dvbdemux->mutex);
return -ENOSPC;
@@ -917,7 +917,7 @@ static int dvbdmx_allocate_section_feed(dmx_demux_t *demux,
if (down_interruptible (&dvbdmx->mutex))
return -ERESTARTSYS;
- if (!(dvbdmxfeed=DvbDmxFeedAlloc(dvbdmx))) {
+ if (!(dvbdmxfeed=dvb_dmx_feed_alloc(dvbdmx))) {
up(&dvbdmx->mutex);
return -EBUSY;
}
@@ -1007,7 +1007,7 @@ static int dvbdmx_write(dmx_demux_t *demux, const char *buf, size_t count)
if (down_interruptible (&dvbdemux->mutex))
return -ERESTARTSYS;
- DvbDmxSWFilter(dvbdemux, buf, count);
+ dvb_dmx_swfilter(dvbdemux, buf, count);
up(&dvbdemux->mutex);
return count;
}
@@ -1096,7 +1096,7 @@ static int dvbdmx_get_pes_pids(dmx_demux_t *demux, u16 *pids)
}
int
-DvbDmxInit(dvb_demux_t *dvbdemux)
+dvb_dmx_init(dvb_demux_t *dvbdemux)
{
int i;
dmx_demux_t *dmx=&dvbdemux->dmx;
@@ -1159,7 +1159,7 @@ DvbDmxInit(dvb_demux_t *dvbdemux)
}
int
-DvbDmxRelease(dvb_demux_t *dvbdemux)
+dvb_dmx_release(dvb_demux_t *dvbdemux)
{
dmx_demux_t *dmx=&dvbdemux->dmx;
diff --git a/linux/drivers/media/dvb/dvb-core/dvb_demux.h b/linux/drivers/media/dvb/dvb-core/dvb_demux.h
index 7fb008c4b..2c4b0f175 100644
--- a/linux/drivers/media/dvb/dvb-core/dvb_demux.h
+++ b/linux/drivers/media/dvb/dvb-core/dvb_demux.h
@@ -127,8 +127,8 @@ typedef struct dvb_demux_s {
} dvb_demux_t;
-int DvbDmxInit(dvb_demux_t *dvbdemux);
-int DvbDmxRelease(dvb_demux_t *dvbdemux);
-void DvbDmxSWFilterPackets(dvb_demux_t *dvbdmx, const u8 *buf, int count);
+int dvb_dmx_init(dvb_demux_t *dvbdemux);
+int dvb_dmx_release(dvb_demux_t *dvbdemux);
+void dvb_dmx_swfilter_packets(dvb_demux_t *dvbdmx, const u8 *buf, int count);
#endif /* _DVB_DEMUX_H_ */
diff --git a/linux/drivers/media/dvb/dvb-core/dvb_filter.c b/linux/drivers/media/dvb/dvb-core/dvb_filter.c
index 4b6ef6d32..d73e27c64 100644
--- a/linux/drivers/media/dvb/dvb-core/dvb_filter.c
+++ b/linux/drivers/media/dvb/dvb-core/dvb_filter.c
@@ -24,8 +24,8 @@ uint32_t ac3_frames[3][32] =
-void pes2ts_init(pes2ts_t *p2ts, unsigned short pid,
- pes2ts_cb_t *cb, void *priv)
+void dvb_filter_dvb_filter_pes2ts_init(dvb_filter_dvb_filter_pes2ts_t *p2ts, unsigned short pid,
+ dvb_filter_dvb_filter_pes2ts_cb_t *cb, void *priv)
{
unsigned char *buf=p2ts->buf;
@@ -37,7 +37,7 @@ void pes2ts_init(pes2ts_t *p2ts, unsigned short pid,
p2ts->priv=priv;
}
-int pes2ts(pes2ts_t *p2ts, unsigned char *pes, int len)
+int dvb_filter_dvb_filter_pes2ts(dvb_filter_dvb_filter_pes2ts_t *p2ts, unsigned char *pes, int len)
{
unsigned char *buf=p2ts->buf;
int ret=0, rest;
@@ -67,7 +67,7 @@ int pes2ts(pes2ts_t *p2ts, unsigned char *pes, int len)
return p2ts->cb(p2ts->priv, buf);
}
-void reset_ipack(ipack *p)
+void dvb_filter_ipack_reset(ipack *p)
{
p->found = 0;
p->cid = 0;
@@ -82,7 +82,7 @@ void reset_ipack(ipack *p)
p->count = 0;
}
-void init_ipack(ipack *p, int size,
+void dvb_filter_ipack_init(ipack *p, int size,
void (*func)(u8 *buf, int size, void *priv))
{
if ( !(p->buf = vmalloc(size*sizeof(u8))) ){
@@ -91,10 +91,10 @@ void init_ipack(ipack *p, int size,
p->size = size;
p->func = func;
p->repack_subids = 0;
- reset_ipack(p);
+ dvb_filter_ipack_reset(p);
}
-void free_ipack(ipack * p)
+void dvb_filter_ipack_free(ipack * p)
{
if (p->buf) vfree(p->buf);
}
@@ -168,14 +168,14 @@ void send_ipack(ipack *p)
}
}
-void send_ipack_rest(ipack *p)
+void dvb_filter_ipack_flush(ipack *p)
{
if (p->plength != MMAX_PLENGTH-6 || p->found<=6)
return;
p->plength = p->found-6;
p->found = 0;
send_ipack(p);
- reset_ipack(p);
+ dvb_filter_ipack_reset(p);
}
static void write_ipack(ipack *p, u8 *data, int count)
@@ -200,7 +200,7 @@ static void write_ipack(ipack *p, u8 *data, int count)
}
}
-int instant_repack(u8 *buf, int count, ipack *p)
+int dvb_filter_dvb_filter_instant_repack(u8 *buf, int count, ipack *p)
{
int l;
int c=0;
@@ -450,9 +450,9 @@ int instant_repack(u8 *buf, int count, ipack *p)
if (p->plength && p->found == p->plength+6) {
send_ipack(p);
- reset_ipack(p);
+ dvb_filter_ipack_reset(p);
if (c < count)
- instant_repack(buf+c, count-c, p);
+ dvb_filter_dvb_filter_instant_repack(buf+c, count-c, p);
}
}
return count;
@@ -464,8 +464,8 @@ void setup_ts2pes(ipack *pa, ipack *pv, u16 *pida, u16 *pidv,
void (*pes_write)(u8 *buf, int count, void *data),
void *priv)
{
- init_ipack(pa, IPACKS, pes_write);
- init_ipack(pv, IPACKS, pes_write);
+ dvb_filter_ipack_init(pa, IPACKS, pes_write);
+ dvb_filter_ipack_init(pv, IPACKS, pes_write);
pa->pid = pida;
pv->pid = pidv;
pa->data = priv;
@@ -485,14 +485,14 @@ void ts_to_pes(ipack *p, u8 *buf) // don't need count (=188)
p->plength = p->found-6;
p->found = 0;
send_ipack(p);
- reset_ipack(p);
+ dvb_filter_ipack_reset(p);
}
}
if (buf[3] & ADAPT_FIELD) { // adaptation field?
off = buf[4] + 1;
if (off+4 > 187) return;
}
- instant_repack(buf+4+off, TS_SIZE-4-off, p);
+ dvb_filter_dvb_filter_instant_repack(buf+4+off, TS_SIZE-4-off, p);
}
/* needs 5 byte input, returns picture coding type*/
diff --git a/linux/drivers/media/dvb/dvb-core/dvb_filter.h b/linux/drivers/media/dvb/dvb-core/dvb_filter.h
index 062fdcae4..c8140a4dd 100644
--- a/linux/drivers/media/dvb/dvb-core/dvb_filter.h
+++ b/linux/drivers/media/dvb/dvb-core/dvb_filter.h
@@ -6,18 +6,18 @@
#include "demux.h"
-typedef int (pes2ts_cb_t) (void *, unsigned char *);
+typedef int (dvb_filter_dvb_filter_pes2ts_cb_t) (void *, unsigned char *);
-typedef struct pes2ts_s {
+typedef struct dvb_filter_dvb_filter_pes2ts_s {
unsigned char buf[188];
unsigned char cc;
- pes2ts_cb_t *cb;
+ dvb_filter_dvb_filter_pes2ts_cb_t *cb;
void *priv;
-} pes2ts_t;
+} dvb_filter_dvb_filter_pes2ts_t;
-void pes2ts_init(pes2ts_t *p2ts, unsigned short pid,
- pes2ts_cb_t *cb, void *priv);
-int pes2ts(pes2ts_t *p2ts, unsigned char *pes, int len);
+void dvb_filter_dvb_filter_pes2ts_init(dvb_filter_dvb_filter_pes2ts_t *p2ts, unsigned short pid,
+ dvb_filter_dvb_filter_pes2ts_cb_t *cb, void *priv);
+int dvb_filter_dvb_filter_pes2ts(dvb_filter_dvb_filter_pes2ts_t *p2ts, unsigned char *pes, int len);
#define PROG_STREAM_MAP 0xBC
@@ -224,17 +224,17 @@ typedef struct audio_i{
} AudioInfo;
-void reset_ipack(ipack *p);
-int instant_repack(u8 *buf, int count, ipack *p);
-void init_ipack(ipack *p, int size,
+void dvb_filter_ipack_reset(ipack *p);
+int dvb_filter_dvb_filter_instant_repack(u8 *buf, int count, ipack *p);
+void dvb_filter_ipack_init(ipack *p, int size,
void (*func)(u8 *buf, int size, void *priv));
-void free_ipack(ipack * p);
+void dvb_filter_ipack_free(ipack * p);
void setup_ts2pes(ipack *pa, ipack *pv, u16 *pida, u16 *pidv,
void (*pes_write)(u8 *buf, int count, void *data),
void *priv);
void ts_to_pes(ipack *p, u8 *buf);
void send_ipack(ipack *p);
-void send_ipack_rest(ipack *p);
+void dvb_filter_ipack_flush(ipack *p);
int get_ainfo(uint8_t *mbuf, int count, AudioInfo *ai, int pr);
int get_ac3info(uint8_t *mbuf, int count, AudioInfo *ai, int pr);
int get_vinfo(uint8_t *mbuf, int count, VideoInfo *vi, int pr);
diff --git a/linux/drivers/media/dvb/dvb-core/dvb_ksyms.c b/linux/drivers/media/dvb/dvb-core/dvb_ksyms.c
index 619ec95b6..edbda9adb 100644
--- a/linux/drivers/media/dvb/dvb-core/dvb_ksyms.c
+++ b/linux/drivers/media/dvb/dvb-core/dvb_ksyms.c
@@ -9,11 +9,11 @@
#include "dvb_net.h"
-EXPORT_SYMBOL(DmxDevInit);
-EXPORT_SYMBOL(DmxDevRelease);
-EXPORT_SYMBOL(DvbDmxInit);
-EXPORT_SYMBOL(DvbDmxRelease);
-EXPORT_SYMBOL(DvbDmxSWFilterPackets);
+EXPORT_SYMBOL(dvb_dmxdev_init);
+EXPORT_SYMBOL(dvb_dmxdev_release);
+EXPORT_SYMBOL(dvb_dmx_init);
+EXPORT_SYMBOL(dvb_dmx_release);
+EXPORT_SYMBOL(dvb_dmx_swfilter_packets);
EXPORT_SYMBOL(dvb_register_frontend);
EXPORT_SYMBOL(dvb_unregister_frontend);
@@ -39,11 +39,11 @@ EXPORT_SYMBOL(dvb_generic_open);
EXPORT_SYMBOL(dvb_generic_release);
EXPORT_SYMBOL(generic_usercopy);
-EXPORT_SYMBOL(init_ipack);
-EXPORT_SYMBOL(reset_ipack);
-EXPORT_SYMBOL(free_ipack);
-EXPORT_SYMBOL(send_ipack_rest);
-EXPORT_SYMBOL(instant_repack);
-EXPORT_SYMBOL(pes2ts_init);
-EXPORT_SYMBOL(pes2ts);
+EXPORT_SYMBOL(dvb_filter_ipack_init);
+EXPORT_SYMBOL(dvb_filter_ipack_reset);
+EXPORT_SYMBOL(dvb_filter_ipack_free);
+EXPORT_SYMBOL(dvb_filter_ipack_flush);
+EXPORT_SYMBOL(dvb_filter_dvb_filter_instant_repack);
+EXPORT_SYMBOL(dvb_filter_dvb_filter_pes2ts_init);
+EXPORT_SYMBOL(dvb_filter_dvb_filter_pes2ts);