From patchwork Wed May 16 08:41:20 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Katsuhiro Suzuki X-Patchwork-Id: 135986 Delivered-To: patch@linaro.org Received: by 2002:a2e:9706:0:0:0:0:0 with SMTP id r6-v6csp617904lji; Wed, 16 May 2018 01:41:29 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoMh4egXOuXAfa6MDSYsM8wP4gfMapxEYoO3IElyrRsdfBhmQTd5sw5Wri2IBeaLwsQC9A9 X-Received: by 2002:a62:9c0d:: with SMTP id f13-v6mr18722740pfe.15.1526460089827; Wed, 16 May 2018 01:41:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526460089; cv=none; d=google.com; s=arc-20160816; b=Jpj2WEGciJsO7eUKQ0RpUXT1OBBF27hktNYiyb3KxPCn72V51gxMJGGZG5veCTbwQF HPMqLKBdyQP9NexJaJDJzdseDKv2IZlLPm96paDf1sM0hTSogTSQpcSV4vhVWYqmWfUC XMgyAVNQCn064Djp98AUoBzBRxyvy2+YxfcLCOPj5XCx6dCRzIMRrvl5aCZhD0rOqrIs 1/lc/HwR9L9QUX1uJ6pWwOX9zQClTpAQoG80YoWI++wPzjCl/cAOlu1cEbn/30kekRy5 HYoczCFr31GM8b0hpGLMBFLEM0uMupKJ0BevhmUINpKAQ+LEuLlMFTxoMlFPZ9AH0RYC t3XQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=M9AT2piHe+YFuGteHSfyShG1NLzJRyliNEm27x7qpmY=; b=R0/ExvrLWF0PvZu+lvaaXGsSNj0S+cHmCS77DSfaNTA16TnMc93EAqvXXkQ6tNUM0f YKAzYVFlpfUHYjZkfrNFyZaJYzMBa68BBeugIVvf9r0y7V5aQhDXGFwxwbBFi0r5VWVv bNNrMHOxL6N1H/owkYU+5iLLB0cwdjIpRtTwCy/sepVPqnjBYh30IBzgPVXn/inH+8/G YLk3rTlpHGMzczLWow3AH3GkHKl8QArG4rY8Bjj9eFzYzzAjAnWZcVnWDxskcDRFrXlb g+n/+P6aPU7xh8IfoofefRKQswcZAMF0zEEWWGpJ0ju2dHggWzV7yBr88ENssy9YqxKH Qydw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j123-v6si2246718pfg.156.2018.05.16.01.41.29; Wed, 16 May 2018 01:41:29 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752767AbeEPIl0 (ORCPT + 29 others); Wed, 16 May 2018 04:41:26 -0400 Received: from mx.socionext.com ([202.248.49.38]:8665 "EHLO mx.socionext.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752428AbeEPIlW (ORCPT ); Wed, 16 May 2018 04:41:22 -0400 Received: from unknown (HELO iyokan-ex.css.socionext.com) ([172.31.9.54]) by mx.socionext.com with ESMTP; 16 May 2018 17:41:21 +0900 Received: from mail.mfilter.local (m-filter-1 [10.213.24.61]) by iyokan-ex.css.socionext.com (Postfix) with ESMTP id A893B6007A; Wed, 16 May 2018 17:41:21 +0900 (JST) Received: from 172.31.9.53 (172.31.9.53) by m-FILTER with ESMTP; Wed, 16 May 2018 17:41:21 +0900 Received: from yuzu.css.socionext.com (yuzu [172.31.8.45]) by iyokan.css.socionext.com (Postfix) with ESMTP id 49CD1402D8; Wed, 16 May 2018 17:41:21 +0900 (JST) Received: from aegis.e01.socionext.com (unknown [10.213.134.210]) by yuzu.css.socionext.com (Postfix) with ESMTP id 178D4120134; Wed, 16 May 2018 17:41:21 +0900 (JST) From: Katsuhiro Suzuki To: Abylay Ospan , Mauro Carvalho Chehab , linux-media@vger.kernel.org Cc: Masami Hiramatsu , Jassi Brar , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Katsuhiro Suzuki Subject: [PATCH] media: helene: fix xtal frequency setting at power on Date: Wed, 16 May 2018 17:41:20 +0900 Message-Id: <20180516084120.28674-1-suzuki.katsuhiro@socionext.com> X-Mailer: git-send-email 2.17.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch fixes crystal frequency setting when power on this device. Signed-off-by: Katsuhiro Suzuki --- drivers/media/dvb-frontends/helene.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) -- 2.17.0 diff --git a/drivers/media/dvb-frontends/helene.c b/drivers/media/dvb-frontends/helene.c index 0a4f312c4368..8fcf7a00782a 100644 --- a/drivers/media/dvb-frontends/helene.c +++ b/drivers/media/dvb-frontends/helene.c @@ -924,7 +924,10 @@ static int helene_x_pon(struct helene_priv *priv) helene_write_regs(priv, 0x99, cdata, sizeof(cdata)); /* 0x81 - 0x94 */ - data[0] = 0x18; /* xtal 24 MHz */ + if (priv->xtal == SONY_HELENE_XTAL_16000) + data[0] = 0x10; /* xtal 16 MHz */ + else + data[0] = 0x18; /* xtal 24 MHz */ data[1] = (uint8_t)(0x80 | (0x04 & 0x1F)); /* 4 x 25 = 100uA */ data[2] = (uint8_t)(0x80 | (0x26 & 0x7F)); /* 38 x 0.25 = 9.5pF */ data[3] = 0x80; /* REFOUT signal output 500mVpp */