aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDominik Brodowski <linux@dominikbrodowski.net>2005-06-27 19:29:01 -0400
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-06-27 21:03:22 -0400
commit57b6281cea59639cce995745f1dc42fe9da2c533 (patch)
tree3853530c322d331417bc5184af38fb77a061d6d1
parent1a8ceafce5f1e68c28c7ba52fd7e72ab0008eb46 (diff)
[PATCH] pcmcia: 8 and 16 bit access for static_map
The PCMCIA card services layer is never setting the i/o map attributes when SS_CAP_STATIC_MAP is specified. Net result, sockets' set_io_map() calls always see requests with most flags clear, meaning 8 bit access. For hardware that always autosizes, that won't matter; and all current STATIC_MAP drivers ignore those attributes. A new driver (for at91rm9200) suffers badly from this, since this forces everything into 8 bit mode and that breaks both (a) cards requiring 16 bit access, and (b) ide-cs; but of course 8-bit cards work OK (as does accessing card attributes). So this patch arranges to pass the attributes down, matching the behavior for non-static mappings (using the first/only I/O window). Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.de> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
-rw-r--r--drivers/pcmcia/pcmcia_resource.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/pcmcia/pcmcia_resource.c b/drivers/pcmcia/pcmcia_resource.c
index 9ed3d4a9b99c..c01dc6bf1526 100644
--- a/drivers/pcmcia/pcmcia_resource.c
+++ b/drivers/pcmcia/pcmcia_resource.c
@@ -89,6 +89,7 @@ static int alloc_io_space(struct pcmcia_socket *s, u_int attr, ioaddr_t *base,
89 } 89 }
90 if ((s->features & SS_CAP_STATIC_MAP) && s->io_offset) { 90 if ((s->features & SS_CAP_STATIC_MAP) && s->io_offset) {
91 *base = s->io_offset | (*base & 0x0fff); 91 *base = s->io_offset | (*base & 0x0fff);
92 s->io[0].Attributes = attr;
92 return 0; 93 return 0;
93 } 94 }
94 /* Check for an already-allocated window that must conflict with 95 /* Check for an already-allocated window that must conflict with