diff options
Diffstat (limited to 'drivers/ssb/pcmcia.c')
-rw-r--r-- | drivers/ssb/pcmcia.c | 15 |
1 files changed, 2 insertions, 13 deletions
diff --git a/drivers/ssb/pcmcia.c b/drivers/ssb/pcmcia.c index e72f4046a5e0..526682d68de8 100644 --- a/drivers/ssb/pcmcia.c +++ b/drivers/ssb/pcmcia.c | |||
@@ -13,7 +13,6 @@ | |||
13 | #include <linux/io.h> | 13 | #include <linux/io.h> |
14 | #include <linux/etherdevice.h> | 14 | #include <linux/etherdevice.h> |
15 | 15 | ||
16 | #include <pcmcia/cs_types.h> | ||
17 | #include <pcmcia/cs.h> | 16 | #include <pcmcia/cs.h> |
18 | #include <pcmcia/cistpl.h> | 17 | #include <pcmcia/cistpl.h> |
19 | #include <pcmcia/ciscode.h> | 18 | #include <pcmcia/ciscode.h> |
@@ -72,14 +71,9 @@ | |||
72 | /* Write to a PCMCIA configuration register. */ | 71 | /* Write to a PCMCIA configuration register. */ |
73 | static int ssb_pcmcia_cfg_write(struct ssb_bus *bus, u8 offset, u8 value) | 72 | static int ssb_pcmcia_cfg_write(struct ssb_bus *bus, u8 offset, u8 value) |
74 | { | 73 | { |
75 | conf_reg_t reg; | ||
76 | int res; | 74 | int res; |
77 | 75 | ||
78 | memset(®, 0, sizeof(reg)); | 76 | res = pcmcia_write_config_byte(bus->host_pcmcia, offset, value); |
79 | reg.Offset = offset; | ||
80 | reg.Action = CS_WRITE; | ||
81 | reg.Value = value; | ||
82 | res = pcmcia_access_configuration_register(bus->host_pcmcia, ®); | ||
83 | if (unlikely(res != 0)) | 77 | if (unlikely(res != 0)) |
84 | return -EBUSY; | 78 | return -EBUSY; |
85 | 79 | ||
@@ -89,16 +83,11 @@ static int ssb_pcmcia_cfg_write(struct ssb_bus *bus, u8 offset, u8 value) | |||
89 | /* Read from a PCMCIA configuration register. */ | 83 | /* Read from a PCMCIA configuration register. */ |
90 | static int ssb_pcmcia_cfg_read(struct ssb_bus *bus, u8 offset, u8 *value) | 84 | static int ssb_pcmcia_cfg_read(struct ssb_bus *bus, u8 offset, u8 *value) |
91 | { | 85 | { |
92 | conf_reg_t reg; | ||
93 | int res; | 86 | int res; |
94 | 87 | ||
95 | memset(®, 0, sizeof(reg)); | 88 | res = pcmcia_read_config_byte(bus->host_pcmcia, offset, value); |
96 | reg.Offset = offset; | ||
97 | reg.Action = CS_READ; | ||
98 | res = pcmcia_access_configuration_register(bus->host_pcmcia, ®); | ||
99 | if (unlikely(res != 0)) | 89 | if (unlikely(res != 0)) |
100 | return -EBUSY; | 90 | return -EBUSY; |
101 | *value = reg.Value; | ||
102 | 91 | ||
103 | return 0; | 92 | return 0; |
104 | } | 93 | } |