arch: Fix nxstyle errors
error: Long line found
This commit is contained in:
parent
fa07c90522
commit
79574c18d8
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/misoc/src/lm32/lm32_config.h
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,25 +16,25 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ARCH_MISOC_SRC_LM32_LM32_CONFIG_H
|
||||
#define __ARCH_MISOC_SRC_LM32_LM32_CONFIG_H
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
#include <arch/chip/chip.h>
|
||||
#include <arch/board/board.h>
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/* UARTs ****************************************************************************/
|
||||
/* UARTs ********************************************************************/
|
||||
|
||||
/* Are any UARTs enabled? */
|
||||
|
||||
@ -59,20 +59,20 @@
|
||||
# undef HAVE_SERIAL_CONSOLE
|
||||
#endif
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Types
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Inline Functions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Functions Prototypes
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#endif /* __ARCH_MISOC_SRC_LM32_LM32_CONFIG_H */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/renesas/src/m16c/chip.h
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,23 +16,23 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ARCH_RENESAS_SRC_M16C_CHIP_H
|
||||
#define __ARCH_RENESAS_SRC_M16C_CHIP_H
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
#ifndef __ASSEMBLY__
|
||||
# include <stdint.h>
|
||||
#endif
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/* FLG register bits */
|
||||
|
||||
@ -54,8 +54,8 @@
|
||||
|
||||
#define M16C_SFR_BASE 0x00000 /* 00000-003ff: Special Function Registers */
|
||||
|
||||
/* Internal, on-chip SRAM begins at address 0x00400 for all chips, regardless of the
|
||||
* size of the on-chip SRAM.
|
||||
/* Internal, on-chip SRAM begins at address 0x00400 for all chips,
|
||||
* regardless of the size of the on-chip SRAM.
|
||||
*/
|
||||
|
||||
#define M16C_IRAM_BASE 0x00400 /* 00400-00xxx: Internal RAM */
|
||||
@ -72,13 +72,13 @@
|
||||
#define M16C_VEEPROM1_BASE 0x0f000 /* 0f000-0f7fff: Virtual EEPPROM block 1 */
|
||||
#define M16C_VEEPROM2_BASE 0x0f800 /* 0f800-0fffff: Virtual EEPPROM block 2 */
|
||||
|
||||
/* If there were external, "far" RAM, it would be begin at 0x10000. However, these
|
||||
* specific chips do not support external RAM.
|
||||
/* If there were external, "far" RAM, it would be begin at 0x10000.
|
||||
* However, thesespecific chips do not support external RAM.
|
||||
*/
|
||||
|
||||
/* Each part has a different amount of on-chip FLASH. The ending FLASH address is
|
||||
* 0xfffff for all chips, but the starting address varies depending on the amount
|
||||
* of on-chip FLASH.
|
||||
/* Each part has a different amount of on-chip FLASH.
|
||||
* The ending FLASH address is0xfffff for all chips, but the starting address
|
||||
* varies depending on the amount of on-chip FLASH.
|
||||
*/
|
||||
|
||||
#if defined(CONFIG_ARCH_CHIP_M30262F3)
|
||||
@ -233,9 +233,9 @@
|
||||
#define M16C_PUR2 0x003fe /* Pull-up control 2 */
|
||||
#define M16C_PCR 0x003ff /* Port control */
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/renesas/src/m16c/m16c_timer.h
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,22 +16,22 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ARCH_RENESAS_SRC_M16C_M16C_TIMER_H
|
||||
#define __ARCH_RENESAS_SRC_M16C_M16C_TIMER_H
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/* Register Bit Definitions *********************************************************/
|
||||
/* Register Bit Definitions *************************************************/
|
||||
|
||||
#define M16C_TA0IC 0x00055 /* Timer A0 interrupt control */
|
||||
#define M16C_TA1IC 0x00056 /* Timer A1 interrupt control */
|
||||
@ -202,9 +202,9 @@
|
||||
#define TBnMR_TCK_PMF32 0x80 /* 10: f32 */
|
||||
#define TBnMR_TCK_PMFC32 0xc0 /* 11: fc32 */
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/renesas/src/m16c/m16c_uart.h
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,28 +16,28 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ARCH_RENESAS_SRC_M16C_M16C_UART_H
|
||||
#define __ARCH_RENESAS_SRC_M16C_M16C_UART_H
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/* UART Register Block Base Addresses ***********************************************/
|
||||
/* UART Register Block Base Addresses ***************************************/
|
||||
|
||||
#define M16C_UART0_BASE 0x003a0 /* First UART0 register */
|
||||
#define M16C_UART1_BASE 0x003a8 /* First UART1 register */
|
||||
#define M16C_UART2_BASE 0x00378 /* First UART2 register (ignoring special regs) */
|
||||
|
||||
/* UART Register Offsets ************************************************************/
|
||||
/* UART Register Offsets ****************************************************/
|
||||
|
||||
#define M16C_UART_MR 0x00 /* 8-bit UART transmit/receive mode */
|
||||
#define M16C_UART_BRG 0x01 /* 8-bit UART bit rate generator */
|
||||
@ -46,7 +46,7 @@
|
||||
#define M16C_UART_C1 0x05 /* 8-bit UART transmit/receive control 1 */
|
||||
#define M16C_UART_RB 0x06 /* 16-bit UART receive buffer */
|
||||
|
||||
/* UART Register Bit Definitions ****************************************************/
|
||||
/* UART Register Bit Definitions ********************************************/
|
||||
|
||||
/* UART transmit/receive mode */
|
||||
|
||||
@ -120,9 +120,9 @@
|
||||
|
||||
/* UART2 special mode register 4 (to be provided) */
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/renesas/src/sh1/sh1_703x.h
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,22 +16,22 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ARCH_RENESAS_SRC_SH1_SH1_703X_H
|
||||
#define __ARCH_RENESAS_SRC_SH1_SH1_703X_H
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/* Memory-mapped register addresses *************************************************/
|
||||
/* Memory-mapped register addresses *****************************************/
|
||||
|
||||
/* Serial Communications interface (SCI) */
|
||||
|
||||
@ -253,7 +253,7 @@
|
||||
#define SH1_TPC_NDRB1 (0x05fffff6) /* 8-bits wide */
|
||||
#define SH1_TPC_NDRA1 (0x05fffff7) /* 8-bits wide */
|
||||
|
||||
/* Register bit definitions *********************************************************/
|
||||
/* Register bit definitions *************************************************/
|
||||
|
||||
/* Serial Communications interface (SCI) */
|
||||
|
||||
@ -432,16 +432,16 @@
|
||||
#define SH1_ICR_NMIE (0x0100) /* Bits 8: Interrupt on rising edge of NMI input */
|
||||
#define SH1_ICR_NMIL (0x8000) /* Bits 15: NMI input level high */
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Types
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Functions Prototypes
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#endif /* __ARCH_RENESAS_SRC_SH1_SH1_703X_H */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/x86/src/qemu/chip.h
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,14 +16,14 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ARCH_X86_SRC_QEMU_CHIP_H
|
||||
#define __ARCH_X86_SRC_QEMU_CHIP_H
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
@ -34,26 +34,26 @@
|
||||
# error "Unsupported I486 chip"
|
||||
#endif
|
||||
|
||||
/* Include only the memory map. Other chip hardware files should then include this
|
||||
* file for the proper setup
|
||||
/* Include only the memory map. Other chip hardware files should then
|
||||
* include this file for the proper setup
|
||||
*/
|
||||
|
||||
#include "qemu_memorymap.h"
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Types
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Functions Prototypes
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#endif /* __ARCH_X86_SRC_QEMU_CHIP_H */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/x86/src/qemu/qemu_memorymap.h
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,37 +16,37 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ARCH_X86_SRC_QEMU_QEMU_MEMORYMAP_H
|
||||
#define __ARCH_X86_SRC_QEMU_QEMU_MEMORYMAP_H
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
#include "chip.h"
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/* Memory Map ***********************************************************************/
|
||||
/* Memory Map ***************************************************************/
|
||||
|
||||
/* Peripheral Base Addresses ********************************************************/
|
||||
/* Peripheral Base Addresses ************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Types
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Functions Prototypes
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#endif /* __ARCH_X86_SRC_QEMU_QEMU_MEMORYMAP_H */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/x86_64/src/intel64/chip.h
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,31 +16,31 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ARCH_X86_64_SRC_INTEL64_CHIP_H
|
||||
#define __ARCH_X86_64_SRC_INTEL64_CHIP_H
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Types
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Function Prototypes
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#endif /* __ARCH_X86_64_SRC_INTEL64_CHIP_H */
|
||||
|
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/x86_64/src/intel64/intel64.h
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,14 +16,14 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ARCH_X86_64_SRC_INTEL64_INTEL64_H
|
||||
#define __ARCH_X86_64_SRC_INTEL64_INTEL64_H
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
#include <nuttx/compiler.h>
|
||||
@ -35,25 +35,25 @@
|
||||
#include "x86_64_internal.h"
|
||||
#include "chip.h"
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/* Configuration ********************************************************************/
|
||||
/* Configuration ************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Types
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Inline Functions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#undef EXTERN
|
||||
#if defined(__cplusplus)
|
||||
@ -64,31 +64,33 @@ extern "C"
|
||||
#define EXTERN extern
|
||||
#endif
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Function Prototypes
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Name: intel64_lowsetup
|
||||
*
|
||||
* Description:
|
||||
* Called at the very beginning of _start. Performs low level initialization
|
||||
* including setup of the console UART. This UART done early so that the serial
|
||||
* console is available for debugging very early in the boot sequence.
|
||||
* Called at the very beginning of _start.
|
||||
* Performs low level initializationincluding setup of the console UART.
|
||||
* This UART done early so that the serial console is available for
|
||||
* debugging very early in the boot sequence.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
void intel64_lowsetup(void);
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Name: vector_*
|
||||
*
|
||||
* Description:
|
||||
* These are the various ISR/IRQ vector address exported from
|
||||
* intel64_vectors.S. These addresses need to have global scope so that they
|
||||
* can be known to the interrupt initialization logic in intel64_irq.c.
|
||||
* intel64_vectors.S. These addresses need to have global scope
|
||||
* so that they can be known to the interrupt initialization logic in
|
||||
* intel64_irq.c.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
void vector_isr0(void);
|
||||
void vector_isr1(void);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* arch/x86_64/src/intel64/intel64_rtc.c
|
||||
*
|
||||
* Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
@ -16,11 +16,11 @@
|
||||
* License for the specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
#include <nuttx/arch.h>
|
||||
@ -36,11 +36,11 @@
|
||||
|
||||
#include "x86_64_internal.h"
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/* Configuration ********************************************************************/
|
||||
/* Configuration ************************************************************/
|
||||
|
||||
/* This is a hacky implementation based on TSC, we only support Hi-RES mode */
|
||||
|
||||
@ -54,33 +54,33 @@
|
||||
#define NS_PER_MSEC 1000000UL
|
||||
#define NS_PER_SEC 1000000000UL
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Private Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Data
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_RTC_HIRES
|
||||
volatile bool g_rtc_enabled = false;
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Private Functions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
static unsigned long rtc_freq;
|
||||
static unsigned long rtc_overflow;
|
||||
static unsigned long rtc_last;
|
||||
static unsigned long rtc_overflows;
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Private Functions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
static unsigned long rtc_read(void)
|
||||
{
|
||||
@ -96,16 +96,16 @@ static unsigned long rtc_read(void)
|
||||
return tmr;
|
||||
}
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Name: up_rtc_initialize
|
||||
*
|
||||
* Description:
|
||||
* Initialize the hardware RTC per the selected configuration. This function is
|
||||
* called once during the OS initialization sequence
|
||||
* Initialize the hardware RTC per the selected configuration.
|
||||
* This function is called once during the OS initialization sequence.
|
||||
*
|
||||
* Input Parameters:
|
||||
* None
|
||||
@ -113,7 +113,7 @@ static unsigned long rtc_read(void)
|
||||
* Returned Value:
|
||||
* Zero (OK) on success; a negated errno on failure
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
int up_rtc_initialize(void)
|
||||
{
|
||||
@ -123,13 +123,13 @@ int up_rtc_initialize(void)
|
||||
return OK;
|
||||
}
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Name: up_rtc_gettime
|
||||
*
|
||||
* Description:
|
||||
* Get the current time from the high resolution RTC clock/counter. This interface
|
||||
* is only supported by the high-resolution RTC/counter hardware implementation.
|
||||
* It is used to replace the system timer.
|
||||
* Get the current time from the high resolution RTC clock/counter.
|
||||
* This interface is only supported by the high-resolution RTC/counter
|
||||
* hardware implementation. It is used to replace the system timer.
|
||||
*
|
||||
* Input Parameters:
|
||||
* tp - The location to return the high resolution time value.
|
||||
@ -137,7 +137,7 @@ int up_rtc_initialize(void)
|
||||
* Returned Value:
|
||||
* Zero (OK) on success; a negated errno on failure
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
int up_rtc_gettime(struct timespec *tp)
|
||||
{
|
||||
@ -150,12 +150,12 @@ int up_rtc_gettime(struct timespec *tp)
|
||||
return OK;
|
||||
}
|
||||
|
||||
/************************************************************************************
|
||||
/****************************************************************************
|
||||
* Name: up_rtc_settime
|
||||
*
|
||||
* Description:
|
||||
* Set the RTC to the provided time. All RTC implementations must be able to
|
||||
* set their time based on a standard timespec.
|
||||
* Set the RTC to the provided time. All RTC implementations must be able
|
||||
* to set their time based on a standard timespec.
|
||||
*
|
||||
* Input Parameters:
|
||||
* tp - the time to use
|
||||
@ -163,7 +163,7 @@ int up_rtc_gettime(struct timespec *tp)
|
||||
* Returned Value:
|
||||
* Zero (OK) on success; a negated errno on failure
|
||||
*
|
||||
************************************************************************************/
|
||||
****************************************************************************/
|
||||
|
||||
int up_rtc_settime(const struct timespec *tp)
|
||||
{
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user