lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20220814064337.32621-9-91tuocao@gmail.com>
Date:   Sun, 14 Aug 2022 14:43:36 +0800
From:   Tuo Cao <91tuocao@...il.com>
To:     James.Bottomley@...senPartnership.com, martin.petersen@...cle.com,
        khalid@...ehiking.org, willy@...radead.org, hare@...e.com
Cc:     anil.gurumurthy@...gic.com, sudarsana.kalluru@...gic.com,
        linux-scsi@...r.kernel.org, linux-kernel@...r.kernel.org,
        91tuocao@...il.com
Subject: [PATCH 8/9] scsi: aha1740: move spin_lock_irqsave to spin_lock in interrupt handler

it is unnecessary to call spin_lock_irqsave in a interrupt handler.

Signed-off-by: Tuo Cao <91tuocao@...il.com>
---
 drivers/scsi/aha1740.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/drivers/scsi/aha1740.c b/drivers/scsi/aha1740.c
index 134255751819..c4f46ab927d1 100644
--- a/drivers/scsi/aha1740.c
+++ b/drivers/scsi/aha1740.c
@@ -218,14 +218,13 @@ static irqreturn_t aha1740_intr_handle(int irq, void *dev_id)
 	struct ecb *ecbptr;
 	struct scsi_cmnd *SCtmp;
 	unsigned int base;
-	unsigned long flags;
 	int handled = 0;
 	struct aha1740_sg *sgptr;
 	struct eisa_device *edev;
 	
 	if (!host)
 		panic("aha1740.c: Irq from unknown host!\n");
-	spin_lock_irqsave(host->host_lock, flags);
+	spin_lock(host->host_lock);
 	base = host->io_port;
 	number_serviced = 0;
 	edev = HOSTDATA(host)->edev;
@@ -315,7 +314,7 @@ static irqreturn_t aha1740_intr_handle(int irq, void *dev_id)
 		number_serviced++;
 	}
 
-	spin_unlock_irqrestore(host->host_lock, flags);
+	spin_unlock(host->host_lock);
 	return IRQ_RETVAL(handled);
 }
 
-- 
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ