[3/3] scsi: fdomain_isa: use CFG1_IRQ_MASK
diff mbox series

Message ID b99d3b36-c8ca-3d0e-0a83-d03c61a90234@cogentembedded.com
State Accepted
Headers show
Series
  • Fix more magic values in the Future Domain drivers
Related show

Commit Message

Sergei Shtylyov July 16, 2019, 8:41 p.m. UTC
Commit 1697c6a64c49 ("scsi: fdomain: Add register definitions") somehow
missed the uses of CFG1_IRQ_MASK in the Futire Domain ISA driver, leaving
the magic numbers intact.  Fix this issue (with no change in the generated 
object file), removing an excess empty line, while at it...

Fixes: 1697c6a64c49 ("scsi: fdomain: Add register definitions")
Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>

---
 drivers/scsi/fdomain_isa.c |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Patch
diff mbox series

Index: linux/drivers/scsi/fdomain_isa.c
===================================================================
--- linux.orig/drivers/scsi/fdomain_isa.c
+++ linux/drivers/scsi/fdomain_isa.c
@@ -131,8 +131,7 @@  static int fdomain_isa_match(struct devi
 	if (!request_region(base, FDOMAIN_REGION_SIZE, "fdomain_isa"))
 		return 0;
 
-	irq = irqs[(inb(base + REG_CFG1) & 0x0e) >> 1];
-
+	irq = irqs[(inb(base + REG_CFG1) & CFG1_IRQ_MASK) >> 1];
 
 	if (sig)
 		this_id = sig->this_id;
@@ -164,7 +163,7 @@  static int fdomain_isa_param_match(struc
 	}
 
 	if (irq_ <= 0)
-		irq_ = irqs[(inb(io[ndev] + REG_CFG1) & 0x0e) >> 1];
+		irq_ = irqs[(inb(io[ndev] + REG_CFG1) & CFG1_IRQ_MASK) >> 1];
 
 	sh = fdomain_create(io[ndev], irq_, scsi_id[ndev], dev);
 	if (!sh) {