-
Notifications
You must be signed in to change notification settings - Fork 6.6k
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
susbys/dfu/img_util: support ERASE PROGRESSIVELY for non-flash mem #79152
Conversation
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…mentation Moved MCUboot trailer's status erase ahead any write operation. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
f21eb74
to
8314f7f
Compare
subsys/dfu/img_util/flash_img.c
Outdated
*/ | ||
offset = (toff + fparams->write_block_size - 1) & | ||
~(fparams->write_block_size - 1); | ||
/* No alignment correction neede here, offset is corrected already */ |
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.
'and size should be aligned'
Please squash both commits together. |
8314f7f
to
cb4cd12
Compare
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
cb4cd12
to
1c63254
Compare
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
subsys/dfu/img_util/flash_img.c
Outdated
} else | ||
#endif | ||
{ | ||
|
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.
stray newline
subsys/dfu/img_util/flash_img.c
Outdated
*/ | ||
offset = (toff + fparams->write_block_size - 1) & | ||
~(fparams->write_block_size - 1); | ||
/* No alignment correction neede here, offset is corrected already |
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.
/* No alignment correction neede here, offset is corrected already | |
/* No alignment correction needed here, offset is corrected already |
subsys/dfu/img_util/flash_img.c
Outdated
int flash_img_buffered_write(struct flash_img_context *ctx, const uint8_t *data, | ||
size_t len, bool flush) | ||
{ | ||
int rc; | ||
|
||
rc = stream_flash_buffered_write(&ctx->stream, data, len, flush); | ||
if (!flush) { | ||
/* If there is need to erase trailer, that should happen before any |
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.
/* If there is need to erase trailer, that should happen before any | |
/* If there is a need to erase the trailer, that should happen before any |
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
1c63254
to
95198b1
Compare
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
95198b1
to
32eab50
Compare
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…mentation Moved MCUboot trailer's status erase ahead any write operation, which is step which helps with addition of support for devices don't require explicit pager erase. For these kind of devices flattening of mcuboot image status in the trailer was introduced. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no>
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no> (cherry picked from commit 30f066a)
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no> (cherry picked from commit 30f066a)
…on-flash mem Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant. Upstream PR: zephyrproject-rtos/zephyr#79152 Signed-off-by: Andrzej Puzdrowski <andrzej.puzdrowski@nordicsemi.no> (cherry picked from commit 30f066a)
Added support for devices don't require explicit pager erase. For these device flattening of mcuboot image status is relevant.