hisi_acc_vfio_pci: bugfix cache write-back issue
authorLongfang Liu <liulongfang@huawei.com>
Sat, 10 May 2025 08:11:52 +0000 (16:11 +0800)
committerAlex Williamson <alex.williamson@redhat.com>
Mon, 19 May 2025 18:41:31 +0000 (12:41 -0600)
commite63c466398731bb7867f42f44b76fa984de59db2
treeef5fc3802a1642b0cda1831721f7e55049838a52
parent3495cec0787721ba7a9d5c19d0bbb66d182de584
hisi_acc_vfio_pci: bugfix cache write-back issue

At present, cache write-back is placed in the device data
copy stage after stopping the device operation.
Writing back to the cache at this stage will cause the data
obtained by the cache to be written back to be empty.

In order to ensure that the cache data is written back
successfully, the data needs to be written back into the
stop device stage.

Fixes: b0eed085903e ("hisi_acc_vfio_pci: Add support for VFIO live migration")
Signed-off-by: Longfang Liu <liulongfang@huawei.com>
Reviewed-by: Shameer Kolothum <shameerali.kolothum.thodi@huawei.com>
Link: https://lore.kernel.org/r/20250510081155.55840-4-liulongfang@huawei.com
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
drivers/vfio/pci/hisilicon/hisi_acc_vfio_pci.c