]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
staging: unisys: visorchannel: Describe spinlocks in VISORCHANNEL_Tag struct
authorBryan Thompson <bryan.thompson@unisys.com>
Fri, 5 Dec 2014 22:09:24 +0000 (17:09 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 10 Jan 2015 01:32:35 +0000 (17:32 -0800)
Add comments indicating the requirements and use of the insert_lock and
remove_lock in the VISORCHANNEL_Tag structure.

Signed-off-by: Bryan Thompson <bryan.thompson@unisys.com>
Signed-off-by: Benjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/unisys/visorchannel/visorchannel_funcs.c

index 1568b95ded47dd6145310bed1b80435a6aff406d..1ce25c237d39f8f0c240565f86448a4c3667a10c 100644 (file)
@@ -33,9 +33,10 @@ struct VISORCHANNEL_Tag {
        struct channel_header chan_hdr;
        uuid_le guid;
        ulong size;
-       BOOL needs_lock;
-       spinlock_t insert_lock;
-       spinlock_t remove_lock;
+       BOOL needs_lock;        /* channel creator knows if more than one
+                                * thread will be inserting or removing */
+       spinlock_t insert_lock; /* protect head writes in chan_hdr */
+       spinlock_t remove_lock; /* protect tail writes in chan_hdr */
 
        struct {
                struct signal_queue_header req_queue;