qemu-patch-raspberry4/hw
Philippe Mathieu-Daudé 9e1245795f sdcard: Update the Configuration Register (SCR) to Spec Version 1.10
The initial implementation is based on the Specs v1.10 (see a1bb27b1e9).

However the SCR is anouncing the card being v1.01.

The new chapters added in version 1.10 are:

    4.3.10 Switch function command

    Switch function command (CMD6) 1 is used to switch or expand
    memory card functions. [...]
    This is a new feature, introduced in SD physical Layer
    Specification Version 1.10. Therefore, cards that are
    compatible with earlier versions of the spec do not support
    it. The host shall check the "SD_SPEC" field in the SCR
    register to recognize what version of the spec the card
    complies with before using CMD6. It is mandatory for SD
    memory card of Ver1.10 to support CMD6.

    4.3.11 High-Speed mode (25MB/sec interface speed)

    Though the Rev 1.01 SD memory card supports up to 12.5MB/sec
    interface speed, the speed of 25MB/sec is necessary to support
    increasing performance needs of the host and because of memory
    size which continues to grow.
    To achieve 25MB/sec interface speed, clock rate is increased to
    50MHz and CLK/CMD/DAT signal timing and circuit conditions are
    reconsidered and changed from Physical Layer Specification
    Version 1.01.

    4.3.12 Command system (This chapter is newly added in version 1.10)

    SD commands CMD34-37, CMD50, CMD57 are reserved for SD command
    system expansion via the switch command.
    [These commands] will be considered as illegal commands (as
    defined in revision 1.01 of the SD physical layer specification).

The SWITCH_FUNCTION is implemented since the first commit, a1bb27b1e9.

The 25MB/sec High-Speed mode was already updated in d7ecb86752.

The current implementation does not implements CMD34-37, CMD50 and
CMD57, thus these commands already return ILLEGAL.

With this patch, the SCR register now matches the description of the header:

 * SD Memory Card emulation as defined in the "SD Memory Card Physical
 * layer specification, Version 1.10."

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-id: 20180607180641.874-2-f4bug@amsat.org
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2018-06-08 13:15:33 +01:00
..
9pfs 9p: xattr: Properly translate xattrcreate flags 2018-06-07 12:17:22 +02:00
acpi acpi, vhost, misc: fixes, features 2018-06-04 10:15:16 +01:00
adc Include qapi/error.h exactly where needed 2018-02-09 13:50:17 +01:00
alpha hw/alpha/dp264: Use the TYPE_SMC37C669_SUPERIO 2018-03-12 16:12:49 +01:00
arm stellaris: Add trailing '\n' to qemu_log() calls 2018-06-08 13:15:33 +01:00
audio hw/i2c: Use DeviceClass::realize instead of I2CSlaveClass::init 2018-06-01 15:14:31 +02:00
block acpi, vhost, misc: fixes, features 2018-06-04 10:15:16 +01:00
bt hw/bt: Replace fprintf(stderr, "*\n" with error_report() 2018-01-22 09:51:00 +01:00
char hw/digic: Add trailing '\n' to qemu_log() calls 2018-06-08 13:15:33 +01:00
core hw/core/register: Add trailing '\n' to qemu_log() call 2018-06-08 13:15:33 +01:00
cpu hw: use "qemu/osdep.h" as first #include in source files 2017-12-18 17:07:02 +03:00
cris hw: Do not include "sysemu/block-backend.h" if it is not necessary 2018-06-01 14:15:10 +02:00
display xilinx-dp: Add trailing '\n' to qemu_log() call 2018-06-08 13:15:33 +01:00
dma xlnx-zdma: Correct mem leaks and memset to zero on desc unaligned errors 2018-05-31 14:50:52 +01:00
gpio hw/i2c: Use DeviceClass::realize instead of I2CSlaveClass::init 2018-06-01 15:14:31 +02:00
hppa acpi, vhost, misc: fixes, features 2018-06-04 10:15:16 +01:00
i2c hw/i2c: Add trace events 2018-06-08 13:15:33 +01:00
i386 migration/next for 20180604 2018-06-04 12:54:00 +01:00
ide acpi, vhost, misc: fixes, features 2018-06-04 10:15:16 +01:00
input hw: make virtio devices configurable via default-configs/ 2018-06-01 15:14:31 +02:00
intc arm_gicv3_kvm: kvm_dist_get/put: skip the registers banked by GICR 2018-06-08 13:15:32 +01:00
ipack pci: Add INTERFACE_CONVENTIONAL_PCI_DEVICE to Conventional PCI devices 2017-10-15 05:54:43 +03:00
ipmi ipmi: Use proper struct reference for KCS vmstate 2018-06-01 15:13:46 +02:00
isa hw/isa/superio: Fix inconsistent use of Chardev->be 2018-06-01 15:13:46 +02:00
lm32 hw: Do not include "sysemu/block-backend.h" if it is not necessary 2018-06-01 14:15:10 +02:00
m68k hw: Do not include "exec/address-spaces.h" if it is not necessary 2018-06-01 14:15:10 +02:00
mem nvdimm: fix typo in label-size definition 2018-05-23 17:02:03 +03:00
microblaze hw: Do not include "sysemu/block-backend.h" if it is not necessary 2018-06-01 14:15:10 +02:00
mips hw/mips/boston: Add trailing '\n' to qemu_log() calls 2018-06-08 13:15:33 +01:00
misc misc: add pca9552 LED blinker model 2018-06-08 13:15:32 +01:00
moxie Change references to serial_hds[] to serial_hd() 2018-04-26 13:57:00 +01:00
net ftgmac100: remove check on runt messages 2018-06-08 13:15:32 +01:00
nios2 Change references to serial_hds[] to serial_hd() 2018-04-26 13:57:00 +01:00
nvram * Linux header upgrade (Peter) 2018-06-01 18:24:16 +01:00
openrisc Change references to serial_hds[] to serial_hd() 2018-04-26 13:57:00 +01:00
pci virtio,vhost,pci,pc: features, cleanups 2018-03-20 15:48:34 +00:00
pci-bridge virtio,vhost,pci,pc: features, fixes and cleanups 2018-02-13 16:33:31 +00:00
pci-host hw: Do not include "exec/address-spaces.h" if it is not necessary 2018-06-01 14:15:10 +02:00
pcmcia hw: Clean up includes 2016-01-29 15:07:25 +00:00
ppc ppc/pnv: Add trailing '\n' to qemu_log() calls 2018-06-08 13:15:33 +01:00
rdma hw/rdma: Fix possible out of bounds access to port GID index 2018-05-03 20:52:29 +03:00
riscv hw: Do not include "exec/address-spaces.h" if it is not necessary 2018-06-01 14:15:10 +02:00
s390x * Linux header upgrade (Peter) 2018-06-01 18:24:16 +01:00
scsi acpi, vhost, misc: fixes, features 2018-06-04 10:15:16 +01:00
sd sdcard: Update the Configuration Register (SCR) to Spec Version 1.10 2018-06-08 13:15:33 +01:00
sh4 hw: Do not include "sysemu/block-backend.h" if it is not necessary 2018-06-01 14:15:10 +02:00
smbios Move include qemu/option.h from qemu-common.h to actual users 2018-02-09 13:52:16 +01:00
sparc Change references to serial_hds[] to serial_hd() 2018-04-26 13:57:00 +01:00
sparc64 serial-isa: Use MAX_ISA_SERIAL_PORTS instead of MAX_SERIAL_PORTS 2018-04-26 13:57:00 +01:00
ssi xilinx_spips: Correct SNOOP_NONE state when flushing the txfifo 2018-04-26 11:04:40 +01:00
timer hw/digic: Add trailing '\n' to qemu_log() calls 2018-06-08 13:15:33 +01:00
tpm tpm: extend TPM TIS with state migration support 2018-05-24 12:07:04 -04:00
tricore hw: Do not include "sysemu/block-backend.h" if it is not necessary 2018-03-12 16:12:46 +01:00
unicore32 hw/input/i8042: Extract declarations from i386/pc.h into input/i8042.h 2018-03-12 16:12:48 +01:00
usb acpi, vhost, misc: fixes, features 2018-06-04 10:15:16 +01:00
vfio vfio/pci: Default display option to "off" 2018-06-05 08:28:09 -06:00
virtio acpi, vhost, misc: fixes, features 2018-06-04 10:15:16 +01:00
watchdog qapi: Empty out qapi-schema.json 2018-03-02 13:45:50 -06:00
xen * Linux header upgrade (Peter) 2018-06-01 18:24:16 +01:00
xenpv hw/xen*: Replace fprintf(stderr, "*\n" with error_report() 2018-02-06 18:29:46 +01:00
xtensa hw: Do not include "sysemu/block-backend.h" if it is not necessary 2018-06-01 14:15:10 +02:00
Makefile.objs hw: allow compiling out SCSI 2018-06-01 15:14:31 +02:00