projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8bae1b2
)
net: irda: init spinlock after memcpy
author
Deepak Saxena
<
[email protected]
>
Mon, 27 Jul 2009 17:49:44 +0000
(10:49 -0700)
committer
David S. Miller
<
[email protected]
>
Mon, 27 Jul 2009 17:49:44 +0000
(10:49 -0700)
irttp_dup() copies a tsap_cb struct, but does not initialize the
spinlock in the new structure, which confuses lockdep.
Signed-off-by: Deepak Saxena <
[email protected]
>
Signed-off-by: Ingo Molnar <
[email protected]
>
Signed-off-by: Thomas Gleixner <
[email protected]
>
Signed-off-by: David S. Miller <
[email protected]
>
net/irda/irttp.c
patch
|
blob
|
history
diff --git
a/net/irda/irttp.c
b/net/irda/irttp.c
index ecf4eb2717cb0c4d75b77aa006c8d15235c7d867..9cb79f95bf63953c9bcdf2b379b4ccbb37089ff5 100644
(file)
--- a/
net/irda/irttp.c
+++ b/
net/irda/irttp.c
@@
-1453,6
+1453,7
@@
struct tsap_cb *irttp_dup(struct tsap_cb *orig, void *instance)
}
/* Dup */
memcpy(new, orig, sizeof(struct tsap_cb));
+ spin_lock_init(&new->lock);
/* We don't need the old instance any more */
spin_unlock_irqrestore(&irttp->tsaps->hb_spinlock, flags);