You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by ag...@apache.org on 2020/04/14 16:19:23 UTC
[incubator-nuttx] 02/02: nxstyle fixes for previous commit.
This is an automated email from the ASF dual-hosted git repository.
aguettouche pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
commit 61f6fa769a0cd9ee95e86d094b7991d477d425ff
Author: Gregory Nutt <gn...@nuttx.org>
AuthorDate: Tue Apr 14 09:42:35 2020 -0600
nxstyle fixes for previous commit.
---
arch/arm/src/lc823450/lc823450_i2c.c | 16 ++++++++++++----
arch/arm/src/stm32l4/stm32l4_1wire.c | 4 +++-
arch/arm/src/stm32l4/stm32l4_i2c.c | 2 +-
3 files changed, 16 insertions(+), 6 deletions(-)
diff --git a/arch/arm/src/lc823450/lc823450_i2c.c b/arch/arm/src/lc823450/lc823450_i2c.c
index 8716903..009ef95 100644
--- a/arch/arm/src/lc823450/lc823450_i2c.c
+++ b/arch/arm/src/lc823450/lc823450_i2c.c
@@ -589,7 +589,9 @@ static void lc823450_i2c_starttransfer(FAR struct lc823450_i2c_priv_s *priv)
{
if (priv->dcnt > 1)
{
- /* If the next byte to be received is not final, we have to send ACK. */
+ /* If the next byte to be received is not final, we have to send
+ * ACK.
+ */
modifyreg32(priv->config->base + I2CCTL, I2C_CTL_ACK,
I2C_CTL_ACK);
@@ -665,7 +667,9 @@ static int lc823450_i2c_poll(FAR struct lc823450_i2c_priv_s *priv)
if (flags & I2C_M_READ)
{
- /* When READ transaction, terminate it with NACK and then STOP condition */
+ /* When READ transaction, terminate it with NACK and then STOP
+ * condition.
+ */
lc823450_i2c_sendnack(priv);
}
@@ -765,7 +769,9 @@ static int lc823450_i2c_poll(FAR struct lc823450_i2c_priv_s *priv)
if (priv->msgv->flags & I2C_M_NOSTART)
{
- /* In this case, we don't have to restart using START condition. */
+ /* In this case, we don't have to restart using START
+ * condition.
+ */
i2cinfo("no re-START condition\n");
@@ -931,7 +937,9 @@ static int lc823450_i2c_deinit(FAR struct lc823450_i2c_priv_s *priv,
modifyreg32(priv->config->base + I2CSTR, I2C_CTL_SCLR, I2C_CTL_SCLR);
modifyreg32(priv->config->base + I2CCTL, I2C_CTL_SRST, I2C_CTL_SRST);
- /* Change pinmux from I2C to GPIO, and i2c mode to Push-Pull to Open Drain */
+ /* Change pinmux from I2C to GPIO, and i2c mode to Push-Pull to Open
+ * Drain.
+ */
if (port == 0)
{
diff --git a/arch/arm/src/stm32l4/stm32l4_1wire.c b/arch/arm/src/stm32l4/stm32l4_1wire.c
index 82ecf63..4a47798 100644
--- a/arch/arm/src/stm32l4/stm32l4_1wire.c
+++ b/arch/arm/src/stm32l4/stm32l4_1wire.c
@@ -1183,7 +1183,9 @@ static int stm32_1wire_pm_prepare(FAR struct pm_callback_s *cb, int domain,
if (sval <= 0)
{
- /* Exclusive lock is held, do not allow entry to deeper PM states. */
+ /* Exclusive lock is held, do not allow entry to deeper PM
+ * states.
+ */
return -EBUSY;
}
diff --git a/arch/arm/src/stm32l4/stm32l4_i2c.c b/arch/arm/src/stm32l4/stm32l4_i2c.c
index 19cc04a..c0d2159 100644
--- a/arch/arm/src/stm32l4/stm32l4_i2c.c
+++ b/arch/arm/src/stm32l4/stm32l4_i2c.c
@@ -931,7 +931,7 @@ static inline int stm32l4_i2c_sem_waitdone(FAR struct stm32l4_i2c_priv_s *priv)
************************************************************************************/
static inline void
-stm32l4_i2c_set_7bit_address(FAR struct stm32l4_i2c_priv_s *priv)
+ stm32l4_i2c_set_7bit_address(FAR struct stm32l4_i2c_priv_s *priv)
{
stm32l4_i2c_modifyreg32(priv, STM32L4_I2C_CR2_OFFSET, I2C_CR2_SADD7_MASK,
((priv->msgv->addr & 0x7f) << I2C_CR2_SADD7_SHIFT));