[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20190722043012.22945-3-jhubbard@nvidia.com>
Date: Sun, 21 Jul 2019 21:30:11 -0700
From: john.hubbard@...il.com
To: Andrew Morton <akpm@...ux-foundation.org>
Cc: Alexander Viro <viro@...iv.linux.org.uk>,
Björn Töpel <bjorn.topel@...el.com>,
Boaz Harrosh <boaz@...xistor.com>,
Christoph Hellwig <hch@....de>,
Daniel Vetter <daniel@...ll.ch>,
Dan Williams <dan.j.williams@...el.com>,
Dave Chinner <david@...morbit.com>,
David Airlie <airlied@...ux.ie>,
"David S . Miller" <davem@...emloft.net>,
Ilya Dryomov <idryomov@...il.com>, Jan Kara <jack@...e.cz>,
Jason Gunthorpe <jgg@...pe.ca>, Jens Axboe <axboe@...nel.dk>,
Jérôme Glisse <jglisse@...hat.com>,
Johannes Thumshirn <jthumshirn@...e.de>,
Magnus Karlsson <magnus.karlsson@...el.com>,
Matthew Wilcox <willy@...radead.org>,
Miklos Szeredi <miklos@...redi.hu>,
Ming Lei <ming.lei@...hat.com>, Sage Weil <sage@...hat.com>,
Santosh Shilimkar <santosh.shilimkar@...cle.com>,
Yan Zheng <zyan@...hat.com>, netdev@...r.kernel.org,
dri-devel@...ts.freedesktop.org, linux-mm@...ck.org,
linux-rdma@...r.kernel.org, bpf@...r.kernel.org,
LKML <linux-kernel@...r.kernel.org>,
John Hubbard <jhubbard@...dia.com>
Subject: [PATCH 2/3] net/xdp: convert put_page() to put_user_page*()
From: John Hubbard <jhubbard@...dia.com>
For pages that were retained via get_user_pages*(), release those pages
via the new put_user_page*() routines, instead of via put_page() or
release_pages().
This is part a tree-wide conversion, as described in commit fc1d8e7cca2d
("mm: introduce put_user_page*(), placeholder versions").
Cc: Björn Töpel <bjorn.topel@...el.com>
Cc: Magnus Karlsson <magnus.karlsson@...el.com>
Cc: David S. Miller <davem@...emloft.net>
Cc: netdev@...r.kernel.org
Signed-off-by: John Hubbard <jhubbard@...dia.com>
---
net/xdp/xdp_umem.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/net/xdp/xdp_umem.c b/net/xdp/xdp_umem.c
index 83de74ca729a..9cbbb96c2a32 100644
--- a/net/xdp/xdp_umem.c
+++ b/net/xdp/xdp_umem.c
@@ -171,8 +171,7 @@ static void xdp_umem_unpin_pages(struct xdp_umem *umem)
for (i = 0; i < umem->npgs; i++) {
struct page *page = umem->pgs[i];
- set_page_dirty_lock(page);
- put_page(page);
+ put_user_pages_dirty_lock(&page, 1);
}
kfree(umem->pgs);
--
2.22.0
Powered by blists - more mailing lists