mirror of https://github.com/ARMmbed/mbed-os.git
Fix possible negative QSPI alt count on STM
Remove an extraneous decrement operation in cases where the alt bits size is a multiple of 8.pull/11297/head
parent
baf375f8cb
commit
9b32c0f316
|
@ -305,7 +305,6 @@ qspi_status_t qspi_prepare_command(const qspi_command_t *command, QSPI_CommandTy
|
||||||
// Align alt value to the end of the most significant byte
|
// Align alt value to the end of the most significant byte
|
||||||
st_command->AlternateBytes = command->alt.value << leftover_bits;
|
st_command->AlternateBytes = command->alt.value << leftover_bits;
|
||||||
} else {
|
} else {
|
||||||
rounded_size -= 1;
|
|
||||||
st_command->AlternateBytes = command->alt.value;
|
st_command->AlternateBytes = command->alt.value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue