diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2013-06-07 16:28:46 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-06-07 16:28:46 -0700 |
commit | 5125ed5b5438ab534df9bfc309dd556781c4ec9b (patch) | |
tree | 243b24b8c34b707022150286bfffce661a7d37dd /drivers | |
parent | b8e9dbacdd60c5a20ab2c77c08f047b2b990f303 (diff) | |
parent | 9a6aa279d3d17af73a029fa40654e92f4e75e8bb (diff) |
Merge tag 'vfio-v3.10-rc5' of git://github.com/awilliam/linux-vfio
Pull vfio fix from Alex Williamson:
"fix rmmod crash"
* tag 'vfio-v3.10-rc5' of git://github.com/awilliam/linux-vfio:
vfio: fix crash on rmmod
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/vfio/vfio.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/vfio/vfio.c b/drivers/vfio/vfio.c index acb7121a9316..6d78736563de 100644 --- a/drivers/vfio/vfio.c +++ b/drivers/vfio/vfio.c @@ -1360,7 +1360,7 @@ static const struct file_operations vfio_device_fops = { */ static char *vfio_devnode(struct device *dev, umode_t *mode) { - if (MINOR(dev->devt) == 0) + if (mode && (MINOR(dev->devt) == 0)) *mode = S_IRUGO | S_IWUGO; return kasprintf(GFP_KERNEL, "vfio/%s", dev_name(dev)); |