RE: [RFC 2/5] crypto: qat - add interface for live migration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> From: Xin Zeng <xin.zeng@xxxxxxxxx>
> Sent: Friday, June 30, 2023 9:13 PM
> +
> +int qat_vfmig_suspend_device(struct pci_dev *pdev, u32 vf_nr)
> +{
> +	struct adf_accel_dev *accel_dev =
> adf_devmgr_pci_to_accel_dev(pdev);
> +
> +	if (!accel_dev) {
> +		dev_err(&pdev->dev, "Failed to find accel_dev\n");
> +		return -ENODEV;
> +	}
> +
> +	if (WARN_ON(!GET_VFMIG_OPS(accel_dev)->suspend_device))
> +		return -EINVAL;

this and other warns should be done one-off at device registration point
instead of letting it triggerable by every user ioctl.





[Index of Archives]     [Kernel]     [Gnu Classpath]     [Gnu Crypto]     [DM Crypt]     [Netfilter]     [Bugtraq]
  Powered by Linux