Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp1685883rdb; Thu, 7 Dec 2023 06:19:21 -0800 (PST) X-Google-Smtp-Source: AGHT+IHiA2B5bTKRNLz7kQLI6Qaa+pwiiCMdwFvMgB4GjXpBm56mS+dGQbeENZG+5eFMVSVHom9N X-Received: by 2002:a17:90a:d990:b0:286:6cc0:b91a with SMTP id d16-20020a17090ad99000b002866cc0b91amr2026778pjv.81.1701958761526; Thu, 07 Dec 2023 06:19:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701958761; cv=none; d=google.com; s=arc-20160816; b=fA9Xv5tILrmX7POLcUb1Mij89JwX0NfYlZ5a4kDLmlzb2TIxnZdjV5907vFfx83PFQ JXxBbB6LLoVrR10UOBT02EM2IDW+HYjYAvD6jnQjUoZ1xAgSzFZMMr2o4ldUGjKLqukp ddaTeEehi46nLN7xpoxEFSWsdq8NcZe3bTlxt5w4oXNzrKrOy6RYrQb5fVWObCHmp8lR H1x0dOqfvdSu58jpM2qhxxtwrCc11ib2+w9zF1i5wtXovaF0JfNlXtAJ3Qvpe1MTgH6c C1YTnN5zUTBR/FOBr0HJl5xv0T49axhO1NbIlyxWn9vgxkjtYir2w/bheEtQ2NL3lw8h xcWQ== 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 :dkim-signature; bh=gvW8xi4ej1XhgskazNvZjO8ylB4EXhvrgB5oGbRm/aY=; fh=2EyuYZuFv7pvbWODgXyYvSVo1Jt/nOD9U4n59BuOM5Q=; b=XgbqloBolUnV+wPoAubrzaXzAW+ZdjyaWzP3aH4AVMcco8AM5HcTBSkVSSOezPb6NZ 9RjS2qni/jt2Yg0w26M64r4+5Jwj5WOaE16jXC8NCiLQcbAL0ngYwFQzsWbME9rQtR2d i7DoHoNb4MaO+sxaK9K872tHX2CykCoQ5AMdSIuhw5ECKBe93hHUlVQpshNPAkMPUzM8 4LRKC1Qart6FhIpyck6zt5cbJHlS6FVRJOicMMG3IUzvfWo3JCMK2eYnAFVOXEOcWbqp XEMluBbtdCRO0b4DendSzq7WOCA93MqEbwL7D54wO3tvngIDx43iMIoqitxkzT32V7ZZ FkoQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=IxqCTkaF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id gt15-20020a17090af2cf00b00286d6caba8esi1097050pjb.95.2023.12.07.06.19.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Dec 2023 06:19:21 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=IxqCTkaF; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 9ED0E80B284F; Thu, 7 Dec 2023 06:19:14 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1443209AbjLGOS2 (ORCPT + 99 others); Thu, 7 Dec 2023 09:18:28 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53402 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1443311AbjLGORt (ORCPT ); Thu, 7 Dec 2023 09:17:49 -0500 Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.100]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8A74E1708; Thu, 7 Dec 2023 06:17:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1701958646; x=1733494646; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=HriWS+6rKR56xLxTFH38aF8Vg3InXBxiKv23eQ6ZDgg=; b=IxqCTkaFENI4IYY8LfNPIYKBurp6ItPeOACeF74CugTKoB9pPDAo/LBp 0rtd6l3bRomYLmc4sZsTtXmy87sj5KbMP5y4ZxtysplxjUOcz8mD1nwpb Rx2/GKTbuyzvd5dt7KXRttlvN5FK+2cvSTAZPSsctUDCxGTOpkfBjKojR D5LntU33O5VEn8Kx+bm//8w1yI2tcvgqdlEMmdSXXrHdJb96gSbX3OLLK 93wXxRxgnmQHsxLdf6i6zshoddQEQPjOta4hVHHxibMa7vUYZjfTMU+8h /l5wUR1TjyAjhS5orytt/DUjd8y7I4zoivk2sub1e1UJ1lOXBuPwuRMrm Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10917"; a="460726223" X-IronPort-AV: E=Sophos;i="6.04,256,1695711600"; d="scan'208";a="460726223" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 07 Dec 2023 06:17:15 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10917"; a="889756109" X-IronPort-AV: E=Sophos;i="6.04,256,1695711600"; d="scan'208";a="889756109" Received: from black.fi.intel.com ([10.237.72.28]) by fmsmga002.fm.intel.com with ESMTP; 07 Dec 2023 06:17:12 -0800 Received: by black.fi.intel.com (Postfix, from userid 1003) id 8A442D50; Thu, 7 Dec 2023 16:17:03 +0200 (EET) From: Andy Shevchenko To: Mario Limonciello , Jarkko Nikula , Herbert Xu , Andy Shevchenko , Wolfram Sang , Andi Shyti , linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Mika Westerberg , Jan Dabros , Philipp Zabel , Serge Semin Subject: [PATCH v5 23/24] i2c: designware: Get rid of redundant 'else' Date: Thu, 7 Dec 2023 16:14:03 +0200 Message-ID: <20231207141653.2785124-24-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.43.0.rc1.1.gbec44491f096 In-Reply-To: <20231207141653.2785124-1-andriy.shevchenko@linux.intel.com> References: <20231207141653.2785124-1-andriy.shevchenko@linux.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-0.8 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Thu, 07 Dec 2023 06:19:14 -0800 (PST) In the snippets like the following if (...) return / goto / break / continue ...; else ... the 'else' is redundant. Get rid of it. Reviewed-by: Andi Shyti Reviewed-by: Mario Limonciello Tested-by: Serge Semin Acked-by: Jarkko Nikula Link: https://lore.kernel.org/r/20231120144641.1660574-24-andriy.shevchenko@linux.intel.com Signed-off-by: Andy Shevchenko --- drivers/i2c/busses/i2c-designware-common.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/i2c/busses/i2c-designware-common.c b/drivers/i2c/busses/i2c-designware-common.c index 45ced3354eef..b8e5d56473d6 100644 --- a/drivers/i2c/busses/i2c-designware-common.c +++ b/drivers/i2c/busses/i2c-designware-common.c @@ -639,10 +639,10 @@ int i2c_dw_handle_tx_abort(struct dw_i2c_dev *dev) if (abort_source & DW_IC_TX_ARB_LOST) return -EAGAIN; - else if (abort_source & DW_IC_TX_ABRT_GCALL_READ) + if (abort_source & DW_IC_TX_ABRT_GCALL_READ) return -EINVAL; /* wrong msgs[] data */ - else - return -EIO; + + return -EIO; } int i2c_dw_set_fifo_size(struct dw_i2c_dev *dev) -- 2.43.0.rc1.1.gbec44491f096