Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp534621pxx; Wed, 28 Oct 2020 10:30:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzL6j2pl/wotBWiUDAebcCwlFHyZrQx7QVLOO7LnDJCyOl4niobfny4nEXIUhdhP/b1kdjJ X-Received: by 2002:a17:906:814:: with SMTP id e20mr111813ejd.367.1603906206062; Wed, 28 Oct 2020 10:30:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603906206; cv=none; d=google.com; s=arc-20160816; b=PN9pTGxDFC0HZ15hagJJnfK9eoXeVwghDOE9CK+E3rzhTlZLzi0V09ucbF7dVDpWGm eRoWQI3JD19LVAC+aU5xbTZXRAJK130FcMAccZQIrQ7y9UUVxjQtnZxtXSfmKWVsFJDj wLWjcwocZbTgbBaGIgXP0fQ4P73tKjyNBii54aTP3VkKSjeRjeNL8Gh+7JUshS119KUP 6jjmuG/wmt91dlVfV7SrO8L5iY6Urtsxj63Ssy79A8llRzW9ymMhBaY0wE35E48dM1lq xEzkB8Vsclqdnhrj9DbF+z4Ee/wHe91XFByQtzUXnIcYNWgPhzLXRHYhOU3Oxa1s2sYL vGXA== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=azJoucp27obGyHsdW/9WMoR6UcufpVDJvpVdJHlkAQU=; b=agHEergf2AQI4HKQG5U0kIc9ZNcK18t0yihtRcl37ewz3bjwDV0tk4c/JvsJunlDII 1PZMTmolxmK831EFcy5O7ZYvyaJYXc2KVHvxnKYYbabAL1zzSW0JUeQyjE+IXaY1lQqI dssYMgSNAs5giMko4YyFQRytUqbs0OGeCfaoLaKZf/nvm6IgAgtZweBAbNqZj5px2Wss Wb+v/Zs3NrBqYVltwsYGcj4hLPGFwelWmrcFc6uRbhn7SK3n9wEjj51zU/cdmUSJrEYU NsuYZ4YnHfp+J8UbglJSoGnnmWgJMp0K4REY/w2bMVpV1WyXJof1pmRKZBrbONteqxQ6 JU3Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=kzgvCUj6; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v14si3762200eja.230.2020.10.28.10.29.43; Wed, 28 Oct 2020 10:30:06 -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; dkim=pass header.i=@kernel.org header.s=default header.b=kzgvCUj6; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1821354AbgJ0Rmy (ORCPT + 99 others); Tue, 27 Oct 2020 13:42:54 -0400 Received: from mail.kernel.org ([198.145.29.99]:59196 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1760078AbgJ0OcT (ORCPT ); Tue, 27 Oct 2020 10:32:19 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 83952206DC; Tue, 27 Oct 2020 14:32:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603809139; bh=6LFXPfRjaXr/B6QXua9ug/OO8Xomm+86NfxiDEDLi6w=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=kzgvCUj6KTsltAdgOQ3cSpF6Kue8RGnOl5vo98OYVauhyGVL5Rlt6/f5P8QfhLPMY XZvy5sRAq1pUYukkY5B9WUijzPCwP4bTD+o63tqTpbOL1aN/sdqd3juOdKCuer1DDy ED8mJM9f2A0QhJB/C4CGC7UuLwT6a/4X1KayFXXI= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Tom Rix , Hans Verkuil , Mauro Carvalho Chehab , Sasha Levin Subject: [PATCH 5.4 090/408] media: tc358743: cleanup tc358743_cec_isr Date: Tue, 27 Oct 2020 14:50:28 +0100 Message-Id: <20201027135459.257091560@linuxfoundation.org> X-Mailer: git-send-email 2.29.1 In-Reply-To: <20201027135455.027547757@linuxfoundation.org> References: <20201027135455.027547757@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Tom Rix [ Upstream commit 877cb8a444dad2304e891294afb0915fe3c278d6 ] tc358743_cec_isr is misnammed, it is not the main isr. So rename it to be consistent with its siblings, tc358743_cec_handler. It also does not check if its input parameter 'handled' is is non NULL like its siblings, so add a check. Fixes: a0ec8d1dc42e ("media: tc358743: add CEC support") Signed-off-by: Tom Rix Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Sasha Levin --- drivers/media/i2c/tc358743.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/drivers/media/i2c/tc358743.c b/drivers/media/i2c/tc358743.c index 211caade9f998..cff99cf61ed4d 100644 --- a/drivers/media/i2c/tc358743.c +++ b/drivers/media/i2c/tc358743.c @@ -919,8 +919,8 @@ static const struct cec_adap_ops tc358743_cec_adap_ops = { .adap_monitor_all_enable = tc358743_cec_adap_monitor_all_enable, }; -static void tc358743_cec_isr(struct v4l2_subdev *sd, u16 intstatus, - bool *handled) +static void tc358743_cec_handler(struct v4l2_subdev *sd, u16 intstatus, + bool *handled) { struct tc358743_state *state = to_state(sd); unsigned int cec_rxint, cec_txint; @@ -953,7 +953,8 @@ static void tc358743_cec_isr(struct v4l2_subdev *sd, u16 intstatus, cec_transmit_attempt_done(state->cec_adap, CEC_TX_STATUS_ERROR); } - *handled = true; + if (handled) + *handled = true; } if ((intstatus & MASK_CEC_RINT) && (cec_rxint & MASK_CECRIEND)) { @@ -968,7 +969,8 @@ static void tc358743_cec_isr(struct v4l2_subdev *sd, u16 intstatus, msg.msg[i] = v & 0xff; } cec_received_msg(state->cec_adap, &msg); - *handled = true; + if (handled) + *handled = true; } i2c_wr16(sd, INTSTATUS, intstatus & (MASK_CEC_RINT | MASK_CEC_TINT)); @@ -1432,7 +1434,7 @@ static int tc358743_isr(struct v4l2_subdev *sd, u32 status, bool *handled) #ifdef CONFIG_VIDEO_TC358743_CEC if (intstatus & (MASK_CEC_RINT | MASK_CEC_TINT)) { - tc358743_cec_isr(sd, intstatus, handled); + tc358743_cec_handler(sd, intstatus, handled); i2c_wr16(sd, INTSTATUS, intstatus & (MASK_CEC_RINT | MASK_CEC_TINT)); intstatus &= ~(MASK_CEC_RINT | MASK_CEC_TINT); -- 2.25.1