Merge tag 'char-misc-4.16-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc
Pull char/misc driver updates from Greg KH: "Here is the big pull request for char/misc drivers for 4.16-rc1. There's a lot of stuff in here. Three new driver subsystems were added for various types of hardware busses: - siox - slimbus - soundwire as well as a new vboxguest subsystem for the VirtualBox hypervisor drivers. There's also big updates from the FPGA subsystem, lots of Android binder fixes, the usual handful of hyper-v updates, and lots of other smaller driver updates. All of these have been in linux-next for a long time, with no reported issues" * tag 'char-misc-4.16-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (155 commits) char: lp: use true or false for boolean values android: binder: use VM_ALLOC to get vm area android: binder: Use true and false for boolean values lkdtm: fix handle_irq_event symbol for INT_HW_IRQ_EN EISA: Delete error message for a failed memory allocation in eisa_probe() EISA: Whitespace cleanup misc: remove AVR32 dependencies virt: vbox: Add error mapping for VERR_INVALID_NAME and VERR_NO_MORE_FILES soundwire: Fix a signedness bug uio_hv_generic: fix new type mismatch warnings uio_hv_generic: fix type mismatch warnings auxdisplay: img-ascii-lcd: add missing MODULE_DESCRIPTION/AUTHOR/LICENSE uio_hv_generic: add rescind support uio_hv_generic: check that host supports monitor page uio_hv_generic: create send and receive buffers uio: document uio_hv_generic regions doc: fix documentation about uio_hv_generic vmbus: add monitor_id and subchannel_id to sysfs per channel vmbus: fix ABI documentation uio_hv_generic: use ISR callback method ...
这个提交包含在:
@@ -937,13 +937,10 @@ static long vop_ioctl(struct file *f, unsigned int cmd, unsigned long arg)
|
||||
dd.num_vq > MIC_MAX_VRINGS)
|
||||
return -EINVAL;
|
||||
|
||||
dd_config = kzalloc(mic_desc_size(&dd), GFP_KERNEL);
|
||||
if (!dd_config)
|
||||
return -ENOMEM;
|
||||
if (copy_from_user(dd_config, argp, mic_desc_size(&dd))) {
|
||||
ret = -EFAULT;
|
||||
goto free_ret;
|
||||
}
|
||||
dd_config = memdup_user(argp, mic_desc_size(&dd));
|
||||
if (IS_ERR(dd_config))
|
||||
return PTR_ERR(dd_config);
|
||||
|
||||
/* Ensure desc has not changed between the two reads */
|
||||
if (memcmp(&dd, dd_config, sizeof(dd))) {
|
||||
ret = -EINVAL;
|
||||
@@ -995,17 +992,12 @@ _unlock_ret:
|
||||
ret = vop_vdev_inited(vdev);
|
||||
if (ret)
|
||||
goto __unlock_ret;
|
||||
buf = kzalloc(vdev->dd->config_len, GFP_KERNEL);
|
||||
if (!buf) {
|
||||
ret = -ENOMEM;
|
||||
buf = memdup_user(argp, vdev->dd->config_len);
|
||||
if (IS_ERR(buf)) {
|
||||
ret = PTR_ERR(buf);
|
||||
goto __unlock_ret;
|
||||
}
|
||||
if (copy_from_user(buf, argp, vdev->dd->config_len)) {
|
||||
ret = -EFAULT;
|
||||
goto done;
|
||||
}
|
||||
ret = vop_virtio_config_change(vdev, buf);
|
||||
done:
|
||||
kfree(buf);
|
||||
__unlock_ret:
|
||||
mutex_unlock(&vdev->vdev_mutex);
|
||||
|
在新工单中引用
屏蔽一个用户