Add mmc_read_disc_information. Change get_disctype to use it and thus it

moves from mmc.c into mmc_hl_cmds.c. Status is now the return type, not
erasable.

Split mmc_cmds.h into mmc_ll_cmds.h and mmc_hl_cmds.h.
test/driver/mmc.c for invalid page check we get the right sense key,
asc, and ascq.
This commit is contained in:
R. Bernstein
2010-02-09 22:39:05 -05:00
parent 245a9a645f
commit 80304a8cef
11 changed files with 597 additions and 454 deletions

View File

@@ -92,13 +92,13 @@ static driver_return_code_t
test_get_disc_erasable(const CdIo_t *p_cdio, const char *psz_source,
bool verbose)
{
driver_return_code_t drc;
bool b_erasable = mmc_get_disc_erasable(p_cdio, &drc);
if (verbose)
driver_return_code_t i_status;
bool b_erasable;
i_status = mmc_get_disc_erasable(p_cdio, &b_erasable);
if (verbose && DRIVER_OP_SUCCESS == i_status)
printf("Disc is %serasable.\n", b_erasable ? "" : "not ");
/* Try also with NULL. */
b_erasable = mmc_get_disc_erasable(p_cdio, NULL);
return drc;
return i_status;
}