aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/telephony/ixj_pcmcia.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/telephony/ixj_pcmcia.c')
-rw-r--r--drivers/telephony/ixj_pcmcia.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/drivers/telephony/ixj_pcmcia.c b/drivers/telephony/ixj_pcmcia.c
index 99cb2246ac72..a1900e502518 100644
--- a/drivers/telephony/ixj_pcmcia.c
+++ b/drivers/telephony/ixj_pcmcia.c
@@ -8,7 +8,6 @@
8#include <linux/errno.h> /* error codes */ 8#include <linux/errno.h> /* error codes */
9#include <linux/slab.h> 9#include <linux/slab.h>
10 10
11#include <pcmcia/cs_types.h>
12#include <pcmcia/cs.h> 11#include <pcmcia/cs.h>
13#include <pcmcia/cistpl.h> 12#include <pcmcia/cistpl.h>
14#include <pcmcia/ds.h> 13#include <pcmcia/ds.h>
@@ -33,9 +32,8 @@ static int ixj_probe(struct pcmcia_device *p_dev)
33{ 32{
34 dev_dbg(&p_dev->dev, "ixj_attach()\n"); 33 dev_dbg(&p_dev->dev, "ixj_attach()\n");
35 /* Create new ixj device */ 34 /* Create new ixj device */
36 p_dev->io.Attributes1 = IO_DATA_PATH_WIDTH_8; 35 p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
37 p_dev->io.Attributes2 = IO_DATA_PATH_WIDTH_8; 36 p_dev->resource[1]->flags |= IO_DATA_PATH_WIDTH_8;
38 p_dev->io.IOAddrLines = 3;
39 p_dev->conf.IntType = INT_MEMORY_AND_IO; 37 p_dev->conf.IntType = INT_MEMORY_AND_IO;
40 p_dev->priv = kzalloc(sizeof(struct ixj_info_t), GFP_KERNEL); 38 p_dev->priv = kzalloc(sizeof(struct ixj_info_t), GFP_KERNEL);
41 if (!p_dev->priv) { 39 if (!p_dev->priv) {
@@ -121,13 +119,14 @@ static int ixj_config_check(struct pcmcia_device *p_dev,
121{ 119{
122 if ((cfg->io.nwin > 0) || (dflt->io.nwin > 0)) { 120 if ((cfg->io.nwin > 0) || (dflt->io.nwin > 0)) {
123 cistpl_io_t *io = (cfg->io.nwin) ? &cfg->io : &dflt->io; 121 cistpl_io_t *io = (cfg->io.nwin) ? &cfg->io : &dflt->io;
124 p_dev->io.BasePort1 = io->win[0].base; 122 p_dev->resource[0]->start = io->win[0].base;
125 p_dev->io.NumPorts1 = io->win[0].len; 123 p_dev->resource[0]->end = io->win[0].len;
124 p_dev->io_lines = 3;
126 if (io->nwin == 2) { 125 if (io->nwin == 2) {
127 p_dev->io.BasePort2 = io->win[1].base; 126 p_dev->resource[1]->start = io->win[1].base;
128 p_dev->io.NumPorts2 = io->win[1].len; 127 p_dev->resource[1]->end = io->win[1].len;
129 } 128 }
130 if (!pcmcia_request_io(p_dev, &p_dev->io)) 129 if (!pcmcia_request_io(p_dev))
131 return 0; 130 return 0;
132 } 131 }
133 return -ENODEV; 132 return -ENODEV;
@@ -151,7 +150,8 @@ static int ixj_config(struct pcmcia_device * link)
151 /* 150 /*
152 * Register the card with the core. 151 * Register the card with the core.
153 */ 152 */
154 j = ixj_pcmcia_probe(link->io.BasePort1, link->io.BasePort1 + 0x10); 153 j = ixj_pcmcia_probe(link->resource[0]->start,
154 link->resource[0]->start + 0x10);
155 155
156 info->ndev = 1; 156 info->ndev = 1;
157 ixj_get_serial(link, j); 157 ixj_get_serial(link, j);