diff options
author | Dominik Brodowski <linux@dominikbrodowski.net> | 2010-07-30 03:51:52 -0400 |
---|---|---|
committer | Dominik Brodowski <linux@dominikbrodowski.net> | 2010-09-29 11:20:23 -0400 |
commit | 440eed43e2a95bb842488755683716814da10f2b (patch) | |
tree | 45c49181a077f845cd366cfa7dc07f259fd01078 /include/pcmcia/ds.h | |
parent | 9485ee14e143c7076e88deea1e87ca3eb0b2f94e (diff) |
pcmcia: introduce autoconfiguration feature
Introduce an autoconfiguration feature to set certain values in
pcmcia_loop_config(), instead of copying the same code over and over
in each PCMCIA driver. At first, introduce the following options:
CONF_AUTO_CHECK_VCC check or matching Vcc entry
CONF_AUTO_SET_VPP set Vpp
CONF_AUTO_AUDIO enable the speaker line
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>
Diffstat (limited to 'include/pcmcia/ds.h')
-rw-r--r-- | include/pcmcia/ds.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/include/pcmcia/ds.h b/include/pcmcia/ds.h index 50b03fd67fd6..0577e5f10304 100644 --- a/include/pcmcia/ds.h +++ b/include/pcmcia/ds.h | |||
@@ -177,7 +177,6 @@ int pcmcia_loop_config(struct pcmcia_device *p_dev, | |||
177 | int (*conf_check) (struct pcmcia_device *p_dev, | 177 | int (*conf_check) (struct pcmcia_device *p_dev, |
178 | cistpl_cftable_entry_t *cf, | 178 | cistpl_cftable_entry_t *cf, |
179 | cistpl_cftable_entry_t *dflt, | 179 | cistpl_cftable_entry_t *dflt, |
180 | unsigned int vcc, | ||
181 | void *priv_data), | 180 | void *priv_data), |
182 | void *priv_data); | 181 | void *priv_data); |
183 | 182 | ||
@@ -270,6 +269,12 @@ static inline int pcmcia_io_cfg_data_width(unsigned int flags) | |||
270 | #define CONF_ENABLE_PULSE_IRQ 0x04 | 269 | #define CONF_ENABLE_PULSE_IRQ 0x04 |
271 | #define CONF_ENABLE_ESR 0x08 | 270 | #define CONF_ENABLE_ESR 0x08 |
272 | 271 | ||
272 | /* flags used by pcmcia_loop_config() autoconfiguration */ | ||
273 | #define CONF_AUTO_CHECK_VCC 0x10 /* check for matching Vcc? */ | ||
274 | #define CONF_AUTO_SET_VPP 0x20 /* set Vpp? */ | ||
275 | #define CONF_AUTO_AUDIO 0x40 /* enable audio line? */ | ||
276 | |||
277 | |||
273 | #endif /* __KERNEL__ */ | 278 | #endif /* __KERNEL__ */ |
274 | 279 | ||
275 | #endif /* _LINUX_DS_H */ | 280 | #endif /* _LINUX_DS_H */ |