projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
dt-bindings: PCI: rockchip: Add DT bindings for Rockchip PCIe controller
[firefly-linux-kernel-4.4.55.git]
/
fs
/
ncpfs
/
ioctl.c
diff --git
a/fs/ncpfs/ioctl.c
b/fs/ncpfs/ioctl.c
index 79b113048eacdc645fb67994cb0dcb25aad84dd0..0a3f9b594602341350afb79f27ba2cd8191468e8 100644
(file)
--- a/
fs/ncpfs/ioctl.c
+++ b/
fs/ncpfs/ioctl.c
@@
-525,6
+525,8
@@
static long __ncp_ioctl(struct inode *inode, unsigned int cmd, unsigned long arg
switch (rqdata.cmd) {
case NCP_LOCK_EX:
case NCP_LOCK_SH:
+ if (rqdata.timeout < 0)
+ return -EINVAL;
if (rqdata.timeout == 0)
rqdata.timeout = NCP_LOCK_DEFAULT_TIMEOUT;
else if (rqdata.timeout > NCP_LOCK_MAX_TIMEOUT)