diff options
author | Yunsheng Lin <linyunsheng@huawei.com> | 2024-10-28 12:53:39 +0100 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2024-11-11 19:56:27 +0100 |
commit | 3d18dfe69ce46f106af327736d2261d7e3ee81c0 (patch) | |
tree | 508012ac2ca4270f28b0eee0cceed9959c589dfd /drivers/vhost | |
parent | mm: page_frag: use initial zero offset for page_frag_alloc_align() (diff) | |
download | linux-3d18dfe69ce46f106af327736d2261d7e3ee81c0.tar.xz linux-3d18dfe69ce46f106af327736d2261d7e3ee81c0.zip |
mm: page_frag: avoid caller accessing 'page_frag_cache' directly
Use appropriate frag_page API instead of caller accessing
'page_frag_cache' directly.
CC: Andrew Morton <akpm@linux-foundation.org>
CC: Linux-MM <linux-mm@kvack.org>
Signed-off-by: Yunsheng Lin <linyunsheng@huawei.com>
Reviewed-by: Alexander Duyck <alexanderduyck@fb.com>
Acked-by: Chuck Lever <chuck.lever@oracle.com>
Link: https://patch.msgid.link/20241028115343.3405838-5-linyunsheng@huawei.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/vhost')
-rw-r--r-- | drivers/vhost/net.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/vhost/net.c b/drivers/vhost/net.c index f16279351db5..9ad37c012189 100644 --- a/drivers/vhost/net.c +++ b/drivers/vhost/net.c @@ -1325,7 +1325,7 @@ static int vhost_net_open(struct inode *inode, struct file *f) vqs[VHOST_NET_VQ_RX]); f->private_data = n; - n->pf_cache.va = NULL; + page_frag_cache_init(&n->pf_cache); return 0; } |