forked from Imagelibrary/rtems
i386/pc386: Clean up and fix warnings
This commit is contained in:
@@ -257,8 +257,6 @@ static void clockOff(void)
|
||||
outport_byte(TIMER_CNTR0, 0);
|
||||
} /* Clock_exit */
|
||||
|
||||
#define Clock_driver_support_shutdown_hardware() clockOff()
|
||||
|
||||
bool Clock_isr_enabled = false;
|
||||
static void Clock_isr_handler(void *param)
|
||||
{
|
||||
|
||||
@@ -242,9 +242,7 @@ _IBMPC_inch(void)
|
||||
/*
|
||||
* Routine that can be used before interrupt management is initialized.
|
||||
*/
|
||||
|
||||
int
|
||||
BSP_wait_polled_input(void)
|
||||
int BSP_wait_polled_input(void)
|
||||
{
|
||||
char c;
|
||||
while (!_IBMPC_scankey(&c))
|
||||
|
||||
@@ -177,6 +177,10 @@ void _IBMPC_initVideo(void); /* from 'outch.c' */
|
||||
void _IBMPC_outch (char); /* from 'outch.c' */
|
||||
char _IBMPC_inch (void); /* from 'inch.c' */
|
||||
char _IBMPC_inch_sleep (void); /* from 'inch.c' */
|
||||
int BSP_wait_polled_input(void); /* from 'inch.c' */
|
||||
int rtems_kbpoll( void ); /* from 'inch.c' */
|
||||
int getch( void ); /* from 'inch.c' */
|
||||
void add_to_queue( unsigned short b ); /* from 'inch.c' */
|
||||
|
||||
void Wait_X_ms(unsigned int timeToWait); /* from 'timer.c' */
|
||||
void Calibrate_loop_1ms(void); /* from 'timer.c' */
|
||||
@@ -188,6 +192,7 @@ void bsp_size_memory(void); /* from 'bspstart.c' */
|
||||
void Clock_driver_install_handler(void); /* from 'ckinit.c' */
|
||||
void Clock_driver_support_initialize_hardware(void); /* from 'ckinit.c' */
|
||||
|
||||
void kbd_reset_setup(char *str, int *ints); /* from 'pc_keyb.c' */
|
||||
size_t read_aux(char * buffer, size_t count); /* from 'ps2_mouse.c' */
|
||||
|
||||
/* Definitions for BSPConsolePort */
|
||||
|
||||
@@ -465,7 +465,7 @@ hex (char ch)
|
||||
}
|
||||
|
||||
/* scan for the sequence $<data>#<checksum> */
|
||||
void
|
||||
static void
|
||||
getpacket (char *buffer)
|
||||
{
|
||||
unsigned char checksum;
|
||||
@@ -529,7 +529,7 @@ getpacket (char *buffer)
|
||||
|
||||
/* send the packet in buffer. */
|
||||
|
||||
void
|
||||
static void
|
||||
putpacket (char *buffer)
|
||||
{
|
||||
unsigned char checksum;
|
||||
@@ -631,7 +631,7 @@ mem2hex (char *mem, char *buf, int count, int may_fault)
|
||||
|
||||
/* convert the hex array pointed to by buf into binary to be placed in mem */
|
||||
/* return a pointer to the character AFTER the last byte written */
|
||||
char *
|
||||
static char *
|
||||
hex2mem (char *buf, char *mem, int count, int may_fault)
|
||||
{
|
||||
int i;
|
||||
|
||||
@@ -60,15 +60,17 @@ uwrite(int uart, int reg, unsigned int val)
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef UARTDEBUG
|
||||
static void
|
||||
uartError(int uart)
|
||||
{
|
||||
unsigned char uartStatus, dummy;
|
||||
|
||||
uartStatus = uread(uart, LSR);
|
||||
(void) uartStatus; /* avoid set but not used warning */
|
||||
dummy = uread(uart, RBR);
|
||||
(void) dummy; /* avoid set but not used warning */
|
||||
|
||||
#ifdef UARTDEBUG
|
||||
if (uartStatus & OE)
|
||||
printk("********* Over run Error **********\n");
|
||||
if (uartStatus & PE)
|
||||
@@ -79,15 +81,8 @@ uartError(int uart)
|
||||
printk("********* Parity Error **********\n");
|
||||
if (uartStatus & ERFIFO)
|
||||
printk("********* Error receive Fifo **********\n");
|
||||
|
||||
}
|
||||
#else
|
||||
inline void uartError(int uart)
|
||||
{
|
||||
uread(uart, LSR);
|
||||
uread(uart, RBR);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
* Uart initialization, it is hardcoded to 8 bit, no parity,
|
||||
@@ -455,7 +450,10 @@ static void ( *driver_input_handler_com2 )( void *, char *, int ) = 0;
|
||||
* This routine sets the handler to handle the characters received
|
||||
* from the serial port.
|
||||
*/
|
||||
void uart_set_driver_handler( int port, void ( *handler )( void *, char *, int ) )
|
||||
static void uart_set_driver_handler(
|
||||
int port,
|
||||
void ( *handler )( void *, char *, int )
|
||||
)
|
||||
{
|
||||
switch( port )
|
||||
{
|
||||
|
||||
@@ -98,6 +98,10 @@ static interrupt_gate_descriptor idtEntry;
|
||||
|
||||
static rtems_raw_irq_global_settings raw_initial_config;
|
||||
|
||||
|
||||
/*
|
||||
* This method is called from irq_asm.S and cannot be static.
|
||||
*/
|
||||
void raw_idt_notify(void)
|
||||
{
|
||||
printk("raw_idt_notify has been called \n");
|
||||
|
||||
Reference in New Issue
Block a user