zephyr: replace zephyr integer types with C99 types

git grep -l 'u\(8\|16\|32\|64\)_t' | \
		xargs sed -i "s/u\(8\|16\|32\|64\)_t/uint\1_t/g"
	git grep -l 's\(8\|16\|32\|64\)_t' | \
		xargs sed -i "s/s\(8\|16\|32\|64\)_t/int\1_t/g"

Signed-off-by: Kumar Gala <kumar.gala@linaro.org>
This commit is contained in:
Kumar Gala 2020-05-27 11:26:57 -05:00 committed by Kumar Gala
commit a1b77fd589
2364 changed files with 32505 additions and 32505 deletions

View file

@ -24,7 +24,7 @@ LOG_MODULE_REGISTER(LOG_DOMAIN);
* offset and len must be aligned on 8 for write,
* positive and not beyond end of flash
*/
bool flash_stm32_valid_range(struct device *dev, off_t offset, u32_t len,
bool flash_stm32_valid_range(struct device *dev, off_t offset, uint32_t len,
bool write)
{
return (!write || (offset % 8 == 0 && len % 8 == 0U)) &&
@ -39,11 +39,11 @@ static unsigned int get_page(off_t offset)
return offset >> STM32G4X_PAGE_SHIFT;
}
static int write_dword(struct device *dev, off_t offset, u64_t val)
static int write_dword(struct device *dev, off_t offset, uint64_t val)
{
volatile u32_t *flash = (u32_t *)(offset + CONFIG_FLASH_BASE_ADDRESS);
volatile uint32_t *flash = (uint32_t *)(offset + CONFIG_FLASH_BASE_ADDRESS);
FLASH_TypeDef *regs = FLASH_STM32_REGS(dev);
u32_t tmp;
uint32_t tmp;
int rc;
/* if the control register is locked, do not fail silently */
@ -72,8 +72,8 @@ static int write_dword(struct device *dev, off_t offset, u64_t val)
tmp = regs->CR;
/* Perform the data write operation at the desired memory address */
flash[0] = (u32_t)val;
flash[1] = (u32_t)(val >> 32);
flash[0] = (uint32_t)val;
flash[1] = (uint32_t)(val >> 32);
/* Wait until the BSY bit is cleared */
rc = flash_stm32_wait_flash_idle(dev);
@ -87,7 +87,7 @@ static int write_dword(struct device *dev, off_t offset, u64_t val)
static int erase_page(struct device *dev, unsigned int page)
{
FLASH_TypeDef *regs = FLASH_STM32_REGS(dev);
u32_t tmp;
uint32_t tmp;
int rc;
/* if the control register is locked, do not fail silently */
@ -166,7 +166,7 @@ int flash_stm32_write_range(struct device *dev, unsigned int offset,
int i, rc = 0;
for (i = 0; i < len; i += 8, offset += 8) {
rc = write_dword(dev, offset, ((const u64_t *) data)[i>>3]);
rc = write_dword(dev, offset, ((const uint64_t *) data)[i>>3]);
if (rc < 0) {
return rc;
}