From patchwork Thu Sep 27 18:17:32 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Omar Sandoval X-Patchwork-Id: 10618387 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 2A7B914BD for ; Thu, 27 Sep 2018 18:18:12 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 1E53D2B3B0 for ; Thu, 27 Sep 2018 18:18:12 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 104F12B98C; Thu, 27 Sep 2018 18:18:12 +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=-7.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5104029988 for ; Thu, 27 Sep 2018 18:18:08 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727522AbeI1Ahh (ORCPT ); Thu, 27 Sep 2018 20:37:37 -0400 Received: from mail-pg1-f195.google.com ([209.85.215.195]:34663 "EHLO mail-pg1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727223AbeI1Ahh (ORCPT ); Thu, 27 Sep 2018 20:37:37 -0400 Received: by mail-pg1-f195.google.com with SMTP id d19-v6so2560977pgv.1 for ; Thu, 27 Sep 2018 11:18:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=osandov-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ZEZkuNk/mYlbmJnqhIp7NLDYlKCO+sBS18MEuPWY8zQ=; b=xLLgeznr+fVffGdJ/vD4OKIObMISxkHr7ElERK08oinOHrvI6vnXD1EDjHCF9SZsnf mpTeW/NSIwsmzHYriikbIvRzycraEzviZJOrPDbYFqV6mMTX6UX4OUr1wU1HI1jO0NVL x9j98edJmPynYGeVzkGhN3gi0Wm7QzOEOTVD+hLOAB4SGAK/jls+40PTtaf6EusmjVi5 yL2F0ZxUt3kHJF15Y1NyepcxE8kyTde+hpI3dZa60SnPjchkBzXq1xj8Myl+C0VZZFzm lzuymP7JjDaeFtNE9dI+sxhEjEWo66qL8NlAdp9DJHHNDIdkUkbfMj94wDLfxFCBYFF0 k3ZA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=ZEZkuNk/mYlbmJnqhIp7NLDYlKCO+sBS18MEuPWY8zQ=; b=K9nAV7bn+1UBCBQJz9ssqw4aC+FycXyTOsS+4/AekViSKcHy6SET48d5tc+k07vWbt F85z7aQztbozBSojA6gOFx1bR1WbMNNVEAYTJSYx2jGLfh320sehy4TUt1s/6Y6EsN3z NIqdrySvlvBb/olbgVj5eUy9uEtUkl1+Lrbm0+elReVff0yAhzw0X9hsVhdte05H5blk 9D5zRKyRT1xrlTmSSgGz/58Zi91Id/esGeJ7YKgQxPYHXNPPGrQr/4T+1q8iRgAKjY3Q Gm4IQCf2AwefD4K+l84mP+6RXiJLQ7jfOWvQp8dMCF14h6W2KxZjJpA5B0hSgbJtNUtO yJqA== X-Gm-Message-State: ABuFfoifnctw3XjYw7hu/SYoMaTWfGkqzf8oPsTiATg5LMuhugANoqv/ aPH39raR8KXE8sjPdxfH2CpcAQ== X-Google-Smtp-Source: ACcGV63q1H3a865Yhxmy+OczLNadL92mqU9O+e5w0jhHHm4FI7zud6Er70Skl17T6r0TTAhiIuo8gw== X-Received: by 2002:a17:902:b092:: with SMTP id p18-v6mr12424534plr.90.1538072286063; Thu, 27 Sep 2018 11:18:06 -0700 (PDT) Received: from vader.thefacebook.com ([2620:10d:c090:200::5:3e64]) by smtp.gmail.com with ESMTPSA id p19-v6sm4086614pgh.60.2018.09.27.11.18.04 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 27 Sep 2018 11:18:05 -0700 (PDT) From: Omar Sandoval To: linux-btrfs@vger.kernel.org Cc: kernel-team@fb.com, David Sterba , linux-fsdevel@vger.kernel.org Subject: [PATCH v9 0/6] Btrfs: implement swap file support Date: Thu, 27 Sep 2018 11:17:32 -0700 Message-Id: X-Mailer: git-send-email 2.19.0 MIME-Version: 1.0 Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Omar Sandoval Hi, This series implements swap file support for Btrfs. Changes from v8 [1]: - Fixed a bug in btrfs_swap_activate() which would cause us to miss some file extents if they were merged into one extent map entry. - Fixed build for !CONFIG_SWAP. - Changed all error messages to KERN_WARN. - Unindented long error messages. I've Cc'd Jon and Al on patch 3 this time, so hopefully we can get an ack for that one, too. Thanks! 1: https://www.spinics.net/lists/linux-btrfs/msg82267.html Omar Sandoval (6): mm: split SWP_FILE into SWP_ACTIVATED and SWP_FS mm: export add_swap_extent() vfs: update swap_{,de}activate documentation Btrfs: prevent ioctls from interfering with a swap file Btrfs: rename get_chunk_map() and make it non-static Btrfs: support swap files Documentation/filesystems/Locking | 17 +- Documentation/filesystems/vfs.txt | 12 +- fs/btrfs/ctree.h | 29 +++ fs/btrfs/dev-replace.c | 8 + fs/btrfs/disk-io.c | 4 + fs/btrfs/inode.c | 338 ++++++++++++++++++++++++++++++ fs/btrfs/ioctl.c | 31 ++- fs/btrfs/relocation.c | 18 +- fs/btrfs/volumes.c | 82 ++++++-- fs/btrfs/volumes.h | 2 + include/linux/swap.h | 13 +- mm/page_io.c | 6 +- mm/swapfile.c | 14 +- 13 files changed, 523 insertions(+), 51 deletions(-)