2009-08-28 Joel Sherrill <joel.sherrill@OARcorp.com>

* bootcard.c, bsplibc.c, clockdrv_shell.h, console-polled.c: Fix
	formatting.
This commit is contained in:
Joel Sherrill
2009-08-28 18:24:10 +00:00
parent bcec9554ec
commit f1e8903dc0
5 changed files with 52 additions and 75 deletions

View File

@@ -1,3 +1,8 @@
2009-08-28 Joel Sherrill <joel.sherrill@OARcorp.com>
* bootcard.c, bsplibc.c, clockdrv_shell.h, console-polled.c: Fix
formatting.
2009-08-12 Joel Sherrill <joel.sherrill@oarcorp.com> 2009-08-12 Joel Sherrill <joel.sherrill@oarcorp.com>
* src/irq-legacy.c: Spacing, tabs, and proper format for license * src/irq-legacy.c: Spacing, tabs, and proper format for license

View File

@@ -88,7 +88,8 @@ static rtems_status_code bootcard_bsp_libc_helper(
* For the default heap size use the free space from the end of the * For the default heap size use the free space from the end of the
* work space up to the end of the work area as heap. * work space up to the end of the work area as heap.
*/ */
heap_size_default = work_area_size - rtems_configuration_get_work_space_size(); heap_size_default = work_area_size -
rtems_configuration_get_work_space_size();
/* Keep it as a multiple of 16 bytes */ /* Keep it as a multiple of 16 bytes */
heap_size_default &= ~((intptr_t) 0xf); heap_size_default &= ~((intptr_t) 0xf);

View File

@@ -30,6 +30,5 @@ void bsp_libc_init(
/* /*
* Set up for the libc handling. * Set up for the libc handling.
*/ */
libc_init(); libc_init();
} }

View File

@@ -19,7 +19,6 @@
#error "clockdrv_shell.c: fast idle and N ISRs per tick is not supported" #error "clockdrv_shell.c: fast idle and N ISRs per tick is not supported"
#endif #endif
/* /*
* This method is rarely used so default it. * This method is rarely used so default it.
*/ */
@@ -30,7 +29,6 @@
/* /*
* ISRs until next clock tick * ISRs until next clock tick
*/ */
#ifdef CLOCK_DRIVER_ISRS_PER_TICK #ifdef CLOCK_DRIVER_ISRS_PER_TICK
volatile uint32_t Clock_driver_isrs; volatile uint32_t Clock_driver_isrs;
#endif #endif
@@ -38,24 +36,15 @@ volatile uint32_t Clock_driver_isrs;
/* /*
* Clock ticks since initialization * Clock ticks since initialization
*/ */
volatile uint32_t Clock_driver_ticks; volatile uint32_t Clock_driver_ticks;
/* /*
* ISR formerly installed. * ISR formerly installed.
*/ */
rtems_isr_entry Old_ticker; rtems_isr_entry Old_ticker;
void Clock_exit( void ); void Clock_exit( void );
/*
* Major and minor number.
*/
rtems_device_major_number rtems_clock_major = UINT32_MAX;
rtems_device_minor_number rtems_clock_minor;
/* /*
* Clock_isr * Clock_isr
* *
@@ -67,9 +56,7 @@ rtems_device_minor_number rtems_clock_minor;
* Output parameters: NONE * Output parameters: NONE
* *
* Return values: NONE * Return values: NONE
*
*/ */
rtems_isr Clock_isr( rtems_isr Clock_isr(
rtems_vector_number vector rtems_vector_number vector
) )
@@ -77,7 +64,6 @@ rtems_isr Clock_isr(
/* /*
* Accurate count of ISRs * Accurate count of ISRs
*/ */
Clock_driver_ticks += 1; Clock_driver_ticks += 1;
#ifdef CLOCK_DRIVER_USE_FAST_IDLE #ifdef CLOCK_DRIVER_USE_FAST_IDLE
@@ -88,31 +74,25 @@ rtems_isr Clock_isr(
Clock_driver_support_at_tick(); Clock_driver_support_at_tick();
return; return;
#else #else
/* /*
* Do the hardware specific per-tick action. * Do the hardware specific per-tick action.
* *
* The counter/timer may or may not be set to automatically reload. * The counter/timer may or may not be set to automatically reload.
*/ */
Clock_driver_support_at_tick(); Clock_driver_support_at_tick();
#ifdef CLOCK_DRIVER_ISRS_PER_TICK #ifdef CLOCK_DRIVER_ISRS_PER_TICK
/* /*
* The driver is multiple ISRs per clock tick. * The driver is multiple ISRs per clock tick.
*/ */
if ( !Clock_driver_isrs ) { if ( !Clock_driver_isrs ) {
rtems_clock_tick(); rtems_clock_tick();
Clock_driver_isrs = CLOCK_DRIVER_ISRS_PER_TICK; Clock_driver_isrs = CLOCK_DRIVER_ISRS_PER_TICK;
} }
Clock_driver_isrs--; Clock_driver_isrs--;
#else #else
/* /*
* The driver is one ISR per clock tick. * The driver is one ISR per clock tick.
*/ */
@@ -210,17 +190,9 @@ rtems_device_driver Clock_initialize(
{ {
Install_clock( Clock_isr ); Install_clock( Clock_isr );
/*
* make major/minor avail to others such as shared memory driver
*/
rtems_clock_major = major;
rtems_clock_minor = minor;
/* /*
* If we are counting ISRs per tick, then initialize the counter. * If we are counting ISRs per tick, then initialize the counter.
*/ */
#ifdef CLOCK_DRIVER_ISRS_PER_TICK #ifdef CLOCK_DRIVER_ISRS_PER_TICK
Clock_driver_isrs = CLOCK_DRIVER_ISRS_PER_TICK; Clock_driver_isrs = CLOCK_DRIVER_ISRS_PER_TICK;
#endif #endif

View File

@@ -35,7 +35,6 @@ void console_initialize_hardware(void);
* Console Termios Support Entry Points * Console Termios Support Entry Points
* *
*/ */
int console_write_support ( int console_write_support (
int minor, int minor,
const char *bufarg, const char *bufarg,
@@ -65,18 +64,19 @@ rtems_device_driver console_initialize(
{ {
rtems_status_code status; rtems_status_code status;
/*
* Ensure Termios is initialized
*/
rtems_termios_initialize(); rtems_termios_initialize();
/* /*
* Make sure the hardware is initialized. * Make sure the hardware is initialized.
*/ */
console_initialize_hardware(); console_initialize_hardware();
/* /*
* Register Device Names * Register Device Names
*/ */
status = rtems_io_register_name( "/dev/console", major, 0 ); status = rtems_io_register_name( "/dev/console", major, 0 );
if (status != RTEMS_SUCCESSFUL) if (status != RTEMS_SUCCESSFUL)
rtems_fatal_error_occurred(status); rtems_fatal_error_occurred(status);