Commit 311e87b7 authored by Shixin Liu's avatar Shixin Liu Committed by Martin K. Petersen

scsi: megaraid_sas: Use DEFINE_SPINLOCK() for spinlock

spinlock can be initialized automatically with DEFINE_SPINLOCK() rather
than explicitly calling spin_lock_init().

Link: https://lore.kernel.org/r/20210329094532.4165147-1-liushixin2@huawei.comAcked-by: default avatarSumit Saxena <sumit.saxena@broadcom.com>
Signed-off-by: default avatarShixin Liu <liushixin2@huawei.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 807b31d8
......@@ -213,7 +213,7 @@ static bool support_nvme_encapsulation;
static bool support_pci_lane_margining;
/* define lock for aen poll */
static spinlock_t poll_aen_lock;
static DEFINE_SPINLOCK(poll_aen_lock);
extern struct dentry *megasas_debugfs_root;
extern int megasas_blk_mq_poll(struct Scsi_Host *shost, unsigned int queue_num);
......@@ -8934,8 +8934,6 @@ static int __init megasas_init(void)
*/
pr_info("megasas: %s\n", MEGASAS_VERSION);
spin_lock_init(&poll_aen_lock);
support_poll_for_event = 2;
support_device_change = 1;
support_nvme_encapsulation = true;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment