Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp3335249yba; Mon, 6 May 2019 22:42:16 -0700 (PDT) X-Google-Smtp-Source: APXvYqwMWxV9Sf4q9gLc9hHL+WZhzq0Gkc7Af430ad22/ik9QOnTkJZ07p0S9cSG+H8hNY+K0lNw X-Received: by 2002:a17:902:8609:: with SMTP id f9mr36091553plo.32.1557207735988; Mon, 06 May 2019 22:42:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557207735; cv=none; d=google.com; s=arc-20160816; b=jH4OQzbQ29XzF+IHwW2rknUVaHE5uPaaxZSyVZbSt+ONF324maUvoWF9rW4dLd+UBD Q8tNY6smBBqo8tevdOkBULcyeQtWLJf4tR0jYOatRI8ct+hnT2HzhABlYZkE2aZyPwi9 kyoQovXYpAarvdxDmaxfsjLY4lVmDj2ntYvu77mueR9qjqJdFG5qrnDGcaAFZR5/7UEb iaNbE/WtR7E8aMc6KbRVZS++34ntELagCDVtv48Vlbb5Qflg4W/9k9Ma8WlKkwnT0pXM tuctQhaotI/D2Q6+0d64YkgaSFUpNCo1y4P5h/Smw9CYFRXxkfBFhNZ6GkE64NcyNqno yr8A== 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:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=rrLALGOs0g19TbK88OutZj+JdR1BTaoG/lF3jQ31rrg=; b=B9lYBtPMU3lDPi1t7w7nBPU7J1JJw+dnELRImh1ZdCkpTHgic5pq45/6SR3RTlxEdU RWU24kKsdvD7ZdpyWf/yrXYiaLvF54749OO91uLfJDcqi2gzXUg8BOXk29wf6xGbAhCk wP6Y6R9V+YFmjMry/6E1fqzxHHJjfQRxXkAOsb1AgZMPMEvyCc9h2tSxkuJNdxvSX7uv pOzZUPLQSwmc9/VSPuZOYZ6cvHMkNC1vWiZ66v4oSiX440FEt984Hq1RbsxulI37Pu1S Arx8M+C6apBJAkhY+KkAKYbmj9iZYX7lG7FQD/ipI7MA6q4Dt2JTQt3XKeVXRGzVQlzk +NSw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=MUMpvl0O; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 187si14584095pfe.116.2019.05.06.22.42.00; Mon, 06 May 2019 22:42:15 -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; dkim=pass header.i=@kernel.org header.s=default header.b=MUMpvl0O; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728664AbfEGFkF (ORCPT + 99 others); Tue, 7 May 2019 01:40:05 -0400 Received: from mail.kernel.org ([198.145.29.99]:59436 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728115AbfEGFj4 (ORCPT ); Tue, 7 May 2019 01:39:56 -0400 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 6DC4C21655; Tue, 7 May 2019 05:39:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1557207596; bh=cRV3ZI6rFtbhhrGibaa5WePGHbpNxqpBN/bzCT3qLso=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=MUMpvl0OXr8TR/ktGPVxlc2esU24OxAa0cGjRv9LTHjuhyyDsjA6S9fKmOX7/kTlo SzKMoVWVnl0RTrgarKwMs0yZ63PEfJu/86rNE4CQQL6mSmuEmz7EEr8cqZvPLLNTx7 hq7UFI2C4jFP/aoMGHho+NbTLqPxi4CSE0oibCKg= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Hans Verkuil , Mauro Carvalho Chehab , Sasha Levin , linux-media@vger.kernel.org Subject: [PATCH AUTOSEL 4.14 45/95] media: adv7604: when the EDID is cleared, unconfigure CEC as well Date: Tue, 7 May 2019 01:37:34 -0400 Message-Id: <20190507053826.31622-45-sashal@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190507053826.31622-1-sashal@kernel.org> References: <20190507053826.31622-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Hans Verkuil [ Upstream commit e7da89926f6dc6cf855f5ffdf79ef99a1b115ca7 ] When there is no EDID the CEC adapter should be unconfigured as well. So call cec_phys_addr_invalidate() when this happens. Signed-off-by: Hans Verkuil Cc: # for v4.18 and up Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Sasha Levin --- drivers/media/i2c/adv7604.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/media/i2c/adv7604.c b/drivers/media/i2c/adv7604.c index d2108aad3c65..26c3ec573a56 100644 --- a/drivers/media/i2c/adv7604.c +++ b/drivers/media/i2c/adv7604.c @@ -2295,8 +2295,10 @@ static int adv76xx_set_edid(struct v4l2_subdev *sd, struct v4l2_edid *edid) state->aspect_ratio.numerator = 16; state->aspect_ratio.denominator = 9; - if (!state->edid.present) + if (!state->edid.present) { state->edid.blocks = 0; + cec_phys_addr_invalidate(state->cec_adap); + } v4l2_dbg(2, debug, sd, "%s: clear EDID pad %d, edid.present = 0x%x\n", __func__, edid->pad, state->edid.present); -- 2.20.1