Skip to content

Commit

Permalink
clang-format
Browse files Browse the repository at this point in the history
  • Loading branch information
Jake-Carter committed Aug 11, 2023
1 parent af2e766 commit 48ebe8c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Libraries/PeriphDrivers/Source/SYS/sys_ai85.c
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ int MXC_SYS_GetUSN(uint8_t *usn, uint8_t *checksum)

uint32_t _usn_32[MXC_SYS_USN_CHECKSUM_LEN / 4];
// ^ Declare as uint32_t to preserve mem alignment
uint8_t *_usn_8 = (uint8_t *) _usn_32;
uint8_t *_usn_8 = (uint8_t *)_usn_32;
memset(_usn_8, 0, MXC_SYS_USN_CHECKSUM_LEN);

_usn_8[0] = (infoblock[0] & 0x007F8000) >> 15;
Expand Down
4 changes: 2 additions & 2 deletions Libraries/PeriphDrivers/Source/SYS/sys_ai87.c
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ int MXC_SYS_GetUSN(uint8_t *usn, uint8_t *checksum)

uint32_t _usn_32[MXC_SYS_USN_CHECKSUM_LEN / 4];
// ^ Declare as uint32_t to preserve mem alignment
uint8_t *_usn_8 = (uint8_t *) _usn_32;
uint8_t *_usn_8 = (uint8_t *)_usn_32;
memset(_usn_8, 0, MXC_SYS_USN_CHECKSUM_LEN);

_usn_8[0] = (infoblock[0] & 0x007F8000) >> 15;
Expand All @@ -102,7 +102,7 @@ int MXC_SYS_GetUSN(uint8_t *usn, uint8_t *checksum)
/* If requested, verify and return the checksum */
if (checksum != NULL) {
uint32_t _check_csum_32[MXC_SYS_USN_CHECKSUM_LEN / 4];
// ^ Declare as uint32_t to preserve mem alignment
// ^ Declare as uint32_t to preserve mem alignment
uint8_t *check_csum = (uint8_t *)_check_csum_32;
memset(check_csum, 0, MXC_SYS_USN_CHECKSUM_LEN);
uint8_t aes_key[MXC_SYS_USN_CHECKSUM_LEN] = { 0 }; // NULL Key (per checksum spec)
Expand Down

0 comments on commit 48ebe8c

Please sign in to comment.