linux/mm/page_io.c

// SPDX-License-Identifier: GPL-2.0
/*
 *  linux/mm/page_io.c
 *
 *  Copyright (C) 1991, 1992, 1993, 1994  Linus Torvalds
 *
 *  Swap reorganised 29.12.95, 
 *  Asynchronous swapping added 30.12.95. Stephen Tweedie
 *  Removed race in async swapping. 14.4.1996. Bruno Haible
 *  Add swap of shared pages through the page cache. 20.2.1998. Stephen Tweedie
 *  Always use brw_page, life becomes simpler. 12 May 1998 Eric Biederman
 */

#include <linux/mm.h>
#include <linux/kernel_stat.h>
#include <linux/gfp.h>
#include <linux/pagemap.h>
#include <linux/swap.h>
#include <linux/bio.h>
#include <linux/swapops.h>
#include <linux/writeback.h>
#include <linux/blkdev.h>
#include <linux/psi.h>
#include <linux/uio.h>
#include <linux/sched/task.h>
#include <linux/delayacct.h>
#include <linux/zswap.h>
#include "swap.h"

static void __end_swap_bio_write(struct bio *bio)
{}

static void end_swap_bio_write(struct bio *bio)
{}

static void __end_swap_bio_read(struct bio *bio)
{}

static void end_swap_bio_read(struct bio *bio)
{}

int generic_swapfile_activate(struct swap_info_struct *sis,
				struct file *swap_file,
				sector_t *span)
{}

/*
 * We may have stale swap cache pages in memory: notice
 * them here and get rid of the unnecessary final write.
 */
int swap_writepage(struct page *page, struct writeback_control *wbc)
{}

static inline void count_swpout_vm_event(struct folio *folio)
{}

#if defined(CONFIG_MEMCG) && defined(CONFIG_BLK_CGROUP)
static void bio_associate_blkg_from_page(struct bio *bio, struct folio *folio)
{}
#else
#define bio_associate_blkg_from_page
#endif /* CONFIG_MEMCG && CONFIG_BLK_CGROUP */

struct swap_iocb {};
static mempool_t *sio_pool;

int sio_pool_init(void)
{}

static void sio_write_complete(struct kiocb *iocb, long ret)
{}

static void swap_writepage_fs(struct folio *folio, struct writeback_control *wbc)
{}

static void swap_writepage_bdev_sync(struct folio *folio,
		struct writeback_control *wbc, struct swap_info_struct *sis)
{}

static void swap_writepage_bdev_async(struct folio *folio,
		struct writeback_control *wbc, struct swap_info_struct *sis)
{}

void __swap_writepage(struct folio *folio, struct writeback_control *wbc)
{}

void swap_write_unplug(struct swap_iocb *sio)
{}

static void sio_read_complete(struct kiocb *iocb, long ret)
{}

static void swap_read_folio_fs(struct folio *folio, struct swap_iocb **plug)
{}

static void swap_read_folio_bdev_sync(struct folio *folio,
		struct swap_info_struct *sis)
{}

static void swap_read_folio_bdev_async(struct folio *folio,
		struct swap_info_struct *sis)
{}

void swap_read_folio(struct folio *folio, struct swap_iocb **plug)
{}

void __swap_read_unplug(struct swap_iocb *sio)
{}