mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 00:14:22 +08:00
up_timer_initialize() is named incorrectly. The prefix should be the architecture name, not up_ since it is private to the architecture. up_timerisr() is similarly misnamed and should also be private since it is used only with the xyz_timerisr.c files. Also updat TODO list.
This commit is contained in:
@@ -44,6 +44,16 @@
|
||||
#include "up_arch.h"
|
||||
#include "up_internal.h"
|
||||
|
||||
/****************************************************************************
|
||||
* Public Function Prototypes
|
||||
****************************************************************************/
|
||||
|
||||
int xtrs_timerisr(int irq, FAR chipreg_t *regs);
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Name: up_irqinitialize
|
||||
****************************************************************************/
|
||||
@@ -56,10 +66,11 @@ void up_irqinitialize(void)
|
||||
*
|
||||
* NOTE: Normally, there are seperate enables for "global" interrupts
|
||||
* and specific device interrupts. In such a "normal" case, the timer
|
||||
* interrupt should be attached and enabled in the function up_timer_initialize()
|
||||
* interrupt should be attached and enabled in the function
|
||||
* xtrs_timer_initialize()
|
||||
*/
|
||||
|
||||
irq_attach(Z80_IRQ_SYSTIMER, (xcpt_t)up_timerisr);
|
||||
irq_attach(Z80_IRQ_SYSTIMER, (xcpt_t)xtrs_timerisr);
|
||||
|
||||
/* And finally, enable interrupts (including the timer) */
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/xtrs/src/xtr_timerisr.c
|
||||
*
|
||||
* Copyright (C) 2008-2009 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2008-2009, 2017 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -46,24 +46,12 @@
|
||||
#include "clock/clock.h"
|
||||
#include "up_internal.h"
|
||||
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Private Function Prototypes
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Function: up_timerisr
|
||||
* Function: xtrs_timerisr
|
||||
*
|
||||
* Description:
|
||||
* The timer ISR will perform a variety of services for various portions of
|
||||
@@ -71,7 +59,7 @@
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int up_timerisr(int irq, FAR chipreg_t *regs)
|
||||
int xtrs_timerisr(int irq, FAR chipreg_t *regs)
|
||||
{
|
||||
/* Process timer interrupt */
|
||||
|
||||
@@ -80,7 +68,7 @@ int up_timerisr(int irq, FAR chipreg_t *regs)
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Function: up_timer_initialize
|
||||
* Function: xtrs_timer_initialize
|
||||
*
|
||||
* Description:
|
||||
* This function is called during start-up to initialize the timer
|
||||
@@ -88,7 +76,7 @@ int up_timerisr(int irq, FAR chipreg_t *regs)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
void up_timer_initialize(void)
|
||||
void xtrs_timer_initialize(void)
|
||||
{
|
||||
/* The timer interrupt was attached in up_irqinitialize -- see comments there */
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user