| /linux/drivers/vfio/pci/mlx5/ |
| H A D | main.c | 37 static void mlx5vf_disable_fd(struct mlx5_vf_migration_file *migf) in mlx5vf_disable_fd() argument 39 mutex_lock(&migf->lock); in mlx5vf_disable_fd() 40 migf->state = MLX5_MIGF_STATE_ERROR; in mlx5vf_disable_fd() 41 migf->filp->f_pos = 0; in mlx5vf_disable_fd() 42 mutex_unlock(&migf->lock); in mlx5vf_disable_fd() 47 struct mlx5_vf_migration_file *migf = filp->private_data; in mlx5vf_release_file() local 49 mlx5vf_disable_fd(migf); in mlx5vf_release_file() 50 mutex_destroy(&migf->lock); in mlx5vf_release_file() 51 kfree(migf); in mlx5vf_release_file() 56 mlx5vf_get_data_buff_from_pos(struct mlx5_vf_migration_file *migf, loff_ argument 90 struct mlx5_vf_migration_file *migf = vhca_buf->migf; mlx5vf_buf_read_done() local 167 struct mlx5_vf_migration_file *migf = filp->private_data; mlx5vf_save_read() local 239 struct mlx5_vf_migration_file *migf = filp->private_data; mlx5vf_save_poll() local 259 mlx5vf_mark_err(struct mlx5_vf_migration_file * migf) mlx5vf_mark_err() argument 265 mlx5vf_mig_file_set_save_work(struct mlx5_vf_migration_file * migf,u8 chunk_num,size_t next_required_umem_size) mlx5vf_mig_file_set_save_work() argument 277 mlx5vf_mig_file_get_stop_copy_buf(struct mlx5_vf_migration_file * migf,u8 index,size_t required_length) mlx5vf_mig_file_get_stop_copy_buf() argument 304 struct mlx5_vf_migration_file *migf = save_data->migf; mlx5vf_mig_file_save_work() local 332 mlx5vf_add_stop_copy_header(struct mlx5_vf_migration_file * migf,bool track) mlx5vf_add_stop_copy_header() argument 379 mlx5vf_prep_stop_copy(struct mlx5vf_pci_core_device * mvdev,struct mlx5_vf_migration_file * migf,size_t state_size,u64 full_size,bool track) mlx5vf_prep_stop_copy() argument 461 struct mlx5_vf_migration_file *migf = filp->private_data; mlx5vf_precopy_ioctl() local 570 struct mlx5_vf_migration_file *migf = mvdev->saving_migf; mlx5vf_pci_save_device_inc_data() local 605 struct mlx5_vf_migration_file *migf; mlx5vf_pci_save_device_data() local 712 mlx5vf_resume_read_image(struct mlx5_vf_migration_file * migf,struct mlx5_vhca_data_buffer * vhca_buf,size_t image_size,const char __user ** buf,size_t * len,loff_t * pos,ssize_t * done,bool * has_work) mlx5vf_resume_read_image() argument 741 mlx5vf_resume_read_header_data(struct mlx5_vf_migration_file * migf,struct mlx5_vhca_data_buffer * vhca_buf,const char __user ** buf,size_t * len,loff_t * pos,ssize_t * done) mlx5vf_resume_read_header_data() argument 791 mlx5vf_resume_read_header(struct mlx5_vf_migration_file * migf,struct mlx5_vhca_data_buffer * vhca_buf,const char __user ** buf,size_t * len,loff_t * pos,ssize_t * done,bool * has_work) mlx5vf_resume_read_header() argument 862 struct mlx5_vf_migration_file *migf = filp->private_data; mlx5vf_resume_write() local 988 struct mlx5_vf_migration_file *migf; mlx5vf_pci_resume_device_data() local 1108 struct mlx5_vf_migration_file *migf; mlx5vf_pci_step_device_state_locked() local 1126 struct mlx5_vf_migration_file *migf = mvdev->saving_migf; mlx5vf_pci_step_device_state_locked() local 1150 struct mlx5_vf_migration_file *migf; mlx5vf_pci_step_device_state_locked() local 1168 struct mlx5_vf_migration_file *migf; mlx5vf_pci_step_device_state_locked() local [all...] |
| H A D | cmd.c | 40 struct mlx5_vf_migration_file *migf = mvdev->saving_migf; in mlx5vf_cmd_suspend_vhca() local 55 if (migf) { in mlx5vf_cmd_suspend_vhca() 56 err = wait_for_completion_interruptible(&migf->save_comp); in mlx5vf_cmd_suspend_vhca() 66 if (migf) in mlx5vf_cmd_suspend_vhca() 67 complete(&migf->save_comp); in mlx5vf_cmd_suspend_vhca() 431 struct mlx5vf_pci_core_device *mvdev = buf->migf->mvdev; in mlx5vf_dma_data_buffer() 442 buf->mkey_in = alloc_mkey_in(buf->npages, buf->migf->pdn); in mlx5vf_dma_data_buffer() 479 struct mlx5vf_pci_core_device *mvdev = buf->migf->mvdev; in mlx5vf_free_data_buffer() 529 mlx5vf_alloc_data_buffer(struct mlx5_vf_migration_file *migf, u32 npages, in mlx5vf_alloc_data_buffer() 540 buf->migf in mlx5vf_alloc_data_buffer() 522 mlx5vf_alloc_data_buffer(struct mlx5_vf_migration_file * migf,u32 npages,enum dma_data_direction dma_dir) mlx5vf_alloc_data_buffer() argument 563 mlx5vf_get_data_buffer(struct mlx5_vf_migration_file * migf,u32 npages,enum dma_data_direction dma_dir) mlx5vf_get_data_buffer() argument 606 mlx5vf_save_callback_complete(struct mlx5_vf_migration_file * migf,struct mlx5vf_async_data * async_data) mlx5vf_save_callback_complete() argument 618 struct mlx5_vf_migration_file *migf = container_of(async_data, mlx5vf_mig_file_cleanup_cb() local 640 struct mlx5_vf_migration_file *migf = header_buf->migf; add_buf_header() local 670 struct mlx5_vf_migration_file *migf = container_of(async_data, mlx5vf_save_callback() local 739 mlx5vf_cmd_save_vhca_state(struct mlx5vf_pci_core_device * mvdev,struct mlx5_vf_migration_file * migf,struct mlx5_vhca_data_buffer * buf,bool inc,bool track) mlx5vf_cmd_save_vhca_state() argument 833 mlx5vf_cmd_load_vhca_state(struct mlx5vf_pci_core_device * mvdev,struct mlx5_vf_migration_file * migf,struct mlx5_vhca_data_buffer * buf) mlx5vf_cmd_load_vhca_state() argument 859 mlx5vf_cmd_alloc_pd(struct mlx5_vf_migration_file * migf) mlx5vf_cmd_alloc_pd() argument 871 mlx5vf_cmd_dealloc_pd(struct mlx5_vf_migration_file * migf) mlx5vf_cmd_dealloc_pd() argument 880 mlx5fv_cmd_clean_migf_resources(struct mlx5_vf_migration_file * migf) mlx5fv_cmd_clean_migf_resources() argument [all...] |
| H A D | cmd.h | 67 struct mlx5_vf_migration_file *migf; 81 struct mlx5_vf_migration_file *migf; 212 struct mlx5_vf_migration_file *migf, 216 struct mlx5_vf_migration_file *migf, 218 int mlx5vf_cmd_alloc_pd(struct mlx5_vf_migration_file *migf); 219 void mlx5vf_cmd_dealloc_pd(struct mlx5_vf_migration_file *migf); 220 void mlx5fv_cmd_clean_migf_resources(struct mlx5_vf_migration_file *migf); 222 mlx5vf_alloc_data_buffer(struct mlx5_vf_migration_file *migf, u32 npages, 226 mlx5vf_get_data_buffer(struct mlx5_vf_migration_file *migf, u32 npages, in mlx5vf_get_migration_page() 244 void mlx5vf_mig_file_set_save_work(struct mlx5_vf_migration_file *migf, 66 struct mlx5_vf_migration_file *migf; global() member 80 struct mlx5_vf_migration_file *migf; global() member [all...] |
| /linux/drivers/vfio/pci/virtio/ |
| H A D | migrate.c | 30 virtiovf_read_device_context_chunk(struct virtiovf_migration_file *migf, 122 virtiovf_alloc_data_buffer(struct virtiovf_migration_file *migf, size_t length) in virtiovf_alloc_data_buffer() argument 136 buf->migf = migf; in virtiovf_alloc_data_buffer() 145 spin_lock_irq(&buf->migf->list_lock); in virtiovf_put_data_buffer() 146 list_add_tail(&buf->buf_elm, &buf->migf->avail_list); in virtiovf_put_data_buffer() 147 spin_unlock_irq(&buf->migf->list_lock); in virtiovf_put_data_buffer() 166 virtiovf_get_data_buffer(struct virtiovf_migration_file *migf, size_t length) in virtiovf_get_data_buffer() argument 173 spin_lock_irq(&migf->list_lock); in virtiovf_get_data_buffer() 174 list_for_each_entry_safe(buf, temp_buf, &migf in virtiovf_get_data_buffer() 200 virtiovf_clean_migf_resources(struct virtiovf_migration_file * migf) virtiovf_clean_migf_resources() argument 226 virtiovf_disable_fd(struct virtiovf_migration_file * migf) virtiovf_disable_fd() argument 295 struct virtiovf_migration_file *migf = filp->private_data; virtiovf_release_file() local 304 virtiovf_get_data_buff_from_pos(struct virtiovf_migration_file * migf,loff_t pos,bool * end_of_data) virtiovf_get_data_buff_from_pos() argument 384 struct virtiovf_migration_file *migf = filp->private_data; virtiovf_save_read() local 441 struct virtiovf_migration_file *migf = filp->private_data; virtiovf_precopy_ioctl() local 540 struct virtiovf_migration_file *migf = header_buf->migf; virtiovf_add_buf_header() local 564 virtiovf_read_device_context_chunk(struct virtiovf_migration_file * migf,u32 ctx_size) virtiovf_read_device_context_chunk() argument 639 struct virtiovf_migration_file *migf = virtvdev->saving_migf; virtiovf_pci_save_device_final_data() local 674 struct virtiovf_migration_file *migf; virtiovf_pci_save_device_data() local 808 virtiovf_resume_read_chunk(struct virtiovf_migration_file * migf,struct virtiovf_data_buffer * vhca_buf,size_t chunk_size,const char __user ** buf,size_t * len,loff_t * pos,ssize_t * done,bool * has_work) virtiovf_resume_read_chunk() argument 837 virtiovf_resume_read_header_data(struct virtiovf_migration_file * migf,struct virtiovf_data_buffer * vhca_buf,const char __user ** buf,size_t * len,loff_t * pos,ssize_t * done) virtiovf_resume_read_header_data() argument 873 virtiovf_resume_read_header(struct virtiovf_migration_file * migf,struct virtiovf_data_buffer * vhca_buf,const char __user ** buf,size_t * len,loff_t * pos,ssize_t * done,bool * has_work) virtiovf_resume_read_header() argument 941 struct virtiovf_migration_file *migf = filp->private_data; virtiovf_resume_write() local 1064 struct virtiovf_migration_file *migf; virtiovf_pci_resume_device_data() local 1162 struct virtiovf_migration_file *migf; virtiovf_pci_step_device_state_locked() local 1180 struct virtiovf_migration_file *migf; virtiovf_pci_step_device_state_locked() local 1198 struct virtiovf_migration_file *migf; virtiovf_pci_step_device_state_locked() local [all...] |
| H A D | common.h | 33 struct virtiovf_migration_file *migf; member
|
| /linux/drivers/vfio/pci/qat/ |
| H A D | main.c | 82 static void qat_vf_disable_fd(struct qat_vf_migration_file *migf) in qat_vf_disable_fd() argument 84 mutex_lock(&migf->lock); in qat_vf_disable_fd() 85 migf->disabled = true; in qat_vf_disable_fd() 86 migf->filp->f_pos = 0; in qat_vf_disable_fd() 87 migf->filled_size = 0; in qat_vf_disable_fd() 88 mutex_unlock(&migf->lock); in qat_vf_disable_fd() 119 struct qat_vf_migration_file *migf = filp->private_data; in qat_vf_precopy_ioctl() local 120 struct qat_vf_core_device *qat_vdev = migf->qat_vdev; in qat_vf_precopy_ioctl() 138 mutex_lock(&migf->lock); in qat_vf_precopy_ioctl() 139 if (migf in qat_vf_precopy_ioctl() 169 struct qat_vf_migration_file *migf = filp->private_data; qat_vf_save_read() local 208 struct qat_vf_migration_file *migf = filp->private_data; qat_vf_release_file() local 226 qat_vf_save_state(struct qat_vf_core_device * qat_vdev,struct qat_vf_migration_file * migf) qat_vf_save_state() argument 239 qat_vf_save_setup(struct qat_vf_core_device * qat_vdev,struct qat_vf_migration_file * migf) qat_vf_save_setup() argument 261 struct qat_vf_migration_file *migf; qat_vf_save_device_data() local 296 struct qat_vf_migration_file *migf = filp->private_data; qat_vf_resume_write() local 352 struct qat_vf_migration_file *migf; qat_vf_resume_device_data() local 412 struct qat_vf_migration_file *migf; qat_vf_pci_step_device_state() local 423 struct qat_vf_migration_file *migf; qat_vf_pci_step_device_state() local 442 struct qat_vf_migration_file *migf; qat_vf_pci_step_device_state() local 453 struct qat_vf_migration_file *migf = qat_vdev->saving_migf; qat_vf_pci_step_device_state() local [all...] |
| /linux/drivers/vfio/pci/xe/ |
| H A D | main.c | 38 struct xe_vfio_pci_migration_file *migf; member 43 static void xe_vfio_pci_disable_file(struct xe_vfio_pci_migration_file *migf) in xe_vfio_pci_disable_file() argument 45 mutex_lock(&migf->lock); in xe_vfio_pci_disable_file() 46 migf->disabled = true; in xe_vfio_pci_disable_file() 47 mutex_unlock(&migf->lock); in xe_vfio_pci_disable_file() 52 xe_vfio_pci_disable_file(xe_vdev->migf); in xe_vfio_pci_put_file() 53 fput(xe_vdev->migf->filp); in xe_vfio_pci_put_file() 54 xe_vdev->migf = NULL; in xe_vfio_pci_put_file() 59 if (xe_vdev->migf) in xe_vfio_pci_reset() 179 struct xe_vfio_pci_migration_file *migf in xe_vfio_pci_save_read() 165 struct xe_vfio_pci_migration_file *migf = filp->private_data; xe_vfio_pci_release_file() local 175 struct xe_vfio_pci_migration_file *migf = filp->private_data; xe_vfio_pci_save_read() local 203 struct xe_vfio_pci_migration_file *migf = filp->private_data; xe_vfio_pci_resume_write() local 250 struct xe_vfio_pci_migration_file *migf; xe_vfio_pci_alloc_file() local 316 struct xe_vfio_pci_migration_file *migf; xe_vfio_set_state() local 346 struct xe_vfio_pci_migration_file *migf; xe_vfio_set_state() local [all...] |
| /linux/drivers/vfio/pci/hisilicon/ |
| H A D | hisi_acc_vfio_pci.c | 402 struct hisi_acc_vf_migration_file *migf) in vf_qm_check_match() argument 404 struct acc_vf_data *vf_data = &migf->vf_data; in vf_qm_check_match() 411 if (migf->total_length < QM_MATCH_SIZE || hisi_acc_vdev->match_done) in vf_qm_check_match() 489 struct hisi_acc_vf_migration_file *migf) in vf_qm_xeqc_save() argument 491 struct acc_vf_data *vf_data = &migf->vf_data; in vf_qm_xeqc_save() 502 struct hisi_acc_vf_migration_file *migf) in vf_qm_load_data() argument 506 struct acc_vf_data *vf_data = &migf->vf_data; in vf_qm_load_data() 510 if (migf->total_length == QM_MATCH_SIZE) in vf_qm_load_data() 513 if (migf->total_length < sizeof(struct acc_vf_data)) in vf_qm_load_data() 594 struct hisi_acc_vf_migration_file *migf) in vf_qm_state_save() argument 688 hisi_acc_vf_disable_fd(struct hisi_acc_vf_migration_file * migf) hisi_acc_vf_disable_fd() argument 757 struct hisi_acc_vf_migration_file *migf = hisi_acc_vdev->resuming_migf; hisi_acc_vf_load_state() local 772 struct hisi_acc_vf_migration_file *migf = filp->private_data; hisi_acc_vf_release_file() local 783 struct hisi_acc_vf_migration_file *migf = filp->private_data; hisi_acc_vf_resume_write() local 832 struct hisi_acc_vf_migration_file *migf; hisi_acc_vf_pci_resume() local 856 struct hisi_acc_vf_migration_file *migf = filp->private_data; hisi_acc_vf_precopy_ioctl() local 906 struct hisi_acc_vf_migration_file *migf = filp->private_data; hisi_acc_vf_save_read() local 953 struct hisi_acc_vf_migration_file *migf; hisi_acc_open_saving_migf() local 985 struct hisi_acc_vf_migration_file *migf; hisi_acc_vf_pre_copy() local 999 struct hisi_acc_vf_migration_file *migf = NULL; hisi_acc_vf_stop_copy() local 1055 struct hisi_acc_vf_migration_file *migf; hisi_acc_vf_set_device_state() local 1066 struct hisi_acc_vf_migration_file *migf; hisi_acc_vf_set_device_state() local 1087 struct hisi_acc_vf_migration_file *migf; hisi_acc_vf_set_device_state() local 1103 struct hisi_acc_vf_migration_file *migf; hisi_acc_vf_set_device_state() local 1664 struct hisi_acc_vf_migration_file *migf; hisi_acc_vfio_debug_init() local [all...] |
| /linux/samples/vfio-mdev/ |
| H A D | mtty.c | 786 static void mtty_disable_file(struct mtty_migration_file *migf) in mtty_disable_file() 788 mutex_lock(&migf->lock); in mtty_disable_file() 789 migf->disabled = true; in mtty_disable_file() 790 migf->filled_size = 0; in mtty_disable_file() 791 migf->filp->f_pos = 0; 792 mutex_unlock(&migf->lock); in mtty_disable_files() 827 struct mtty_migration_file *migf = filp->private_data; in mtty_release_migf() 829 mtty_disable_file(migf); in mtty_release_migf() 830 mutex_destroy(&migf->lock); in mtty_release_migf() 831 kfree(migf); in mtty_release_migf() 783 mtty_disable_file(struct mtty_migration_file * migf) mtty_disable_file() argument 824 struct mtty_migration_file *migf = filp->private_data; mtty_release_migf() local 836 struct mtty_migration_file *migf = filp->private_data; mtty_precopy_ioctl() local 887 struct mtty_migration_file *migf = filp->private_data; mtty_save_read() local 934 struct mtty_migration_file *migf = mdev_state->saving_migf; mtty_save_state() local 950 struct mtty_migration_file *migf = mdev_state->resuming_migf; mtty_load_state() local 975 struct mtty_migration_file *migf = mdev_state->saving_migf; mtty_save_device_data() local 1023 struct mtty_migration_file *migf = filp->private_data; mtty_resume_write() local 1089 struct mtty_migration_file *migf; mtty_resume_device_data() local 1192 struct mtty_migration_file *migf; mtty_step_state() local 1208 struct mtty_migration_file *migf; mtty_step_state() local [all...] |