change log for rtems (2010-06-21)

rtems-vc at rtems.org rtems-vc at rtems.org
Mon Jun 21 16:11:50 UTC 2010


 *sh*:
2010-06-21	Arnout Vandecappelle <arnout at mind.be>

	PR 1576/misc
	* libchip/i2c/spi-sd-card.c: Enable CRC checks.

M  1.524  c/src/ChangeLog
M   1.19  c/src/libchip/i2c/spi-sd-card.c

diff -u rtems/c/src/ChangeLog:1.523 rtems/c/src/ChangeLog:1.524
--- rtems/c/src/ChangeLog:1.523	Mon Jun 21 09:36:24 2010
+++ rtems/c/src/ChangeLog	Mon Jun 21 10:25:04 2010
@@ -1,5 +1,10 @@
 2010-06-21	Arnout Vandecappelle <arnout at mind.be>
 
+	PR 1576/misc
+	* libchip/i2c/spi-sd-card.c: Enable CRC checks.
+
+2010-06-21	Arnout Vandecappelle <arnout at mind.be>
+
 	PR 1569/misc
 	* libchip/i2c/spi-sd-card.c: Added CRC checks.
 

diff -u rtems/c/src/libchip/i2c/spi-sd-card.c:1.18 rtems/c/src/libchip/i2c/spi-sd-card.c:1.19
--- rtems/c/src/libchip/i2c/spi-sd-card.c:1.18	Mon Jun 21 09:36:25 2010
+++ rtems/c/src/libchip/i2c/spi-sd-card.c	Mon Jun 21 10:25:04 2010
@@ -461,7 +461,8 @@
 	}
 
 	crc7 = sd_card_compute_crc7( e->response + e->response_index, 5);
-	if (crc7 != SD_CARD_COMMAND_GET_CRC7( e->response + e->response_index)) {
+	if (crc7 != SD_CARD_COMMAND_GET_CRC7( e->response + e->response_index) &&
+		SD_CARD_COMMAND_GET_CRC7( e->response + e->response_index) != 0x7f) {
 		RTEMS_SYSLOG_ERROR( "CRC check failed on register command\n");
 		return -RTEMS_IO_ERROR;
 	}
@@ -752,6 +753,9 @@
 		cmd_arg = SD_CARD_FLAG_HCS;
 	}
 
+	/* Enable CRC */
+	sd_card_send_command( e, SD_CARD_CMD_CRC_ON_OFF, 1);
+
 	/* Initialize card */
 	while (true) {
 		if (assume_sd) {



--

Generated by Deluxe Loginfo [http://www.codewiz.org/projects/index.html#loginfo] 2.122 by Bernardo Innocenti <bernie at develer.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/vc/attachments/20100621/bb83e252/attachment-0001.html>


More information about the vc mailing list