--- margi2/decoder.c 2001/02/01 14:47:33 1.5 +++ margi2/decoder.c 2001/03/06 23:39:26 1.6 @@ -54,10 +54,12 @@ int DecoderQueueNavi(struct cvdv_cards * return 0; } -u32 ParseSCR(const u8 *scrdata) +u32 ParseSCR(const u8 *data) { u32 SCR_base=0; - + u8 scrdata[9]; + copy_from_user (scrdata, data, 9); + if ((!scrdata[0]) && (!scrdata[1]) && (scrdata[2]==1) && (scrdata[3]==0xBA) && ((scrdata[4]&0xC0)==0x40)) { SCR_base=((scrdata[4]>>3)&0x07); @@ -96,7 +98,7 @@ void DecoderPause(struct cvdv_cards *car { DecoderMaskByte(card, 0x007, 0xD2, 0xD2); // Set 0x010, halt SCR counter - AudioSetPlayMode(card, AUDIO_PAUSE); + AudioSetPlayMode(card, MAUDIO_PAUSE); DecoderStopDecode(card); card->paused = 1; } @@ -104,7 +106,7 @@ void DecoderPause(struct cvdv_cards *car void DecoderUnPause(struct cvdv_cards *card) { DecoderStartDecode(card); - AudioSetPlayMode(card, AUDIO_PLAY); + AudioSetPlayMode(card, MAUDIO_PLAY); DecoderMaskByte(card, 0x007, 0xD2, 0xC2); // Del 0x010, SCR counter run card->paused = 0; @@ -112,6 +114,12 @@ void DecoderUnPause(struct cvdv_cards *c void CloseCard(struct cvdv_cards *card) { + int i; +#ifdef NOINT + spin_lock(&card->timelock); + i = del_timer(&card->timer); + spin_unlock(&card->timelock); +#endif MargiFlush(card); printk(KERN_DEBUG LOGNAME ": Closing card\n"); card->DecoderOpen = 1; @@ -123,6 +131,7 @@ void CloseCard(struct cvdv_cards *card) AudioClose(card); OSDClose(card); L64021Init(card); + OSDOpen(card, 50, 50, 150, 150, 2, 1); OSDTest(card); } @@ -1070,7 +1079,7 @@ printk(KERN_DEBUG LOGNAME ": Delayed Vid else ap = 0; if (ap > 40) { printk(KERN_DEBUG LOGNAME ": Delayed Audio Decoder start\n"); - AudioSetPlayMode(card, AUDIO_PLAY); + AudioSetPlayMode(card, MAUDIO_PLAY); if (!AudioStart(card)) { card->startingA = 0; }