All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH 00/20] sdcard: proper implementation of CRC
@ 2018-05-04 15:58 Philippe Mathieu-Daudé
  2018-05-04 15:58 ` [Qemu-devel] [PATCH 01/20] sdcard: Use the ldst API Philippe Mathieu-Daudé
                   ` (20 more replies)
  0 siblings, 21 replies; 26+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-05-04 15:58 UTC (permalink / raw)
  To: Peter Maydell, Edgar E . Iglesias
  Cc: Philippe Mathieu-Daudé,
	qemu-devel, Paolo Bonzini, Stefan Hajnoczi, Alistair Francis

Hi,

This series emerged after last Coverity scan and Peter suggestion in:
http://lists.nongnu.org/archive/html/qemu-devel/2018-04/msg05046.html

    (3) "proper" implementation of CRC, so that an sd controller
    can either (a) mark the SDRequest as "no CRC" and have
    sd_req_crc_validate() always pass, or (b) mark the SDRequest
    as having a CRC and have sd_req_crc_validate() actually
    do the check which it currently stubs out with "return 0"

- Coverity issues fixed (up to patch 6)
- crc16 now works
- new functions documented
- qtests added

Regards,

Phil.

Philippe Mathieu-Daudé (20):
  sdcard: Use the ldst API
  sdcard: Extract sd_calc_frame48_crc7() from sd_req_crc_validate()
  sdcard: Rename the SDRequest as SDFrame48
  sdcard: Add sd_prepare_request[_with_crc]()
  sdcard: Use the sd_prepare_request*() functions
  sdcard: Add a "validate-crc" property
  sdcard: Constify sd_crc*()'s message argument
  sdcard: Fix sd_crc*() style
  sdcard: Expose sd_crc*() functions for QTest use
  sdcard: Expose sd_prepare_request*() functions for QTest use
  sdcard: Add test_sd_request_frame_crc7() qtest (request command CRC7)
  sdcard: Let sd_frame48_crc7_calc() work on response frames
  sdcard: Expose sd_prepare_frame48() for QTest use
  sdcard: Add test_sd_response_frame48_crc7 qtest (command response CRC7)
  sdcard: Add SDFrame136 struct and 136-bit SD response frames functions
  sdcard: Add test_sd_response_frame136_crc7() qtest
  sdcard: Add SDFrameData struct and data frame checksum functions
  sdcard: Fix sd_crc16()
  sdcard: Add test_sd_data_frame_crc16() qtest
  sdcard: Add test_sd_verify_cksum_frame48() qtest

 hw/sd/sdmmc-internal.h    |  24 +++++++
 include/hw/sd/sd.h        | 136 +++++++++++++++++++++++++++++++++++++-
 hw/sd/bcm2835_sdhost.c    |   3 +-
 hw/sd/milkymist-memcard.c |   9 ++-
 hw/sd/omap_mmc.c          |   4 +-
 hw/sd/pxa2xx_mmci.c       |   4 +-
 hw/sd/sd.c                |  48 +++-----------
 hw/sd/sdhci.c             |   6 +-
 hw/sd/sdmmc-internal.c    | 114 ++++++++++++++++++++++++++++++++
 hw/sd/ssi-sd.c            |   6 +-
 tests/sdcard-test.c       | 116 ++++++++++++++++++++++++++++++++
 tests/Makefile.include    |   2 +
 12 files changed, 409 insertions(+), 63 deletions(-)
 create mode 100644 tests/sdcard-test.c

-- 
2.17.0

^ permalink raw reply	[flat|nested] 26+ messages in thread

end of thread, other threads:[~2018-05-07 20:09 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-04 15:58 [Qemu-devel] [PATCH 00/20] sdcard: proper implementation of CRC Philippe Mathieu-Daudé
2018-05-04 15:58 ` [Qemu-devel] [PATCH 01/20] sdcard: Use the ldst API Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 02/20] sdcard: Extract sd_calc_frame48_crc7() from sd_req_crc_validate() Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 03/20] sdcard: Rename the SDRequest as SDFrame48 Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 04/20] sdcard: Add sd_prepare_request[_with_crc]() Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 05/20] sdcard: Use the sd_prepare_request*() functions Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 06/20] sdcard: Add a "validate-crc" property Philippe Mathieu-Daudé
2018-05-04 23:33   ` Alistair Francis
2018-05-04 15:59 ` [Qemu-devel] [PATCH 07/20] sdcard: Constify sd_crc*()'s message argument Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 08/20] sdcard: Fix sd_crc*() style Philippe Mathieu-Daudé
2018-05-04 23:34   ` Alistair Francis
2018-05-04 15:59 ` [Qemu-devel] [PATCH 09/20] sdcard: Expose sd_crc*() functions for QTest use Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 10/20] sdcard: Expose sd_prepare_request*() " Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 11/20] sdcard: Add test_sd_request_frame_crc7() qtest (request command CRC7) Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 12/20] sdcard: Let sd_frame48_crc7_calc() work on response frames Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 13/20] sdcard: Expose sd_prepare_frame48() for QTest use Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 14/20] sdcard: Add test_sd_response_frame48_crc7 qtest (command response CRC7) Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 15/20] sdcard: Add SDFrame136 struct and 136-bit SD response frames functions Philippe Mathieu-Daudé
2018-05-04 16:57   ` Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 16/20] sdcard: Add test_sd_response_frame136_crc7() qtest Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 17/20] sdcard: Add SDFrameData struct and data frame checksum functions Philippe Mathieu-Daudé
2018-05-05  2:22   ` Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 18/20] sdcard: Fix sd_crc16() Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 19/20] sdcard: Add test_sd_data_frame_crc16() qtest Philippe Mathieu-Daudé
2018-05-04 15:59 ` [Qemu-devel] [PATCH 20/20] sdcard: Add test_sd_verify_cksum_frame48() qtest Philippe Mathieu-Daudé
2018-05-07 20:09 ` [Qemu-devel] [PATCH 00/20] sdcard: proper implementation of CRC Philippe Mathieu-Daudé

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.