summaryrefslogtreecommitdiff
path: root/drivers/usb/cdns3/host.c
diff options
context:
space:
mode:
authorSandeep Dhavale <dhavale@google.com>2024-02-21 13:03:47 -0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-03-01 13:26:33 +0100
commitd9d24262535360fceebacaf93eaba281d4135c52 (patch)
tree344b99e3e33cd4b3bf03c129ef9e11cb6f3dd0f8 /drivers/usb/cdns3/host.c
parent943c8b1fcc86210ac7a62cbba77360936554477c (diff)
erofs: fix refcount on the metabuf used for inode lookup
commit 56ee7db31187dc36d501622cb5f1415e88e01c2a upstream. In erofs_find_target_block() when erofs_dirnamecmp() returns 0, we do not assign the target metabuf. This causes the caller erofs_namei()'s erofs_put_metabuf() at the end to be not effective leaving the refcount on the page. As the page from metabuf (buf->page) is never put, such page cannot be migrated or reclaimed. Fix it now by putting the metabuf from previous loop and assigning the current metabuf to target before returning so caller erofs_namei() can do the final put as it was intended. Fixes: 500edd095648 ("erofs: use meta buffers for inode lookup") Cc: <stable@vger.kernel.org> # 5.18+ Signed-off-by: Sandeep Dhavale <dhavale@google.com> Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com> Reviewed-by: Jingbo Xu <jefflexu@linux.alibaba.com> Reviewed-by: Chao Yu <chao@kernel.org> Link: https://lore.kernel.org/r/20240221210348.3667795-1-dhavale@google.com Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/cdns3/host.c')
0 files changed, 0 insertions, 0 deletions