Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp2143897pxb; Mon, 12 Apr 2021 15:57:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwO/jDWgCeP00iUUw2hGSRwhe4mkn+poqYRV/QptFfBeeuLe/voxTA9gs1vH3gUzkODcPp9 X-Received: by 2002:a17:90a:94ca:: with SMTP id j10mr1608024pjw.126.1618268241660; Mon, 12 Apr 2021 15:57:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618268241; cv=none; d=google.com; s=arc-20160816; b=J2YzYmLERCq3Yrdh8i9Rb83sQecDuJHcNxTHJX4znzNPSW9K+ATXxgrMX5sOWaAk55 ibzf2O+F8UTIdOhzAulaS7r6A9Bds8d8Yct+nCyp78E/hYU2/FjuWLmmhUwUgUXxFgbI aqZLOjJXEXVQWyBASBVzp3SsCHNYnLW+qnFbNHg3Py9EzBVx0p/Q7hjHSSBo/30b5skO Y7diZfXbhhR/KlgNBNSrVLzg5sIDRGsbYyyrBr1B1fs1ZsvpA1NyJXrZI4VH1IY3eWwD WihH2O+exUdD+oy2f4yhCc8qoanlOxOyiUJ6bfShKktZo5q+G3YvPXLVEEznd+P8R8yd mwjg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=w23t34vzt2rPwzlmb6G2g3lSvpcDq+2I4xdkoZa8vX0=; b=A5t9+pMLyWS4x0BA0rrEMBrRzHMlxjn+A12q1vtFRT+zQASjd6kYCODq4gr5eExCQ3 LzAcroll5Z1EQZN4Ks2ylaPUYv22+j1nyReWsr2ygqf/eaS2SsI/o9hsaiHSDmi0YVhd noJpw4UgKj1Sdj0Teq9IcUinj6hKD1/WihPlxx61MmxhP3A7MYunMsMZF5q7b50hrtV9 ywhdhS/QgPM2hN7jOKb8nGqVVOcrn2le39Jg0q816zTAfn6vtxvuBJv39rOKegCZnUDN s7Uh2XeRCvnNm5g7lyWU3rjwxfF2qJLAZMr8p4W6BZst7TFKkdlK5j1JIObpIHM+7NS4 rP2w== 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 x14si14795257plr.12.2021.04.12.15.57.08; Mon, 12 Apr 2021 15:57:21 -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 S239039AbhDLJsJ (ORCPT + 99 others); Mon, 12 Apr 2021 05:48:09 -0400 Received: from relay12.mail.gandi.net ([217.70.178.232]:60669 "EHLO relay12.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238497AbhDLJeq (ORCPT ); Mon, 12 Apr 2021 05:34:46 -0400 Received: from uno.lan (93-34-118-233.ip49.fastwebnet.it [93.34.118.233]) (Authenticated sender: jacopo@jmondi.org) by relay12.mail.gandi.net (Postfix) with ESMTPSA id 1E1A320000F; Mon, 12 Apr 2021 09:34:25 +0000 (UTC) From: Jacopo Mondi To: kieran.bingham+renesas@ideasonboard.com, laurent.pinchart+renesas@ideasonboard.com, niklas.soderlund+renesas@ragnatech.se, geert@linux-m68k.org Cc: Jacopo Mondi , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-kernel@vger.kernel.org, Laurent Pinchart Subject: [PATCH v4 04/17] media: i2c: max9286: Define high channel amplitude Date: Mon, 12 Apr 2021 11:34:38 +0200 Message-Id: <20210412093451.14198-5-jacopo+renesas@jmondi.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210412093451.14198-1-jacopo+renesas@jmondi.org> References: <20210412093451.14198-1-jacopo+renesas@jmondi.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Provide a macro to define the reverse channel amplitude to be used to compensate the remote serializer noise immunity. While at it, update a comment. Reviewed-by: Kieran Bingham Reviewed-by: Laurent Pinchart Signed-off-by: Jacopo Mondi --- drivers/media/i2c/max9286.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/media/i2c/max9286.c b/drivers/media/i2c/max9286.c index ed1cdefe7c30..9124d5fa6ea3 100644 --- a/drivers/media/i2c/max9286.c +++ b/drivers/media/i2c/max9286.c @@ -113,6 +113,7 @@ #define MAX9286_REV_TRF(n) ((n) << 4) #define MAX9286_REV_AMP(n) ((((n) - 30) / 10) << 1) /* in mV */ #define MAX9286_REV_AMP_X BIT(0) +#define MAX9286_REV_AMP_HIGH 170 /* Register 0x3f */ #define MAX9286_EN_REV_CFG BIT(6) #define MAX9286_REV_FLEN(n) ((n) - 20) @@ -567,12 +568,12 @@ static int max9286_notify_bound(struct v4l2_async_notifier *notifier, * channels: * * - Increase the reverse channel amplitude to compensate for the - * remote ends high threshold, if not done already + * remote ends high threshold * - Verify all configuration links are properly detected * - Disable auto-ack as communication on the control channel are now * stable. */ - max9286_reverse_channel_setup(priv, 170); + max9286_reverse_channel_setup(priv, MAX9286_REV_AMP_HIGH); max9286_check_config_link(priv, priv->source_mask); /* -- 2.31.1