From patchwork Thu Jan 31 02:29:50 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Huaisheng Ye X-Patchwork-Id: 10789549 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 627E0139A for ; Thu, 31 Jan 2019 02:31:18 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5AE8030889 for ; Thu, 31 Jan 2019 02:31:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 4E32430890; Thu, 31 Jan 2019 02:31:18 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,FREEMAIL_FROM,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from ml01.01.org (ml01.01.org [198.145.21.10]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id C034230889 for ; Thu, 31 Jan 2019 02:31:17 +0000 (UTC) Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 6CC77211C2822; Wed, 30 Jan 2019 18:31:17 -0800 (PST) X-Original-To: linux-nvdimm@lists.01.org Delivered-To: linux-nvdimm@lists.01.org Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=135.84.80.237; helo=sender-pp-092.zoho.com; envelope-from=yehs2007@zoho.com; receiver=linux-nvdimm@lists.01.org Received: from sender-pp-092.zoho.com (sender-pp-092.zoho.com [135.84.80.237]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id AF183211B5A4C for ; Wed, 30 Jan 2019 18:31:15 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548901870; cv=none; d=zoho.com; s=zohoarc; b=X+ml8GMBbecCc3TqJto8+8DMraRD8xLGYKg5Xzzco0pN6xiYjFRdMLHcHy2fS5O2Ef1xlV36vZMx6j1X2FEftv+sXrCrEl+f5PK0g6v6jT3P9VM5llXCUdntyH61ofRWF7K87dm5NtFVk0lQDACsfpkByCRUztQYmA2U8gkcxW0= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1548901870; h=Cc:Date:From:Message-ID:Subject:To:ARC-Authentication-Results; bh=Hprshl33TxrC7I6MgIhdNaFls+1mjN5XVsCBfTa4/Vk=; b=hdBFMP4a0NT7dcmBvRS+EY45WcIS3niSsXOq5cAUBG1Fv4eesllME8AQYXYtaP7YR/eH4uT4oR/pymcXngupvmQ7t8+HvU/T23U6RJvWrSQpojSPMWtNitA2CXa1RuIbDCGuA4ZQ8RnN8hfUaQoHQmVz0gWXno1rmzjUYLsLeLc= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=pass header.i=zoho.com; spf=pass smtp.mailfrom=yehs2007@zoho.com; dmarc=pass header.from= header.from= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=zapps768; d=zoho.com; h=from:to:cc:subject:date:message-id; b=HTuEgdcbZQmmTutO0542+OhLG4dc+iGM1cZRdGCjuy0KypODgxvXNDtlnY1PZcmXxnRVyjQ0zUak tMe1r5gE/ydSHoV/reMp81MAUvbhCXdlemoJ6NctGHGU3UqWD4al DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1548901870; s=default; d=zoho.com; i=yehs2007@zoho.com; h=From:To:Cc:Subject:Date:Message-Id; l=1196; bh=Hprshl33TxrC7I6MgIhdNaFls+1mjN5XVsCBfTa4/Vk=; b=IJHMiJMGXd0ppiRLfxbuB3ZMfyLZnrk69054SKhnCKd5D8JTrtLf2FaqVu7sut4+ ZmBWTzywgAPZbjNQpaoW6sAUe3dFuE7SOdrAcstdaiuNccYx4H7Rq47G6/l8L3UIWn5 sqjqG7/78VadDGVLqdNbKuzgRZtwqgVf/kkwiNdU= Received: from YEHS1XR956R00D1.lenovo.com (106.38.1.115 [106.38.1.115]) by mx.zohomail.com with SMTPS id 1548901867914504.01422197228715; Wed, 30 Jan 2019 18:31:07 -0800 (PST) From: Huaisheng Ye To: mpatocka@redhat.com, snitzer@redhat.com, agk@redhat.com Subject: [PATCH v3 0/5] Optimize writecache when using pmem as cache Date: Thu, 31 Jan 2019 10:29:50 +0800 Message-Id: <20190131022955.9920-1-yehs2007@zoho.com> X-Mailer: git-send-email 2.17.0.windows.1 X-ZohoMailClient: External X-BeenThere: linux-nvdimm@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Linux-nvdimm developer list." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: jack@suse.cz, corbet@lwn.net, linux-nvdimm@lists.01.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, dm-devel@redhat.com, hch@lst.de MIME-Version: 1.0 Errors-To: linux-nvdimm-bounces@lists.01.org Sender: "Linux-nvdimm" X-Virus-Scanned: ClamAV using ClamSMTP From: Huaisheng Ye This patch set could be used for dm-writecache when use persistent memory as cache data device. Patch 1 and 2 go towards removing unused parameter and codes which actually doesn't really work. Patch 3 and 4 are targeted at solving problem fn ctr failed to work due to invalid magic or version, which is caused by the super block of pmem has messy data stored. Patch 5 is used for getting the status of seq_count. Changes Since v2: - seq_count is important for flush operations, output it within status for debugging and analyzing code behavior. [1]: https://lkml.org/lkml/2019/1/3/43 [2]: https://lkml.org/lkml/2019/1/9/6 Huaisheng Ye (5): dm-writecache: remove unused size to writecache_flush_region dm-writecache: get rid of memory_data flush to writecache_flush_entry dm-writecache: expand pmem_reinit for struct dm_writecache Documentation/device-mapper: add optional parameter reinit dm-writecache: output seq_count within status Documentation/device-mapper/writecache.txt | 4 ++++ drivers/md/dm-writecache.c | 23 +++++++++++++---------- 2 files changed, 17 insertions(+), 10 deletions(-)