#include <linux/anon_inodes.h>
#include <linux/file.h>
#include <linux/fs.h>
#include <linux/highmem.h>
#include <linux/vfio.h>
#include <linux/vfio_pci_core.h>
#include "vfio_dev.h"
#include "cmds.h"
static struct pds_vfio_lm_file *
pds_vfio_get_lm_file(const struct file_operations *fops, int flags, u64 size)
{ … }
static void pds_vfio_put_lm_file(struct pds_vfio_lm_file *lm_file)
{ … }
void pds_vfio_put_save_file(struct pds_vfio_pci_device *pds_vfio)
{ … }
void pds_vfio_put_restore_file(struct pds_vfio_pci_device *pds_vfio)
{ … }
static struct page *pds_vfio_get_file_page(struct pds_vfio_lm_file *lm_file,
unsigned long offset)
{ … }
static int pds_vfio_release_file(struct inode *inode, struct file *filp)
{ … }
static ssize_t pds_vfio_save_read(struct file *filp, char __user *buf,
size_t len, loff_t *pos)
{ … }
static const struct file_operations pds_vfio_save_fops = …;
static int pds_vfio_get_save_file(struct pds_vfio_pci_device *pds_vfio)
{ … }
static ssize_t pds_vfio_restore_write(struct file *filp, const char __user *buf,
size_t len, loff_t *pos)
{ … }
static const struct file_operations pds_vfio_restore_fops = …;
static int pds_vfio_get_restore_file(struct pds_vfio_pci_device *pds_vfio)
{ … }
struct file *
pds_vfio_step_device_state_locked(struct pds_vfio_pci_device *pds_vfio,
enum vfio_device_mig_state next)
{ … }