From patchwork Sun Feb 14 02:41:06 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Antti Palosaari X-Patchwork-Id: 8301141 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 578B9C02AA for ; Sun, 14 Feb 2016 02:41:33 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 33772203C1 for ; Sun, 14 Feb 2016 02:41:31 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 277AE202A1 for ; Sun, 14 Feb 2016 02:41:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751605AbcBNCl1 (ORCPT ); Sat, 13 Feb 2016 21:41:27 -0500 Received: from mail.kapsi.fi ([217.30.184.167]:35957 "EHLO mail.kapsi.fi" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751589AbcBNCl1 (ORCPT ); Sat, 13 Feb 2016 21:41:27 -0500 Received: from dyn3-82-128-190-33.psoas.suomi.net ([82.128.190.33] helo=localhost.localdomain.localdomain) by mail.kapsi.fi with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1aUmco-0001Qk-Cn; Sun, 14 Feb 2016 04:41:26 +0200 From: Antti Palosaari To: linux-media@vger.kernel.org Cc: Antti Palosaari Subject: [PATCH] mn88473: add DVB-T2 PLP support Date: Sun, 14 Feb 2016 04:41:06 +0200 Message-Id: <1455417666-17755-1-git-send-email-crope@iki.fi> X-Mailer: git-send-email 2.4.3 X-SA-Exim-Connect-IP: 82.128.190.33 X-SA-Exim-Mail-From: crope@iki.fi X-SA-Exim-Scanned: No (on mail.kapsi.fi); SAEximRunCond expanded to false Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Adds PLP ID filtering for DVB-T2. It is untested as I don't have any signal having PLP ID other than 0. There is only 2 extra registers, 0x32 and 0x36 on bank2, that are programmed for DVB-T2 but not for DVB-T and all the rest are programmed similarly - so it is likely PLP. Testing required!! --- drivers/media/dvb-frontends/mn88473.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/drivers/media/dvb-frontends/mn88473.c b/drivers/media/dvb-frontends/mn88473.c index 6c5d5921..0ab8faa 100644 --- a/drivers/media/dvb-frontends/mn88473.c +++ b/drivers/media/dvb-frontends/mn88473.c @@ -223,6 +223,13 @@ static int mn88473_set_frontend(struct dvb_frontend *fe) if (ret) goto err; + /* PLP */ + if (c->delivery_system == SYS_DVBT2) { + ret = regmap_write(dev->regmap[2], 0x36, c->stream_id); + if (ret) + goto err; + } + /* Reset FSM */ ret = regmap_write(dev->regmap[2], 0xf8, 0x9f); if (ret) @@ -429,7 +436,8 @@ static const struct dvb_frontend_ops mn88473_ops = { FE_CAN_GUARD_INTERVAL_AUTO | FE_CAN_HIERARCHY_AUTO | FE_CAN_MUTE_TS | - FE_CAN_2G_MODULATION + FE_CAN_2G_MODULATION | + FE_CAN_MULTISTREAM }, .get_tune_settings = mn88473_get_tune_settings,