/linux/drivers/tty/serial/ |
A D | serial_mctrl_gpio.c | 29 unsigned int mctrl; member 59 mctrl & mctrl_gpios_desc[i].mctrl); in mctrl_gpio_set() 81 return *mctrl; in mctrl_gpio_get() 86 *mctrl |= mctrl_gpios_desc[i].mctrl; in mctrl_gpio_get() 88 *mctrl &= ~mctrl_gpios_desc[i].mctrl; in mctrl_gpio_get() 92 return *mctrl; in mctrl_gpio_get() 102 return *mctrl; in mctrl_gpio_get_outputs() 107 *mctrl |= mctrl_gpios_desc[i].mctrl; in mctrl_gpio_get_outputs() 109 *mctrl &= ~mctrl_gpios_desc[i].mctrl; in mctrl_gpio_get_outputs() 113 return *mctrl; in mctrl_gpio_get_outputs() [all …]
|
A D | serial_mctrl_gpio.h | 38 void mctrl_gpio_set(struct mctrl_gpios *gpios, unsigned int mctrl); 44 unsigned int mctrl_gpio_get(struct mctrl_gpios *gpios, unsigned int *mctrl); 51 mctrl_gpio_get_outputs(struct mctrl_gpios *gpios, unsigned int *mctrl); 97 void mctrl_gpio_set(struct mctrl_gpios *gpios, unsigned int mctrl) in mctrl_gpio_set() argument 102 unsigned int mctrl_gpio_get(struct mctrl_gpios *gpios, unsigned int *mctrl) in mctrl_gpio_get() argument 104 return *mctrl; in mctrl_gpio_get() 108 mctrl_gpio_get_outputs(struct mctrl_gpios *gpios, unsigned int *mctrl) in mctrl_gpio_get_outputs() argument 110 return *mctrl; in mctrl_gpio_get_outputs()
|
A D | zs.c | 322 unsigned int mctrl; in zs_raw_get_ab_mctrl() local 332 return mctrl; in zs_raw_get_ab_mctrl() 359 mctrl = zport->mctrl; in zs_raw_xor_mctrl() 361 mctrl &= ~mmask; in zs_raw_xor_mctrl() 365 delta = mctrl ^ zport->mctrl; in zs_raw_xor_mctrl() 367 zport->mctrl = mctrl; in zs_raw_xor_mctrl() 376 unsigned int mctrl; in zs_get_mctrl() local 382 return mctrl; in zs_get_mctrl() 394 if (mctrl & TIOCM_DTR) in zs_set_mctrl() 398 if (mctrl & TIOCM_RTS) in zs_set_mctrl() [all …]
|
A D | vr41xx_siu.c | 190 if (mctrl & TIOCM_DTR) in siu_set_mctrl() 192 if (mctrl & TIOCM_RTS) in siu_set_mctrl() 194 if (mctrl & TIOCM_OUT1) in siu_set_mctrl() 196 if (mctrl & TIOCM_OUT2) in siu_set_mctrl() 198 if (mctrl & TIOCM_LOOP) in siu_set_mctrl() 207 unsigned int mctrl = 0; in siu_get_mctrl() local 211 mctrl |= TIOCM_CAR; in siu_get_mctrl() 213 mctrl |= TIOCM_RNG; in siu_get_mctrl() 215 mctrl |= TIOCM_DSR; in siu_get_mctrl() 217 mctrl |= TIOCM_CTS; in siu_get_mctrl() [all …]
|
A D | men_z135_uart.c | 485 if (mctrl & TIOCM_RTS) in men_z135_set_mctrl() 490 if (mctrl & TIOCM_DTR) in men_z135_set_mctrl() 495 if (mctrl & TIOCM_OUT1) in men_z135_set_mctrl() 500 if (mctrl & TIOCM_OUT2) in men_z135_set_mctrl() 505 if (mctrl & TIOCM_LOOP) in men_z135_set_mctrl() 522 unsigned int mctrl = 0; in men_z135_get_mctrl() local 528 mctrl |= TIOCM_CTS; in men_z135_get_mctrl() 530 mctrl |= TIOCM_DSR; in men_z135_get_mctrl() 532 mctrl |= TIOCM_RI; in men_z135_get_mctrl() 534 mctrl |= TIOCM_CAR; in men_z135_get_mctrl() [all …]
|
A D | bcm63xx_uart.c | 99 static void bcm_uart_set_mctrl(struct uart_port *port, unsigned int mctrl) in bcm_uart_set_mctrl() argument 106 if (!(mctrl & TIOCM_DTR)) in bcm_uart_set_mctrl() 108 if (!(mctrl & TIOCM_RTS)) in bcm_uart_set_mctrl() 113 if (mctrl & TIOCM_LOOP) in bcm_uart_set_mctrl() 125 unsigned int val, mctrl; in bcm_uart_get_mctrl() local 127 mctrl = 0; in bcm_uart_get_mctrl() 130 mctrl |= TIOCM_RI; in bcm_uart_get_mctrl() 132 mctrl |= TIOCM_CTS; in bcm_uart_get_mctrl() 134 mctrl |= TIOCM_CD; in bcm_uart_get_mctrl() 136 mctrl |= TIOCM_DSR; in bcm_uart_get_mctrl() [all …]
|
A D | sccnxp.c | 577 sccnxp_set_bit(port, DTR_OP, mctrl & TIOCM_DTR); in sccnxp_set_mctrl() 591 return mctrl; in sccnxp_get_mctrl() 600 mctrl &= ~TIOCM_DSR; in sccnxp_get_mctrl() 601 mctrl |= (ipr & bitmask) ? TIOCM_DSR : 0; in sccnxp_get_mctrl() 606 mctrl &= ~TIOCM_CTS; in sccnxp_get_mctrl() 607 mctrl |= (ipr & bitmask) ? TIOCM_CTS : 0; in sccnxp_get_mctrl() 612 mctrl &= ~TIOCM_CAR; in sccnxp_get_mctrl() 613 mctrl |= (ipr & bitmask) ? TIOCM_CAR : 0; in sccnxp_get_mctrl() 618 mctrl &= ~TIOCM_RNG; in sccnxp_get_mctrl() 619 mctrl |= (ipr & bitmask) ? TIOCM_RNG : 0; in sccnxp_get_mctrl() [all …]
|
A D | pxa.c | 294 static void serial_pxa_set_mctrl(struct uart_port *port, unsigned int mctrl) in serial_pxa_set_mctrl() argument 299 if (mctrl & TIOCM_RTS) in serial_pxa_set_mctrl() 301 if (mctrl & TIOCM_DTR) in serial_pxa_set_mctrl() 303 if (mctrl & TIOCM_OUT1) in serial_pxa_set_mctrl() 305 if (mctrl & TIOCM_OUT2) in serial_pxa_set_mctrl() 307 if (mctrl & TIOCM_LOOP) in serial_pxa_set_mctrl() 372 up->port.mctrl |= TIOCM_OUT2; in serial_pxa_startup() 373 serial_pxa_set_mctrl(&up->port, up->port.mctrl); in serial_pxa_startup() 409 up->port.mctrl &= ~TIOCM_OUT2; in serial_pxa_shutdown() 410 serial_pxa_set_mctrl(&up->port, up->port.mctrl); in serial_pxa_shutdown() [all …]
|
A D | pic32_uart.c | 72 static void pic32_uart_set_mctrl(struct uart_port *port, unsigned int mctrl) in pic32_uart_set_mctrl() argument 77 if (mctrl & TIOCM_LOOP) in pic32_uart_set_mctrl() 99 unsigned int mctrl = 0; in pic32_uart_get_mctrl() local 102 mctrl |= TIOCM_CTS; in pic32_uart_get_mctrl() 104 mctrl |= TIOCM_CTS; in pic32_uart_get_mctrl() 109 mctrl |= TIOCM_CD; in pic32_uart_get_mctrl() 110 mctrl |= TIOCM_DSR; in pic32_uart_get_mctrl() 112 return mctrl; in pic32_uart_get_mctrl()
|
A D | mxs-auart.c | 721 static void mxs_auart_set_mctrl(struct uart_port *u, unsigned mctrl) in mxs_auart_set_mctrl() argument 728 if (mctrl & TIOCM_RTS) { in mxs_auart_set_mctrl() 737 mctrl_gpio_set(s->gpios, mctrl); in mxs_auart_set_mctrl() 745 mctrl_diff = mctrl ^ s->mctrl_prev; in mxs_auart_modem_status() 746 s->mctrl_prev = mctrl; in mxs_auart_modem_status() 754 uart_handle_dcd_change(&s->port, mctrl & TIOCM_CD); in mxs_auart_modem_status() 756 uart_handle_cts_change(&s->port, mctrl & TIOCM_CTS); in mxs_auart_modem_status() 760 return mctrl; in mxs_auart_modem_status() 767 u32 mctrl = 0; in mxs_auart_get_mctrl() local 770 mctrl |= TIOCM_CTS; in mxs_auart_get_mctrl() [all …]
|
A D | sunsu.c | 582 if (mctrl & TIOCM_RTS) in sunsu_set_mctrl() 584 if (mctrl & TIOCM_DTR) in sunsu_set_mctrl() 586 if (mctrl & TIOCM_OUT1) in sunsu_set_mctrl() 588 if (mctrl & TIOCM_OUT2) in sunsu_set_mctrl() 590 if (mctrl & TIOCM_LOOP) in sunsu_set_mctrl() 688 up->port.mctrl |= TIOCM_OUT2; in sunsu_startup() 690 sunsu_set_mctrl(&up->port, up->port.mctrl); in sunsu_startup() 738 up->port.mctrl |= TIOCM_OUT1; in sunsu_shutdown() 740 up->port.mctrl &= ~TIOCM_OUT2; in sunsu_shutdown() 742 sunsu_set_mctrl(&up->port, up->port.mctrl); in sunsu_shutdown() [all …]
|
A D | rda-uart.c | 154 unsigned int mctrl = 0; in rda_uart_get_mctrl() local 160 mctrl |= TIOCM_RTS; in rda_uart_get_mctrl() 162 mctrl |= TIOCM_CTS; in rda_uart_get_mctrl() 164 return mctrl; in rda_uart_get_mctrl() 167 static void rda_uart_set_mctrl(struct uart_port *port, unsigned int mctrl) in rda_uart_set_mctrl() argument 171 if (mctrl & TIOCM_RTS) { in rda_uart_set_mctrl() 182 if (mctrl & TIOCM_LOOP) in rda_uart_set_mctrl()
|
A D | xilinx_uartps.c | 1013 unsigned int mctrl = 0; in cdns_uart_get_mctrl() local 1021 mctrl |= TIOCM_CTS; in cdns_uart_get_mctrl() 1023 mctrl |= TIOCM_DSR; in cdns_uart_get_mctrl() 1025 mctrl |= TIOCM_RNG; in cdns_uart_get_mctrl() 1027 mctrl |= TIOCM_CAR; in cdns_uart_get_mctrl() 1029 return mctrl; in cdns_uart_get_mctrl() 1032 static void cdns_uart_set_mctrl(struct uart_port *port, unsigned int mctrl) in cdns_uart_set_mctrl() argument 1047 if (mctrl & TIOCM_RTS) in cdns_uart_set_mctrl() 1049 if (mctrl & TIOCM_DTR) in cdns_uart_set_mctrl() 1051 if (mctrl & TIOCM_LOOP) in cdns_uart_set_mctrl()
|
A D | owl-uart.c | 94 static void owl_uart_set_mctrl(struct uart_port *port, unsigned int mctrl) in owl_uart_set_mctrl() argument 100 if (mctrl & TIOCM_LOOP) in owl_uart_set_mctrl() 110 unsigned int mctrl = TIOCM_CAR | TIOCM_DSR; in owl_uart_get_mctrl() local 116 mctrl |= TIOCM_RTS; in owl_uart_get_mctrl() 118 mctrl |= TIOCM_CTS; in owl_uart_get_mctrl() 119 return mctrl; in owl_uart_get_mctrl()
|
A D | sb1250-duart.c | 242 unsigned int mctrl, status; in sbd_get_mctrl() local 246 mctrl = (!(status & M_DUART_IN_PIN0_VAL) ? TIOCM_CTS : 0) | in sbd_get_mctrl() 250 return mctrl; in sbd_get_mctrl() 253 static void sbd_set_mctrl(struct uart_port *uport, unsigned int mctrl) in sbd_set_mctrl() argument 258 if (mctrl & TIOCM_DTR) in sbd_set_mctrl() 262 if (mctrl & TIOCM_RTS) in sbd_set_mctrl() 271 if (mctrl & TIOCM_LOOP) in sbd_set_mctrl()
|
/linux/drivers/cpufreq/ |
A D | sparc-us2e-cpufreq.c | 76 unsigned long mctrl = read_hbreg(HBIRD_MEM_CNTL0_ADDR); in self_refresh_ctl() local 79 mctrl |= MCTRL0_SREFRESH_ENAB; in self_refresh_ctl() 81 mctrl &= ~MCTRL0_SREFRESH_ENAB; in self_refresh_ctl() 82 write_hbreg(HBIRD_MEM_CNTL0_ADDR, mctrl); in self_refresh_ctl() 90 unsigned long old_refr_count, refr_count, mctrl; in frob_mem_refresh() local 95 mctrl = read_hbreg(HBIRD_MEM_CNTL0_ADDR); in frob_mem_refresh() 96 old_refr_count = (mctrl & MCTRL0_REFR_COUNT_MASK) in frob_mem_refresh() 99 mctrl &= ~MCTRL0_REFR_COUNT_MASK; in frob_mem_refresh() 100 mctrl |= refr_count << MCTRL0_REFR_COUNT_SHIFT; in frob_mem_refresh() 101 write_hbreg(HBIRD_MEM_CNTL0_ADDR, mctrl); in frob_mem_refresh() [all …]
|
/linux/drivers/tty/hvc/ |
A D | hvsi_lib.c | 50 pv->mctrl |= TIOCM_CD; in hvsi_cd_change() 52 pv->mctrl &= ~TIOCM_CD; in hvsi_cd_change() 290 unsigned short mctrl; in hvsilib_write_mctrl() local 292 mctrl = pv->mctrl; in hvsilib_write_mctrl() 294 mctrl |= TIOCM_DTR; in hvsilib_write_mctrl() 296 mctrl &= ~TIOCM_DTR; in hvsilib_write_mctrl() 297 if (mctrl == pv->mctrl) in hvsilib_write_mctrl() 299 pv->mctrl = mctrl; in hvsilib_write_mctrl()
|
A D | hvsi.c | 76 uint16_t mctrl; member 235 hp->mctrl &= TIOCM_CD; in hvsi_recv_control() 264 hp->mctrl = 0; in hvsi_recv_response() 267 hp->mctrl |= TIOCM_DTR; in hvsi_recv_response() 269 hp->mctrl |= TIOCM_CD; in hvsi_recv_response() 594 if (mctrl & TIOCM_DTR) in hvsi_set_mctrl() 737 ret = hvsi_set_mctrl(hp, hp->mctrl | TIOCM_DTR); in hvsi_open() 998 return hp->mctrl; in hvsi_tiocmget() 1014 new_mctrl = (hp->mctrl & ~clear) | set; in hvsi_tiocmset() 1016 if (hp->mctrl != new_mctrl) { in hvsi_tiocmset() [all …]
|
/linux/Documentation/devicetree/bindings/gpio/ |
A D | cirrus,clps711x-mctrl-gpio.txt | 4 - compatible: Should contain "cirrus,ep7209-mctrl-gpio". 13 compatible = "cirrus,ep7312-mctrl-gpio", 14 "cirrus,ep7209-mctrl-gpio";
|
/linux/drivers/mmc/core/ |
A D | sdio_uart.c | 74 unsigned int mctrl; member 214 unsigned int mctrl) in sdio_uart_write_mctrl() argument 218 if (mctrl & TIOCM_RTS) in sdio_uart_write_mctrl() 220 if (mctrl & TIOCM_DTR) in sdio_uart_write_mctrl() 222 if (mctrl & TIOCM_OUT1) in sdio_uart_write_mctrl() 224 if (mctrl & TIOCM_OUT2) in sdio_uart_write_mctrl() 226 if (mctrl & TIOCM_LOOP) in sdio_uart_write_mctrl() 237 old = port->mctrl; in sdio_uart_update_mctrl() 238 port->mctrl = (old & ~clear) | set; in sdio_uart_update_mctrl() 239 if (old != port->mctrl) in sdio_uart_update_mctrl() [all …]
|
/linux/arch/arm/mach-integrator/ |
A D | integrator_ap.c | 107 void __iomem *base, unsigned int mctrl) in integrator_uart_set_mctrl() argument 123 if (mctrl & TIOCM_RTS) in integrator_uart_set_mctrl() 128 if (mctrl & TIOCM_DTR) in integrator_uart_set_mctrl()
|
/linux/drivers/tty/serial/8250/ |
A D | 8250.h | 230 int mctrl; in serial8250_in_MCR() local 232 mctrl = serial_in(up, UART_MCR); in serial8250_in_MCR() 238 mctrl |= serial8250_TIOCM_to_MCR(mctrl_gpio); in serial8250_in_MCR() 241 return mctrl; in serial8250_in_MCR()
|
/linux/arch/arm/boot/dts/ |
A D | ep7209.dtsi | 195 mctrl: mctrl { label 196 compatible = "cirrus,ep7209-mctrl-gpio";
|
/linux/drivers/net/ethernet/sfc/falcon/ |
A D | txc43128_phy.c | 279 int mctrl; in txc_apply_defaults() local 309 mctrl = ef4_mdio_read(efx, MDIO_MMD_PHYXS, TXC_MRGS_CTL); in txc_apply_defaults() 312 mctrl &= ~((1 << TXC_MCTL_TXLED_LBN) | (1 << TXC_MCTL_RXLED_LBN)); in txc_apply_defaults() 313 ef4_mdio_write(efx, MDIO_MMD_PHYXS, TXC_MRGS_CTL, mctrl); in txc_apply_defaults()
|
/linux/drivers/staging/fwserial/ |
A D | fwserial.c | 393 if (port->mctrl & TIOCM_DTR) in __fwtty_port_line_status() 395 if (port->mctrl & TIOCM_RTS) in __fwtty_port_line_status() 397 if (port->mctrl & OOB_RX_THROTTLE) in __fwtty_port_line_status() 453 old = port->mctrl; in fwtty_throttle_port() 454 port->mctrl |= OOB_RX_THROTTLE; in fwtty_throttle_port() 456 port->mctrl &= ~TIOCM_RTS; in fwtty_throttle_port() 997 port->mctrl = 0; in fwtty_port_activate() 999 port->mctrl = TIOCM_DTR | TIOCM_RTS; in fwtty_port_activate() 1179 port->mctrl &= ~OOB_RX_THROTTLE; in fwtty_unthrottle() 1181 port->mctrl |= TIOCM_RTS; in fwtty_unthrottle() [all …]
|