- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I've been perusing the DCT code to get a better feel for how it works. (My main concern was how/if backwards compatibility would be handled if, for example, the device was upgraded to v1.2 which added new DCT data, then downgraded back to v1.1. Looks like this will be fine.)
Anyway, if I understand the code correctly, the data-length check at the beginning of platform_write_dct() isn't quite right. It's currently:
/* Check if the data is too big to write */
if ( data_length + data_start_offset > ( PLATFORM_DCT_COPY1_END_ADDRESS - PLATFORM_DCT_COPY1_START_ADDRESS ) )
{
return -1;
}
But I think it should be:
/* Check if the data is too big to write */
if ( sizeof(platform_dct_header_t) + data_length + data_start_offset > ( PLATFORM_DCT_COPY1_END_ADDRESS - PLATFORM_DCT_COPY1_START_ADDRESS ) )
{
return -1;
}
More generally -- is this the place you'd like people to be submitting bug reports?
Cheers!
- Labels:
-
SPI
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
Thank you very much, you are correct. There is a possible bug during dct data write to the flash if the total data is greater than 16K. Issue will be fixed on next release.
Thanks,
Seyhan