[PATCH 05/10] staging: unisys: added spinlock comments visorchannel_funcs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This patch adds comment documentation to visorchannel_tag struct

Signed-off-by: Erik Arfvidson <erik.arfvidson@xxxxxxxxxx>
---
 drivers/staging/unisys/visorchannel/visorchannel_funcs.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/drivers/staging/unisys/visorchannel/visorchannel_funcs.c b/drivers/staging/unisys/visorchannel/visorchannel_funcs.c
index c24052b..0490194 100644
--- a/drivers/staging/unisys/visorchannel/visorchannel_funcs.c
+++ b/drivers/staging/unisys/visorchannel/visorchannel_funcs.c
@@ -33,9 +33,13 @@ 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; /* Some channels don't need lock due to simplicity */
+	/* The guest can remove from certain queues, but cannot insert into
+	 * those queues. The guest can insert into other queues, but can't
+	 * remove from those queues . This is based on the queue type.
+	 */
+	spinlock_t insert_lock; /* Protects queue insertion variables */
+	spinlock_t remove_lock; /* Protects queue from removal variables */
 
 	struct {
 		struct signal_queue_header req_queue;
-- 
1.9.1

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux