Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp3918657pxv; Mon, 28 Jun 2021 16:38:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwsxeDSC6aaGeBlVyxxthWBt0r1vh8SEA5fGCL/DYWBzu97UTRFZcAxs/pfs9sOyruplIWh X-Received: by 2002:a92:ce91:: with SMTP id r17mr19959679ilo.168.1624923538315; Mon, 28 Jun 2021 16:38:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624923538; cv=none; d=google.com; s=arc-20160816; b=q75im3lZI8r7bmwu6LQPlIr1DRpFjZqjEsewQ8GJ+SmZmaTXx/pZ3Hgsk9Jqu1aY3r /hbnUUJXGHd4WBtf3Ha1MmufwyzmYk4F+U6Fo1SzzGxiOEj4JabwoNXISiwjWF/BNb2S SloZNutp89YuZ4jc3WKaqMwUMt1lojhNcvmyv7UlTUemhK3JYU+D1+IE2puUz6Ivp/qf 10hRhS66bo0z9oZoHnkL+1PIVIEbSbytHSECISa5M5ElEGejaH7pkT5AjlcF26PGh23h JEik4Opp58m4xpUvvCh1aA4lBefoAdMNrt/Q4uH8VVtv/DpTZRIZE5bXiGomjNjDRaX+ y9Ag== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :to:subject; bh=GfRxaMN2eKFBKbZywqJEXzXKupkpoSlsw/XGm2NWMos=; b=ROuDyG/qBLzpsrgAfaTUoc8d6HDwKWPaVCuQcthMdPkX7NyWi6OIU8f8vhH1XMnAzP GIGW3C97ojPmcZsxhD0OE3QXwLu79sFySu0vJ73VdQWrbNytn0b52xHxDvTtsoMWG/6/ q5/1s+DWuInlZQbwWKSCptPJ4doLKTvclX5cp9F/MVqCGn7Ln7EEC7cczTjcLiy3xWsN dD1uSHdy1obmlFmeXdFMSY/9+WSQTtEWouJ/9wHsqkaYln5NOdi8GVW0nxWdQv8QY+7a BYZj6qxjvcQO2bzQDWew2FmdktHf63Xr5DhBIuvTSbjvte/zgvNHbwGewQrqbCSfleVx HsbQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r4si16457130ioh.93.2021.06.28.16.38.46; Mon, 28 Jun 2021 16:38:58 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232000AbhF1Q7I (ORCPT + 99 others); Mon, 28 Jun 2021 12:59:08 -0400 Received: from mail-pf1-f172.google.com ([209.85.210.172]:34545 "EHLO mail-pf1-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231848AbhF1Q7H (ORCPT ); Mon, 28 Jun 2021 12:59:07 -0400 Received: by mail-pf1-f172.google.com with SMTP id i6so14659194pfq.1; Mon, 28 Jun 2021 09:56:41 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=GfRxaMN2eKFBKbZywqJEXzXKupkpoSlsw/XGm2NWMos=; b=LKVS8Y4UxRk5fJw3NrxPbTrou5PiWzuRUKPJ7axBi++RFbfqTCwtSovrhkJVoBoYec wrokS6wqFtaKR+PhJxEJwcEQJ13lDtnTjWhZpavCrtX3JTFne7KPcOmMfhsazQ18/16d fkV5fZItKRcYz3QJOjmz2XCuBYO1vvuIHWXXT+howzWqScxLAl3nJlYdfVlj1K5Bn+aQ KkUZHkrx+T/jFKXK1do5567b6zP8dZYXSqYCDlOt4AbTQtdVpWQo+cCnkC2oje2uJ4cc H2fW55Xl9Xo9df5MjV11aJQn8QY20JaAuVtWxbuYreRmSWxTTCi5CzLxe4zp8mi5yL17 yhxw== X-Gm-Message-State: AOAM5311TcUvKiY10J5nFWu9KL+AXeWFciw9hG/i7+rsGHroFszEqCW3 EtlXYZszCCMRXLbgAavPo3Y= X-Received: by 2002:a65:5aca:: with SMTP id d10mr10991753pgt.422.1624899400726; Mon, 28 Jun 2021 09:56:40 -0700 (PDT) Received: from [192.168.3.217] (c-73-241-217-19.hsd1.ca.comcast.net. [73.241.217.19]) by smtp.gmail.com with ESMTPSA id u7sm16197677pjd.55.2021.06.28.09.56.38 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 28 Jun 2021 09:56:40 -0700 (PDT) Subject: Re: [PATCH v2] scsi: ufs: Refactor ufshcd_is_intr_aggr_allowed() To: keosung.park@samsung.com, ALIM AKHTAR , "avri.altman@wdc.com" , "jejb@linux.ibm.com" , "martin.petersen@oracle.com" , "stanley.chu@mediatek.com" , "cang@codeaurora.org" , "beanhuo@micron.com" , "adrian.hunter@intel.com" , Kiwoong Kim , "satyat@google.com" , "asutoshd@codeaurora.org" , "linux-scsi@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "jpinto@synopsys.com" , "joe@perches.com" References: <1891546521.01624860001810.JavaMail.epsvc@epcpadp3> From: Bart Van Assche Message-ID: <41f85bd8-f159-0518-eeb8-05ac814dea9f@acm.org> Date: Mon, 28 Jun 2021 09:56:37 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <1891546521.01624860001810.JavaMail.epsvc@epcpadp3> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/27/21 10:58 PM, Keoseong Park wrote: > Simplify if else statement to return statement, > and remove code related to CONFIG_SCSI_UFS_DWC that is not in use. > > v1 -> v2 > Remove code related to CONFIG_SCSI_UFS_DWC that is not in use. > > Cc: Joao Pinto > Signed-off-by: Keoseong Park > --- > drivers/scsi/ufs/ufshcd.h | 12 ++---------- > 1 file changed, 2 insertions(+), 10 deletions(-) > > diff --git a/drivers/scsi/ufs/ufshcd.h b/drivers/scsi/ufs/ufshcd.h > index c98d540ac044..c9faca237290 100644 > --- a/drivers/scsi/ufs/ufshcd.h > +++ b/drivers/scsi/ufs/ufshcd.h > @@ -893,16 +893,8 @@ static inline bool ufshcd_is_rpm_autosuspend_allowed(struct ufs_hba *hba) > > static inline bool ufshcd_is_intr_aggr_allowed(struct ufs_hba *hba) > { > -/* DWC UFS Core has the Interrupt aggregation feature but is not detectable*/ > -#ifndef CONFIG_SCSI_UFS_DWC > - if ((hba->caps & UFSHCD_CAP_INTR_AGGR) && > - !(hba->quirks & UFSHCD_QUIRK_BROKEN_INTR_AGGR)) > - return true; > - else > - return false; > -#else > -return true; > -#endif > + return (hba->caps & UFSHCD_CAP_INTR_AGGR) && > + !(hba->quirks & UFSHCD_QUIRK_BROKEN_INTR_AGGR); > } Reviewed-by: Bart Van Assche