projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
38eb712
)
atmel: at76c50x: use DEFINE_MUTEX() for mutex lock
author
Zheng Yongjun
<zhengyongjun3@huawei.com>
Thu, 24 Dec 2020 13:24:56 +0000
(21:24 +0800)
committer
Kalle Valo
<kvalo@codeaurora.org>
Mon, 8 Feb 2021 11:14:43 +0000
(13:14 +0200)
mutex lock can be initialized automatically with DEFINE_MUTEX()
rather than explicitly calling mutex_init().
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link:
https://lore.kernel.org/r/20201224132456.31341-1-zhengyongjun3@huawei.com
drivers/net/wireless/atmel/at76c50x-usb.c
patch
|
blob
|
history
diff --git
a/drivers/net/wireless/atmel/at76c50x-usb.c
b/drivers/net/wireless/atmel/at76c50x-usb.c
index 4042578000331e54d3ec9c73c996877c1d35b1a2..7582761c61e2c98165936ced97803f361767a1a7 100644
(file)
--- a/
drivers/net/wireless/atmel/at76c50x-usb.c
+++ b/
drivers/net/wireless/atmel/at76c50x-usb.c
@@
-101,7
+101,7
@@
do { \
static uint at76_debug = DBG_DEFAULTS;
/* Protect against concurrent firmware loading and parsing */
-static
struct mutex fw_mutex
;
+static
DEFINE_MUTEX(fw_mutex)
;
static struct fwentry firmwares[] = {
[0] = { "" },
@@
-2572,8
+2572,6
@@
static int __init at76_mod_init(void)
printk(KERN_INFO DRIVER_DESC " " DRIVER_VERSION " loading\n");
- mutex_init(&fw_mutex);
-
/* register this driver with the USB subsystem */
result = usb_register(&at76_driver);
if (result < 0)