projects
/
firefly-linux-kernel-4.4.55.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
604631f
)
staging: dgap: redundant NULL and magic check in dgap_get_modem_info()
author
Daeseok Youn
<daeseok.youn@gmail.com>
Fri, 11 Jul 2014 10:22:04 +0000
(19:22 +0900)
committer
Greg Kroah-Hartman
<gregkh@linuxfoundation.org>
Sat, 12 Jul 2014 00:35:45 +0000
(17:35 -0700)
The "ch" is already checking in caller.
Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/dgap/dgap.c
patch
|
blob
|
history
diff --git
a/drivers/staging/dgap/dgap.c
b/drivers/staging/dgap/dgap.c
index 9affc5bf7228ac283d7fc7fdf1d0cc23952df1e6..79ea11696a23a247d5f3a3ede126c7297eef1d6c 100644
(file)
--- a/
drivers/staging/dgap/dgap.c
+++ b/
drivers/staging/dgap/dgap.c
@@
-3061,9
+3061,6
@@
static int dgap_get_modem_info(struct channel_t *ch, unsigned int __user *value)
ulong lock_flags;
int rc;
- if (!ch || ch->magic != DGAP_CHANNEL_MAGIC)
- return -EIO;
-
spin_lock_irqsave(&ch->ch_lock, lock_flags);
mstat = readb(&(ch->ch_bs->m_stat));