serial: rename struct field int_pri to irq_pri
This is just a cosmetic change to unify anything interrupt related under 'irq'. Change-Id: Ib8804d194e11eb49526fda952d9efc0f2ffac2df Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This commit is contained in:
parent
f06cae3775
commit
e564035521
|
@ -73,7 +73,7 @@ static int k20_uart_console_init(struct device *dev)
|
|||
.baud_rate = CONFIG_UART_CONSOLE_BAUDRATE,
|
||||
.sys_clk_freq = CONFIG_UART_CONSOLE_CLK_FREQ,
|
||||
/* Only supported in polling mode, but init all info fields */
|
||||
.int_pri = CONFIG_UART_CONSOLE_INT_PRI
|
||||
.irq_pri = CONFIG_UART_CONSOLE_INT_PRI
|
||||
};
|
||||
|
||||
/* UART0 Rx and Tx pin assignments */
|
||||
|
|
|
@ -73,7 +73,7 @@ static int stellaris_uart_console_init(struct device *dev)
|
|||
.sys_clk_freq = SYSCLK_DEFAULT_IOSC_HZ,
|
||||
.baud_rate = CONFIG_UART_CONSOLE_BAUDRATE,
|
||||
/* Only supported in polling mode, but init all info fields */
|
||||
.int_pri = CONFIG_UART_CONSOLE_INT_PRI,
|
||||
.irq_pri = CONFIG_UART_CONSOLE_INT_PRI,
|
||||
};
|
||||
|
||||
uart_init(UART_CONSOLE_DEV, &info);
|
||||
|
|
|
@ -64,7 +64,7 @@ static int ns16550_uart_console_init(struct device *dev)
|
|||
struct uart_init_info info = {
|
||||
.baud_rate = CONFIG_UART_CONSOLE_BAUDRATE,
|
||||
.sys_clk_freq = UART_XTAL_FREQ,
|
||||
.int_pri = CONFIG_UART_CONSOLE_INT_PRI
|
||||
.irq_pri = CONFIG_UART_CONSOLE_INT_PRI
|
||||
};
|
||||
|
||||
if (dev == UART_CONSOLE_DEV) {
|
||||
|
@ -99,7 +99,7 @@ static struct uart_device_config_t ns16550_uart_dev_cfg[] = {
|
|||
{
|
||||
.port = CONFIG_UART_PORT_0_REGS,
|
||||
.irq = CONFIG_UART_PORT_0_IRQ,
|
||||
.int_pri = CONFIG_UART_PORT_0_IRQ_PRIORITY,
|
||||
.irq_pri = CONFIG_UART_PORT_0_IRQ_PRIORITY,
|
||||
|
||||
.port_init = ns16550_uart_port_init,
|
||||
|
||||
|
@ -112,7 +112,7 @@ static struct uart_device_config_t ns16550_uart_dev_cfg[] = {
|
|||
{
|
||||
.port = CONFIG_UART_PORT_1_REGS,
|
||||
.irq = CONFIG_UART_PORT_1_IRQ,
|
||||
.int_pri = CONFIG_UART_PORT_1_IRQ_PRIORITY,
|
||||
.irq_pri = CONFIG_UART_PORT_1_IRQ_PRIORITY,
|
||||
|
||||
.port_init = ns16550_uart_port_init,
|
||||
|
||||
|
|
|
@ -281,7 +281,7 @@ static int bt_uart_open()
|
|||
.options = 0,
|
||||
.sys_clk_freq = CONFIG_BLUETOOTH_UART_FREQ,
|
||||
.baud_rate = CONFIG_BLUETOOTH_UART_BAUDRATE,
|
||||
.int_pri = CONFIG_BLUETOOTH_UART_INT_PRI,
|
||||
.irq_pri = CONFIG_BLUETOOTH_UART_INT_PRI,
|
||||
};
|
||||
|
||||
bt_uart_setup(BT_UART_DEV, &info);
|
||||
|
|
|
@ -87,7 +87,7 @@ void k20_uart_port_init(struct device *dev,
|
|||
C1_t c1; /* UART C1 register value */
|
||||
C2_t c2; /* UART C2 register value */
|
||||
|
||||
DEV_CFG(dev)->int_pri = init_info->int_pri;
|
||||
DEV_CFG(dev)->irq_pri = init_info->irq_pri;
|
||||
|
||||
K20_UART_t *uart_p = UART_STRUCT(dev);
|
||||
|
||||
|
|
|
@ -281,7 +281,7 @@ void ns16550_uart_port_init(struct device *dev,
|
|||
|
||||
ns16550_pci_uart_scan();
|
||||
|
||||
dev_cfg->int_pri = init_info->int_pri;
|
||||
dev_cfg->irq_pri = init_info->irq_pri;
|
||||
dev_data->iir_cache = 0;
|
||||
|
||||
oldLevel = irq_lock();
|
||||
|
|
|
@ -279,7 +279,7 @@ void stellaris_uart_port_init(struct device *dev,
|
|||
{
|
||||
struct uart_device_config_t * const dev_cfg = DEV_CFG(dev);
|
||||
|
||||
dev_cfg->int_pri = init_info->int_pri;
|
||||
dev_cfg->irq_pri = init_info->irq_pri;
|
||||
|
||||
disable(dev);
|
||||
baudrateSet(dev, init_info->baud_rate, init_info->sys_clk_freq);
|
||||
|
|
|
@ -108,7 +108,7 @@ void uart_simple_register(uint8_t *buf, size_t len, uart_simple_recv_cb cb)
|
|||
.options = 0,
|
||||
.sys_clk_freq = CONFIG_UART_SIMPLE_FREQ,
|
||||
.baud_rate = CONFIG_UART_SIMPLE_BAUDRATE,
|
||||
.int_pri = CONFIG_UART_SIMPLE_INT_PRI,
|
||||
.irq_pri = CONFIG_UART_SIMPLE_INT_PRI,
|
||||
};
|
||||
|
||||
recv_buf = buf;
|
||||
|
|
|
@ -54,7 +54,7 @@ struct uart_device_config_t {
|
|||
uint32_t regs;
|
||||
};
|
||||
uint8_t irq; /**< interrupt request level */
|
||||
uint8_t int_pri; /**< interrupt priority */
|
||||
uint8_t irq_pri; /**< interrupt priority */
|
||||
|
||||
/**
|
||||
* Initializes the UART port.
|
||||
|
@ -72,7 +72,7 @@ struct uart_init_info {
|
|||
int baud_rate; /* Baud rate */
|
||||
uint32_t sys_clk_freq; /* System clock frequency in Hz */
|
||||
|
||||
uint8_t int_pri; /* Interrupt priority level */
|
||||
uint8_t irq_pri; /* Interrupt priority level */
|
||||
uint8_t options; /* HW Flow Control option */
|
||||
|
||||
uint32_t regs; /* Register address */
|
||||
|
|
|
@ -80,12 +80,12 @@ static void uart1_init(void)
|
|||
struct uart_init_info uart1 = {
|
||||
.baud_rate = CONFIG_UART_BAUDRATE,
|
||||
.sys_clk_freq = UART_XTAL_FREQ,
|
||||
.int_pri = UART1_INT_PRI,
|
||||
.irq_pri = UART1_INT_PRI,
|
||||
};
|
||||
|
||||
uart_init(UART1, &uart1);
|
||||
|
||||
irq_connect(UART1_IRQ, uart1.int_pri, uart1_isr, 0);
|
||||
irq_connect(UART1_IRQ, uart1.irq_pri, uart1_isr, 0);
|
||||
|
||||
irq_enable(UART1_IRQ);
|
||||
|
||||
|
|
Loading…
Reference in a new issue