forked from Imagelibrary/rtems
libchip/serial: Add const qualifier
This commit is contained in:
@@ -31,7 +31,7 @@ static void fbcons_write_polled(int minor, char c);
|
|||||||
static int fbcons_set_attributes(int minor, const struct termios *t);
|
static int fbcons_set_attributes(int minor, const struct termios *t);
|
||||||
|
|
||||||
/* Pointers to functions for handling the UART. */
|
/* Pointers to functions for handling the UART. */
|
||||||
console_fns fbcons_fns =
|
const console_fns fbcons_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe,
|
libchip_serial_default_probe,
|
||||||
fbcons_first_open,
|
fbcons_first_open,
|
||||||
|
|||||||
@@ -29,24 +29,24 @@
|
|||||||
#include <libchip/sersupp.h>
|
#include <libchip/sersupp.h>
|
||||||
#include <bspopts.h>
|
#include <bspopts.h>
|
||||||
|
|
||||||
extern console_fns dbgu_fns;
|
extern const console_fns dbgu_fns;
|
||||||
|
|
||||||
#if ENABLE_LCD
|
#if ENABLE_LCD
|
||||||
extern console_fns fbcons_fns;
|
extern const console_fns fbcons_fns;
|
||||||
#define LCD_DEV 1
|
#define LCD_DEV 1
|
||||||
#else
|
#else
|
||||||
#define LCD_DEV 0
|
#define LCD_DEV 0
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if (ENABLE_UMON && ENABLE_UMON_CONSOLE)
|
#if (ENABLE_UMON && ENABLE_UMON_CONSOLE)
|
||||||
extern console_fns umoncons_fns;
|
extern const console_fns umoncons_fns;
|
||||||
#define UMON_CONS_DEV 1
|
#define UMON_CONS_DEV 1
|
||||||
#else
|
#else
|
||||||
#define UMON_CONS_DEV 0
|
#define UMON_CONS_DEV 0
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if ENABLE_USART0 || ENABLE_USART1 || ENABLE_USART2 || ENABLE_USART3
|
#if ENABLE_USART0 || ENABLE_USART1 || ENABLE_USART2 || ENABLE_USART3
|
||||||
extern console_fns usart_polling_fns;
|
extern const console_fns usart_polling_fns;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if ENABLE_USART0
|
#if ENABLE_USART0
|
||||||
|
|||||||
@@ -30,7 +30,7 @@ static int uart_set_attributes(int minor, const struct termios *t);
|
|||||||
|
|
||||||
unsigned long Console_Configuration_Count = NUM_DEVS;
|
unsigned long Console_Configuration_Count = NUM_DEVS;
|
||||||
|
|
||||||
console_fns uart_fns =
|
const console_fns uart_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe,
|
libchip_serial_default_probe,
|
||||||
uart_first_open,
|
uart_first_open,
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ static int uart_set_attributes(int minor, const struct termios *t);
|
|||||||
unsigned long Console_Configuration_Count = NUM_DEVS;
|
unsigned long Console_Configuration_Count = NUM_DEVS;
|
||||||
|
|
||||||
/* Pointers to functions for handling the UART. */
|
/* Pointers to functions for handling the UART. */
|
||||||
console_fns uart_fns =
|
const console_fns uart_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe,
|
libchip_serial_default_probe,
|
||||||
uart_first_open,
|
uart_first_open,
|
||||||
|
|||||||
@@ -27,7 +27,7 @@
|
|||||||
/* These are used by code in console.c */
|
/* These are used by code in console.c */
|
||||||
unsigned long Console_Configuration_Count = NUM_DEVS;
|
unsigned long Console_Configuration_Count = NUM_DEVS;
|
||||||
|
|
||||||
extern console_fns ffuart_fns;
|
extern const console_fns ffuart_fns;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* There's one item in array for each UART.
|
* There's one item in array for each UART.
|
||||||
|
|||||||
@@ -91,7 +91,7 @@ static int set_attribues(int minor, const struct termios *term)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
console_fns lm3s69xx_uart_fns = {
|
const console_fns lm3s69xx_uart_fns = {
|
||||||
.deviceProbe = libchip_serial_default_probe,
|
.deviceProbe = libchip_serial_default_probe,
|
||||||
.deviceFirstOpen = first_open,
|
.deviceFirstOpen = first_open,
|
||||||
.deviceLastClose = last_close,
|
.deviceLastClose = last_close,
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ typedef struct {
|
|||||||
uint32_t icr;
|
uint32_t icr;
|
||||||
} lm3s69xx_uart;
|
} lm3s69xx_uart;
|
||||||
|
|
||||||
extern console_fns lm3s69xx_uart_fns;
|
extern const console_fns lm3s69xx_uart_fns;
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -26,7 +26,7 @@
|
|||||||
#include <bsp/lpc32xx.h>
|
#include <bsp/lpc32xx.h>
|
||||||
#include <bsp/irq.h>
|
#include <bsp/irq.h>
|
||||||
|
|
||||||
extern console_fns lpc32xx_hsu_fns;
|
extern const console_fns lpc32xx_hsu_fns;
|
||||||
|
|
||||||
static uint8_t lpc32xx_uart_get_register(uintptr_t addr, uint8_t i)
|
static uint8_t lpc32xx_uart_get_register(uintptr_t addr, uint8_t i)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -189,7 +189,7 @@ static int lpc32xx_hsu_set_attributes(int minor, const struct termios *term)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
console_fns lpc32xx_hsu_fns = {
|
const console_fns lpc32xx_hsu_fns = {
|
||||||
.deviceProbe = libchip_serial_default_probe,
|
.deviceProbe = libchip_serial_default_probe,
|
||||||
.deviceFirstOpen = lpc32xx_hsu_first_open,
|
.deviceFirstOpen = lpc32xx_hsu_first_open,
|
||||||
.deviceLastClose = NULL,
|
.deviceLastClose = NULL,
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ static int uart_set_attributes(int minor, const struct termios *t);
|
|||||||
unsigned long Console_Configuration_Count = NUM_DEVS;
|
unsigned long Console_Configuration_Count = NUM_DEVS;
|
||||||
|
|
||||||
/* Pointers to functions for handling the UART. */
|
/* Pointers to functions for handling the UART. */
|
||||||
console_fns uart_fns =
|
const console_fns uart_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe,
|
libchip_serial_default_probe,
|
||||||
uart_first_open,
|
uart_first_open,
|
||||||
|
|||||||
@@ -199,7 +199,7 @@ static int usart_set_attributes(int minor, const struct termios *term)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
console_fns stm32f4_usart_fns = {
|
const console_fns stm32f4_usart_fns = {
|
||||||
.deviceProbe = libchip_serial_default_probe,
|
.deviceProbe = libchip_serial_default_probe,
|
||||||
.deviceFirstOpen = usart_first_open,
|
.deviceFirstOpen = usart_first_open,
|
||||||
.deviceLastClose = usart_last_close,
|
.deviceLastClose = usart_last_close,
|
||||||
|
|||||||
@@ -21,7 +21,7 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif /* __cplusplus */
|
#endif /* __cplusplus */
|
||||||
|
|
||||||
extern console_fns stm32f4_usart_fns;
|
extern const console_fns stm32f4_usart_fns;
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -186,7 +186,7 @@ bool vgacons_probe(
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
console_fns vgacons_fns =
|
const console_fns vgacons_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
vgacons_open, /* deviceFirstOpen */
|
vgacons_open, /* deviceFirstOpen */
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ bool vgacons_probe( int minor );
|
|||||||
/*
|
/*
|
||||||
* Driver function table
|
* Driver function table
|
||||||
*/
|
*/
|
||||||
extern console_fns vgacons_fns;
|
extern const console_fns vgacons_fns;
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ static bool config_68360_scc_base_probe_10(int minor);
|
|||||||
static bool config_68360_scc_base_probe_11(int minor);
|
static bool config_68360_scc_base_probe_11(int minor);
|
||||||
static bool config_68360_scc_base_probe_12(int minor);
|
static bool config_68360_scc_base_probe_12(int minor);
|
||||||
|
|
||||||
extern console_fns mc68360_scc_fns;
|
extern const console_fns mc68360_scc_fns;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The following table configures the console drivers used in this BSP.
|
* The following table configures the console drivers used in this BSP.
|
||||||
|
|||||||
@@ -959,7 +959,7 @@ int mc68360_scc_create_chip( PPMCQ1BoardData BoardData, uint8_t int_vector )
|
|||||||
return RTEMS_SUCCESSFUL;
|
return RTEMS_SUCCESSFUL;
|
||||||
}
|
}
|
||||||
|
|
||||||
console_fns mc68360_scc_fns = {
|
const console_fns mc68360_scc_fns = {
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
mc68360_scc_open, /* deviceFirstOpen */
|
mc68360_scc_open, /* deviceFirstOpen */
|
||||||
NULL, /* deviceLastClose */
|
NULL, /* deviceLastClose */
|
||||||
@@ -971,7 +971,7 @@ console_fns mc68360_scc_fns = {
|
|||||||
TRUE /* deviceOutputUsesInterrupts */
|
TRUE /* deviceOutputUsesInterrupts */
|
||||||
};
|
};
|
||||||
|
|
||||||
console_fns mc68360_scc_polled = {
|
const console_fns mc68360_scc_polled = {
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
mc68360_scc_open, /* deviceFirstOpen */
|
mc68360_scc_open, /* deviceFirstOpen */
|
||||||
mc68360_scc_close, /* deviceLastClose */
|
mc68360_scc_close, /* deviceLastClose */
|
||||||
|
|||||||
@@ -31,8 +31,8 @@ void Write_ns16550_register(
|
|||||||
uint8_t ucData
|
uint8_t ucData
|
||||||
);
|
);
|
||||||
|
|
||||||
extern console_fns ns16550_fns_8245;
|
extern const console_fns ns16550_fns_8245;
|
||||||
extern console_fns ns16550_fns_polled_8245;
|
extern const console_fns ns16550_fns_polled_8245;
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -182,7 +182,7 @@ static int set_attributes(int minor, const struct termios *term)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
console_fns qoriq_uart_bridge_master = {
|
const console_fns qoriq_uart_bridge_master = {
|
||||||
.deviceProbe = libchip_serial_default_probe,
|
.deviceProbe = libchip_serial_default_probe,
|
||||||
.deviceFirstOpen = first_open,
|
.deviceFirstOpen = first_open,
|
||||||
.deviceLastClose = last_close,
|
.deviceLastClose = last_close,
|
||||||
|
|||||||
@@ -198,7 +198,7 @@ static int set_attribues(int minor, const struct termios *term)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
console_fns qoriq_uart_bridge_slave = {
|
const console_fns qoriq_uart_bridge_slave = {
|
||||||
.deviceProbe = libchip_serial_default_probe,
|
.deviceProbe = libchip_serial_default_probe,
|
||||||
.deviceFirstOpen = first_open,
|
.deviceFirstOpen = first_open,
|
||||||
.deviceLastClose = last_close,
|
.deviceLastClose = last_close,
|
||||||
|
|||||||
@@ -55,9 +55,9 @@ typedef struct {
|
|||||||
rtems_chain_control transmit_fifo;
|
rtems_chain_control transmit_fifo;
|
||||||
} uart_bridge_slave_control;
|
} uart_bridge_slave_control;
|
||||||
|
|
||||||
extern console_fns qoriq_uart_bridge_master;
|
extern const console_fns qoriq_uart_bridge_master;
|
||||||
|
|
||||||
extern console_fns qoriq_uart_bridge_slave;
|
extern const console_fns qoriq_uart_bridge_slave;
|
||||||
|
|
||||||
/** @} */
|
/** @} */
|
||||||
|
|
||||||
|
|||||||
@@ -112,7 +112,7 @@ static int set_attribues(int minor, const struct termios *term)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
static console_fns t32mppc_console_fns = {
|
static const console_fns t32mppc_console_fns = {
|
||||||
.deviceProbe = libchip_serial_default_probe,
|
.deviceProbe = libchip_serial_default_probe,
|
||||||
.deviceFirstOpen = first_open,
|
.deviceFirstOpen = first_open,
|
||||||
.deviceLastClose = last_close,
|
.deviceLastClose = last_close,
|
||||||
|
|||||||
@@ -228,7 +228,7 @@ int xlite_set_attributes(int minor, const struct termios *t)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
console_fns xlite_fns_polled =
|
const console_fns xlite_fns_polled =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
xlite_open, /* deviceFirstOpen */
|
xlite_open, /* deviceFirstOpen */
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
/*
|
/*
|
||||||
* Function set for interrupt enabled termios console
|
* Function set for interrupt enabled termios console
|
||||||
*/
|
*/
|
||||||
console_fns sh_sci_fns =
|
const console_fns sh_sci_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
sh_sci_first_open, /* deviceFirstOpen */
|
sh_sci_first_open, /* deviceFirstOpen */
|
||||||
@@ -41,7 +41,7 @@ console_fns sh_sci_fns =
|
|||||||
/*
|
/*
|
||||||
* Function set for polled termios console
|
* Function set for polled termios console
|
||||||
*/
|
*/
|
||||||
console_fns sh_sci_fns_polled =
|
const console_fns sh_sci_fns_polled =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
sh_sci_first_open, /* deviceFirstOpen */
|
sh_sci_first_open, /* deviceFirstOpen */
|
||||||
|
|||||||
@@ -26,7 +26,7 @@ static void umoncons_write_polled(int minor, char c);
|
|||||||
static int umoncons_set_attributes(int minor, const struct termios *t);
|
static int umoncons_set_attributes(int minor, const struct termios *t);
|
||||||
|
|
||||||
/* Pointers to functions for handling the UART. */
|
/* Pointers to functions for handling the UART. */
|
||||||
console_fns umoncons_fns =
|
const console_fns umoncons_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe,
|
libchip_serial_default_probe,
|
||||||
umoncons_first_open,
|
umoncons_first_open,
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ static int erc32_console_first_open(int major, int minor, void *arg);
|
|||||||
static void erc32_console_initialize(int minor);
|
static void erc32_console_initialize(int minor);
|
||||||
|
|
||||||
#if (CONSOLE_USE_INTERRUPTS)
|
#if (CONSOLE_USE_INTERRUPTS)
|
||||||
console_fns erc32_fns = {
|
const console_fns erc32_fns = {
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
erc32_console_first_open, /* deviceFirstOpen */
|
erc32_console_first_open, /* deviceFirstOpen */
|
||||||
NULL, /* deviceLastClose */
|
NULL, /* deviceLastClose */
|
||||||
@@ -69,7 +69,7 @@ static void erc32_console_initialize(int minor);
|
|||||||
TERMIOS_IRQ_DRIVEN /* deviceOutputUsesInterrupts */
|
TERMIOS_IRQ_DRIVEN /* deviceOutputUsesInterrupts */
|
||||||
};
|
};
|
||||||
#else
|
#else
|
||||||
console_fns erc32_fns = {
|
const console_fns erc32_fns = {
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
erc32_console_first_open, /* deviceFirstOpen */
|
erc32_console_first_open, /* deviceFirstOpen */
|
||||||
NULL, /* deviceLastClose */
|
NULL, /* deviceLastClose */
|
||||||
|
|||||||
@@ -45,7 +45,7 @@ bool sun4v_console_deviceProbe (int minor){
|
|||||||
/*
|
/*
|
||||||
* Polled mode functions
|
* Polled mode functions
|
||||||
*/
|
*/
|
||||||
console_fns pooled_functions={
|
const console_fns pooled_functions={
|
||||||
sun4v_console_deviceProbe, /* deviceProbe */
|
sun4v_console_deviceProbe, /* deviceProbe */
|
||||||
sun4v_console_device_first_open, /* deviceFirstOpen */
|
sun4v_console_device_first_open, /* deviceFirstOpen */
|
||||||
NULL, /* deviceLastClose */
|
NULL, /* deviceLastClose */
|
||||||
@@ -57,7 +57,7 @@ console_fns pooled_functions={
|
|||||||
NULL /* deviceOutputUsesInterrupts */
|
NULL /* deviceOutputUsesInterrupts */
|
||||||
};
|
};
|
||||||
|
|
||||||
console_flow sun4v_console_console_flow = {
|
const console_flow sun4v_console_console_flow = {
|
||||||
NULL, /* deviceStopRemoteTx */
|
NULL, /* deviceStopRemoteTx */
|
||||||
NULL /* deviceStartRemoteTx */
|
NULL /* deviceStartRemoteTx */
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -35,7 +35,7 @@ static void dbgu_write_polled(int minor, char c);
|
|||||||
static int dbgu_set_attributes(int minor, const struct termios *t);
|
static int dbgu_set_attributes(int minor, const struct termios *t);
|
||||||
|
|
||||||
/* Pointers to functions for handling the UART. */
|
/* Pointers to functions for handling the UART. */
|
||||||
console_fns dbgu_fns =
|
const console_fns dbgu_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe,
|
libchip_serial_default_probe,
|
||||||
dbgu_first_open,
|
dbgu_first_open,
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ static int usart_set_attributes(int minor, const struct termios *t);
|
|||||||
at91rm9200_usart_regs_t *usart_get_base(int minor);
|
at91rm9200_usart_regs_t *usart_get_base(int minor);
|
||||||
|
|
||||||
/* Pointers to functions for handling the UART polled. */
|
/* Pointers to functions for handling the UART polled. */
|
||||||
console_fns usart_polling_fns = {
|
const console_fns usart_polling_fns = {
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
usart_first_open, /* deviceFirstOpen */
|
usart_first_open, /* deviceFirstOpen */
|
||||||
usart_last_close, /* deviceLastClose */
|
usart_last_close, /* deviceLastClose */
|
||||||
|
|||||||
@@ -29,7 +29,7 @@ static void ffuart_write_polled(int minor, char c);
|
|||||||
static int ffuart_set_attributes(int minor, const struct termios *t);
|
static int ffuart_set_attributes(int minor, const struct termios *t);
|
||||||
|
|
||||||
/* Pointers to functions for handling the UART. */
|
/* Pointers to functions for handling the UART. */
|
||||||
console_fns ffuart_fns =
|
const console_fns ffuart_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe,
|
libchip_serial_default_probe,
|
||||||
ffuart_first_open,
|
ffuart_first_open,
|
||||||
|
|||||||
@@ -893,7 +893,7 @@ MG5UART_STATIC void mg5uart_enable_interrupts(
|
|||||||
* Flow control is only supported when using interrupts
|
* Flow control is only supported when using interrupts
|
||||||
*/
|
*/
|
||||||
|
|
||||||
console_fns mg5uart_fns =
|
const console_fns mg5uart_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
mg5uart_open, /* deviceFirstOpen */
|
mg5uart_open, /* deviceFirstOpen */
|
||||||
@@ -906,7 +906,7 @@ console_fns mg5uart_fns =
|
|||||||
TRUE /* deviceOutputUsesInterrupts */
|
TRUE /* deviceOutputUsesInterrupts */
|
||||||
};
|
};
|
||||||
|
|
||||||
console_fns mg5uart_fns_polled =
|
const console_fns mg5uart_fns_polled =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
mg5uart_open, /* deviceFirstOpen */
|
mg5uart_open, /* deviceFirstOpen */
|
||||||
|
|||||||
@@ -73,8 +73,8 @@ extern "C" {
|
|||||||
* Driver function table
|
* Driver function table
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern console_fns mg5uart_fns;
|
extern const console_fns mg5uart_fns;
|
||||||
extern console_fns mg5uart_fns_polled;
|
extern const console_fns mg5uart_fns_polled;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Default register access routines
|
* Default register access routines
|
||||||
|
|||||||
@@ -27,7 +27,7 @@
|
|||||||
* Flow control is only supported when using interrupts
|
* Flow control is only supported when using interrupts
|
||||||
*/
|
*/
|
||||||
|
|
||||||
console_fns mc68681_fns =
|
const console_fns mc68681_fns =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
mc68681_open, /* deviceFirstOpen */
|
mc68681_open, /* deviceFirstOpen */
|
||||||
@@ -40,7 +40,7 @@ console_fns mc68681_fns =
|
|||||||
true /* deviceOutputUsesInterrupts */
|
true /* deviceOutputUsesInterrupts */
|
||||||
};
|
};
|
||||||
|
|
||||||
console_fns mc68681_fns_polled =
|
const console_fns mc68681_fns_polled =
|
||||||
{
|
{
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
mc68681_open, /* deviceFirstOpen */
|
mc68681_open, /* deviceFirstOpen */
|
||||||
|
|||||||
@@ -61,8 +61,8 @@ extern mc68681_baud_t
|
|||||||
* Driver function table
|
* Driver function table
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern console_fns mc68681_fns;
|
extern const console_fns mc68681_fns;
|
||||||
extern console_fns mc68681_fns_polled;
|
extern const console_fns mc68681_fns_polled;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Default register access routines
|
* Default register access routines
|
||||||
|
|||||||
@@ -62,17 +62,17 @@
|
|||||||
* Flow control is only supported when using interrupts
|
* Flow control is only supported when using interrupts
|
||||||
*/
|
*/
|
||||||
|
|
||||||
console_flow ns16550_flow_RTSCTS = {
|
const console_flow ns16550_flow_RTSCTS = {
|
||||||
ns16550_negate_RTS, /* deviceStopRemoteTx */
|
ns16550_negate_RTS, /* deviceStopRemoteTx */
|
||||||
ns16550_assert_RTS /* deviceStartRemoteTx */
|
ns16550_assert_RTS /* deviceStartRemoteTx */
|
||||||
};
|
};
|
||||||
|
|
||||||
console_flow ns16550_flow_DTRCTS = {
|
const console_flow ns16550_flow_DTRCTS = {
|
||||||
ns16550_negate_DTR, /* deviceStopRemoteTx */
|
ns16550_negate_DTR, /* deviceStopRemoteTx */
|
||||||
ns16550_assert_DTR /* deviceStartRemoteTx */
|
ns16550_assert_DTR /* deviceStartRemoteTx */
|
||||||
};
|
};
|
||||||
|
|
||||||
console_fns ns16550_fns = {
|
const console_fns ns16550_fns = {
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
ns16550_open, /* deviceFirstOpen */
|
ns16550_open, /* deviceFirstOpen */
|
||||||
ns16550_close, /* deviceLastClose */
|
ns16550_close, /* deviceLastClose */
|
||||||
@@ -84,7 +84,7 @@ console_fns ns16550_fns = {
|
|||||||
true /* deviceOutputUsesInterrupts */
|
true /* deviceOutputUsesInterrupts */
|
||||||
};
|
};
|
||||||
|
|
||||||
console_fns ns16550_fns_polled = {
|
const console_fns ns16550_fns_polled = {
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
ns16550_open, /* deviceFirstOpen */
|
ns16550_open, /* deviceFirstOpen */
|
||||||
ns16550_close, /* deviceLastClose */
|
ns16550_close, /* deviceLastClose */
|
||||||
|
|||||||
@@ -35,15 +35,15 @@ extern "C" {
|
|||||||
* Driver function table
|
* Driver function table
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern console_fns ns16550_fns;
|
extern const console_fns ns16550_fns;
|
||||||
extern console_fns ns16550_fns_polled;
|
extern const console_fns ns16550_fns_polled;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Flow control function tables
|
* Flow control function tables
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern console_flow ns16550_flow_RTSCTS;
|
extern const console_flow ns16550_flow_RTSCTS;
|
||||||
extern console_flow ns16550_flow_DTRCTS;
|
extern const console_flow ns16550_flow_DTRCTS;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Helpers for printk
|
* Helpers for printk
|
||||||
|
|||||||
@@ -123,7 +123,7 @@ typedef struct _console_tbl {
|
|||||||
*/
|
*/
|
||||||
console_devs deviceType;
|
console_devs deviceType;
|
||||||
/** pDeviceFns This is a pointer to the set of driver routines to use. */
|
/** pDeviceFns This is a pointer to the set of driver routines to use. */
|
||||||
console_fns *pDeviceFns;
|
const console_fns *pDeviceFns;
|
||||||
/** This value is passed to the serial device driver for use. In termios
|
/** This value is passed to the serial device driver for use. In termios
|
||||||
* itself the number is ignored.
|
* itself the number is ignored.
|
||||||
*/
|
*/
|
||||||
@@ -135,7 +135,7 @@ typedef struct _console_tbl {
|
|||||||
* should be necessary as RTS will be driven automatically
|
* should be necessary as RTS will be driven automatically
|
||||||
* when the transmitter is active.
|
* when the transmitter is active.
|
||||||
*/
|
*/
|
||||||
console_flow *pDeviceFlow;
|
const console_flow *pDeviceFlow;
|
||||||
/** The high water mark in the input buffer is set to the buffer
|
/** The high water mark in the input buffer is set to the buffer
|
||||||
* size less ulMargin. Once this level is reached, the driver's
|
* size less ulMargin. Once this level is reached, the driver's
|
||||||
* flow control routine used to stop the remote transmitter will
|
* flow control routine used to stop the remote transmitter will
|
||||||
|
|||||||
@@ -40,12 +40,12 @@
|
|||||||
* Flow control is only supported when using interrupts
|
* Flow control is only supported when using interrupts
|
||||||
*/
|
*/
|
||||||
|
|
||||||
console_flow z85c30_flow_RTSCTS = {
|
const console_flow z85c30_flow_RTSCTS = {
|
||||||
z85c30_negate_RTS, /* deviceStopRemoteTx */
|
z85c30_negate_RTS, /* deviceStopRemoteTx */
|
||||||
z85c30_assert_RTS /* deviceStartRemoteTx */
|
z85c30_assert_RTS /* deviceStartRemoteTx */
|
||||||
};
|
};
|
||||||
|
|
||||||
console_flow z85c30_flow_DTRCTS = {
|
const console_flow z85c30_flow_DTRCTS = {
|
||||||
z85c30_negate_DTR, /* deviceStopRemoteTx */
|
z85c30_negate_DTR, /* deviceStopRemoteTx */
|
||||||
z85c30_assert_DTR /* deviceStartRemoteTx */
|
z85c30_assert_DTR /* deviceStartRemoteTx */
|
||||||
};
|
};
|
||||||
@@ -54,7 +54,7 @@ console_flow z85c30_flow_DTRCTS = {
|
|||||||
* Exported driver function table
|
* Exported driver function table
|
||||||
*/
|
*/
|
||||||
|
|
||||||
console_fns z85c30_fns = {
|
const console_fns z85c30_fns = {
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
z85c30_open, /* deviceFirstOpen */
|
z85c30_open, /* deviceFirstOpen */
|
||||||
NULL, /* deviceLastClose */
|
NULL, /* deviceLastClose */
|
||||||
@@ -66,7 +66,7 @@ console_fns z85c30_fns = {
|
|||||||
true /* deviceOutputUsesInterrupts */
|
true /* deviceOutputUsesInterrupts */
|
||||||
};
|
};
|
||||||
|
|
||||||
console_fns z85c30_fns_polled = {
|
const console_fns z85c30_fns_polled = {
|
||||||
libchip_serial_default_probe, /* deviceProbe */
|
libchip_serial_default_probe, /* deviceProbe */
|
||||||
z85c30_open, /* deviceFirstOpen */
|
z85c30_open, /* deviceFirstOpen */
|
||||||
z85c30_close, /* deviceLastClose */
|
z85c30_close, /* deviceLastClose */
|
||||||
|
|||||||
@@ -42,15 +42,15 @@ extern "C" {
|
|||||||
* Driver function table
|
* Driver function table
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern console_fns z85c30_fns;
|
extern const console_fns z85c30_fns;
|
||||||
extern console_fns z85c30_fns_polled;
|
extern const console_fns z85c30_fns_polled;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Flow control function tables
|
* Flow control function tables
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern console_flow z85c30_flow_RTSCTS;
|
extern const console_flow z85c30_flow_RTSCTS;
|
||||||
extern console_flow z85c30_flow_DTRCTS;
|
extern const console_flow z85c30_flow_DTRCTS;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Default register access routines
|
* Default register access routines
|
||||||
|
|||||||
Reference in New Issue
Block a user