Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp573316ybg; Tue, 9 Jun 2020 07:39:49 -0700 (PDT) X-Google-Smtp-Source: ABdhPJydywi451LmebOgvR1388RCcIUbOfxmtIg3+R0MhD9+/1y/3llyQKNa5ujfNygc4poTUJqk X-Received: by 2002:a50:b2a1:: with SMTP id p30mr27938355edd.199.1591713589626; Tue, 09 Jun 2020 07:39:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591713589; cv=none; d=google.com; s=arc-20160816; b=o0WJ0Ej5tT3m0PVdPn6sHLpayThSEo7f0Odly1G7PLHeuKqBmuFsRUnqrBNzuu2MIk jlsHh/XwDyNPwrQi/G8/EQkETHnpIR57+zxbGtVbTQJcKlTr9EP6Zg7G654j00f1aFaU u9usYulwxtmAVi+D+xWGOJHQrwTFejiukGH1C4D6vNGSrqaZo0UmRUyv/HCb8aGTLStv gUNtkwHS0DlCUKDKYx1E1y7i/F8T/iy2xJrjrduKBbjXmVjrrHXvt/CC9Kz1DUfAAwjL TAuZe93KHajMRkbbWWco1dPGbus+jisWIUiq6Jx3hh0t9IKmLeeShr1Jrqq/vLeEMokh fAWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:cc:references:to:from:subject; bh=dhrAe6rwG9MMfi/oYrG+mzH5HsEYCbq/fhNDWzbRIo0=; b=OqG/PSIOdKAIdKh9L3gejCyV3B86Ev79cf0lTtcWhEfUQHODZcsM1zP9RTVIMHbD0l hvCvvRtPmD1tgMq3QPa86xr9VOXZ+7f5iYLShJPqk+Flz7sQJgvnR+Oy8ZA8sCkTCSgo dqgMg+vZNlt0ERRb806sDRR3QCe4TEP1HIIW59jbKIMPBcn6bAcZXrCDVa/M/vr9z4oX iE3DMtX+ekkHVNIorzXK24tRDg2GCczRxRCvD8Z/JBdlVFAFK+fY+MW8efqw5NlKbnp7 PzTRxUQ865wVaNZJEU3wdzpdirnOe0ydkdKG/pr6jpntZQ7FkJb2FXAHamurLixz9hQo GDSQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f17si11409619edr.515.2020.06.09.07.39.26; Tue, 09 Jun 2020 07:39:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729990AbgFIOg7 (ORCPT + 99 others); Tue, 9 Jun 2020 10:36:59 -0400 Received: from ns.iliad.fr ([212.27.33.1]:43864 "EHLO ns.iliad.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726395AbgFIOg7 (ORCPT ); Tue, 9 Jun 2020 10:36:59 -0400 X-Greylist: delayed 326 seconds by postgrey-1.27 at vger.kernel.org; Tue, 09 Jun 2020 10:36:58 EDT Received: from ns.iliad.fr (localhost [127.0.0.1]) by ns.iliad.fr (Postfix) with ESMTP id D3AA3201AA; Tue, 9 Jun 2020 16:31:29 +0200 (CEST) Received: from [192.168.108.51] (freebox.vlq16.iliad.fr [213.36.7.13]) by ns.iliad.fr (Postfix) with ESMTP id BBCDE200C3; Tue, 9 Jun 2020 16:31:29 +0200 (CEST) Subject: Re: Scanning for TV channels over DVB-T and DVB-T2 From: Marc Gonzalez To: linux-media , Sean Young , Mauro Carvalho Chehab , Jan Pieter van Woerkom , Brad Love , Antti Palosaari References: <11fbc112-c410-8c67-9bcb-9450924d12ef@free.fr> Cc: LKML Message-ID: <4904d37d-1cd4-b8f3-9c3c-82eb4569bca7@free.fr> Date: Tue, 9 Jun 2020 16:31:29 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0 MIME-Version: 1.0 In-Reply-To: <11fbc112-c410-8c67-9bcb-9450924d12ef@free.fr> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Virus-Scanned: ClamAV using ClamSMTP ; ns.iliad.fr ; Tue Jun 9 16:31:29 2020 +0200 (CEST) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 08/06/2020 17:30, Marc Gonzalez wrote: > Suppose we know that several channels are transmitted on a given frequency > by terrestrial antenna. However, we don't know if the signal is "encoded" > (not sure this is the right term) in DVB-T or DVB-T2 modulation. > > Do we have to scan the frequency /twice/ > first with DTV_DELIVERY_SYSTEM = SYS_DVBT > then with DTV_DELIVERY_SYSTEM = SYS_DVBT2 ? > > Or is there some optimization where both modulations are handled > in a single step? > > Or maybe it depends on the tuner driver? Digging a bit deeper... My system sports a Silicon Labs Si2168 DVB-T2/T/C demodulator The data sheet states: "For DVB-T2 and T2-Lite: DVB-T2 versus DVB-T automatic detection" "In DVB-T and DVB-T2 reception, parameters necessary for device synchronization are broadcast in the transmission parameters (respectively TPS and P1 symbol). When these transmission parameters are found and decoded, the demodulator is automatically and accordingly configured to achieve full synchronization." This HW is supported upstream by drivers/media/dvb-frontends/si2168.c https://elixir.bootlin.com/linux/latest/source/drivers/media/dvb-frontends/si2168.c I have a nagging feeling because si2168_set_frontend() appears to behave differently for SYS_DVBT and for SYS_DVBT2... https://elixir.bootlin.com/linux/latest/source/drivers/media/dvb-frontends/si2168.c#L250 https://elixir.bootlin.com/linux/latest/source/drivers/media/dvb-frontends/si2168.c#L297 https://elixir.bootlin.com/linux/latest/source/drivers/media/dvb-frontends/si2168.c#L345 Maybe setting SYS_DVBT2 would also work for DVB-T transmissions? (TODO: test that) Any insight would be greatly appreciated. Regards.