From patchwork Mon Aug 14 09:48:37 2006 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Klaus Schmidinger X-Patchwork-Id: 12374 Received: from raven.cadsoft.de ([217.7.101.211]) by www.linuxtv.org with esmtp (Exim 4.50) id 1GCZ3o-0000VA-SN for vdr@linuxtv.org; Mon, 14 Aug 2006 11:48:40 +0200 Received: from [192.168.100.10] (hawk.cadsoft.de [192.168.100.10]) by raven.cadsoft.de (8.13.3/8.13.3) with ESMTP id k7E9mce9008707 for ; Mon, 14 Aug 2006 11:48:39 +0200 Message-ID: <44E046F5.2080000@cadsoft.de> Date: Mon, 14 Aug 2006 11:48:37 +0200 From: Klaus Schmidinger Organization: CadSoft Computer GmbH User-Agent: Thunderbird 1.5.0.4 (X11/20060516) MIME-Version: 1.0 To: vdr@linuxtv.org Subject: Re: [vdr] Blank screen when switching channels on same transponder with Dpid References: <000001c6bf13$91ac9b90$1400a8c0@enterprise> In-Reply-To: <000001c6bf13$91ac9b90$1400a8c0@enterprise> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0 (raven.cadsoft.de [192.168.1.1]); Mon, 14 Aug 2006 11:48:39 +0200 (CEST) X-BeenThere: vdr@linuxtv.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: VDR Mailing List List-Id: VDR Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 14 Aug 2006 09:48:41 -0000 Status: O X-Status: X-Keywords: X-UID: 10418 Tomas Berglund wrote: > Your workaround patch only prevent additional dpids to be set when dolby is disabled. I really would like to switch channels with > dolby enabled. The problem is that those additional pids are never removed....or set to false in SetPid(). > > Is there any other way to add additional pids without setting them with ciHandler->SetPid ? If AddPid() is used to set them, they > would be removed in cDevice::DelPid(). Please try the attached patch. At least with my CAM here I don't get any more sticky PIDs in the CAM now. Klaus --- dvbdevice.c 2006/06/11 09:03:55 1.159 +++ dvbdevice.c 2006/08/14 09:38:32 @@ -853,11 +853,6 @@ esyslog("ERROR: failed to set PIDs for channel %d on device %d", Channel->Number(), CardIndex() + 1); return false; } - //XXX quick workaround for additional live audio PIDs: - if (ciHandler) { - ciHandler->SetPid(Channel->Apid(1), true); - ciHandler->SetPid(Channel->Dpid(0), true); - } if (IsPrimaryDevice()) AddPid(Channel->Tpid(), ptTeletext); CHECK(ioctl(fd_audio, AUDIO_SET_MUTE, true)); // actually one would expect 'false' here, but according to Marco Schlüßler this works @@ -927,8 +922,14 @@ if (IS_AUDIO_TRACK(Type) || (IS_DOLBY_TRACK(Type) && SetAudioBypass(true))) { if (pidHandles[ptAudio].pid && pidHandles[ptAudio].pid != TrackId->id) { DetachAll(pidHandles[ptAudio].pid); + if (ciHandler) + ciHandler->SetPid(pidHandles[ptAudio].pid, false); pidHandles[ptAudio].pid = TrackId->id; SetPid(&pidHandles[ptAudio], ptAudio, true); + if (ciHandler) { + ciHandler->SetPid(pidHandles[ptAudio].pid, true); + ciHandler->StartDecrypting(); + } } } else if (IS_DOLBY_TRACK(Type)) {