From patchwork Wed Jul 27 06:59:04 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jinyoung CHOI X-Patchwork-Id: 594317 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id E2971C04A68 for ; Wed, 27 Jul 2022 06:59:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230016AbiG0G7e (ORCPT ); Wed, 27 Jul 2022 02:59:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39602 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231443AbiG0G7S (ORCPT ); Wed, 27 Jul 2022 02:59:18 -0400 Received: from mailout1.samsung.com (mailout1.samsung.com [203.254.224.24]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DA4BF313AE for ; Tue, 26 Jul 2022 23:59:07 -0700 (PDT) Received: from epcas2p2.samsung.com (unknown [182.195.41.54]) by mailout1.samsung.com (KnoxPortal) with ESMTP id 20220727065905epoutp0121220ef9b0a63677864db65a4199d89b~FnXDY1XWq0942909429epoutp011 for ; Wed, 27 Jul 2022 06:59:05 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout1.samsung.com 20220727065905epoutp0121220ef9b0a63677864db65a4199d89b~FnXDY1XWq0942909429epoutp011 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1658905145; bh=lNNfLiLq987R9+I+SlWzlrwsx34BfKrbsSzg18k1BO4=; h=Subject:Reply-To:From:To:Date:References:From; b=D8IIiIIBBQB75u8AF4W+Jiz36v3io1J77S12mn7PU8cvZsROrGPF4Ya13psG9PGGj fVjfH0DFWtzNH1pKD98RITKQYB5dNyY8jQ830HNG4ayuJk90U3qYZuJN8SDb1Bjhf9 Bc5uQN5si0JSebfrf7TEpLAbn9rM9/JogbQ6hjKQ= Received: from epsnrtp1.localdomain (unknown [182.195.42.162]) by epcas2p4.samsung.com (KnoxPortal) with ESMTP id 20220727065905epcas2p46087a372261c557b2b8689796a468825~FnXC2lDm81032510325epcas2p4O; Wed, 27 Jul 2022 06:59:05 +0000 (GMT) Received: from epsmges2p1.samsung.com (unknown [182.195.36.68]) by epsnrtp1.localdomain (Postfix) with ESMTP id 4Lt4Q04KhJz4x9Pv; Wed, 27 Jul 2022 06:59:04 +0000 (GMT) X-AuditID: b6c32a45-45bff700000025c2-b6-62e0e2389809 Received: from epcas2p1.samsung.com ( [182.195.41.53]) by epsmges2p1.samsung.com (Symantec Messaging Gateway) with SMTP id 0B.57.09666.832E0E26; Wed, 27 Jul 2022 15:59:04 +0900 (KST) Mime-Version: 1.0 Subject: [PATCH v4 0/7] scsi: ufs: wb: Add sysfs attribute and cleanup Reply-To: j-young.choi@samsung.com Sender: Jinyoung CHOI From: Jinyoung CHOI To: ALIM AKHTAR , "avri.altman@wdc.com" , "bvanassche@acm.org" , "jejb@linux.ibm.com" , "martin.petersen@oracle.com" , "beanhuo@micron.com" , "adrian.hunter@intel.com" , "linux-scsi@vger.kernel.org" , "linux-kernel@vger.kernel.org" X-Priority: 3 X-Content-Kind-Code: NORMAL X-CPGS-Detection: blocking_info_exchange X-Drm-Type: N,general X-Msg-Generator: Mail X-Msg-Type: PERSONAL X-Reply-Demand: N Message-ID: <20220727065904epcms2p60a7a56101785ddefa55c82b3cc25116d@epcms2p6> Date: Wed, 27 Jul 2022 15:59:04 +0900 X-CMS-MailID: 20220727065904epcms2p60a7a56101785ddefa55c82b3cc25116d X-Sendblock-Type: AUTO_CONFIDENTIAL X-CPGSPASS: Y X-CPGSPASS: Y CMS-TYPE: 102P X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFlrIJsWRmVeSWpSXmKPExsWy7bCmqa7Fowd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2VXc6kNrSvUl4V6cUiyRxRKvVuV qrHlf4teUt8iwf/Fy5SrzrxZHeMqVPTqZ9ueP7b/t9mWMC1nED7XOm1NkFdbg4XIp7R/CVzB TPM8rK61J02rTRQIfZ4upHzWv/J4mxJLcUaioRZzUXEiAHfwaP80BAAA DLP-Filter: Pass X-CFilter-Loop: Reflected X-CMS-RootMailID: 20220727065904epcms2p60a7a56101785ddefa55c82b3cc25116d References: Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org This patch series is to clean up UFS's Write Booster code and adds sysfs attribute which can control the specific feature of it. V2: - modify commit message - move & modify err messages - remove unnesscessary debug messages V3: - split patch (functional, non-functional) V4: - split patch (The number of patches from 2 to 7) - modify dev messages - modify commit message Jinyoung Choi (7): scsi: ufs: wb: Move ufshcd_is_wb_allowed() to callee function scsi: ufs: wb: Change wb_enabled condition test scsi: ufs: wb: Change functions name and modify parameter name scsi: ufs: wb: Add explicit flush sysfs attribute scsi: ufs: wb: Add ufshcd_is_wb_buf_flush_allowed() scsi: ufs: wb: Modify messages scsi: ufs: wb: Move the comment to the right position drivers/ufs/core/ufs-sysfs.c | 46 +++++++++++++++++++++++- drivers/ufs/core/ufshcd.c | 69 +++++++++++++++++++----------------- include/ufs/ufshcd.h | 7 ++++ 3 files changed, 89 insertions(+), 33 deletions(-)