]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
filemap: remove unused folio_add_wait_queue
authorDr. David Alan Gilbert <linux@treblig.org>
Sat, 16 Nov 2024 15:14:46 +0000 (15:14 +0000)
committerAndrew Morton <akpm@linux-foundation.org>
Tue, 14 Jan 2025 06:40:38 +0000 (22:40 -0800)
folio_add_wait_queue() has been unused since 2021's commit 850cba069c26
("cachefiles: Delete the cachefiles driver pending rewrite")

Remove it.

Link: https://lkml.kernel.org/r/20241116151446.95555-1-linux@treblig.org
Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
Reviewed-by: David Hildenbrand <david@redhat.com>
Reviewed-by: Vishal Moola (Oracle) <vishal.moola@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/pagemap.h
mm/filemap.c

index d796c8a33647893fe970373a44a4501d32de9bd6..fc2e1319c7bb5e9a7912aed7112512a1fdbe551b 100644 (file)
@@ -1280,11 +1280,6 @@ void folio_end_private_2(struct folio *folio);
 void folio_wait_private_2(struct folio *folio);
 int folio_wait_private_2_killable(struct folio *folio);
 
-/*
- * Add an arbitrary waiter to a page's wait queue
- */
-void folio_add_wait_queue(struct folio *folio, wait_queue_entry_t *waiter);
-
 /*
  * Fault in userspace address range.
  */
index 4f476411a9a2dadf6b24f1852eda2e2d429a9df9..b6494d2d3bc2aa26c029b8e13919f5138711bfa8 100644 (file)
@@ -1463,25 +1463,6 @@ static int folio_put_wait_locked(struct folio *folio, int state)
        return folio_wait_bit_common(folio, PG_locked, state, DROP);
 }
 
-/**
- * folio_add_wait_queue - Add an arbitrary waiter to a folio's wait queue
- * @folio: Folio defining the wait queue of interest
- * @waiter: Waiter to add to the queue
- *
- * Add an arbitrary @waiter to the wait queue for the nominated @folio.
- */
-void folio_add_wait_queue(struct folio *folio, wait_queue_entry_t *waiter)
-{
-       wait_queue_head_t *q = folio_waitqueue(folio);
-       unsigned long flags;
-
-       spin_lock_irqsave(&q->lock, flags);
-       __add_wait_queue_entry_tail(q, waiter);
-       folio_set_waiters(folio);
-       spin_unlock_irqrestore(&q->lock, flags);
-}
-EXPORT_SYMBOL_GPL(folio_add_wait_queue);
-
 /**
  * folio_unlock - Unlock a locked folio.
  * @folio: The folio.