hw/sd/sdcard: Zero out function selection fields before being populated
commit89c6700fe7eed9195f10055751edbc6d5e7ab940
authorBin Meng <bin.meng@windriver.com>
Sat, 24 Oct 2020 01:49:54 +0000 (24 09:49 +0800)
committerPhilippe Mathieu-Daudé <f4bug@amsat.org>
Mon, 26 Oct 2020 08:23:47 +0000 (26 09:23 +0100)
treead5edc1709cb49b4dc82f65257fa2f5537afbd9b
parent692fb0ef31af680632c84bc18bc639cba4a0e24b
hw/sd/sdcard: Zero out function selection fields before being populated

The function selection fields (399:376) should be zeroed out to
prevent leftover from being or'ed into the switch function status
data structure.

This fixes the boot failure as seen in the acceptance testing on
the orangepi target.

Fixes: b638627c723a ("hw/sd: Fix incorrect populated function switch status data structure")
Reported-by: Michael Roth <mdroth@linux.vnet.ibm.com>
Signed-off-by: Bin Meng <bin.meng@windriver.com>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20201024014954.21330-1-bmeng.cn@gmail.com>
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
hw/sd/sd.c