Skip to contentSkip to conversation

"mmc_host mmc0: WARNING: IMR=0x00004040" on debug console

DISCUSSION Thomas Bechtold 2 participants 2 messages Jan 19, 2012 – Feb 4, 2012 MMC, SD and SDIO

lore
Share & tools
lore
#0 lore raw

Hi,

i updated from kernel 2.6.35.3 (from kernel.org) to kernel 3.2.1 (from kernel.org) on arm (at91stamp9G20) and have a MMC card which can be completly disabled with a hardware switch. The mmc card is then used by another processor without linux. That works very well.
My question is, why i get always the message "mmc_host mmc0: WARNING:
IMR=0x00004040" after i removed the mmc card slot once. That's a new behavior with 3.2.1. I had no message with 2.6.35.3.
When the mmc slot returns to linux, the message stops and i get:

mmc_host mmc0: WARNING: IMR=0x00004040
mmc0: host does not support reading read-only switch. assuming write-enable.
mmc0: new SD card at address b368
mmcblk0: mmc0:b368 H1697 1.91 GiB
mmcblk0: unknown partition table

That's fine.

Should i just ignore the message (or simple patch
driver/mmc/host/atmel_mci.c)?

TIA

Tom

#1 lore raw

Hi, adding some recent atmel-mci.c committers to the thread,

Quoted 15 lines · Thomas Bechtold

i updated from kernel 2.6.35.3 (from kernel.org) to kernel 3.2.1 (from kernel.org) on arm (at91stamp9G20) and have a MMC card which can be completly disabled with a hardware switch. The mmc card is then used by another processor without linux. That works very well.
My question is, why i get always the message "mmc_host mmc0: WARNING:
IMR=0x00004040" after i removed the mmc card slot once. That's a new behavior with 3.2.1. I had no message with 2.6.35.3.
When the mmc slot returns to linux, the message stops and i get:

mmc_host mmc0: WARNING: IMR=0x00004040
mmc0: host does not support reading read-only switch. assuming write-enable.
mmc0: new SD card at address b368
mmcblk0: mmc0:b368 H1697 1.91 GiB
mmcblk0: unknown partition table

Quoted 4 lines

That's fine.

Should i just ignore the message (or simple patch
driver/mmc/host/atmel_mci.c)?

It would be good to leave the warning in for situations that we still don't expect, and it looks like IMR=0x00004040 decodes to ATMCI_ENDTX and ATMCI_TXBUFE, so you could try something like:

        if (iflags & ~(ATMCI_SDIOIRQA | ATMCI_SDIOIRQB)) {
                /* Interrupts with ENDTX and TXBUFE set are seen
                 * with at91stamp9G20 hardware when switching the
                 * processor that MMC is attached to, so don't warn
                 * if they are set. 
                 */
                if (iflags & ~(ATMCI_ENDTX | ATMCI_TXBUFE)) {
                        dev_warn(&slot->mmc->class_dev, "WARNING: IMR="
                                 "0x%08x\n", iflags);
                }
        }

- Chris.

Signature · 2 lines
Chris Ball   <[email protected]>   <http://printf.net/>
One Laptop Per Child