Fix nxstyle warnings

This commit is contained in:
Nakamura, Yuuichi 2020-07-10 10:08:49 +09:00 committed by Xiang Xiao
parent f392d246d3
commit 9db5d2aeea
6 changed files with 36 additions and 22 deletions

View File

@ -1,7 +1,8 @@
/**************************************************************************** /****************************************************************************
* arch/avr/src/common/up_initialize.c * arch/avr/src/common/up_initialize.c
* *
* Copyright (C) 2010, 2012-2013, 2015-2017 Gregory Nutt. All rights reserved. * Copyright (C) 2010, 2012-2013, 2015-2017 Gregory Nutt. All rights
* reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
* *
* Redistribution and use in source and binary forms, with or without * Redistribution and use in source and binary forms, with or without
@ -64,7 +65,8 @@
/* Determine which (if any) console driver to use. This will probably cause /* Determine which (if any) console driver to use. This will probably cause
* up_serialinit to be incorrectly called if there is no USART configured to * up_serialinit to be incorrectly called if there is no USART configured to
* be an RS-232 device (see as an example arch/avr/src/at32uc23/at32uc3_config.h) * be an RS-232 device (see as an example
* arch/avr/src/at32uc23/at32uc3_config.h)
* This will probably have to be revisited someday. * This will probably have to be revisited someday.
* *
* If a console is enabled and no other console device is specified, then a * If a console is enabled and no other console device is specified, then a
@ -166,8 +168,8 @@ void up_initialize(void)
#endif #endif
#ifdef CONFIG_ARCH_DMA #ifdef CONFIG_ARCH_DMA
/* Initialize the DMA subsystem if the weak function up_dma_initialize has been /* Initialize the DMA subsystem if the weak function up_dma_initialize has
* brought into the build * been brought into the build
*/ */
#ifdef CONFIG_HAVE_WEAKFUNCTIONS #ifdef CONFIG_HAVE_WEAKFUNCTIONS

View File

@ -1,7 +1,8 @@
/**************************************************************************** /****************************************************************************
* arch/hc/src/common/up_initialize.c * arch/hc/src/common/up_initialize.c
* *
* Copyright (C) 2009-2010, 2012-2013, 2015-2017 Gregory Nutt. All rights reserved. * Copyright (C) 2009-2010, 2012-2013, 2015-2017 Gregory Nutt. All rights
* reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
* *
* Redistribution and use in source and binary forms, with or without * Redistribution and use in source and binary forms, with or without
@ -99,8 +100,8 @@ void up_initialize(void)
#endif #endif
#ifdef CONFIG_ARCH_DMA #ifdef CONFIG_ARCH_DMA
/* Initialize the DMA subsystem if the weak function up_dma_initialize has been /* Initialize the DMA subsystem if the weak function up_dma_initialize has
* brought into the build * been brought into the build
*/ */
#ifdef CONFIG_HAVE_WEAKFUNCTIONS #ifdef CONFIG_HAVE_WEAKFUNCTIONS

View File

@ -74,7 +74,8 @@ void up_enable_icache(void)
mfspr(SPR_SYS_ICCFGR, iccfg); mfspr(SPR_SYS_ICCFGR, iccfg);
syslog(LOG_INFO, "ICACHE NCW: %d NCS: %d CBS: %d CCRI: %d CBIRI: %d CBPRI: %d\n", syslog(LOG_INFO,
"ICACHE NCW: %d NCS: %d CBS: %d CCRI: %d CBIRI: %d CBPRI: %d\n",
(iccfg & SPR_ICCFGR_NCW_MASK) >> SPR_ICCFGR_NCW_SHIFT, (iccfg & SPR_ICCFGR_NCW_MASK) >> SPR_ICCFGR_NCW_SHIFT,
(iccfg & SPR_ICCFGR_NCS_MASK) >> SPR_ICCFGR_NCS_SHIFT, (iccfg & SPR_ICCFGR_NCS_MASK) >> SPR_ICCFGR_NCS_SHIFT,
(iccfg & SPR_ICCFGR_CBS) ? 1 : 0, (iccfg & SPR_ICCFGR_CBS) ? 1 : 0,
@ -91,7 +92,6 @@ void up_enable_icache(void)
mfspr(SPR_SYS_SR, sr); mfspr(SPR_SYS_SR, sr);
sr |= SPR_SR_ICE; sr |= SPR_SR_ICE;
mtspr(SPR_SYS_SR, sr); mtspr(SPR_SYS_SR, sr);
} }
#endif #endif
@ -104,7 +104,8 @@ void up_enable_dcache(void)
mfspr(SPR_SYS_DCCFGR, dccfg); mfspr(SPR_SYS_DCCFGR, dccfg);
syslog(LOG_INFO, "DCACHE NCW: %d NCS: %d CBS: %d CCRI: %d CBIRI: %d CBPRI: %d\n", syslog(LOG_INFO,
"DCACHE NCW: %d NCS: %d CBS: %d CCRI: %d CBIRI: %d CBPRI: %d\n",
(dccfg & SPR_DCCFGR_NCW_MASK) >> SPR_DCCFGR_NCW_SHIFT, (dccfg & SPR_DCCFGR_NCW_MASK) >> SPR_DCCFGR_NCW_SHIFT,
(dccfg & SPR_DCCFGR_NCS_MASK) >> SPR_DCCFGR_NCS_SHIFT, (dccfg & SPR_DCCFGR_NCS_MASK) >> SPR_DCCFGR_NCS_SHIFT,
(dccfg & SPR_DCCFGR_CBS) ? 1 : 0, (dccfg & SPR_DCCFGR_CBS) ? 1 : 0,
@ -194,8 +195,8 @@ void up_initialize(void)
#endif #endif
#ifdef CONFIG_ARCH_DMA #ifdef CONFIG_ARCH_DMA
/* Initialize the DMA subsystem if the weak function up_dma_initialize has been /* Initialize the DMA subsystem if the weak function up_dma_initialize has
* brought into the build * been brought into the build
*/ */
#ifdef CONFIG_HAVE_WEAKFUNCTIONS #ifdef CONFIG_HAVE_WEAKFUNCTIONS

View File

@ -1,7 +1,8 @@
/**************************************************************************** /****************************************************************************
* arch/renesas/src/common/up_initialize.c * arch/renesas/src/common/up_initialize.c
* *
* Copyright (C) 2008-2010, 2012-2013, 2015-2017 Gregory Nutt. All rights reserved. * Copyright (C) 2008-2010, 2012-2013, 2015-2017 Gregory Nutt. All rights
* reserved.
* Author: Gregory Nutt <gnutt@nuttx.org> * Author: Gregory Nutt <gnutt@nuttx.org>
* *
* Redistribution and use in source and binary forms, with or without * Redistribution and use in source and binary forms, with or without
@ -131,9 +132,10 @@ void up_initialize(void)
#endif #endif
/* Initialize the console device driver (if it is other than the standard /* Initialize the console device driver (if it is other than the standard
* serial driver). NOTE that the naming implies that the console is a serial * serial driver). NOTE that the naming implies that the console is a
* driver. That is usually the case, however, if no UARTs are enabled, the * serial driver. That is usually the case, however, if no UARTs are
* console could also be provided through some other device, such as an LCD. * enabled, the console could also be provided through some other device,
* such as an LCD.
* Architecture-specific logic will have to detect that case. * Architecture-specific logic will have to detect that case.
*/ */

View File

@ -91,7 +91,9 @@ static void up_init_smartfs(void)
{ {
mtd = m25p_initialize(spi); mtd = m25p_initialize(spi);
/* Now initialize a SMART Flash block device and bind it to the MTD device */ /* Now initialize a SMART Flash block device and bind it to the MTD
* device
*/
if (mtd != NULL) if (mtd != NULL)
{ {
@ -108,7 +110,9 @@ static void up_init_smartfs(void)
{ {
mtd = sst26_initialize_spi(spi); mtd = sst26_initialize_spi(spi);
/* Now initialize a SMART Flash block device and bind it to the MTD device */ /* Now initialize a SMART Flash block device and bind it to the MTD
* device
*/
if (mtd != NULL) if (mtd != NULL)
{ {
@ -125,7 +129,9 @@ static void up_init_smartfs(void)
{ {
mtd = w25_initialize(spi); mtd = w25_initialize(spi);
/* Now initialize a SMART Flash block device and bind it to the MTD device */ /* Now initialize a SMART Flash block device and bind it to the MTD
* device
*/
if (mtd != NULL) if (mtd != NULL)
{ {
@ -143,7 +149,9 @@ static void up_init_smartfs(void)
{ {
mtd = n25qxxx_initialize(qspi, 0); mtd = n25qxxx_initialize(qspi, 0);
/* Now initialize a SMART Flash block device and bind it to the MTD device */ /* Now initialize a SMART Flash block device and bind it to the MTD
* device
*/
if (mtd != NULL) if (mtd != NULL)
{ {

View File

@ -101,8 +101,8 @@ void up_initialize(void)
#endif #endif
#ifdef CONFIG_ARCH_DMA #ifdef CONFIG_ARCH_DMA
/* Initialize the DMA subsystem if the weak function up_dma_initialize has been /* Initialize the DMA subsystem if the weak function up_dma_initialize has
* brought into the build * been brought into the build
*/ */
#ifdef CONFIG_HAVE_WEAKFUNCTIONS #ifdef CONFIG_HAVE_WEAKFUNCTIONS