pcmcia: convert pcmcia_request_configuration to pcmcia_enable_device
pcmcia_enable_device() now replaces pcmcia_request_configuration(). Instead of config_req_t, all necessary flags are either passed as a parameter to pcmcia_enable_device(), or (in rare circumstances) set in struct pcmcia_device -> flags. With the last remaining user of include/pcmcia/cs.h gone, remove all references. CC: netdev@vger.kernel.org CC: linux-wireless@vger.kernel.org CC: linux-ide@vger.kernel.org CC: linux-usb@vger.kernel.org CC: laforge@gnumonks.org CC: linux-mtd@lists.infradead.org CC: alsa-devel@alsa-project.org CC: linux-serial@vger.kernel.org CC: Jiri Kosina <jkosina@suse.cz> CC: linux-scsi@vger.kernel.org Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> (for drivers/bluetooth) Tested-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
This commit is contained in:
parent
7feabb6412
commit
1ac71e5a35
90 changed files with 179 additions and 395 deletions
|
@ -1,4 +1,10 @@
|
||||||
This file details changes in 2.6 which affect PCMCIA card driver authors:
|
This file details changes in 2.6 which affect PCMCIA card driver authors:
|
||||||
|
* pcmcia_request_configuration -> pcmcia_enable_device (as of 2.6.36)
|
||||||
|
pcmcia_request_configuration() got renamed to pcmcia_enable_device(),
|
||||||
|
as it mirrors pcmcia_disable_device(). Configuration settings are now
|
||||||
|
stored in struct pcmcia_device, e.g. in the fields config_flags,
|
||||||
|
config_index, config_base, vpp.
|
||||||
|
|
||||||
* pcmcia_request_window changes (as of 2.6.36)
|
* pcmcia_request_window changes (as of 2.6.36)
|
||||||
Instead of win_req_t, drivers are now requested to fill out
|
Instead of win_req_t, drivers are now requested to fill out
|
||||||
struct pcmcia_device *p_dev->resource[2,3,4,5] for up to four ioport
|
struct pcmcia_device *p_dev->resource[2,3,4,5] for up to four ioport
|
||||||
|
|
|
@ -34,7 +34,6 @@
|
||||||
#include <linux/ata.h>
|
#include <linux/ata.h>
|
||||||
#include <linux/libata.h>
|
#include <linux/libata.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
|
@ -249,7 +248,7 @@ static int pcmcia_init_one(struct pcmcia_device *pdev)
|
||||||
/* Set up attributes in order to probe card and get resources */
|
/* Set up attributes in order to probe card and get resources */
|
||||||
pdev->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
pdev->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
pdev->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
pdev->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
pdev->conf.Attributes = CONF_ENABLE_IRQ;
|
pdev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* See if we have a manufacturer identifier. Use it to set is_kme for
|
/* See if we have a manufacturer identifier. Use it to set is_kme for
|
||||||
vendor quirks */
|
vendor quirks */
|
||||||
|
@ -275,7 +274,7 @@ static int pcmcia_init_one(struct pcmcia_device *pdev)
|
||||||
if (!pdev->irq)
|
if (!pdev->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(pdev, &pdev->conf);
|
ret = pcmcia_enable_device(pdev);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -39,7 +39,6 @@
|
||||||
#include <linux/skbuff.h>
|
#include <linux/skbuff.h>
|
||||||
#include <linux/io.h>
|
#include <linux/io.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -865,7 +864,7 @@ static int bluecard_probe(struct pcmcia_device *link)
|
||||||
info->p_dev = link;
|
info->p_dev = link;
|
||||||
link->priv = info;
|
link->priv = info;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
return bluecard_config(link);
|
return bluecard_config(link);
|
||||||
}
|
}
|
||||||
|
@ -905,7 +904,7 @@ static int bluecard_config(struct pcmcia_device *link)
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -45,7 +45,6 @@
|
||||||
#include <linux/device.h>
|
#include <linux/device.h>
|
||||||
#include <linux/firmware.h>
|
#include <linux/firmware.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -660,7 +659,7 @@ static int bt3c_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
link->resource[0]->end = 8;
|
link->resource[0]->end = 8;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
return bt3c_config(link);
|
return bt3c_config(link);
|
||||||
}
|
}
|
||||||
|
@ -741,7 +740,7 @@ found_port:
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -41,7 +41,6 @@
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -589,7 +588,7 @@ static int btuart_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
link->resource[0]->end = 8;
|
link->resource[0]->end = 8;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
return btuart_config(link);
|
return btuart_config(link);
|
||||||
}
|
}
|
||||||
|
@ -670,7 +669,7 @@ found_port:
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -41,7 +41,6 @@
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -575,7 +574,7 @@ static int dtl1_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
link->resource[0]->end = 8;
|
link->resource[0]->end = 8;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
return dtl1_config(link);
|
return dtl1_config(link);
|
||||||
}
|
}
|
||||||
|
@ -619,7 +618,7 @@ static int dtl1_config(struct pcmcia_device *link)
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -34,7 +34,6 @@
|
||||||
#include <linux/uaccess.h>
|
#include <linux/uaccess.h>
|
||||||
#include <linux/io.h>
|
#include <linux/io.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
@ -1767,7 +1766,7 @@ static int cm4000_config(struct pcmcia_device * link, int devno)
|
||||||
if (pcmcia_loop_config(link, cm4000_config_check, NULL))
|
if (pcmcia_loop_config(link, cm4000_config_check, NULL))
|
||||||
goto cs_release;
|
goto cs_release;
|
||||||
|
|
||||||
if (pcmcia_request_configuration(link, &link->conf))
|
if (pcmcia_enable_device(link))
|
||||||
goto cs_release;
|
goto cs_release;
|
||||||
|
|
||||||
dev = link->priv;
|
dev = link->priv;
|
||||||
|
|
|
@ -29,7 +29,6 @@
|
||||||
#include <asm/uaccess.h>
|
#include <asm/uaccess.h>
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
@ -547,10 +546,10 @@ static int reader_config(struct pcmcia_device *link, int devno)
|
||||||
if (pcmcia_loop_config(link, cm4040_config_check, NULL))
|
if (pcmcia_loop_config(link, cm4040_config_check, NULL))
|
||||||
goto cs_release;
|
goto cs_release;
|
||||||
|
|
||||||
fail_rc = pcmcia_request_configuration(link, &link->conf);
|
fail_rc = pcmcia_enable_device(link);
|
||||||
if (fail_rc != 0) {
|
if (fail_rc != 0) {
|
||||||
dev_printk(KERN_INFO, &link->dev,
|
dev_printk(KERN_INFO, &link->dev,
|
||||||
"pcmcia_request_configuration failed 0x%x\n",
|
"pcmcia_enable_device failed 0x%x\n",
|
||||||
fail_rc);
|
fail_rc);
|
||||||
goto cs_release;
|
goto cs_release;
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,7 +32,6 @@
|
||||||
#include <pcmcia/device_id.h>
|
#include <pcmcia/device_id.h>
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
|
|
||||||
static struct pcmcia_device_id ipw_ids[] = {
|
static struct pcmcia_device_id ipw_ids[] = {
|
||||||
PCMCIA_DEVICE_MANF_CARD(0x02f2, 0x0100),
|
PCMCIA_DEVICE_MANF_CARD(0x02f2, 0x0100),
|
||||||
|
@ -172,7 +171,7 @@ static int config_ipwireless(struct ipw_dev *ipw)
|
||||||
if (ret != 0)
|
if (ret != 0)
|
||||||
return ret;
|
return ret;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
INIT_WORK(&ipw->work_reboot, signalled_reboot_work);
|
INIT_WORK(&ipw->work_reboot, signalled_reboot_work);
|
||||||
|
|
||||||
|
@ -210,8 +209,7 @@ static int config_ipwireless(struct ipw_dev *ipw)
|
||||||
* Do the RequestConfiguration last, because it enables interrupts.
|
* Do the RequestConfiguration last, because it enables interrupts.
|
||||||
* Then we don't get any interrupts before we're ready for them.
|
* Then we don't get any interrupts before we're ready for them.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
|
|
||||||
if (ret != 0)
|
if (ret != 0)
|
||||||
goto exit;
|
goto exit;
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,6 @@
|
||||||
#include <linux/sched.h>
|
#include <linux/sched.h>
|
||||||
#include <linux/types.h>
|
#include <linux/types.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
|
|
@ -21,7 +21,6 @@
|
||||||
#include <linux/types.h>
|
#include <linux/types.h>
|
||||||
#include <linux/sched.h>
|
#include <linux/sched.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
|
|
@ -70,7 +70,6 @@
|
||||||
#include <linux/workqueue.h>
|
#include <linux/workqueue.h>
|
||||||
#include <linux/hdlc.h>
|
#include <linux/hdlc.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -550,8 +549,6 @@ static int mgslpc_probe(struct pcmcia_device *link)
|
||||||
|
|
||||||
/* Initialize the struct pcmcia_device structure */
|
/* Initialize the struct pcmcia_device structure */
|
||||||
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
ret = mgslpc_config(link);
|
ret = mgslpc_config(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
return ret;
|
return ret;
|
||||||
|
@ -593,14 +590,14 @@ static int mgslpc_config(struct pcmcia_device *link)
|
||||||
if (ret != 0)
|
if (ret != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_index = 8;
|
link->config_index = 8;
|
||||||
link->config_regs = PRESENT_OPTION;
|
link->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
ret = pcmcia_request_irq(link, mgslpc_isr);
|
ret = pcmcia_request_irq(link, mgslpc_isr);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
@ -609,8 +606,7 @@ static int mgslpc_config(struct pcmcia_device *link)
|
||||||
|
|
||||||
dev_info(&link->dev, "index 0x%02x:",
|
dev_info(&link->dev, "index 0x%02x:",
|
||||||
link->config_index);
|
link->config_index);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %d", link->irq);
|
||||||
printk(", irq %d", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(", io %pR", link->resource[0]);
|
printk(", io %pR", link->resource[0]);
|
||||||
printk("\n");
|
printk("\n");
|
||||||
|
|
|
@ -43,7 +43,6 @@
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
|
@ -99,7 +98,7 @@ static int ide_probe(struct pcmcia_device *link)
|
||||||
|
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
return ide_config(link);
|
return ide_config(link);
|
||||||
} /* ide_attach */
|
} /* ide_attach */
|
||||||
|
@ -284,7 +283,8 @@ static int ide_config(struct pcmcia_device *link)
|
||||||
|
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
|
||||||
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,6 @@
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -79,7 +78,7 @@ static int avmcs_probe(struct pcmcia_device *p_dev)
|
||||||
p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
|
|
||||||
/* General socket configuration */
|
/* General socket configuration */
|
||||||
p_dev->conf.Attributes = CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
p_dev->config_index = 1;
|
p_dev->config_index = 1;
|
||||||
p_dev->config_regs = PRESENT_OPTION;
|
p_dev->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
|
@ -149,7 +148,7 @@ static int avmcs_config(struct pcmcia_device *link)
|
||||||
/*
|
/*
|
||||||
* configure the PCMCIA socket
|
* configure the PCMCIA socket
|
||||||
*/
|
*/
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0) {
|
if (i != 0) {
|
||||||
pcmcia_disable_device(link);
|
pcmcia_disable_device(link);
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -20,7 +20,6 @@
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include "hisax_cfg.h"
|
#include "hisax_cfg.h"
|
||||||
|
@ -84,7 +83,7 @@ static int __devinit avma1cs_probe(struct pcmcia_device *p_dev)
|
||||||
p_dev->resource[1]->flags |= IO_DATA_PATH_WIDTH_16;
|
p_dev->resource[1]->flags |= IO_DATA_PATH_WIDTH_16;
|
||||||
|
|
||||||
/* General socket configuration */
|
/* General socket configuration */
|
||||||
p_dev->conf.Attributes = CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
p_dev->config_index = 1;
|
p_dev->config_index = 1;
|
||||||
p_dev->config_regs = PRESENT_OPTION;
|
p_dev->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
|
@ -160,7 +159,7 @@ static int __devinit avma1cs_config(struct pcmcia_device *link)
|
||||||
/*
|
/*
|
||||||
* configure the PCMCIA socket
|
* configure the PCMCIA socket
|
||||||
*/
|
*/
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0) {
|
if (i != 0) {
|
||||||
pcmcia_disable_device(link);
|
pcmcia_disable_device(link);
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -46,7 +46,6 @@
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -129,8 +128,6 @@ static int __devinit elsa_cs_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->end = 8;
|
link->resource[0]->end = 8;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
|
||||||
|
|
||||||
return elsa_cs_config(link);
|
return elsa_cs_config(link);
|
||||||
} /* elsa_cs_attach */
|
} /* elsa_cs_attach */
|
||||||
|
|
||||||
|
@ -205,15 +202,14 @@ static int __devinit elsa_cs_config(struct pcmcia_device *link)
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
/* Finally, report what we've done */
|
/* Finally, report what we've done */
|
||||||
dev_info(&link->dev, "index 0x%02x: ",
|
dev_info(&link->dev, "index 0x%02x: ",
|
||||||
link->config_index);
|
link->config_index);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %d", link->irq);
|
||||||
printk(", irq %d", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(" & %pR", link->resource[0]);
|
printk(" & %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -46,7 +46,6 @@
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -132,8 +131,6 @@ static int __devinit sedlbauer_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->end = 8;
|
link->resource[0]->end = 8;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
return sedlbauer_config(link);
|
return sedlbauer_config(link);
|
||||||
} /* sedlbauer_attach */
|
} /* sedlbauer_attach */
|
||||||
|
|
||||||
|
@ -175,7 +172,7 @@ static int sedlbauer_config_check(struct pcmcia_device *p_dev,
|
||||||
|
|
||||||
/* Does this card need audio output? */
|
/* Does this card need audio output? */
|
||||||
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_SPKR;
|
p_dev->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
/* Use power settings for Vcc and Vpp if present */
|
/* Use power settings for Vcc and Vpp if present */
|
||||||
/* Note that the CIS values need to be rescaled */
|
/* Note that the CIS values need to be rescaled */
|
||||||
|
@ -192,7 +189,7 @@ static int sedlbauer_config_check(struct pcmcia_device *p_dev,
|
||||||
else if (dflt->vpp1.present & (1<<CISTPL_POWER_VNOM))
|
else if (dflt->vpp1.present & (1<<CISTPL_POWER_VNOM))
|
||||||
p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM]/10000;
|
p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM]/10000;
|
||||||
|
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -247,7 +244,7 @@ static int __devinit sedlbauer_config(struct pcmcia_device *link)
|
||||||
the I/O windows and the interrupt mapping, and putting the
|
the I/O windows and the interrupt mapping, and putting the
|
||||||
card and host interface into "Memory and IO" mode.
|
card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
@ -256,8 +253,7 @@ static int __devinit sedlbauer_config(struct pcmcia_device *link)
|
||||||
link->config_index);
|
link->config_index);
|
||||||
if (link->vpp)
|
if (link->vpp)
|
||||||
printk(", Vpp %d.%d", link->vpp/10, link->vpp%10);
|
printk(", Vpp %d.%d", link->vpp/10, link->vpp%10);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %d", link->irq);
|
||||||
printk(", irq %d", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(" & %pR", link->resource[0]);
|
printk(" & %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -27,7 +27,6 @@
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -109,7 +108,7 @@ static int __devinit teles_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->end = 96;
|
link->resource[0]->end = 96;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
return teles_cs_config(link);
|
return teles_cs_config(link);
|
||||||
} /* teles_attach */
|
} /* teles_attach */
|
||||||
|
@ -185,15 +184,14 @@ static int __devinit teles_cs_config(struct pcmcia_device *link)
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto cs_failed;
|
goto cs_failed;
|
||||||
|
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
goto cs_failed;
|
goto cs_failed;
|
||||||
|
|
||||||
/* Finally, report what we've done */
|
/* Finally, report what we've done */
|
||||||
dev_info(&link->dev, "index 0x%02x:",
|
dev_info(&link->dev, "index 0x%02x:",
|
||||||
link->config_index);
|
link->config_index);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %d", link->irq);
|
||||||
printk(", irq %d", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(" & %pR", link->resource[0]);
|
printk(" & %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -30,7 +30,6 @@
|
||||||
#include <linux/ioport.h>
|
#include <linux/ioport.h>
|
||||||
#include <linux/scatterlist.h>
|
#include <linux/scatterlist.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include <linux/io.h>
|
#include <linux/io.h>
|
||||||
|
|
|
@ -16,7 +16,6 @@
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -568,7 +567,6 @@ static int pcmciamtd_config(struct pcmcia_device *link)
|
||||||
dev->pcmcia_map.map_priv_2 = (unsigned long)link->resource[2];
|
dev->pcmcia_map.map_priv_2 = (unsigned long)link->resource[2];
|
||||||
|
|
||||||
dev->vpp = (vpp) ? vpp : link->socket->socket.Vpp;
|
dev->vpp = (vpp) ? vpp : link->socket->socket.Vpp;
|
||||||
link->conf.Attributes = 0;
|
|
||||||
if(setvpp == 2) {
|
if(setvpp == 2) {
|
||||||
link->vpp = dev->vpp;
|
link->vpp = dev->vpp;
|
||||||
} else {
|
} else {
|
||||||
|
@ -577,7 +575,7 @@ static int pcmciamtd_config(struct pcmcia_device *link)
|
||||||
|
|
||||||
link->config_index = 0;
|
link->config_index = 0;
|
||||||
DEBUG(2, "Setting Configuration");
|
DEBUG(2, "Setting Configuration");
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret != 0) {
|
if (ret != 0) {
|
||||||
if (dev->win_base) {
|
if (dev->win_base) {
|
||||||
iounmap(dev->win_base);
|
iounmap(dev->win_base);
|
||||||
|
@ -718,8 +716,6 @@ static int pcmciamtd_probe(struct pcmcia_device *link)
|
||||||
dev->p_dev = link;
|
dev->p_dev = link;
|
||||||
link->priv = dev;
|
link->priv = dev;
|
||||||
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
return pcmciamtd_config(link);
|
return pcmciamtd_config(link);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -87,7 +87,6 @@ earlier 3Com products.
|
||||||
#include <linux/bitops.h>
|
#include <linux/bitops.h>
|
||||||
#include <linux/mii.h>
|
#include <linux/mii.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
@ -280,7 +279,7 @@ static int tc574_probe(struct pcmcia_device *link)
|
||||||
spin_lock_init(&lp->window_lock);
|
spin_lock_init(&lp->window_lock);
|
||||||
link->resource[0]->end = 32;
|
link->resource[0]->end = 32;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_16;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_16;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_index = 1;
|
link->config_index = 1;
|
||||||
|
|
||||||
dev->netdev_ops = &el3_netdev_ops;
|
dev->netdev_ops = &el3_netdev_ops;
|
||||||
|
@ -351,7 +350,7 @@ static int tc574_config(struct pcmcia_device *link)
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -41,7 +41,6 @@
|
||||||
#include <linux/bitops.h>
|
#include <linux/bitops.h>
|
||||||
#include <linux/jiffies.h>
|
#include <linux/jiffies.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
@ -216,7 +215,7 @@ static int tc589_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->end = 16;
|
link->resource[0]->end = 16;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_16;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_16;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_index = 1;
|
link->config_index = 1;
|
||||||
|
|
||||||
dev->netdev_ops = &el3_netdev_ops;
|
dev->netdev_ops = &el3_netdev_ops;
|
||||||
|
@ -293,7 +292,7 @@ static int tc589_config(struct pcmcia_device *link)
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -39,7 +39,6 @@
|
||||||
#include <linux/mii.h>
|
#include <linux/mii.h>
|
||||||
#include "../8390.h"
|
#include "../8390.h"
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -166,7 +165,7 @@ static int axnet_probe(struct pcmcia_device *link)
|
||||||
info = PRIV(dev);
|
info = PRIV(dev);
|
||||||
info->p_dev = link;
|
info->p_dev = link;
|
||||||
link->priv = dev;
|
link->priv = dev;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
dev->netdev_ops = &axnet_netdev_ops;
|
dev->netdev_ops = &axnet_netdev_ops;
|
||||||
|
|
||||||
|
@ -332,11 +331,12 @@ static int axnet_config(struct pcmcia_device *link)
|
||||||
|
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
if (resource_size(link->resource[1]) == 8)
|
if (resource_size(link->resource[1]) == 8)
|
||||||
link->conf.Attributes |= CONF_ENABLE_SPKR;
|
link->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -43,7 +43,6 @@
|
||||||
#include <linux/arcdevice.h>
|
#include <linux/arcdevice.h>
|
||||||
#include <linux/com20020.h>
|
#include <linux/com20020.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -160,7 +159,7 @@ static int com20020_probe(struct pcmcia_device *p_dev)
|
||||||
|
|
||||||
p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
p_dev->resource[0]->end = 16;
|
p_dev->resource[0]->end = 16;
|
||||||
p_dev->conf.Attributes = CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
info->dev = dev;
|
info->dev = dev;
|
||||||
p_dev->priv = info;
|
p_dev->priv = info;
|
||||||
|
@ -281,7 +280,7 @@ static int com20020_config(struct pcmcia_device *link)
|
||||||
|
|
||||||
dev->irq = link->irq;
|
dev->irq = link->irq;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -49,7 +49,6 @@
|
||||||
#include <linux/ioport.h>
|
#include <linux/ioport.h>
|
||||||
#include <linux/crc32.h>
|
#include <linux/crc32.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -252,7 +251,7 @@ static int fmvj18x_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
|
|
||||||
/* General socket configuration */
|
/* General socket configuration */
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
dev->netdev_ops = &fjn_netdev_ops;
|
dev->netdev_ops = &fjn_netdev_ops;
|
||||||
dev->watchdog_timeo = TX_TIMEOUT;
|
dev->watchdog_timeo = TX_TIMEOUT;
|
||||||
|
@ -431,7 +430,7 @@ static int fmvj18x_config(struct pcmcia_device *link)
|
||||||
ret = pcmcia_request_irq(link, fjn_interrupt);
|
ret = pcmcia_request_irq(link, fjn_interrupt);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -57,7 +57,6 @@
|
||||||
#include <linux/trdevice.h>
|
#include <linux/trdevice.h>
|
||||||
#include <linux/ibmtr.h>
|
#include <linux/ibmtr.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -152,7 +151,7 @@ static int __devinit ibmtr_attach(struct pcmcia_device *link)
|
||||||
|
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
link->resource[0]->end = 4;
|
link->resource[0]->end = 4;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_regs = PRESENT_OPTION;
|
link->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
info->dev = dev;
|
info->dev = dev;
|
||||||
|
@ -269,7 +268,7 @@ static int __devinit ibmtr_config(struct pcmcia_device *link)
|
||||||
resource_size(link->resource[3]));
|
resource_size(link->resource[3]));
|
||||||
ti->sram_phys = link->resource[3]->start;
|
ti->sram_phys = link->resource[3]->start;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -146,7 +146,6 @@ Include Files
|
||||||
#include <linux/ioport.h>
|
#include <linux/ioport.h>
|
||||||
#include <linux/bitops.h>
|
#include <linux/bitops.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -460,7 +459,7 @@ static int nmclan_probe(struct pcmcia_device *link)
|
||||||
spin_lock_init(&lp->bank_lock);
|
spin_lock_init(&lp->bank_lock);
|
||||||
link->resource[0]->end = 32;
|
link->resource[0]->end = 32;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_index = 1;
|
link->config_index = 1;
|
||||||
link->config_regs = PRESENT_OPTION;
|
link->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
|
@ -649,7 +648,7 @@ static int nmclan_config(struct pcmcia_device *link)
|
||||||
ret = pcmcia_request_exclusive_irq(link, mace_interrupt);
|
ret = pcmcia_request_exclusive_irq(link, mace_interrupt);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -42,7 +42,6 @@
|
||||||
#include <linux/mii.h>
|
#include <linux/mii.h>
|
||||||
#include "../8390.h"
|
#include "../8390.h"
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -260,7 +259,7 @@ static int pcnet_probe(struct pcmcia_device *link)
|
||||||
info->p_dev = link;
|
info->p_dev = link;
|
||||||
link->priv = dev;
|
link->priv = dev;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
dev->netdev_ops = &pcnet_netdev_ops;
|
dev->netdev_ops = &pcnet_netdev_ops;
|
||||||
|
|
||||||
|
@ -560,13 +559,13 @@ static hw_info_t *pcnet_try_config(struct pcmcia_device *link,
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
if (resource_size(link->resource[1]) == 8)
|
if (resource_size(link->resource[1]) == 8)
|
||||||
link->conf.Attributes |= CONF_ENABLE_SPKR;
|
link->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
if ((link->manf_id == MANFID_IBM) &&
|
if ((link->manf_id == MANFID_IBM) &&
|
||||||
(link->card_id == PRODID_IBM_HOME_AND_AWAY))
|
(link->card_id == PRODID_IBM_HOME_AND_AWAY))
|
||||||
link->config_index |= 0x10;
|
link->config_index |= 0x10;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
|
|
|
@ -44,7 +44,6 @@
|
||||||
#include <linux/jiffies.h>
|
#include <linux/jiffies.h>
|
||||||
#include <linux/firmware.h>
|
#include <linux/firmware.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
@ -326,7 +325,7 @@ static int smc91c92_probe(struct pcmcia_device *link)
|
||||||
spin_lock_init(&smc->lock);
|
spin_lock_init(&smc->lock);
|
||||||
link->resource[0]->end = 16;
|
link->resource[0]->end = 16;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* The SMC91c92-specific entries in the device structure. */
|
/* The SMC91c92-specific entries in the device structure. */
|
||||||
dev->netdev_ops = &smc_netdev_ops;
|
dev->netdev_ops = &smc_netdev_ops;
|
||||||
|
@ -444,7 +443,7 @@ static int mhz_mfc_config(struct pcmcia_device *link)
|
||||||
unsigned int offset;
|
unsigned int offset;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
link->conf.Attributes |= CONF_ENABLE_SPKR;
|
link->config_flags |= CONF_ENABLE_SPKR;
|
||||||
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
link->resource[1]->end = 8;
|
link->resource[1]->end = 8;
|
||||||
|
|
||||||
|
@ -637,7 +636,7 @@ static int osi_config(struct pcmcia_device *link)
|
||||||
static const unsigned int com[4] = { 0x3f8, 0x2f8, 0x3e8, 0x2e8 };
|
static const unsigned int com[4] = { 0x3f8, 0x2f8, 0x3e8, 0x2e8 };
|
||||||
int i, j;
|
int i, j;
|
||||||
|
|
||||||
link->conf.Attributes |= CONF_ENABLE_SPKR;
|
link->config_flags |= CONF_ENABLE_SPKR;
|
||||||
link->resource[0]->end = 64;
|
link->resource[0]->end = 64;
|
||||||
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
link->resource[1]->end = 8;
|
link->resource[1]->end = 8;
|
||||||
|
@ -862,7 +861,7 @@ static int smc91c92_config(struct pcmcia_device *link)
|
||||||
i = pcmcia_request_irq(link, smc_interrupt);
|
i = pcmcia_request_irq(link, smc_interrupt);
|
||||||
if (i)
|
if (i)
|
||||||
goto config_failed;
|
goto config_failed;
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i)
|
if (i)
|
||||||
goto config_failed;
|
goto config_failed;
|
||||||
|
|
||||||
|
|
|
@ -82,7 +82,6 @@
|
||||||
#include <linux/bitops.h>
|
#include <linux/bitops.h>
|
||||||
#include <linux/mii.h>
|
#include <linux/mii.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
@ -529,7 +528,7 @@ xirc2ps_probe(struct pcmcia_device *link)
|
||||||
link->priv = dev;
|
link->priv = dev;
|
||||||
|
|
||||||
/* General socket configuration */
|
/* General socket configuration */
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_index = 1;
|
link->config_index = 1;
|
||||||
|
|
||||||
/* Fill in card specific entries */
|
/* Fill in card specific entries */
|
||||||
|
@ -811,9 +810,6 @@ xirc2ps_config(struct pcmcia_device * link)
|
||||||
if (local->modem) {
|
if (local->modem) {
|
||||||
int pass;
|
int pass;
|
||||||
|
|
||||||
if (do_sound)
|
|
||||||
link->conf.Attributes |= CONF_ENABLE_SPKR;
|
|
||||||
|
|
||||||
link->resource[1]->end = 8;
|
link->resource[1]->end = 8;
|
||||||
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
if (local->dingo) {
|
if (local->dingo) {
|
||||||
|
@ -863,7 +859,11 @@ xirc2ps_config(struct pcmcia_device * link)
|
||||||
* This actually configures the PCMCIA socket -- setting up
|
* This actually configures the PCMCIA socket -- setting up
|
||||||
* the I/O windows and the interrupt mapping.
|
* the I/O windows and the interrupt mapping.
|
||||||
*/
|
*/
|
||||||
if ((err=pcmcia_request_configuration(link, &link->conf)))
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
if (do_sound)
|
||||||
|
link->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
|
if ((err = pcmcia_enable_device(link)))
|
||||||
goto config_error;
|
goto config_error;
|
||||||
|
|
||||||
if (local->dingo) {
|
if (local->dingo) {
|
||||||
|
|
|
@ -32,7 +32,6 @@
|
||||||
#include <linux/timer.h>
|
#include <linux/timer.h>
|
||||||
#include <linux/netdevice.h>
|
#include <linux/netdevice.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -96,15 +95,6 @@ static int airo_probe(struct pcmcia_device *p_dev)
|
||||||
|
|
||||||
dev_dbg(&p_dev->dev, "airo_attach()\n");
|
dev_dbg(&p_dev->dev, "airo_attach()\n");
|
||||||
|
|
||||||
/*
|
|
||||||
General socket configuration defaults can go here. In this
|
|
||||||
client, we assume very little, and rely on the CIS for almost
|
|
||||||
everything. In most clients, many details (i.e., number, sizes,
|
|
||||||
and attributes of IO windows) are fixed by the nature of the
|
|
||||||
device, and can be hard-wired here.
|
|
||||||
*/
|
|
||||||
p_dev->conf.Attributes = 0;
|
|
||||||
|
|
||||||
/* Allocate space for private device-specific data */
|
/* Allocate space for private device-specific data */
|
||||||
local = kzalloc(sizeof(local_info_t), GFP_KERNEL);
|
local = kzalloc(sizeof(local_info_t), GFP_KERNEL);
|
||||||
if (!local) {
|
if (!local) {
|
||||||
|
@ -158,7 +148,7 @@ static int airo_cs_config_check(struct pcmcia_device *p_dev,
|
||||||
|
|
||||||
/* Does this card need audio output? */
|
/* Does this card need audio output? */
|
||||||
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_SPKR;
|
p_dev->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
/* Use power settings for Vcc and Vpp if present */
|
/* Use power settings for Vcc and Vpp if present */
|
||||||
/* Note that the CIS values need to be rescaled */
|
/* Note that the CIS values need to be rescaled */
|
||||||
|
@ -167,7 +157,7 @@ static int airo_cs_config_check(struct pcmcia_device *p_dev,
|
||||||
else if (dflt->vpp1.present & (1<<CISTPL_POWER_VNOM))
|
else if (dflt->vpp1.present & (1<<CISTPL_POWER_VNOM))
|
||||||
p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM]/10000;
|
p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM]/10000;
|
||||||
|
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -229,7 +219,7 @@ static int airo_config(struct pcmcia_device *link)
|
||||||
the I/O windows and the interrupt mapping, and putting the
|
the I/O windows and the interrupt mapping, and putting the
|
||||||
card and host interface into "Memory and IO" mode.
|
card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
((local_info_t *)link->priv)->eth_dev =
|
((local_info_t *)link->priv)->eth_dev =
|
||||||
|
|
|
@ -42,7 +42,6 @@
|
||||||
#include <linux/moduleparam.h>
|
#include <linux/moduleparam.h>
|
||||||
#include <linux/device.h>
|
#include <linux/device.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -106,15 +105,6 @@ static int atmel_probe(struct pcmcia_device *p_dev)
|
||||||
|
|
||||||
dev_dbg(&p_dev->dev, "atmel_attach()\n");
|
dev_dbg(&p_dev->dev, "atmel_attach()\n");
|
||||||
|
|
||||||
/*
|
|
||||||
General socket configuration defaults can go here. In this
|
|
||||||
client, we assume very little, and rely on the CIS for almost
|
|
||||||
everything. In most clients, many details (i.e., number, sizes,
|
|
||||||
and attributes of IO windows) are fixed by the nature of the
|
|
||||||
device, and can be hard-wired here.
|
|
||||||
*/
|
|
||||||
p_dev->conf.Attributes = 0;
|
|
||||||
|
|
||||||
/* Allocate space for private device-specific data */
|
/* Allocate space for private device-specific data */
|
||||||
local = kzalloc(sizeof(local_info_t), GFP_KERNEL);
|
local = kzalloc(sizeof(local_info_t), GFP_KERNEL);
|
||||||
if (!local) {
|
if (!local) {
|
||||||
|
@ -175,7 +165,7 @@ static int atmel_config_check(struct pcmcia_device *p_dev,
|
||||||
|
|
||||||
/* Does this card need audio output? */
|
/* Does this card need audio output? */
|
||||||
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_SPKR;
|
p_dev->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
/* Use power settings for Vcc and Vpp if present */
|
/* Use power settings for Vcc and Vpp if present */
|
||||||
/* Note that the CIS values need to be rescaled */
|
/* Note that the CIS values need to be rescaled */
|
||||||
|
@ -184,7 +174,7 @@ static int atmel_config_check(struct pcmcia_device *p_dev,
|
||||||
else if (dflt->vpp1.present & (1<<CISTPL_POWER_VNOM))
|
else if (dflt->vpp1.present & (1<<CISTPL_POWER_VNOM))
|
||||||
p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM]/10000;
|
p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM]/10000;
|
||||||
|
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -242,7 +232,7 @@ static int atmel_config(struct pcmcia_device *link)
|
||||||
the I/O windows and the interrupt mapping, and putting the
|
the I/O windows and the interrupt mapping, and putting the
|
||||||
card and host interface into "Memory and IO" mode.
|
card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
#include <linux/ssb/ssb.h>
|
#include <linux/ssb/ssb.h>
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -72,7 +71,7 @@ static int __devinit b43_pcmcia_probe(struct pcmcia_device *dev)
|
||||||
|
|
||||||
err = -ENODEV;
|
err = -ENODEV;
|
||||||
|
|
||||||
dev->conf.Attributes = CONF_ENABLE_IRQ;
|
dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
dev->resource[2]->flags |= WIN_ENABLE | WIN_DATA_WIDTH_16 |
|
dev->resource[2]->flags |= WIN_ENABLE | WIN_DATA_WIDTH_16 |
|
||||||
WIN_USE_WAIT;
|
WIN_USE_WAIT;
|
||||||
|
@ -89,7 +88,7 @@ static int __devinit b43_pcmcia_probe(struct pcmcia_device *dev)
|
||||||
if (!dev->irq)
|
if (!dev->irq)
|
||||||
goto err_disable;
|
goto err_disable;
|
||||||
|
|
||||||
res = pcmcia_request_configuration(dev, &dev->conf);
|
res = pcmcia_enable_device(dev);
|
||||||
if (res != 0)
|
if (res != 0)
|
||||||
goto err_disable;
|
goto err_disable;
|
||||||
|
|
||||||
|
|
|
@ -12,7 +12,6 @@
|
||||||
#include <linux/wireless.h>
|
#include <linux/wireless.h>
|
||||||
#include <net/iw_handler.h>
|
#include <net/iw_handler.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -484,7 +483,7 @@ static int prism2_config_check(struct pcmcia_device *p_dev,
|
||||||
|
|
||||||
/* Does this card need audio output? */
|
/* Does this card need audio output? */
|
||||||
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_SPKR;
|
p_dev->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
/* Use power settings for Vcc and Vpp if present */
|
/* Use power settings for Vcc and Vpp if present */
|
||||||
/* Note that the CIS values need to be rescaled */
|
/* Note that the CIS values need to be rescaled */
|
||||||
|
@ -510,7 +509,7 @@ static int prism2_config_check(struct pcmcia_device *p_dev,
|
||||||
p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM] / 10000;
|
p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM] / 10000;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
PDEBUG(DEBUG_EXTRA, "IO window settings: cfg->io.nwin=%d "
|
PDEBUG(DEBUG_EXTRA, "IO window settings: cfg->io.nwin=%d "
|
||||||
|
@ -590,7 +589,7 @@ static int prism2_config(struct pcmcia_device *link)
|
||||||
* the I/O windows and the interrupt mapping, and putting the
|
* the I/O windows and the interrupt mapping, and putting the
|
||||||
* card and host interface into "Memory and IO" mode.
|
* card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed_unlock;
|
goto failed_unlock;
|
||||||
|
|
||||||
|
@ -605,8 +604,7 @@ static int prism2_config(struct pcmcia_device *link)
|
||||||
if (link->vpp)
|
if (link->vpp)
|
||||||
printk(", Vpp %d.%d", link->vpp / 10,
|
printk(", Vpp %d.%d", link->vpp / 10,
|
||||||
link->vpp % 10);
|
link->vpp % 10);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %d", link->irq);
|
||||||
printk(", irq %d", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(" & %pR", link->resource[0]);
|
printk(" & %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -28,7 +28,6 @@
|
||||||
#include <linux/firmware.h>
|
#include <linux/firmware.h>
|
||||||
#include <linux/netdevice.h>
|
#include <linux/netdevice.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -806,7 +805,7 @@ static int if_cs_ioprobe(struct pcmcia_device *p_dev,
|
||||||
p_dev->resource[0]->end = cfg->io.win[0].len;
|
p_dev->resource[0]->end = cfg->io.win[0].len;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
if (cfg->io.nwin != 1) {
|
if (cfg->io.nwin != 1) {
|
||||||
|
@ -835,14 +834,11 @@ static int if_cs_probe(struct pcmcia_device *p_dev)
|
||||||
card->p_dev = p_dev;
|
card->p_dev = p_dev;
|
||||||
p_dev->priv = card;
|
p_dev->priv = card;
|
||||||
|
|
||||||
p_dev->conf.Attributes = 0;
|
|
||||||
|
|
||||||
if (pcmcia_loop_config(p_dev, if_cs_ioprobe, NULL)) {
|
if (pcmcia_loop_config(p_dev, if_cs_ioprobe, NULL)) {
|
||||||
lbs_pr_err("error in pcmcia_loop_config\n");
|
lbs_pr_err("error in pcmcia_loop_config\n");
|
||||||
goto out1;
|
goto out1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Allocate an interrupt line. Note that this does not assign
|
* Allocate an interrupt line. Note that this does not assign
|
||||||
* a handler to the interrupt, unless the 'Handler' member of
|
* a handler to the interrupt, unless the 'Handler' member of
|
||||||
|
@ -865,9 +861,9 @@ static int if_cs_probe(struct pcmcia_device *p_dev)
|
||||||
* the I/O windows and the interrupt mapping, and putting the
|
* the I/O windows and the interrupt mapping, and putting the
|
||||||
* card and host interface into "Memory and IO" mode.
|
* card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(p_dev, &p_dev->conf);
|
ret = pcmcia_enable_device(p_dev);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
lbs_pr_err("error in pcmcia_request_configuration\n");
|
lbs_pr_err("error in pcmcia_enable_device\n");
|
||||||
goto out2;
|
goto out2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -17,7 +17,6 @@
|
||||||
#include <linux/kernel.h>
|
#include <linux/kernel.h>
|
||||||
#include <linux/init.h>
|
#include <linux/init.h>
|
||||||
#include <linux/delay.h>
|
#include <linux/delay.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -117,13 +116,6 @@ orinoco_cs_probe(struct pcmcia_device *link)
|
||||||
card->p_dev = link;
|
card->p_dev = link;
|
||||||
link->priv = priv;
|
link->priv = priv;
|
||||||
|
|
||||||
/* General socket configuration defaults can go here. In this
|
|
||||||
* client, we assume very little, and rely on the CIS for
|
|
||||||
* almost everything. In most clients, many details (i.e.,
|
|
||||||
* number, sizes, and attributes of IO windows) are fixed by
|
|
||||||
* the nature of the device, and can be hard-wired here. */
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
return orinoco_cs_config(link);
|
return orinoco_cs_config(link);
|
||||||
} /* orinoco_cs_attach */
|
} /* orinoco_cs_attach */
|
||||||
|
|
||||||
|
@ -187,7 +179,7 @@ static int orinoco_cs_config_check(struct pcmcia_device *p_dev,
|
||||||
dflt->vpp1.param[CISTPL_POWER_VNOM] / 10000;
|
dflt->vpp1.param[CISTPL_POWER_VNOM] / 10000;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -266,7 +258,7 @@ orinoco_cs_config(struct pcmcia_device *link)
|
||||||
* the I/O windows and the interrupt mapping, and putting the
|
* the I/O windows and the interrupt mapping, and putting the
|
||||||
* card and host interface into "Memory and IO" mode.
|
* card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -25,7 +25,6 @@
|
||||||
#include <linux/kernel.h>
|
#include <linux/kernel.h>
|
||||||
#include <linux/init.h>
|
#include <linux/init.h>
|
||||||
#include <linux/delay.h>
|
#include <linux/delay.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -179,13 +178,6 @@ spectrum_cs_probe(struct pcmcia_device *link)
|
||||||
card->p_dev = link;
|
card->p_dev = link;
|
||||||
link->priv = priv;
|
link->priv = priv;
|
||||||
|
|
||||||
/* General socket configuration defaults can go here. In this
|
|
||||||
* client, we assume very little, and rely on the CIS for
|
|
||||||
* almost everything. In most clients, many details (i.e.,
|
|
||||||
* number, sizes, and attributes of IO windows) are fixed by
|
|
||||||
* the nature of the device, and can be hard-wired here. */
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
return spectrum_cs_config(link);
|
return spectrum_cs_config(link);
|
||||||
} /* spectrum_cs_attach */
|
} /* spectrum_cs_attach */
|
||||||
|
|
||||||
|
@ -249,7 +241,7 @@ static int spectrum_cs_config_check(struct pcmcia_device *p_dev,
|
||||||
dflt->vpp1.param[CISTPL_POWER_VNOM] / 10000;
|
dflt->vpp1.param[CISTPL_POWER_VNOM] / 10000;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -329,7 +321,7 @@ spectrum_cs_config(struct pcmcia_device *link)
|
||||||
* the I/O windows and the interrupt mapping, and putting the
|
* the I/O windows and the interrupt mapping, and putting the
|
||||||
* card and host interface into "Memory and IO" mode.
|
* card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -46,7 +46,6 @@
|
||||||
#include <linux/ethtool.h>
|
#include <linux/ethtool.h>
|
||||||
#include <linux/ieee80211.h>
|
#include <linux/ieee80211.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -318,7 +317,7 @@ static int ray_probe(struct pcmcia_device *p_dev)
|
||||||
p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
|
|
||||||
/* General socket configuration */
|
/* General socket configuration */
|
||||||
p_dev->conf.Attributes = CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
p_dev->config_index = 1;
|
p_dev->config_index = 1;
|
||||||
|
|
||||||
p_dev->priv = dev;
|
p_dev->priv = dev;
|
||||||
|
@ -413,7 +412,7 @@ static int ray_config(struct pcmcia_device *link)
|
||||||
/* This actually configures the PCMCIA socket -- setting up
|
/* This actually configures the PCMCIA socket -- setting up
|
||||||
the I/O windows and the interrupt mapping.
|
the I/O windows and the interrupt mapping.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -48,7 +48,6 @@
|
||||||
|
|
||||||
#include <net/iw_handler.h>
|
#include <net/iw_handler.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -1888,7 +1887,7 @@ static int wl3501_probe(struct pcmcia_device *p_dev)
|
||||||
p_dev->resource[0]->flags = IO_DATA_PATH_WIDTH_8;
|
p_dev->resource[0]->flags = IO_DATA_PATH_WIDTH_8;
|
||||||
|
|
||||||
/* General socket configuration */
|
/* General socket configuration */
|
||||||
p_dev->conf.Attributes = CONF_ENABLE_IRQ;
|
p_dev->config_flags = CONF_ENABLE_IRQ;
|
||||||
p_dev->config_index = 1;
|
p_dev->config_index = 1;
|
||||||
|
|
||||||
dev = alloc_etherdev(sizeof(struct wl3501_card));
|
dev = alloc_etherdev(sizeof(struct wl3501_card));
|
||||||
|
@ -1954,7 +1953,7 @@ static int wl3501_config(struct pcmcia_device *link)
|
||||||
/* This actually configures the PCMCIA socket -- setting up the I/O
|
/* This actually configures the PCMCIA socket -- setting up the I/O
|
||||||
* windows and the interrupt mapping. */
|
* windows and the interrupt mapping. */
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -48,7 +48,6 @@
|
||||||
#include <linux/parport.h>
|
#include <linux/parport.h>
|
||||||
#include <linux/parport_pc.h>
|
#include <linux/parport_pc.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
|
@ -103,7 +102,7 @@ static int parport_probe(struct pcmcia_device *link)
|
||||||
|
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
link->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
return parport_config(link);
|
return parport_config(link);
|
||||||
} /* parport_attach */
|
} /* parport_attach */
|
||||||
|
@ -172,7 +171,7 @@ static int parport_config(struct pcmcia_device *link)
|
||||||
|
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,6 @@
|
||||||
|
|
||||||
/* include the world */
|
/* include the world */
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include "cs_internal.h"
|
#include "cs_internal.h"
|
||||||
|
|
|
@ -31,7 +31,6 @@
|
||||||
#include <linux/proc_fs.h>
|
#include <linux/proc_fs.h>
|
||||||
#include <linux/types.h>
|
#include <linux/types.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,6 @@
|
||||||
#include <asm/unaligned.h>
|
#include <asm/unaligned.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include "cs_internal.h"
|
#include "cs_internal.h"
|
||||||
|
|
|
@ -33,7 +33,6 @@
|
||||||
#include <asm/irq.h>
|
#include <asm/irq.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
|
@ -33,14 +33,9 @@
|
||||||
typedef struct config_t {
|
typedef struct config_t {
|
||||||
struct kref ref;
|
struct kref ref;
|
||||||
unsigned int state;
|
unsigned int state;
|
||||||
unsigned int Attributes;
|
|
||||||
|
|
||||||
struct resource io[MAX_IO_WIN]; /* io ports */
|
struct resource io[MAX_IO_WIN]; /* io ports */
|
||||||
struct resource mem[MAX_WIN]; /* mem areas */
|
struct resource mem[MAX_WIN]; /* mem areas */
|
||||||
|
|
||||||
struct {
|
|
||||||
u_int Attributes;
|
|
||||||
} irq;
|
|
||||||
} config_t;
|
} config_t;
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
#include <linux/dma-mapping.h>
|
#include <linux/dma-mapping.h>
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
|
@ -1178,7 +1177,7 @@ static int pcmcia_dev_resume(struct device *dev)
|
||||||
|
|
||||||
if (p_dev->device_no == p_dev->func) {
|
if (p_dev->device_no == p_dev->func) {
|
||||||
dev_dbg(dev, "requesting configuration\n");
|
dev_dbg(dev, "requesting configuration\n");
|
||||||
ret = pcmcia_request_configuration(p_dev, &p_dev->conf);
|
ret = pcmcia_enable_device(p_dev);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,7 +16,6 @@
|
||||||
#include <linux/device.h>
|
#include <linux/device.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
|
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
|
|
|
@ -51,7 +51,6 @@
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
|
|
||||||
#include <linux/isapnp.h>
|
#include <linux/isapnp.h>
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,6 @@
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
|
|
||||||
#undef MAX_IO_WIN /* FIXME */
|
#undef MAX_IO_WIN /* FIXME */
|
||||||
#define MAX_IO_WIN 1
|
#define MAX_IO_WIN 1
|
||||||
|
|
|
@ -28,7 +28,6 @@
|
||||||
#include <asm/addrspace.h>
|
#include <asm/addrspace.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
|
|
||||||
/* XXX: should be moved into asm/irq.h */
|
/* XXX: should be moved into asm/irq.h */
|
||||||
#define PCC0_IRQ 24
|
#define PCC0_IRQ 24
|
||||||
|
|
|
@ -59,7 +59,6 @@
|
||||||
#include <asm/irq.h>
|
#include <asm/irq.h>
|
||||||
#include <asm/fs_pd.h>
|
#include <asm/fs_pd.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
|
|
||||||
#define pcmcia_info(args...) printk(KERN_INFO "m8xx_pcmcia: "args)
|
#define pcmcia_info(args...) printk(KERN_INFO "m8xx_pcmcia: "args)
|
||||||
|
|
|
@ -22,7 +22,6 @@
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include "cs_internal.h"
|
#include "cs_internal.h"
|
||||||
|
|
||||||
|
|
|
@ -26,7 +26,6 @@
|
||||||
#include <asm/irq.h>
|
#include <asm/irq.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -230,7 +229,7 @@ EXPORT_SYMBOL(pcmcia_map_mem_page);
|
||||||
* pcmcia_fixup_iowidth() - reduce io width to 8bit
|
* pcmcia_fixup_iowidth() - reduce io width to 8bit
|
||||||
*
|
*
|
||||||
* pcmcia_fixup_iowidth() allows a PCMCIA device driver to reduce the
|
* pcmcia_fixup_iowidth() allows a PCMCIA device driver to reduce the
|
||||||
* IO width to 8bit after having called pcmcia_request_configuration()
|
* IO width to 8bit after having called pcmcia_enable_device()
|
||||||
* previously.
|
* previously.
|
||||||
*/
|
*/
|
||||||
int pcmcia_fixup_iowidth(struct pcmcia_device *p_dev)
|
int pcmcia_fixup_iowidth(struct pcmcia_device *p_dev)
|
||||||
|
@ -278,7 +277,7 @@ EXPORT_SYMBOL(pcmcia_fixup_iowidth);
|
||||||
* pcmcia_fixup_vpp() - set Vpp to a new voltage level
|
* pcmcia_fixup_vpp() - set Vpp to a new voltage level
|
||||||
*
|
*
|
||||||
* pcmcia_fixup_vpp() allows a PCMCIA device driver to set Vpp to
|
* pcmcia_fixup_vpp() allows a PCMCIA device driver to set Vpp to
|
||||||
* a new voltage level between calls to pcmcia_request_configuration()
|
* a new voltage level between calls to pcmcia_enable_device()
|
||||||
* and pcmcia_disable_device().
|
* and pcmcia_disable_device().
|
||||||
*/
|
*/
|
||||||
int pcmcia_fixup_vpp(struct pcmcia_device *p_dev, unsigned char new_vpp)
|
int pcmcia_fixup_vpp(struct pcmcia_device *p_dev, unsigned char new_vpp)
|
||||||
|
@ -432,18 +431,21 @@ int pcmcia_release_window(struct pcmcia_device *p_dev, struct resource *res)
|
||||||
} /* pcmcia_release_window */
|
} /* pcmcia_release_window */
|
||||||
EXPORT_SYMBOL(pcmcia_release_window);
|
EXPORT_SYMBOL(pcmcia_release_window);
|
||||||
|
|
||||||
|
/**
|
||||||
int pcmcia_request_configuration(struct pcmcia_device *p_dev,
|
* pcmcia_enable_device() - set up and activate a PCMCIA device
|
||||||
config_req_t *req)
|
*
|
||||||
|
*/
|
||||||
|
int pcmcia_enable_device(struct pcmcia_device *p_dev)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
u_int base;
|
unsigned int base;
|
||||||
struct pcmcia_socket *s = p_dev->socket;
|
struct pcmcia_socket *s = p_dev->socket;
|
||||||
config_t *c;
|
config_t *c;
|
||||||
pccard_io_map iomap;
|
pccard_io_map iomap;
|
||||||
unsigned char status = 0;
|
unsigned char status = 0;
|
||||||
unsigned char ext_status = 0;
|
unsigned char ext_status = 0;
|
||||||
unsigned char option = 0;
|
unsigned char option = 0;
|
||||||
|
unsigned int flags = p_dev->config_flags;
|
||||||
|
|
||||||
if (!(s->state & SOCKET_PRESENT))
|
if (!(s->state & SOCKET_PRESENT))
|
||||||
return -ENODEV;
|
return -ENODEV;
|
||||||
|
@ -466,23 +468,20 @@ int pcmcia_request_configuration(struct pcmcia_device *p_dev,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Pick memory or I/O card, DMA mode, interrupt */
|
/* Pick memory or I/O card, DMA mode, interrupt */
|
||||||
c->Attributes = req->Attributes;
|
|
||||||
if (p_dev->_io)
|
if (p_dev->_io)
|
||||||
s->socket.flags |= SS_IOCARD;
|
s->socket.flags |= SS_IOCARD;
|
||||||
if (req->Attributes & CONF_ENABLE_DMA)
|
if (flags & CONF_ENABLE_SPKR) {
|
||||||
s->socket.flags |= SS_DMA_MODE;
|
|
||||||
if (req->Attributes & CONF_ENABLE_SPKR) {
|
|
||||||
s->socket.flags |= SS_SPKR_ENA;
|
s->socket.flags |= SS_SPKR_ENA;
|
||||||
status = CCSR_AUDIO_ENA;
|
status = CCSR_AUDIO_ENA;
|
||||||
if (!(p_dev->config_regs & PRESENT_STATUS))
|
if (!(p_dev->config_regs & PRESENT_STATUS))
|
||||||
dev_warn(&p_dev->dev, "speaker requested, but "
|
dev_warn(&p_dev->dev, "speaker requested, but "
|
||||||
"PRESENT_STATUS not set!\n");
|
"PRESENT_STATUS not set!\n");
|
||||||
}
|
}
|
||||||
if (req->Attributes & CONF_ENABLE_IRQ)
|
if (flags & CONF_ENABLE_IRQ)
|
||||||
s->socket.io_irq = s->pcmcia_irq;
|
s->socket.io_irq = s->pcmcia_irq;
|
||||||
else
|
else
|
||||||
s->socket.io_irq = 0;
|
s->socket.io_irq = 0;
|
||||||
if (req->Attributes & CONF_ENABLE_ESR) {
|
if (flags & CONF_ENABLE_ESR) {
|
||||||
p_dev->config_regs |= PRESENT_EXT_STATUS;
|
p_dev->config_regs |= PRESENT_EXT_STATUS;
|
||||||
ext_status = ESR_REQ_ATTN_ENA;
|
ext_status = ESR_REQ_ATTN_ENA;
|
||||||
}
|
}
|
||||||
|
@ -510,8 +509,8 @@ int pcmcia_request_configuration(struct pcmcia_device *p_dev,
|
||||||
if (p_dev->config_regs & PRESENT_IOBASE_0)
|
if (p_dev->config_regs & PRESENT_IOBASE_0)
|
||||||
option |= COR_ADDR_DECODE;
|
option |= COR_ADDR_DECODE;
|
||||||
}
|
}
|
||||||
if ((req->Attributes & CONF_ENABLE_IRQ) &&
|
if ((flags & CONF_ENABLE_IRQ) &&
|
||||||
!(req->Attributes & CONF_ENABLE_PULSE_IRQ))
|
!(flags & CONF_ENABLE_PULSE_IRQ))
|
||||||
option |= COR_LEVEL_REQ;
|
option |= COR_LEVEL_REQ;
|
||||||
pcmcia_write_cis_mem(s, 1, (base + CISREG_COR)>>1, 1, &option);
|
pcmcia_write_cis_mem(s, 1, (base + CISREG_COR)>>1, 1, &option);
|
||||||
mdelay(40);
|
mdelay(40);
|
||||||
|
@ -560,8 +559,8 @@ int pcmcia_request_configuration(struct pcmcia_device *p_dev,
|
||||||
p_dev->_locked = 1;
|
p_dev->_locked = 1;
|
||||||
mutex_unlock(&s->ops_mutex);
|
mutex_unlock(&s->ops_mutex);
|
||||||
return 0;
|
return 0;
|
||||||
} /* pcmcia_request_configuration */
|
} /* pcmcia_enable_device */
|
||||||
EXPORT_SYMBOL(pcmcia_request_configuration);
|
EXPORT_SYMBOL(pcmcia_enable_device);
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -18,7 +18,6 @@
|
||||||
#include <linux/io.h>
|
#include <linux/io.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
|
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
|
|
|
@ -17,7 +17,6 @@
|
||||||
#include <linux/kernel.h>
|
#include <linux/kernel.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include "cs_internal.h"
|
#include "cs_internal.h"
|
||||||
|
|
||||||
|
|
|
@ -17,7 +17,6 @@
|
||||||
#include <linux/kernel.h>
|
#include <linux/kernel.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include "cs_internal.h"
|
#include "cs_internal.h"
|
||||||
|
|
||||||
|
|
|
@ -29,7 +29,6 @@
|
||||||
#include <asm/irq.h>
|
#include <asm/irq.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include "cs_internal.h"
|
#include "cs_internal.h"
|
||||||
|
|
||||||
|
|
|
@ -35,7 +35,6 @@
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
#include <linux/platform_device.h>
|
#include <linux/platform_device.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
|
|
||||||
#include <asm/hardware/scoop.h>
|
#include <asm/hardware/scoop.h>
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
|
|
||||||
/* include the world */
|
/* include the world */
|
||||||
#include <linux/cpufreq.h>
|
#include <linux/cpufreq.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,6 @@
|
||||||
#include <asm/irq.h>
|
#include <asm/irq.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
|
@ -49,7 +49,6 @@
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include "tcic.h"
|
#include "tcic.h"
|
||||||
|
|
||||||
|
|
|
@ -17,7 +17,6 @@
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
#include <linux/spinlock.h>
|
#include <linux/spinlock.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,6 @@
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
|
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
|
|
||||||
#include "yenta_socket.h"
|
#include "yenta_socket.h"
|
||||||
#include "i82365.h"
|
#include "i82365.h"
|
||||||
|
|
|
@ -49,7 +49,6 @@
|
||||||
#include <scsi/scsi_host.h>
|
#include <scsi/scsi_host.h>
|
||||||
#include "aha152x.h"
|
#include "aha152x.h"
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -102,7 +101,7 @@ static int aha152x_probe(struct pcmcia_device *link)
|
||||||
|
|
||||||
link->resource[0]->end = 0x20;
|
link->resource[0]->end = 0x20;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_regs = PRESENT_OPTION;
|
link->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
return aha152x_config_cs(link);
|
return aha152x_config_cs(link);
|
||||||
|
@ -159,7 +158,7 @@ static int aha152x_config_cs(struct pcmcia_device *link)
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -46,7 +46,6 @@
|
||||||
#include <scsi/scsi_host.h>
|
#include <scsi/scsi_host.h>
|
||||||
#include "fdomain.h"
|
#include "fdomain.h"
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -85,7 +84,7 @@ static int fdomain_probe(struct pcmcia_device *link)
|
||||||
link->priv = info;
|
link->priv = info;
|
||||||
link->resource[0]->end = 0x10;
|
link->resource[0]->end = 0x10;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_regs = PRESENT_OPTION;
|
link->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
return fdomain_config(link);
|
return fdomain_config(link);
|
||||||
|
@ -131,7 +130,7 @@ static int fdomain_config(struct pcmcia_device *link)
|
||||||
|
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,6 @@
|
||||||
#include <scsi/scsi.h>
|
#include <scsi/scsi.h>
|
||||||
#include <scsi/scsi_ioctl.h>
|
#include <scsi/scsi_ioctl.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -1562,7 +1561,7 @@ static int nsp_cs_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->flags = IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags = IO_DATA_PATH_WIDTH_AUTO;
|
||||||
|
|
||||||
/* General socket configuration */
|
/* General socket configuration */
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
ret = nsp_cs_config(link);
|
ret = nsp_cs_config(link);
|
||||||
|
|
||||||
|
@ -1608,7 +1607,7 @@ static int nsp_cs_config_check(struct pcmcia_device *p_dev,
|
||||||
|
|
||||||
/* Does this card need audio output? */
|
/* Does this card need audio output? */
|
||||||
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_SPKR;
|
p_dev->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
/* Use power settings for Vcc and Vpp if present */
|
/* Use power settings for Vcc and Vpp if present */
|
||||||
/* Note that the CIS values need to be rescaled */
|
/* Note that the CIS values need to be rescaled */
|
||||||
|
@ -1629,7 +1628,7 @@ static int nsp_cs_config_check(struct pcmcia_device *p_dev,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -1700,7 +1699,7 @@ static int nsp_cs_config(struct pcmcia_device *link)
|
||||||
if (pcmcia_request_irq(link, nspintr))
|
if (pcmcia_request_irq(link, nspintr))
|
||||||
goto cs_failed;
|
goto cs_failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto cs_failed;
|
goto cs_failed;
|
||||||
|
|
||||||
|
@ -1749,9 +1748,7 @@ static int nsp_cs_config(struct pcmcia_device *link)
|
||||||
if (link->vpp) {
|
if (link->vpp) {
|
||||||
printk(", Vpp %d.%d", link->vpp/10, link->vpp%10);
|
printk(", Vpp %d.%d", link->vpp/10, link->vpp%10);
|
||||||
}
|
}
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ) {
|
printk(", irq %d", link->irq);
|
||||||
printk(", irq %d", link->irq);
|
|
||||||
}
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(", io %pR", link->resource[0]);
|
printk(", io %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -48,7 +48,6 @@
|
||||||
#include <scsi/scsi_host.h>
|
#include <scsi/scsi_host.h>
|
||||||
#include "../qlogicfas408.h"
|
#include "../qlogicfas408.h"
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
@ -158,7 +157,7 @@ static int qlogic_probe(struct pcmcia_device *link)
|
||||||
link->priv = info;
|
link->priv = info;
|
||||||
link->resource[0]->end = 16;
|
link->resource[0]->end = 16;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_regs = PRESENT_OPTION;
|
link->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
return qlogic_config(link);
|
return qlogic_config(link);
|
||||||
|
@ -208,7 +207,7 @@ static int qlogic_config(struct pcmcia_device * link)
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
@ -263,7 +262,7 @@ static int qlogic_resume(struct pcmcia_device *link)
|
||||||
{
|
{
|
||||||
scsi_info_t *info = link->priv;
|
scsi_info_t *info = link->priv;
|
||||||
|
|
||||||
pcmcia_request_configuration(link, &link->conf);
|
pcmcia_enable_device(link);
|
||||||
if ((info->manf_id == MANFID_MACNICA) ||
|
if ((info->manf_id == MANFID_MACNICA) ||
|
||||||
(info->manf_id == MANFID_PIONEER) ||
|
(info->manf_id == MANFID_PIONEER) ||
|
||||||
(info->manf_id == 0x0098)) {
|
(info->manf_id == 0x0098)) {
|
||||||
|
|
|
@ -71,7 +71,6 @@
|
||||||
#include <scsi/scsi.h>
|
#include <scsi/scsi.h>
|
||||||
#include <scsi/scsi_host.h>
|
#include <scsi/scsi_host.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
@ -721,7 +720,7 @@ SYM53C500_config(struct pcmcia_device *link)
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
@ -861,7 +860,7 @@ SYM53C500_probe(struct pcmcia_device *link)
|
||||||
link->priv = info;
|
link->priv = info;
|
||||||
link->resource[0]->end = 16;
|
link->resource[0]->end = 16;
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
return SYM53C500_config(link);
|
return SYM53C500_config(link);
|
||||||
} /* SYM53C500_attach */
|
} /* SYM53C500_attach */
|
||||||
|
|
|
@ -45,7 +45,6 @@
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -184,7 +183,7 @@ static void quirk_config_socket(struct pcmcia_device *link)
|
||||||
struct serial_info *info = link->priv;
|
struct serial_info *info = link->priv;
|
||||||
|
|
||||||
if (info->multi)
|
if (info->multi)
|
||||||
link->conf.Attributes |= CONF_ENABLE_ESR;
|
link->config_flags |= CONF_ENABLE_ESR;
|
||||||
}
|
}
|
||||||
|
|
||||||
static const struct serial_quirk quirks[] = {
|
static const struct serial_quirk quirks[] = {
|
||||||
|
@ -333,9 +332,9 @@ static int serial_probe(struct pcmcia_device *link)
|
||||||
info->p_dev = link;
|
info->p_dev = link;
|
||||||
link->priv = info;
|
link->priv = info;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
if (do_sound)
|
if (do_sound)
|
||||||
link->conf.Attributes |= CONF_ENABLE_SPKR;
|
link->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
return serial_config(link);
|
return serial_config(link);
|
||||||
}
|
}
|
||||||
|
@ -503,7 +502,7 @@ found_port:
|
||||||
if (info->quirk && info->quirk->config)
|
if (info->quirk && info->quirk->config)
|
||||||
info->quirk->config(link);
|
info->quirk->config(link);
|
||||||
|
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
return -1;
|
return -1;
|
||||||
return setup_serial(link, info, link->resource[0]->start, link->irq);
|
return setup_serial(link, info, link->resource[0]->start, link->irq);
|
||||||
|
@ -579,7 +578,7 @@ static int multi_config(struct pcmcia_device *link)
|
||||||
if (info->quirk && info->quirk->config)
|
if (info->quirk && info->quirk->config)
|
||||||
info->quirk->config(link);
|
info->quirk->config(link);
|
||||||
|
|
||||||
i = pcmcia_request_configuration(link, &link->conf);
|
i = pcmcia_enable_device(link);
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
return -ENODEV;
|
return -ENODEV;
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,6 @@
|
||||||
#include <linux/mmc/sdio_func.h>
|
#include <linux/mmc/sdio_func.h>
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,6 @@
|
||||||
#include <linux/io.h>
|
#include <linux/io.h>
|
||||||
#include <linux/etherdevice.h>
|
#include <linux/etherdevice.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
|
@ -17,7 +17,6 @@
|
||||||
#include <linux/pci.h>
|
#include <linux/pci.h>
|
||||||
#include <linux/io.h>
|
#include <linux/io.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
|
|
@ -37,7 +37,6 @@ Status: experimental
|
||||||
#include <linux/delay.h>
|
#include <linux/delay.h>
|
||||||
#include <linux/pci.h>
|
#include <linux/pci.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -692,9 +691,6 @@ static int das16cs_pcmcia_attach(struct pcmcia_device *link)
|
||||||
local->link = link;
|
local->link = link;
|
||||||
link->priv = local;
|
link->priv = local;
|
||||||
|
|
||||||
/* Initialize the pcmcia_device structure */
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
cur_dev = link;
|
cur_dev = link;
|
||||||
|
|
||||||
das16cs_pcmcia_config(link);
|
das16cs_pcmcia_config(link);
|
||||||
|
@ -723,7 +719,7 @@ static int das16cs_pcmcia_config_loop(struct pcmcia_device *p_dev,
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -767,14 +763,13 @@ static void das16cs_pcmcia_config(struct pcmcia_device *link)
|
||||||
the I/O windows and the interrupt mapping, and putting the
|
the I/O windows and the interrupt mapping, and putting the
|
||||||
card and host interface into "Memory and IO" mode.
|
card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
/* Finally, report what we've done */
|
/* Finally, report what we've done */
|
||||||
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %u", link->irq);
|
||||||
printk(", irq %u", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(", io %pR", link->resource[0]);
|
printk(", io %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -48,7 +48,6 @@ Command support does not exist, but could be added for this board.
|
||||||
#include "das08.h"
|
#include "das08.h"
|
||||||
|
|
||||||
/* pcmcia includes */
|
/* pcmcia includes */
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -162,15 +161,6 @@ static int das08_pcmcia_attach(struct pcmcia_device *link)
|
||||||
local->link = link;
|
local->link = link;
|
||||||
link->priv = local;
|
link->priv = local;
|
||||||
|
|
||||||
/*
|
|
||||||
General socket configuration defaults can go here. In this
|
|
||||||
client, we assume very little, and rely on the CIS for almost
|
|
||||||
everything. In most clients, many details (i.e., number, sizes,
|
|
||||||
and attributes of IO windows) are fixed by the nature of the
|
|
||||||
device, and can be hard-wired here.
|
|
||||||
*/
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
cur_dev = link;
|
cur_dev = link;
|
||||||
|
|
||||||
das08_pcmcia_config(link);
|
das08_pcmcia_config(link);
|
||||||
|
@ -211,7 +201,7 @@ static int das08_pcmcia_config_loop(struct pcmcia_device *p_dev,
|
||||||
return -ENODEV;
|
return -ENODEV;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -263,14 +253,13 @@ static void das08_pcmcia_config(struct pcmcia_device *link)
|
||||||
the I/O windows and the interrupt mapping, and putting the
|
the I/O windows and the interrupt mapping, and putting the
|
||||||
card and host interface into "Memory and IO" mode.
|
card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
/* Finally, report what we've done */
|
/* Finally, report what we've done */
|
||||||
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %u", link->irq);
|
||||||
printk(", irq %u", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(", io %pR", link->resource[0]);
|
printk(", io %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -47,7 +47,6 @@ IRQ is assigned but not used.
|
||||||
|
|
||||||
#include <linux/ioport.h>
|
#include <linux/ioport.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -491,15 +490,6 @@ static int dio700_cs_attach(struct pcmcia_device *link)
|
||||||
local->link = link;
|
local->link = link;
|
||||||
link->priv = local;
|
link->priv = local;
|
||||||
|
|
||||||
/*
|
|
||||||
General socket configuration defaults can go here. In this
|
|
||||||
client, we assume very little, and rely on the CIS for almost
|
|
||||||
everything. In most clients, many details (i.e., number, sizes,
|
|
||||||
and attributes of IO windows) are fixed by the nature of the
|
|
||||||
device, and can be hard-wired here.
|
|
||||||
*/
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
pcmcia_cur_dev = link;
|
pcmcia_cur_dev = link;
|
||||||
|
|
||||||
dio700_config(link);
|
dio700_config(link);
|
||||||
|
@ -550,10 +540,10 @@ static int dio700_pcmcia_config_loop(struct pcmcia_device *p_dev,
|
||||||
|
|
||||||
/* Does this card need audio output? */
|
/* Does this card need audio output? */
|
||||||
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_SPKR;
|
p_dev->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -602,14 +592,13 @@ static void dio700_config(struct pcmcia_device *link)
|
||||||
the I/O windows and the interrupt mapping, and putting the
|
the I/O windows and the interrupt mapping, and putting the
|
||||||
card and host interface into "Memory and IO" mode.
|
card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret != 0)
|
if (ret != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
/* Finally, report what we've done */
|
/* Finally, report what we've done */
|
||||||
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %d", link->irq);
|
||||||
printk(", irq %d", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(", io %pR", link->resource[0]);
|
printk(", io %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -48,7 +48,6 @@ the PCMCIA interface.
|
||||||
|
|
||||||
#include "8255.h"
|
#include "8255.h"
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -243,15 +242,6 @@ static int dio24_cs_attach(struct pcmcia_device *link)
|
||||||
local->link = link;
|
local->link = link;
|
||||||
link->priv = local;
|
link->priv = local;
|
||||||
|
|
||||||
/*
|
|
||||||
General socket configuration defaults can go here. In this
|
|
||||||
client, we assume very little, and rely on the CIS for almost
|
|
||||||
everything. In most clients, many details (i.e., number, sizes,
|
|
||||||
and attributes of IO windows) are fixed by the nature of the
|
|
||||||
device, and can be hard-wired here.
|
|
||||||
*/
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
pcmcia_cur_dev = link;
|
pcmcia_cur_dev = link;
|
||||||
|
|
||||||
dio24_config(link);
|
dio24_config(link);
|
||||||
|
@ -302,10 +292,10 @@ static int dio24_pcmcia_config_loop(struct pcmcia_device *p_dev,
|
||||||
|
|
||||||
/* Does this card need audio output? */
|
/* Does this card need audio output? */
|
||||||
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_SPKR;
|
p_dev->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -353,14 +343,13 @@ static void dio24_config(struct pcmcia_device *link)
|
||||||
the I/O windows and the interrupt mapping, and putting the
|
the I/O windows and the interrupt mapping, and putting the
|
||||||
card and host interface into "Memory and IO" mode.
|
card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
/* Finally, report what we've done */
|
/* Finally, report what we've done */
|
||||||
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %d", link->irq);
|
||||||
printk(", irq %d", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(" & %pR", link->resource[0]);
|
printk(" & %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -71,7 +71,6 @@ NI manuals:
|
||||||
#include "comedi_fc.h"
|
#include "comedi_fc.h"
|
||||||
#include "ni_labpc.h"
|
#include "ni_labpc.h"
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -219,15 +218,6 @@ static int labpc_cs_attach(struct pcmcia_device *link)
|
||||||
local->link = link;
|
local->link = link;
|
||||||
link->priv = local;
|
link->priv = local;
|
||||||
|
|
||||||
/*
|
|
||||||
General socket configuration defaults can go here. In this
|
|
||||||
client, we assume very little, and rely on the CIS for almost
|
|
||||||
everything. In most clients, many details (i.e., number, sizes,
|
|
||||||
and attributes of IO windows) are fixed by the nature of the
|
|
||||||
device, and can be hard-wired here.
|
|
||||||
*/
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
pcmcia_cur_dev = link;
|
pcmcia_cur_dev = link;
|
||||||
|
|
||||||
labpc_config(link);
|
labpc_config(link);
|
||||||
|
@ -281,10 +271,10 @@ static int labpc_pcmcia_config_loop(struct pcmcia_device *p_dev,
|
||||||
|
|
||||||
/* Does this card need audio output? */
|
/* Does this card need audio output? */
|
||||||
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
if (cfg->flags & CISTPL_CFTABLE_AUDIO)
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_SPKR;
|
p_dev->config_flags |= CONF_ENABLE_SPKR;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ | CONF_ENABLE_PULSE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ | CONF_ENABLE_PULSE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -331,14 +321,14 @@ static void labpc_config(struct pcmcia_device *link)
|
||||||
the I/O windows and the interrupt mapping, and putting the
|
the I/O windows and the interrupt mapping, and putting the
|
||||||
card and host interface into "Memory and IO" mode.
|
card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
p_dev->config_flags |= CONF_ENABLE_IRQ | CONF_ENABLE_PULSE_IRQ;
|
||||||
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
/* Finally, report what we've done */
|
/* Finally, report what we've done */
|
||||||
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %d", link->irq);
|
||||||
printk(", irq %d", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(" & %pR", link->resource[0]);
|
printk(" & %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -48,7 +48,6 @@ See the notes in the ni_atmio.o driver.
|
||||||
#include "ni_stc.h"
|
#include "ni_stc.h"
|
||||||
#include "8255.h"
|
#include "8255.h"
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -265,7 +264,7 @@ static int cs_attach(struct pcmcia_device *link)
|
||||||
{
|
{
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_16;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_16;
|
||||||
link->resource[0]->end = 16;
|
link->resource[0]->end = 16;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
cur_dev = link;
|
cur_dev = link;
|
||||||
|
|
||||||
|
@ -336,7 +335,7 @@ static void mio_cs_config(struct pcmcia_device *link)
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
dev_info(&link->dev, "no IRQ available\n");
|
dev_info(&link->dev, "no IRQ available\n");
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int mio_cs_attach(struct comedi_device *dev, struct comedi_devconfig *it)
|
static int mio_cs_attach(struct comedi_device *dev, struct comedi_devconfig *it)
|
||||||
|
|
|
@ -50,7 +50,6 @@ Devices: [Quatech] DAQP-208 (daqp), DAQP-308
|
||||||
#include "../comedidev.h"
|
#include "../comedidev.h"
|
||||||
#include <linux/semaphore.h>
|
#include <linux/semaphore.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -1031,15 +1030,6 @@ static int daqp_cs_attach(struct pcmcia_device *link)
|
||||||
local->link = link;
|
local->link = link;
|
||||||
link->priv = local;
|
link->priv = local;
|
||||||
|
|
||||||
/*
|
|
||||||
General socket configuration defaults can go here. In this
|
|
||||||
client, we assume very little, and rely on the CIS for almost
|
|
||||||
everything. In most clients, many details (i.e., number, sizes,
|
|
||||||
and attributes of IO windows) are fixed by the nature of the
|
|
||||||
device, and can be hard-wired here.
|
|
||||||
*/
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
daqp_cs_config(link);
|
daqp_cs_config(link);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
@ -1088,7 +1078,7 @@ static int daqp_pcmcia_config_loop(struct pcmcia_device *p_dev,
|
||||||
return -ENODEV;
|
return -ENODEV;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -1132,14 +1122,13 @@ static void daqp_cs_config(struct pcmcia_device *link)
|
||||||
the I/O windows and the interrupt mapping, and putting the
|
the I/O windows and the interrupt mapping, and putting the
|
||||||
card and host interface into "Memory and IO" mode.
|
card and host interface into "Memory and IO" mode.
|
||||||
*/
|
*/
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
/* Finally, report what we've done */
|
/* Finally, report what we've done */
|
||||||
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
dev_info(&link->dev, "index 0x%02x", link->config_index);
|
||||||
if (link->conf.Attributes & CONF_ENABLE_IRQ)
|
printk(", irq %u", link->irq);
|
||||||
printk(", irq %u", link->irq);
|
|
||||||
if (link->resource[0])
|
if (link->resource[0])
|
||||||
printk(" & %pR", link->resource[0]);
|
printk(" & %pR", link->resource[0]);
|
||||||
if (link->resource[1])
|
if (link->resource[1])
|
||||||
|
|
|
@ -83,7 +83,6 @@
|
||||||
#include <linux/if_arp.h>
|
#include <linux/if_arp.h>
|
||||||
#include <linux/ioport.h>
|
#include <linux/ioport.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
@ -147,7 +146,7 @@ static int wl_adapter_attach(struct pcmcia_device *link)
|
||||||
|
|
||||||
link->resource[0]->end = HCF_NUM_IO_PORTS;
|
link->resource[0]->end = HCF_NUM_IO_PORTS;
|
||||||
link->resource[0]->flags= IO_DATA_PATH_WIDTH_16;
|
link->resource[0]->flags= IO_DATA_PATH_WIDTH_16;
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_index = 5;
|
link->config_index = 5;
|
||||||
link->config_regs = PRESENT_OPTION;
|
link->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
|
@ -301,7 +300,7 @@ void wl_adapter_insert(struct pcmcia_device *link)
|
||||||
dev = link->priv;
|
dev = link->priv;
|
||||||
|
|
||||||
/* Do we need to allocate an interrupt? */
|
/* Do we need to allocate an interrupt? */
|
||||||
link->conf.Attributes |= CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->io_lines = 6;
|
link->io_lines = 6;
|
||||||
|
|
||||||
ret = pcmcia_request_io(link);
|
ret = pcmcia_request_io(link);
|
||||||
|
@ -312,7 +311,7 @@ void wl_adapter_insert(struct pcmcia_device *link)
|
||||||
if (ret != 0)
|
if (ret != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret != 0)
|
if (ret != 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -69,7 +69,6 @@
|
||||||
******************************************************************************/
|
******************************************************************************/
|
||||||
#include <linux/version.h>
|
#include <linux/version.h>
|
||||||
#ifdef BUS_PCMCIA
|
#ifdef BUS_PCMCIA
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ciscode.h>
|
#include <pcmcia/ciscode.h>
|
||||||
|
|
|
@ -8,7 +8,6 @@
|
||||||
#include <linux/errno.h> /* error codes */
|
#include <linux/errno.h> /* error codes */
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
@ -143,7 +142,7 @@ static int ixj_config(struct pcmcia_device * link)
|
||||||
if (pcmcia_loop_config(link, ixj_config_check, &dflt))
|
if (pcmcia_loop_config(link, ixj_config_check, &dflt))
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
if (pcmcia_request_configuration(link, &link->conf))
|
if (pcmcia_enable_device(link))
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -20,7 +20,6 @@
|
||||||
#include <linux/ioport.h>
|
#include <linux/ioport.h>
|
||||||
#include <linux/platform_device.h>
|
#include <linux/platform_device.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/cisreg.h>
|
#include <pcmcia/cisreg.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
@ -159,7 +158,7 @@ static int sl811_cs_config_check(struct pcmcia_device *p_dev,
|
||||||
dflt->vpp1.param[CISTPL_POWER_VNOM]/10000;
|
dflt->vpp1.param[CISTPL_POWER_VNOM]/10000;
|
||||||
|
|
||||||
/* we need an interrupt */
|
/* we need an interrupt */
|
||||||
p_dev->conf.Attributes |= CONF_ENABLE_IRQ;
|
p_dev->config_flags |= CONF_ENABLE_IRQ;
|
||||||
|
|
||||||
/* IO window settings */
|
/* IO window settings */
|
||||||
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
|
||||||
|
@ -195,7 +194,7 @@ static int sl811_cs_config(struct pcmcia_device *link)
|
||||||
if (!link->irq)
|
if (!link->irq)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
@ -227,8 +226,6 @@ static int sl811_cs_probe(struct pcmcia_device *link)
|
||||||
local->p_dev = link;
|
local->p_dev = link;
|
||||||
link->priv = local;
|
link->priv = local;
|
||||||
|
|
||||||
link->conf.Attributes = 0;
|
|
||||||
|
|
||||||
return sl811_cs_config(link);
|
return sl811_cs_config(link);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,35 +0,0 @@
|
||||||
/*
|
|
||||||
* cs.h
|
|
||||||
*
|
|
||||||
* This program is free software; you can redistribute it and/or modify
|
|
||||||
* it under the terms of the GNU General Public License version 2 as
|
|
||||||
* published by the Free Software Foundation.
|
|
||||||
*
|
|
||||||
* The initial developer of the original code is David A. Hinds
|
|
||||||
* <dahinds@users.sourceforge.net>. Portions created by David A. Hinds
|
|
||||||
* are Copyright (C) 1999 David A. Hinds. All Rights Reserved.
|
|
||||||
*
|
|
||||||
* (C) 1999 David A. Hinds
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef _LINUX_CS_H
|
|
||||||
#define _LINUX_CS_H
|
|
||||||
|
|
||||||
#ifdef __KERNEL__
|
|
||||||
#include <linux/interrupt.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* For RequestConfiguration */
|
|
||||||
typedef struct config_req_t {
|
|
||||||
u_int Attributes;
|
|
||||||
} config_req_t;
|
|
||||||
|
|
||||||
/* Attributes for RequestConfiguration */
|
|
||||||
#define CONF_ENABLE_IRQ 0x01
|
|
||||||
#define CONF_ENABLE_DMA 0x02
|
|
||||||
#define CONF_ENABLE_SPKR 0x04
|
|
||||||
#define CONF_ENABLE_PULSE_IRQ 0x08
|
|
||||||
#define CONF_ENABLE_ESR 0x10
|
|
||||||
#define CONF_VALID_CLIENT 0x100
|
|
||||||
|
|
||||||
#endif /* _LINUX_CS_H */
|
|
|
@ -24,9 +24,11 @@
|
||||||
|
|
||||||
#ifdef __KERNEL__
|
#ifdef __KERNEL__
|
||||||
#include <linux/device.h>
|
#include <linux/device.h>
|
||||||
|
#include <linux/interrupt.h>
|
||||||
#include <pcmcia/ss.h>
|
#include <pcmcia/ss.h>
|
||||||
#include <asm/atomic.h>
|
#include <asm/atomic.h>
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* PCMCIA device drivers (16-bit cards only; 32-bit cards require CardBus
|
* PCMCIA device drivers (16-bit cards only; 32-bit cards require CardBus
|
||||||
* a.k.a. PCI drivers
|
* a.k.a. PCI drivers
|
||||||
|
@ -88,18 +90,16 @@ struct pcmcia_device {
|
||||||
|
|
||||||
struct list_head socket_device_list;
|
struct list_head socket_device_list;
|
||||||
|
|
||||||
/* deprecated, will be cleaned up soon */
|
|
||||||
config_req_t conf;
|
|
||||||
|
|
||||||
/* device setup */
|
/* device setup */
|
||||||
unsigned int irq;
|
unsigned int irq;
|
||||||
struct resource *resource[PCMCIA_NUM_RESOURCES];
|
struct resource *resource[PCMCIA_NUM_RESOURCES];
|
||||||
unsigned int vpp;
|
unsigned int vpp;
|
||||||
|
|
||||||
unsigned int io_lines; /* number of I/O lines */
|
unsigned int config_flags; /* CONF_ENABLE_ flags below */
|
||||||
unsigned int config_base;
|
unsigned int config_base;
|
||||||
unsigned int config_index;
|
unsigned int config_index;
|
||||||
unsigned int config_regs; /* PRESENT_ flags below */
|
unsigned int config_regs; /* PRESENT_ flags below */
|
||||||
|
unsigned int io_lines; /* number of I/O lines */
|
||||||
|
|
||||||
/* Is the device suspended? */
|
/* Is the device suspended? */
|
||||||
u16 suspended:1;
|
u16 suspended:1;
|
||||||
|
@ -207,8 +207,7 @@ pcmcia_request_exclusive_irq(struct pcmcia_device *p_dev,
|
||||||
int __must_check pcmcia_request_irq(struct pcmcia_device *p_dev,
|
int __must_check pcmcia_request_irq(struct pcmcia_device *p_dev,
|
||||||
irq_handler_t handler);
|
irq_handler_t handler);
|
||||||
|
|
||||||
int pcmcia_request_configuration(struct pcmcia_device *p_dev,
|
int pcmcia_enable_device(struct pcmcia_device *p_dev);
|
||||||
config_req_t *req);
|
|
||||||
|
|
||||||
int pcmcia_request_window(struct pcmcia_device *p_dev, struct resource *res,
|
int pcmcia_request_window(struct pcmcia_device *p_dev, struct resource *res,
|
||||||
unsigned int speed);
|
unsigned int speed);
|
||||||
|
@ -265,6 +264,12 @@ static inline int pcmcia_io_cfg_data_width(unsigned int flags)
|
||||||
#define PRESENT_IOBASE_3 0x100
|
#define PRESENT_IOBASE_3 0x100
|
||||||
#define PRESENT_IOSIZE 0x200
|
#define PRESENT_IOSIZE 0x200
|
||||||
|
|
||||||
|
/* flags to be passed to pcmcia_enable_device() */
|
||||||
|
#define CONF_ENABLE_IRQ 0x01
|
||||||
|
#define CONF_ENABLE_SPKR 0x02
|
||||||
|
#define CONF_ENABLE_PULSE_IRQ 0x04
|
||||||
|
#define CONF_ENABLE_ESR 0x08
|
||||||
|
|
||||||
#endif /* __KERNEL__ */
|
#endif /* __KERNEL__ */
|
||||||
|
|
||||||
#endif /* _LINUX_DS_H */
|
#endif /* _LINUX_DS_H */
|
||||||
|
|
|
@ -19,7 +19,6 @@
|
||||||
#include <linux/sched.h> /* task_struct, completion */
|
#include <linux/sched.h> /* task_struct, completion */
|
||||||
#include <linux/mutex.h>
|
#include <linux/mutex.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#ifdef CONFIG_CARDBUS
|
#ifdef CONFIG_CARDBUS
|
||||||
#include <linux/pci.h>
|
#include <linux/pci.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -142,7 +142,7 @@ static int snd_pdacf_probe(struct pcmcia_device *link)
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
link->resource[0]->end = 16;
|
link->resource[0]->end = 16;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ | CONF_ENABLE_PULSE_IRQ;
|
link->config_flags = CONF_ENABLE_IRQ | CONF_ENABLE_PULSE_IRQ;
|
||||||
link->config_index = 1;
|
link->config_index = 1;
|
||||||
link->config_regs = PRESENT_OPTION;
|
link->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
|
@ -217,6 +217,7 @@ static int pdacf_config(struct pcmcia_device *link)
|
||||||
|
|
||||||
snd_printdd(KERN_DEBUG "pdacf_config called\n");
|
snd_printdd(KERN_DEBUG "pdacf_config called\n");
|
||||||
link->config_index = 0x5;
|
link->config_index = 0x5;
|
||||||
|
link->config_flags |= CONF_ENABLE_IRQ | CONF_ENABLE_PULSE_IRQ;
|
||||||
|
|
||||||
ret = pcmcia_request_io(link);
|
ret = pcmcia_request_io(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
|
@ -226,7 +227,7 @@ static int pdacf_config(struct pcmcia_device *link)
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -24,7 +24,6 @@
|
||||||
#include <sound/pcm.h>
|
#include <sound/pcm.h>
|
||||||
#include <asm/io.h>
|
#include <asm/io.h>
|
||||||
#include <linux/interrupt.h>
|
#include <linux/interrupt.h>
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* Driver for Digigram VXpocket V2/440 soundcards
|
* Driver for Digigram VXpocket V2/440 soundcards
|
||||||
*
|
*
|
||||||
* Copyright (c) 2002 by Takashi Iwai <tiwai@suse.de>
|
* Copyright (c) 2002 by Takashi Iwai <tiwai@suse.de>
|
||||||
*
|
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
* the Free Software Foundation; either version 2 of the License, or
|
* the Free Software Foundation; either version 2 of the License, or
|
||||||
|
@ -162,7 +162,7 @@ static int snd_vxpocket_new(struct snd_card *card, int ibl,
|
||||||
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
|
||||||
link->resource[0]->end = 16;
|
link->resource[0]->end = 16;
|
||||||
|
|
||||||
link->conf.Attributes = CONF_ENABLE_IRQ;
|
link->config_flags |= CONF_ENABLE_IRQ;
|
||||||
link->config_index = 1;
|
link->config_index = 1;
|
||||||
link->config_regs = PRESENT_OPTION;
|
link->config_regs = PRESENT_OPTION;
|
||||||
|
|
||||||
|
@ -233,7 +233,7 @@ static int vxpocket_config(struct pcmcia_device *link)
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
ret = pcmcia_request_configuration(link, &link->conf);
|
ret = pcmcia_enable_device(link);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto failed;
|
goto failed;
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,6 @@
|
||||||
|
|
||||||
#include <sound/vx_core.h>
|
#include <sound/vx_core.h>
|
||||||
|
|
||||||
#include <pcmcia/cs.h>
|
|
||||||
#include <pcmcia/cistpl.h>
|
#include <pcmcia/cistpl.h>
|
||||||
#include <pcmcia/ds.h>
|
#include <pcmcia/ds.h>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue