-
-
Notifications
You must be signed in to change notification settings - Fork 178
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FatFS fixes for F7 series #1538
Conversation
Hi @networkfusion, I'm nanoFramework bot. A human will be reviewing it shortly. 😉 |
if (mmcStartSequentialWrite(&FATFS_HAL_DEVICE, sector)) | ||
return RES_ERROR; | ||
// invalidate cache on buffer | ||
cacheBufferFlush(buff, MMCSD_BLOCK_SIZE*count); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here but inside the while. Similar reason, if we don't flush the cache the data chunk to be written could be still have older data.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeap
BTW, why is this a breaking change? |
It's a breaking change more in the sense that's breaking with ChibiOS code. From a code perspective it looks lile more an enhacement along with a bug fix (for F7). |
Just edited the code to make a couple of adjustments and add proper comments. |
Fine by me... I am guessing the read commands also need adding to the contrib repo for it to work as expected? Once this is merged, I will add the changes so that we can seperate from the FatFS zip in chibiOS to using our own git repo... |
Also, I am guessing we need to adjust the FatFS source once separated to we can align buffers? |
That's absolutely mandatory for cache invalidate otherwise will mess up with the adjacent memory. |
Description
Use our own diskio.c file for FatFS since the ChibiOS project is unwilling to add it.
TODO (as seperate PR's)
Use our own (up to date) FatFS repo
Add read cache invalidation to the chibios_contrib version.
How Has This Been Tested?
Testing is still to be completed!
Screenshots
Types of changes
Checklist: