From patchwork Thu Apr 21 15:09:46 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: kernel test robot X-Patchwork-Id: 12821809 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id E25CEC43217 for ; Thu, 21 Apr 2022 15:10:50 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 516346B0072; Thu, 21 Apr 2022 11:10:50 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 4C5616B0073; Thu, 21 Apr 2022 11:10:50 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 38D976B0074; Thu, 21 Apr 2022 11:10:50 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay.hostedemail.com [64.99.140.27]) by kanga.kvack.org (Postfix) with ESMTP id 2A3F36B0072 for ; Thu, 21 Apr 2022 11:10:50 -0400 (EDT) Received: from smtpin23.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay12.hostedemail.com (Postfix) with ESMTP id EEBFE12326C for ; Thu, 21 Apr 2022 15:10:49 +0000 (UTC) X-FDA: 79381223418.23.7466E4E Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by imf01.hostedemail.com (Postfix) with ESMTP id D675F40023 for ; Thu, 21 Apr 2022 15:10:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1650553849; x=1682089849; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=6s/Jh5/Nw/2YaODYM5uQMsmu5ex+nw0PjlAspdHlwBU=; b=FRolyLFKN+ecOaHbaqw6PqBdA2L0iFIzWEtHLWlw0c7JwK2RGTcwqais P44U+EguwpalauIMmQQn/Fg4kL75Tlm8KTAkZaj0Iklf9r28W1OJrc2SC 5jr4mPgDxF698aZqDe5A6sky+Md45eGChfrPno9J9huJf9JPO4sjOkj03 Bk2zwccqbvzB2yxi8MFRNpdqfAIoyrKnuIGcO/o+aJwQ/T1OYCpAC5bUm IpwtOR4Svrr8b90sl0+YAh42nPc6NG00I446MObOYJmRyEjeVsGVjwbgs WApZ0EsZxsJAfLmfSlsOv+3zZ75jVNjzRozSjHcbbNw5zcGRaIUSH0ORs Q==; X-IronPort-AV: E=McAfee;i="6400,9594,10324"; a="264143079" X-IronPort-AV: E=Sophos;i="5.90,279,1643702400"; d="scan'208";a="264143079" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Apr 2022 08:10:25 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.90,279,1643702400"; d="scan'208";a="626547444" Received: from lkp-server01.sh.intel.com (HELO 3abc53900bec) ([10.239.97.150]) by fmsmga004.fm.intel.com with ESMTP; 21 Apr 2022 08:10:21 -0700 Received: from kbuild by 3abc53900bec with local (Exim 4.95) (envelope-from ) id 1nhYRp-0008Vb-6c; Thu, 21 Apr 2022 15:10:21 +0000 Date: Thu, 21 Apr 2022 23:09:46 +0800 From: kernel test robot To: Sandor Yu Cc: kbuild-all@lists.01.org, Linux Memory Management List , Robert Foss , Shengjiu Wang , Neil Armstrong , Andrzej Hajda , Laurent Pinchart , Jonas Karlman , Jernej Skrabec , David Airlie , Daniel Vetter , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH] drm: bridge: dw_hdmi: Audio: fix returnvar.cocci warnings Message-ID: References: <202204212311.TnfpcTGm-lkp@intel.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <202204212311.TnfpcTGm-lkp@intel.com> X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: D675F40023 X-Rspam-User: Authentication-Results: imf01.hostedemail.com; dkim=pass header.d=intel.com header.s=Intel header.b=FRolyLFK; spf=none (imf01.hostedemail.com: domain of lkp@intel.com has no SPF policy when checking 134.134.136.65) smtp.mailfrom=lkp@intel.com; dmarc=pass (policy=none) header.from=intel.com X-Stat-Signature: 7nqzr96mb61uinq8ei7dntzkb6ymqfgn X-HE-Tag: 1650553846-767429 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: From: kernel test robot drivers/gpu/drm/bridge/synopsys/dw-hdmi-gp-audio.c:80:5-8: Unneeded variable: "ret". Return "0" on line 94 drivers/gpu/drm/bridge/synopsys/dw-hdmi-gp-audio.c:105:5-8: Unneeded variable: "ret". Return "0" on line 112 Remove unneeded variable used to store return value. Generated by: scripts/coccinelle/misc/returnvar.cocci CC: Sandor Yu Reported-by: kernel test robot Signed-off-by: kernel test robot Reviewed-by: Neil Armstrong Reviewed-by: Sandor Yu --- tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: 65eb92e4c9f0a962656f131521f4fbc0d24c9d4c commit: d970ce303ff80ae57bbd3e784f2772dbf3056e0c [4441/5346] drm: bridge: dw_hdmi: Audio: Add General Parallel Audio (GPA) driver :::::: branch date: 8 hours ago :::::: commit date: 2 days ago drivers/gpu/drm/bridge/synopsys/dw-hdmi-gp-audio.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi-gp-audio.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi-gp-audio.c @@ -77,7 +77,6 @@ static int audio_hw_params(struct device struct hdmi_codec_params *params) { struct snd_dw_hdmi *dw = dev_get_drvdata(dev); - int ret = 0; u8 ca; dw_hdmi_set_sample_rate(dw->data.hdmi, params->sample_rate); @@ -91,7 +90,7 @@ static int audio_hw_params(struct device params->iec.status[0] & IEC958_AES0_NONAUDIO); dw_hdmi_set_sample_width(dw->data.hdmi, params->sample_width); - return ret; + return 0; } static void audio_shutdown(struct device *dev, void *data) @@ -102,14 +101,13 @@ static int audio_mute_stream(struct devi bool enable, int direction) { struct snd_dw_hdmi *dw = dev_get_drvdata(dev); - int ret = 0; if (!enable) dw_hdmi_audio_enable(dw->data.hdmi); else dw_hdmi_audio_disable(dw->data.hdmi); - return ret; + return 0; } static int audio_get_eld(struct device *dev, void *data,