access to CF card registers doesn't look good
Holger Schurig
hs4233 at mail.mn-solutions.de
Tue Feb 20 11:06:04 EST 2007
Hmm, I'm already at the first obstacle.
I insert my CF card ("product info: "Marvell", "802.11 CF", "ID:
04", "", manfid: 0x02df, 0x8103); my driver loads and I parse
the CIS. I then get
mrv8xxx_cs: enter libertas_cs_config() at 134
mrv8xxx_cs: eth1: at 0.0, irq 11, io 0xc100-0xc17f
The from-to numbers are
p_dev->io.BasePort1,
p_dev->io.BasePort1 + p_dev->io.NumPorts1 - 1
Now I map this in and get a dump of the registers:
mem = ioport_map(p_dev->io.BasePort1, p_dev->io.NumPorts1);
for (i=0; i<0x200; i+=2) {
printk("%04x: %04x\n", i, ioread16(card->mem + i));
}
and I get the dump at the end of my message. However, the spec
that I have talks in the context of the CF Interface / Firmware
download:
Check the Card Configuration and Scratch port register (0x3f)
- if it is 0x5a, firmware is already there
- if it is 0x00, bootloader is ready to download firmware
- else, this register has an invalid value
So the question is: does my card need the helper download? Am I
accessing the hardware correctly? Where am I dumb?
0000: 0000
0002: 0000
0004: 001f
0006: 0000
0008: 0000
000a: c000
000c: 0000
000e: c000
0010: 8490
0012: 0940
0014: 0000
0016: 0000
0018: 0000
001a: 0000
001c: 0013
001e: 0000
0020: 0004
0022: 0000
0024: 0000
0026: 0000
0028: 0000
002a: c000
002c: 0000
002e: c000
0030: 0000
0032: 0000
0034: 0000
0036: c000
0038: 0000
003a: c000
003c: 0200
003e: 008f
0040: 0000
0042: 0000
0044: 0017
0046: 0000
0048: 0301
004a: 0000
004c: 8490
004e: 0000
0050: 0000
0052: c000
0054: 0000
0056: c000
0058: f040
005a: 0000
005c: 0003
005e: 0001
0060: 0000
0062: 0000
0064: 0000
0066: 0000
0068: 0000
006a: 0000
006c: 0000
006e: 0000
0070: 0000
0072: 0000
0074: 0000
0076: 0000
0078: 0000
007a: 0000
007c: 0000
007e: 0000
0080: ffff
...
01fe: ffff
More information about the libertas-dev
mailing list