shell_history: align buffer to pointer size
The code in shell_history_put() adds padding to new entries so they are pointer aligned. The whole buffer has to be so aligned too. Signed-off-by: Nicolas Pitre <npitre@baylibre.com>
This commit is contained in:
parent
2dc6eea143
commit
91d057f146
1 changed files with 1 additions and 1 deletions
|
@ -31,7 +31,7 @@ struct shell_history {
|
||||||
* @param _size Memory dedicated for shell history.
|
* @param _size Memory dedicated for shell history.
|
||||||
*/
|
*/
|
||||||
#define SHELL_HISTORY_DEFINE(_name, _size) \
|
#define SHELL_HISTORY_DEFINE(_name, _size) \
|
||||||
static u8_t __noinit __aligned(sizeof(u32_t)) \
|
static u8_t __noinit __aligned(sizeof(void *)) \
|
||||||
_name##_ring_buf_data[_size]; \
|
_name##_ring_buf_data[_size]; \
|
||||||
static struct ring_buf _name##_ring_buf = \
|
static struct ring_buf _name##_ring_buf = \
|
||||||
{ \
|
{ \
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue