staging/rdma/hfi1: Add comment for spinlock_t definition
authorJubin John <jubin.john@intel.com>
Mon, 15 Feb 2016 04:21:34 +0000 (20:21 -0800)
committerDoug Ledford <dledford@redhat.com>
Fri, 11 Mar 2016 01:45:40 +0000 (20:45 -0500)
Add comments describing the spinlock for spinlock_t definitions to
fix checkpatch check:
CHECK: spinlock_t definition without comment

Reviewed-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Reviewed-by: Ira Weiny <ira.weiny@intel.com>
Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Signed-off-by: Jubin John <jubin.john@intel.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/staging/rdma/hfi1/hfi.h
drivers/staging/rdma/hfi1/qsfp.h
drivers/staging/rdma/hfi1/sdma.h

index 805535eca040cae80bb6c5d16664908e50c2a442..774d8ffa94efbef47c0c666fc4ed4cd96eec2774 100644 (file)
@@ -313,6 +313,7 @@ struct hfi1_ctxtdata {
         */
        struct task_struct *progress;
        struct list_head sdma_queues;
+       /* protect sdma queues */
        spinlock_t sdma_qlock;
 
        /* Is ASPM interrupt supported for this context */
@@ -380,6 +381,7 @@ struct hfi1_snoop_data {
        int mode_flag;
        struct cdev cdev;
        struct device *class_dev;
+       /* protect snoop data */
        spinlock_t snoop_lock;
        struct list_head queue;
        wait_queue_head_t waitq;
@@ -561,6 +563,7 @@ enum {
 };
 
 struct vl_arb_cache {
+       /* protect vl arb cache */
        spinlock_t lock;
        struct ib_vl_weight_elem table[VL_ARB_TABLE_SIZE];
 };
index 9f6e2f301040f4edc1ad1897e607923571a64039..c391750bf9d2d44736bf6555e2d0100ccb5d720f 100644 (file)
@@ -215,6 +215,7 @@ struct qsfp_data {
        struct hfi1_pportdata *ppd;
        struct work_struct qsfp_work;
        u8 cache[QSFP_MAX_NUM_PAGES * 128];
+       /* protect qsfp data */
        spinlock_t qsfp_lock;
        u8 check_interrupt_flags;
        u8 reset_needed;
index 0c5f501ee937bf65d9d598dcbc76ec5f6501806e..5aec18b58189d2e81b2a8471da6dd0ed00cf3bce 100644 (file)
@@ -412,6 +412,7 @@ struct sdma_engine {
        u32                   progress_check_head;
        /* private: */
        struct work_struct flush_worker;
+       /* protect flush list */
        spinlock_t flushlist_lock;
        /* private: */
        struct list_head flushlist;