Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp1216783pxx; Tue, 27 Oct 2020 10:57:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxcpM+zHRalHwslRsfT7NUVyWnRJpVaeM38hipShJWgLohA9r1DBdsEizjAXeqzpFTYG6Kl X-Received: by 2002:a17:906:f90a:: with SMTP id lc10mr3705034ejb.272.1603821472332; Tue, 27 Oct 2020 10:57:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603821472; cv=none; d=google.com; s=arc-20160816; b=e76dWrI6WlDGa6iov+GLhMuMX4LKM/bRC6r6SONGAJRLtb7N4JIxEuhwXnXKUvECIe 12s4MFqzRimf56Ejru2wB80FIyc1srpIJLP5HfYFnVheDuD9NgmfBF4/MkX8PwhS0xDZ mIKJnkjoH7EQihPTvR7M/84ft/WkRLjXSuAvRvloEsfzg+rdpQlx5YsYbleVpsz1lXmZ fELp2tGNueXqKWYyHXgkzw11kHyIoScX/QMFX5OaT3wb336q5Z+oEpDjjP0fJxuHp3yR sZxj+jBsWxjAHiNq+8zcBB3/IOsxaXQnuICrHBLLYZnsHjr8c3gH1seoH6Gc/yuoYRgP 70XA== 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=MnKaFyunp+LXveC810Y91wp1P/ZMq8McclGVK4BFa/PvRyRlMU4fx34jPvOyFcuQ50 8ET7Qd7HrwguEPO5uZelv/ouGDCtNzP+/8fBt9pk0igUvcn7KCOfsGamm8qvbnCewbEo 6kATpyE9rFXEkhSUOM7fzwyuRudynJHse8+TqZg5mUEOTlKXymzZTecykgU1Nr3NJnw8 X9fPExkKC9bzGcnaJnl0B21Qw9o1c2uwpVK7pjK4zJXYL5cKrjiyKzownAbPSeQC2acL FKQE402DtpHma2xWxrsJyhyvlyuPiYKZi6ihJBorfCRndzEZtZv0HejwOJhuxA1Lvqr7 kPQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=k5YDEYX7; 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 h10si1444825edr.423.2020.10.27.10.57.29; Tue, 27 Oct 2020 10:57:52 -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=k5YDEYX7; 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 S1819044AbgJ0R0z (ORCPT + 99 others); Tue, 27 Oct 2020 13:26:55 -0400 Received: from mail.kernel.org ([198.145.29.99]:54292 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751928AbgJ0Oxy (ORCPT ); Tue, 27 Oct 2020 10:53:54 -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 56A5922264; Tue, 27 Oct 2020 14:53:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603810433; bh=6LFXPfRjaXr/B6QXua9ug/OO8Xomm+86NfxiDEDLi6w=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=k5YDEYX7RIKWPNjtmCnO0ac5Xc7/xjG3Yff6323bXd9qHbL4YW0ARM6GY1lopYpcG JDv5NLBoPgoMq+sw0J8IQXcA6CUXsUcMesdAfvO4MXe2DtyS0oRKhU9pihb8JKYTxJ 6YSKu0ae0qRij0BdVyfsvQSck74eBa1ePm65CceM= 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.8 137/633] media: tc358743: cleanup tc358743_cec_isr Date: Tue, 27 Oct 2020 14:48:00 +0100 Message-Id: <20201027135529.119946069@linuxfoundation.org> X-Mailer: git-send-email 2.29.1 In-Reply-To: <20201027135522.655719020@linuxfoundation.org> References: <20201027135522.655719020@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