From fc16cfaefee3ea5f417ecd16453686ac89413bb3 Mon Sep 17 00:00:00 2001 From: Xiang Xiao Date: Mon, 25 Apr 2022 14:36:11 +0800 Subject: [PATCH] Correct the code alignment found in review Signed-off-by: Xiang Xiao --- arch/risc-v/src/bl602/bl602_pwm_lowerhalf.c | 4 ++-- arch/risc-v/src/bl602/bl602_serial.c | 2 +- arch/risc-v/src/esp32c3/esp32c3_usbserial.c | 2 +- arch/sim/src/sim/up_keyboard.c | 2 +- .../pic32mx7mmb/src/pic32_touchscreen.c | 24 +++++++++---------- 5 files changed, 17 insertions(+), 17 deletions(-) diff --git a/arch/risc-v/src/bl602/bl602_pwm_lowerhalf.c b/arch/risc-v/src/bl602/bl602_pwm_lowerhalf.c index 2a7128eb5f..cbf144fe25 100644 --- a/arch/risc-v/src/bl602/bl602_pwm_lowerhalf.c +++ b/arch/risc-v/src/bl602/bl602_pwm_lowerhalf.c @@ -362,8 +362,8 @@ static int bl602_pwm_start(struct pwm_lowerhalf_s *dev, const struct pwm_info_s *info) { struct bl602_pwm_s *priv = (struct bl602_pwm_s *)dev; - int ret = OK; - int i; + int ret = OK; + int i; UNUSED(i); diff --git a/arch/risc-v/src/bl602/bl602_serial.c b/arch/risc-v/src/bl602/bl602_serial.c index 3b3ae9f42b..4787a6852c 100644 --- a/arch/risc-v/src/bl602/bl602_serial.c +++ b/arch/risc-v/src/bl602/bl602_serial.c @@ -391,7 +391,7 @@ static void bl602_shutdown(struct uart_dev_s *dev) static int bl602_attach(struct uart_dev_s *dev) { - int ret; + int ret; struct bl602_uart_s *priv = (struct bl602_uart_s *)dev->priv; ret = irq_attach(priv->irq, __uart_interrupt, (void *)dev); diff --git a/arch/risc-v/src/esp32c3/esp32c3_usbserial.c b/arch/risc-v/src/esp32c3/esp32c3_usbserial.c index 340a0b7684..84702daa04 100644 --- a/arch/risc-v/src/esp32c3/esp32c3_usbserial.c +++ b/arch/risc-v/src/esp32c3/esp32c3_usbserial.c @@ -402,7 +402,7 @@ static int esp32c3_ioctl(struct file *filep, int cmd, unsigned long arg) struct inode *inode = filep->f_inode; struct uart_dev_s *dev = inode->i_private; #endif - int ret = OK; + int ret = OK; switch (cmd) { diff --git a/arch/sim/src/sim/up_keyboard.c b/arch/sim/src/sim/up_keyboard.c index 413b124dfe..e2eb436798 100644 --- a/arch/sim/src/sim/up_keyboard.c +++ b/arch/sim/src/sim/up_keyboard.c @@ -69,7 +69,7 @@ static struct up_dev_s g_simkeyboard; int sim_kbd_initialize(void) { - int ret; + int ret; struct up_dev_s *priv = &g_simkeyboard; memset(priv, 0, sizeof(*priv)); diff --git a/boards/mips/pic32mx/pic32mx7mmb/src/pic32_touchscreen.c b/boards/mips/pic32mx/pic32mx7mmb/src/pic32_touchscreen.c index 7c7544be81..d36dee946d 100644 --- a/boards/mips/pic32mx/pic32mx7mmb/src/pic32_touchscreen.c +++ b/boards/mips/pic32mx/pic32mx7mmb/src/pic32_touchscreen.c @@ -978,9 +978,9 @@ static int tc_open(struct file *filep) { #ifdef CONFIG_TOUCHSCREEN_REFCNT struct inode *inode; - struct tc_dev_s *priv; - uint8_t tmp; - int ret; + struct tc_dev_s *priv; + uint8_t tmp; + int ret; DEBUGASSERT(filep); inode = filep->f_inode; @@ -1031,8 +1031,8 @@ static int tc_close(struct file *filep) { #ifdef CONFIG_TOUCHSCREEN_REFCNT struct inode *inode; - struct tc_dev_s *priv; - int ret; + struct tc_dev_s *priv; + int ret; DEBUGASSERT(filep); inode = filep->f_inode; @@ -1070,10 +1070,10 @@ static int tc_close(struct file *filep) static ssize_t tc_read(struct file *filep, char *buffer, size_t len) { struct inode *inode; - struct tc_dev_s *priv; + struct tc_dev_s *priv; struct touch_sample_s *report; struct tc_sample_s sample; - int ret; + int ret; DEBUGASSERT(filep); inode = filep->f_inode; @@ -1195,8 +1195,8 @@ static int tc_ioctl(struct file *filep, int cmd, unsigned long arg) return -ENOTTY; /* None yet supported */ #else struct inode *inode; - struct tc_dev_s *priv; - int ret; + struct tc_dev_s *priv; + int ret; iinfo("cmd: %d arg: %ld\n", cmd, arg); DEBUGASSERT(filep); @@ -1237,9 +1237,9 @@ static int tc_poll(struct file *filep, struct pollfd *fds, bool setup) { struct inode *inode; - struct tc_dev_s *priv; - int ret; - int i; + struct tc_dev_s *priv; + int ret; + int i; iinfo("setup: %d\n", (int)setup); DEBUGASSERT(filep && fds);