diff options
| author | Zhenzhong Duan <zhenzhong.duan@intel.com> | 2026-03-29 23:07:55 -0400 |
|---|---|---|
| committer | Jason Gunthorpe <jgg@nvidia.com> | 2026-03-31 13:12:18 -0300 |
| commit | aaca2aa92785a6ab8e3183e7184bca447a99cd76 (patch) | |
| tree | f603bd8c3adff955f88ea02f59dc88c96ea6881b /drivers/staging/bcm/git@git.tavy.me:linux.git | |
| parent | 67cb50aee082842077a8404337dc21b7d03829d7 (diff) | |
iommufd: Fix return value of iommufd_fault_fops_write()
copy_from_user() may return number of bytes failed to copy, we should
not pass over this number to user space to cheat that write() succeed.
Instead, -EFAULT should be returned.
Link: https://patch.msgid.link/r/20260330030755.12856-1-zhenzhong.duan@intel.com
Cc: stable@vger.kernel.org
Fixes: 07838f7fd529 ("iommufd: Add iommufd fault object")
Signed-off-by: Zhenzhong Duan <zhenzhong.duan@intel.com>
Reviewed-by: Lu Baolu <baolu.lu@linux.intel.com>
Reviewed-by: Pranjal Shrivastava <praan@google.com>
Reviewed-by: Shuai Xue <xueshuai@linux.alibaba.com>
Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'drivers/staging/bcm/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions
