aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/pcmcia/nsp_cs.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/pcmcia/nsp_cs.c')
-rw-r--r--drivers/scsi/pcmcia/nsp_cs.c23
1 files changed, 5 insertions, 18 deletions
diff --git a/drivers/scsi/pcmcia/nsp_cs.c b/drivers/scsi/pcmcia/nsp_cs.c
index 02124645487..0f0e112c3f8 100644
--- a/drivers/scsi/pcmcia/nsp_cs.c
+++ b/drivers/scsi/pcmcia/nsp_cs.c
@@ -1563,13 +1563,6 @@ static int nsp_cs_probe(struct pcmcia_device *link)
1563 link->io.Attributes1 = IO_DATA_PATH_WIDTH_AUTO; 1563 link->io.Attributes1 = IO_DATA_PATH_WIDTH_AUTO;
1564 link->io.IOAddrLines = 10; /* not used */ 1564 link->io.IOAddrLines = 10; /* not used */
1565 1565
1566 /* Interrupt setup */
1567 link->irq.Attributes = IRQ_TYPE_EXCLUSIVE;
1568
1569 /* Interrupt handler */
1570 link->irq.Handler = &nspintr;
1571 link->irq.Attributes |= IRQF_SHARED;
1572
1573 /* General socket configuration */ 1566 /* General socket configuration */
1574 link->conf.Attributes = CONF_ENABLE_IRQ; 1567 link->conf.Attributes = CONF_ENABLE_IRQ;
1575 link->conf.IntType = INT_MEMORY_AND_IO; 1568 link->conf.IntType = INT_MEMORY_AND_IO;
@@ -1646,8 +1639,7 @@ static int nsp_cs_config_check(struct pcmcia_device *p_dev,
1646 } 1639 }
1647 1640
1648 /* Do we need to allocate an interrupt? */ 1641 /* Do we need to allocate an interrupt? */
1649 if (cfg->irq.IRQInfo1 || dflt->irq.IRQInfo1) 1642 p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
1650 p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
1651 1643
1652 /* IO window settings */ 1644 /* IO window settings */
1653 p_dev->io.NumPorts1 = p_dev->io.NumPorts2 = 0; 1645 p_dev->io.NumPorts1 = p_dev->io.NumPorts2 = 0;
@@ -1720,10 +1712,8 @@ static int nsp_cs_config(struct pcmcia_device *link)
1720 if (ret) 1712 if (ret)
1721 goto cs_failed; 1713 goto cs_failed;
1722 1714
1723 if (link->conf.Attributes & CONF_ENABLE_IRQ) { 1715 if (pcmcia_request_irq(link, nspintr))
1724 if (pcmcia_request_irq(link, &link->irq)) 1716 goto cs_failed;
1725 goto cs_failed;
1726 }
1727 1717
1728 ret = pcmcia_request_configuration(link, &link->conf); 1718 ret = pcmcia_request_configuration(link, &link->conf);
1729 if (ret) 1719 if (ret)
@@ -1741,7 +1731,7 @@ static int nsp_cs_config(struct pcmcia_device *link)
1741 /* Set port and IRQ */ 1731 /* Set port and IRQ */
1742 data->BaseAddress = link->io.BasePort1; 1732 data->BaseAddress = link->io.BasePort1;
1743 data->NumAddress = link->io.NumPorts1; 1733 data->NumAddress = link->io.NumPorts1;
1744 data->IrqNumber = link->irq.AssignedIRQ; 1734 data->IrqNumber = link->irq;
1745 1735
1746 nsp_dbg(NSP_DEBUG_INIT, "I/O[0x%x+0x%x] IRQ %d", 1736 nsp_dbg(NSP_DEBUG_INIT, "I/O[0x%x+0x%x] IRQ %d",
1747 data->BaseAddress, data->NumAddress, data->IrqNumber); 1737 data->BaseAddress, data->NumAddress, data->IrqNumber);
@@ -1764,8 +1754,6 @@ static int nsp_cs_config(struct pcmcia_device *link)
1764 1754
1765 scsi_scan_host(host); 1755 scsi_scan_host(host);
1766 1756
1767 snprintf(info->node.dev_name, sizeof(info->node.dev_name), "scsi%d", host->host_no);
1768 link->dev_node = &info->node;
1769 info->host = host; 1757 info->host = host;
1770 1758
1771 /* Finally, report what we've done */ 1759 /* Finally, report what we've done */
@@ -1775,7 +1763,7 @@ static int nsp_cs_config(struct pcmcia_device *link)
1775 printk(", Vpp %d.%d", link->conf.Vpp/10, link->conf.Vpp%10); 1763 printk(", Vpp %d.%d", link->conf.Vpp/10, link->conf.Vpp%10);
1776 } 1764 }
1777 if (link->conf.Attributes & CONF_ENABLE_IRQ) { 1765 if (link->conf.Attributes & CONF_ENABLE_IRQ) {
1778 printk(", irq %d", link->irq.AssignedIRQ); 1766 printk(", irq %d", link->irq);
1779 } 1767 }
1780 if (link->io.NumPorts1) { 1768 if (link->io.NumPorts1) {
1781 printk(", io 0x%04x-0x%04x", link->io.BasePort1, 1769 printk(", io 0x%04x-0x%04x", link->io.BasePort1,
@@ -1823,7 +1811,6 @@ static void nsp_cs_release(struct pcmcia_device *link)
1823 if (info->host != NULL) { 1811 if (info->host != NULL) {
1824 scsi_remove_host(info->host); 1812 scsi_remove_host(info->host);
1825 } 1813 }
1826 link->dev_node = NULL;
1827 1814
1828 if (link->win) { 1815 if (link->win) {
1829 if (data != NULL) { 1816 if (data != NULL) {