brd: Remove use of page->index
authorMatthew Wilcox (Oracle) <willy@infradead.org>
Fri, 15 Mar 2024 18:12:09 +0000 (18:12 +0000)
committerJens Axboe <axboe@kernel.dk>
Mon, 1 Apr 2024 17:53:36 +0000 (11:53 -0600)
commit7d8d35791b1b87a503ebe1f2f48407ee05dbaf5e
treeca4ac4e93b1c55a615b12c663e38f40903849537
parent39cd87c4eb2b893354f3b850f916353f2658ae6f
brd: Remove use of page->index

This debugging check will become more costly in the future when we shrink
struct page.  It has not proven to be useful, so simply remove it.

This lets us use __xa_insert instead of __xa_cmpxchg() as we no longer
need to know about the page that is currently stored in the XArray.

Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Reviewed-by: Keith Busch <kbusch@kernel.org>
Link: https://lore.kernel.org/r/20240315181212.2573753-1-willy@infradead.org
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/block/brd.c