Hi Yoichi, > --- mips-orig/drivers/mmc/host/au1xmmc.c 2007-05-11 10:27:01.068483750 +0900 > +++ mips/drivers/mmc/host/au1xmmc.c 2007-05-11 19:13:11.426283750 +0900 > @@ -189,7 +189,7 @@ static void au1xmmc_tasklet_finish(unsig > @@ -213,24 +213,17 @@ static int au1xmmc_send_command(struct a > return MMC_ERR_INVALID; > } > > - switch(cmd->opcode) { > - case MMC_READ_SINGLE_BLOCK: > - case SD_APP_SEND_SCR: > - mmccmd |= SD_CMD_CT_2; > - break; > - case MMC_READ_MULTIPLE_BLOCK: > - mmccmd |= SD_CMD_CT_4; > - break; > - case MMC_WRITE_BLOCK: > - mmccmd |= SD_CMD_CT_1; > - break; > - > - case MMC_WRITE_MULTIPLE_BLOCK: > - mmccmd |= SD_CMD_CT_3; > - break; > - case MMC_STOP_TRANSMISSION: > - mmccmd |= SD_CMD_CT_7; > - break; > + flags = cmd->data->flags; ^^^^^^^^ This line oopses the driver on my Au1200 ->data can be NULL > + if (flags & MMC_DATA_READ) { > + if (flags & MMC_DATA_MULTI) > + mmccmd |= SD_CMD_CT_4; > + else > + mmccmd |= SD_CMD_CT_2; > + } else if (flags & MMC_DATA_WRITE) { > + if (flags & MMC_DATA_MULTI) > + mmccmd |= SD_CMD_CT_3; > + else > + mmccmd |= SD_CMD_CT_1; > } what about SD_CMD_CT_7? Hows this: if (cmd->data) flags = cmd->data->flags; else if (cmd->opcode == 12) mmccmd |= CD_SMD_CT_7; else flags = 0; if (flags & MMC_DATA_READ) { [...] > au_writel(cmd->arg, HOST_CMDARG(host)); > Thanks, Manuel Lauss