Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp5577295rwr; Mon, 1 May 2023 07:55:34 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7wRwV8PhH8uN1b+MBcnLG7KKF/qOhKEvsemdyAMM0/ZQwvKwauEEoppKTEN+4VUPgLIGNI X-Received: by 2002:a17:903:1210:b0:1aa:cddd:57d8 with SMTP id l16-20020a170903121000b001aacddd57d8mr10309883plh.30.1682952934618; Mon, 01 May 2023 07:55:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682952934; cv=none; d=google.com; s=arc-20160816; b=BR6tYmzXM6jCnu29t7X1EMwOiLaAGAIadscROjeVkcxQDkZGaGN7To2dPcBIOOnhsU 1/uWtePE4LKQ/g+fbUrkX2sGQUpXLsnknUjTrn/NA3IckPSldHGMHLeDUwnHXljFiAdh L+S7ItTIMByoEPSYLUlBpBDiNQasMHfM5TPywJGa9BV/Jujs4hSMxtvpMa5A0zTaEh0G FUqRn5e9XHWmng38/xwHc3Z14KxNnogdscsewTWI5TsHcaADFg9nMweBzKce3FSX3zQW 7vLain9oahciQMo9SzxaNmLBFr2W5xKBE3y7ecHYN+29w2udHzTaFmGwUCFip0+ujITt XQOQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=fuotRf3i3/TTg5Xxfj454QFWTgwhJTEWhOwqyGZQpjk=; b=Q1HVhmm6yGUhdS7Jj6mHVTwIh1ohJpl8PXWVZh2B3orl2teh/xm9x9o6Sv0gRgEb6s LcLgVhCZZrcn6PSJY8i4YALBfVkEVR0WdOuHq9+fhjDzTueEXAO5l9nb2faGwkqARDbr 6a4RXWyfF7gm36uREkbK0Jg32B5x1G3doOXSIOHBGCkmLAo6LJOUY17U2jwtuXYWOSJc iPxZyge86kizFzYDolxebYv7rm4cvm+N8al0xqTEzJvjYN6OZ3Ga0WPxvVUH5qR2R3FJ ULXHXAZEF86nFYXiVlEqJ+jvkE2K2Y7oL8Psq2YHdBd6J5BbVdVkKXS8j3fnpGUcHWfG f56w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=iX4V1P7j; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p2-20020a1709026b8200b001a65688c863si27629909plk.56.2023.05.01.07.55.19; Mon, 01 May 2023 07:55:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=iX4V1P7j; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232450AbjEAOx0 (ORCPT + 99 others); Mon, 1 May 2023 10:53:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60238 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232234AbjEAOxZ (ORCPT ); Mon, 1 May 2023 10:53:25 -0400 Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6C0C810FC; Mon, 1 May 2023 07:53:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1682952785; x=1714488785; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=eK08VlhbMvavR7mKJ5uIKLoVViksnz0G9VSv4u8dCXk=; b=iX4V1P7jocVVv1R44EYnfZfywREzCrk/laagPr2X3fqH7MHrH20n/9Nx mLMNgv30F17bfcstIxtbWhrN0fCfKaCBbXrv+8eMW1u3iTKTy+RclljBH 4G2/PaMplLsEFZYpDImJG9dGS1ZHgKiZL0NV2nFcTPObSlxm4w2IUCRUt iw0mK1u3ifwOZuEV4E+DXkmaNN/9zFqZKql/xIhsrJdp/uuGvxHZkHpDN A237/Y/rZ5bYzrqOTw8Xj33Im+d+CdmfyEk2u4pplrrwZvNxNQPNQWAeQ hyikF2DT0FiOeX6YMArDtYw7K/+LHVwuKCn/tGoMrqzXXZsn0pozHK+Vb Q==; X-IronPort-AV: E=McAfee;i="6600,9927,10697"; a="434474123" X-IronPort-AV: E=Sophos;i="5.99,241,1677571200"; d="scan'208";a="434474123" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 May 2023 07:53:04 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10697"; a="765326986" X-IronPort-AV: E=Sophos;i="5.99,241,1677571200"; d="scan'208";a="765326986" Received: from djiang5-mobl3.amr.corp.intel.com (HELO [10.212.85.208]) ([10.212.85.208]) by fmsmga004-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 01 May 2023 07:53:04 -0700 Message-ID: Date: Mon, 1 May 2023 07:53:04 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Firefox/102.0 Thunderbird/102.10.0 Subject: Re: [PATCH v2 2/2] cxl/region: Remove else after return statement Content-Language: en-US To: Raghu H , linux-cxl@vger.kernel.org, Alison Schofield , ira.weiny@intel.com, bwidawsk@kernel.org, dan.j.williams@intel.com, vishal.l.verma@intel.com Cc: linux-kernel@vger.kernel.org References: <20230428012235.119333-1-raghuhack78@gmail.com> <20230428012235.119333-3-raghuhack78@gmail.com> From: Dave Jiang In-Reply-To: <20230428012235.119333-3-raghuhack78@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-6.0 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 4/27/23 6:22 PM, Raghu H wrote: > Issue found with checkpatch > > The else section here is redundant after return statement, removing it. > Sanity and correctness is not affected due to this fix. > > Signed-off-by: Raghu H Reviewed-by: Dave Jiang > --- > drivers/cxl/core/region.c | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) > > diff --git a/drivers/cxl/core/region.c b/drivers/cxl/core/region.c > index f29028148806..a46d6ad9ef0a 100644 > --- a/drivers/cxl/core/region.c > +++ b/drivers/cxl/core/region.c > @@ -2666,11 +2666,11 @@ static int cxl_region_invalidate_memregion(struct cxl_region *cxlr) > "Bypassing cpu_cache_invalidate_memregion() for testing!\n"); > clear_bit(CXL_REGION_F_INCOHERENT, &cxlr->flags); > return 0; > - } else { > - dev_err(&cxlr->dev, > - "Failed to synchronize CPU cache state\n"); > - return -ENXIO; > } > + > + dev_err(&cxlr->dev, > + "Failed to synchronize CPU cache state\n"); > + return -ENXIO; > } > > cpu_cache_invalidate_memregion(IORES_DESC_CXL);