From patchwork Sun Apr 9 19:38:15 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Scheller X-Patchwork-Id: 9671725 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 9DBED600CB for ; Sun, 9 Apr 2017 19:38:46 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8A5C526E8A for ; Sun, 9 Apr 2017 19:38:46 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7F53F27F10; Sun, 9 Apr 2017 19:38:46 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2482326E8A for ; Sun, 9 Apr 2017 19:38:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752587AbdDITio (ORCPT ); Sun, 9 Apr 2017 15:38:44 -0400 Received: from mail-wr0-f194.google.com ([209.85.128.194]:34886 "EHLO mail-wr0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752322AbdDITih (ORCPT ); Sun, 9 Apr 2017 15:38:37 -0400 Received: by mail-wr0-f194.google.com with SMTP id t20so26640429wra.2 for ; Sun, 09 Apr 2017 12:38:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=AxRwjGu88cjkB+vG0ZECeJR4TeniV7+e8al2bKZOB7I=; b=Ia879eCkO/KmoPikRlSnzbKol4eOA3b6L+Kt9ieyiczC2CfBFaN1e/mna2j/3X/DEi Dmmcm8ic0vpk30SAWT8mOAElSAWVM3ntQFSyFy5t3DAs/JPhMz5Fi8Zak17TzkYs+HIZ fQQkKbEjZKugh/Atxq3bco4mipl6AdMdOJQZU/t7lJGhTcvTdgjXtO+AWWY3nBCSGTyY hzxI4iS8TcX2ginA/J6uQ78iN7guw4gWZ+G4B36FXTF9LzacflutzYwQ3G+TyXW+cHyg EkC8IqlaTpSRmgnZ2/WfV4jt9c0AKWD5WDiMSoVdVJAdpq3kT+0xNgM1wM5P0FWhI/R8 9w7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=AxRwjGu88cjkB+vG0ZECeJR4TeniV7+e8al2bKZOB7I=; b=qtJMITvQ0BAbMA8OZSZF6Jzh1Xg2DOtRpLDkQHLO5Zc64EmLVqCx/lgY65nkJXjCeX dYUUOV76IqetUCa8rNy3ur48IU22cxYPVC4A3ljc+zqwFrn4qBeVN4BqkqGC0JFM6/cP Mz8ybidnyBzeD8S0XvSKXtGO0U2Oa7ZXmOOg4xFsd05lsR+rWujbifTS8AcS1J6EW7fd ZqdEaz5GJVolGdh44tJDPYnmrGlV6DpDd/lQjvKGq+EgaiLSycbbrf/ZKZMkfAAzfPl6 glRpr0Pb10PN8b4Th1U05zI+BWKvgCczpAYWZtouc32V4IuS8jwMARPhw/Ru3v0sTb+/ bI9w== X-Gm-Message-State: AN3rC/7awHY8S+Ixq7UFtKjhuEubQfGx0kdd766Bb8riEyH80jdSj/XzwcGKfe5b31+QiA== X-Received: by 10.223.173.167 with SMTP id w36mr13337107wrc.68.1491766716542; Sun, 09 Apr 2017 12:38:36 -0700 (PDT) Received: from dvbdev.wuest.de (ip-37-24-178-151.hsi14.unitymediagroup.de. [37.24.178.151]) by smtp.gmail.com with ESMTPSA id f135sm7441407wmd.7.2017.04.09.12.38.35 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 09 Apr 2017 12:38:36 -0700 (PDT) From: Daniel Scheller To: aospan@netup.ru, serjk@netup.ru, mchehab@kernel.org, linux-media@vger.kernel.org Cc: rjkm@metzlerbros.de Subject: [PATCH 06/19] [media] dvb-frontends/cxd2841er: add variable for configuration flags Date: Sun, 9 Apr 2017 21:38:15 +0200 Message-Id: <20170409193828.18458-7-d.scheller.oss@gmail.com> X-Mailer: git-send-email 2.10.2 In-Reply-To: <20170409193828.18458-1-d.scheller.oss@gmail.com> References: <20170409193828.18458-1-d.scheller.oss@gmail.com> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Daniel Scheller Throughout the patch series some configuration flags will be added to the demod driver. This patch prepares this by adding the flags var to struct cxd2841er_config, which will serve as a bitmask to toggle various options and behaviour in the driver. Signed-off-by: Daniel Scheller Acked-by: Abylay Ospan --- drivers/media/dvb-frontends/cxd2841er.c | 2 ++ drivers/media/dvb-frontends/cxd2841er.h | 1 + 2 files changed, 3 insertions(+) diff --git a/drivers/media/dvb-frontends/cxd2841er.c b/drivers/media/dvb-frontends/cxd2841er.c index 6648bd1..f49a09b 100644 --- a/drivers/media/dvb-frontends/cxd2841er.c +++ b/drivers/media/dvb-frontends/cxd2841er.c @@ -65,6 +65,7 @@ struct cxd2841er_priv { u8 system; enum cxd2841er_xtal xtal; enum fe_caps caps; + u32 flags; }; static const struct cxd2841er_cnr_data s_cn_data[] = { @@ -3736,6 +3737,7 @@ static struct dvb_frontend *cxd2841er_attach(struct cxd2841er_config *cfg, priv->i2c_addr_slvx = (cfg->i2c_addr + 4) >> 1; priv->i2c_addr_slvt = (cfg->i2c_addr) >> 1; priv->xtal = cfg->xtal; + priv->flags = cfg->flags; priv->frontend.demodulator_priv = priv; dev_info(&priv->i2c->dev, "%s(): I2C adapter %p SLVX addr %x SLVT addr %x\n", diff --git a/drivers/media/dvb-frontends/cxd2841er.h b/drivers/media/dvb-frontends/cxd2841er.h index 7f1acfb..2fb8b38 100644 --- a/drivers/media/dvb-frontends/cxd2841er.h +++ b/drivers/media/dvb-frontends/cxd2841er.h @@ -33,6 +33,7 @@ enum cxd2841er_xtal { struct cxd2841er_config { u8 i2c_addr; enum cxd2841er_xtal xtal; + u32 flags; }; #if IS_REACHABLE(CONFIG_DVB_CXD2841ER)