XArray: Fix xas_pause for large multi-index entries
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Fri, 31 Jan 2020 11:17:09 +0000 (06:17 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 17 Apr 2020 08:50:18 +0000 (10:50 +0200)
commit8f4c8e92bdac564b8c562460a271d3ff11317fe9
treeabdeb91c07d0be2feda73142d16879c8fc23e7ca
parenta1ffc47f22a843b75f6d6b9a989abcc825939564
XArray: Fix xas_pause for large multi-index entries

commit c36d451ad386b34f452fc3c8621ff14b9eaa31a6 upstream.

Inspired by the recent Coverity report, I looked for other places where
the offset wasn't being converted to an unsigned long before being
shifted, and I found one in xas_pause() when the entry being paused is
of order >32.

Fixes: b803b42823d0 ("xarray: Add XArray iterators")
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Cc: stable@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
lib/test_xarray.c
lib/xarray.c