/openbmc/linux/Documentation/devicetree/bindings/serial/ |
H A D | rs485.yaml | 1 # SPDX-License-Identifier: GPL-2.0 3 --- 4 $id: http://devicetree.org/schemas/serial/rs485.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 7 title: RS485 serial communications 9 description: The RTS signal is capable of automatically controlling line 10 direction for the built-in half-duplex mode. The properties described 11 hereafter shall be given to a half-duplex capable UART node. 14 - Rob Herring <robh@kernel.org> 17 rs485-rts-delay: [all …]
|
/openbmc/linux/Documentation/driver-api/serial/ |
H A D | serial-rs485.rst | 2 RS485 Serial Communications 8 EIA-485, also known as TIA/EIA-485 or RS-485, is a standard defining the 15 2. Hardware-related Considerations 18 Some CPUs/UARTs (e.g., Atmel AT91 or 16C950 UART) contain a built-in 19 half-duplex mode capable of automatically controlling line direction by 20 toggling RTS or DTR signals. That can be used to control external 21 half-duplex hardware like an RS485 transceiver or any RS232-connected 22 half-duplex devices like some modems. 26 available at user-level to allow switching from one mode to the other, and 32 The Linux kernel provides the struct serial_rs485 to handle RS485 [all …]
|
/openbmc/linux/arch/arm/boot/dts/ti/omap/ |
H A D | am335x-nano.dts | 1 // SPDX-License-Identifier: GPL-2.0-only 3 * Copyright (C) 2013 Newflow Ltd - http://www.newflow.co.uk/ 5 /dts-v1/; 15 cpu0-supply = <&dcdc2_reg>; 25 compatible = "gpio-leds"; 30 default-state = "off"; 36 pinctrl-names = "default"; 37 pinctrl-0 = <&misc_pins>; 39 misc_pins: misc-pins { 40 pinctrl-single,pins = < [all …]
|
H A D | am335x-pdu001.dts | 6 * Copyright (C) 2018 EETS GmbH - http://www.eets.ch/ 8 * Copyright (C) 2011, Texas Instruments, Incorporated - https://www.ti.com/ 10 * SPDX-License-Identifier: GPL-2.0+ 13 /dts-v1/; 16 #include <dt-bindings/interrupt-controller/irq.h> 17 #include <dt-bindings/leds/leds-pca9532.h> 24 stdout-path = &uart3; 29 cpu0-supply = <&vdd1_reg>; 39 compatible = "regulator-fixed"; 40 regulator-name = "vbat"; [all …]
|
/openbmc/linux/arch/arm/boot/dts/microchip/ |
H A D | aks-cdu.dts | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * aks-cdu.dts - Device Tree file for AK signal CDU 9 /dts-v1/; 11 #include "ge863-pro3.dtsi" 20 clock-frequency = <32768>; 32 linux,rs485-enabled-at-boot-time; 33 rs485-rts-delay = <0 0>; 38 linux,rs485-enabled-at-boot-time; 39 rs485-rts-delay = <0 0>; 44 linux,rs485-enabled-at-boot-time; [all …]
|
/openbmc/linux/include/uapi/linux/ |
H A D | serial.h | 1 /* SPDX-License-Identifier: GPL-1.0+ WITH Linux-syscall-note */ 63 #define PORT_RSA 13 /* RSA-DV II/S card */ 82 * Multiport serial configuration structure --- external structure 99 * Serial input interrupt line counters -- external structure 111 * struct serial_rs485 - serial interface for controlling RS485 settings. 112 * @flags: RS485 feature flags. 113 * @delay_rts_before_send: Delay before send (milliseconds). 114 * @delay_rts_after_send: Delay after send (milliseconds). 115 * @addr_recv: Receive filter for RS485 addressing mode 117 * @addr_dest: Destination address for RS485 addressing mode [all …]
|
/openbmc/linux/arch/arm64/boot/dts/freescale/ |
H A D | imx8mp-verdin-dev.dtsi | 1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT 7 reg_eth2phy: regulator-eth2phy { 8 compatible = "regulator-fixed"; 9 enable-active-high; 11 off-on-delay-us = <500000>; 12 regulator-max-microvolt = <3300000>; 13 regulator-min-microvolt = <3300000>; 14 regulator-name = "+V3.3_ETH"; 15 startup-delay-us = <200000>; 16 vin-supply = <®_3p3v>; [all …]
|
H A D | imx8mm-venice-gw7902.dts | 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 6 /dts-v1/; 8 #include <dt-bindings/gpio/gpio.h> 9 #include <dt-bindings/input/linux-event-codes.h> 10 #include <dt-bindings/leds/common.h> 11 #include <dt-bindings/net/ti-dp83867.h> 12 #include <dt-bindings/phy/phy-imx8-pcie.h> 18 compatible = "gw,imx8mm-gw7902", "fsl,imx8mm"; 27 stdout-path = &uart2; 36 compatible = "fixed-clock"; [all …]
|
H A D | imx8mm-venice-gw7901.dts | 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 6 /dts-v1/; 8 #include <dt-bindings/gpio/gpio.h> 9 #include <dt-bindings/input/linux-event-codes.h> 10 #include <dt-bindings/leds/common.h> 11 #include <dt-bindings/phy/phy-imx8-pcie.h> 17 compatible = "gw,imx8mm-gw7901", "fsl,imx8mm"; 30 stdout-path = &uart2; 38 gpio-keys { 39 compatible = "gpio-keys"; [all …]
|
/openbmc/linux/drivers/tty/serial/8250/ |
H A D | 8250_lpc18xx.c | 1 // SPDX-License-Identifier: GPL-2.0 36 struct serial_rs485 *rs485) in lpc18xx_rs485_config() argument 43 if (rs485->flags & SER_RS485_ENABLED) { in lpc18xx_rs485_config() 47 if (rs485->flags & SER_RS485_RTS_ON_SEND) in lpc18xx_rs485_config() 51 if (rs485->delay_rts_after_send) { in lpc18xx_rs485_config() 52 baud_clk = port->uartclk / up->dl_read(up); in lpc18xx_rs485_config() 53 rs485_dly_reg = DIV_ROUND_UP(rs485->delay_rts_after_send in lpc18xx_rs485_config() 59 /* Calculate the resulting delay in ms */ in lpc18xx_rs485_config() 60 rs485->delay_rts_after_send = (rs485_dly_reg * MSEC_PER_SEC) in lpc18xx_rs485_config() 80 offset = offset << p->regshift; in lpc18xx_uart_serial_out() [all …]
|
H A D | 8250_pci1xxxx.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * Probe module for 8250/16550-type MCHP PCI serial ports. 91 {0, 1, 2, -1}, /* PCI3p012 */ 92 {0, 1, 3, -1}, /* PCI3p013 */ 93 {0, 2, 3, -1}, /* PCI3p023 */ 94 {1, 2, 3, -1}, /* PCI3p123 */ 95 {0, 1, -1, -1}, /* PCI2p01 */ 96 {0, 2, -1, -1}, /* PCI2p02 */ 97 {0, 3, -1, -1}, /* PCI2p03 */ 98 {1, 2, -1, -1}, /* PCI2p12 */ [all …]
|
H A D | 8250_omap.c | 1 // SPDX-License-Identifier: GPL-2.0 3 * 8250-core based driver for the OMAP internal UART 5 * based on omap-serial.c, Copyright (C) 2010 Texas Instruments. 23 #include <linux/delay.h> 28 #include <linux/dma-mapping.h> 165 return readl(priv->membase + (reg << OMAP_UART_REGSHIFT)); in uart_read() 179 struct omap8250_priv *priv = up->port.private_data; in __omap8250_set_mctrl() 184 if (!mctrl_gpio_to_gpiod(up->gpios, UART_GPIO_RTS)) { in __omap8250_set_mctrl() 186 * Turn off autoRTS if RTS is lowered and restore autoRTS in __omap8250_set_mctrl() 187 * setting if RTS is raised in __omap8250_set_mctrl() [all …]
|
H A D | 8250_port.c | 1 // SPDX-License-Identifier: GPL-2.0+ 3 * Base port operations for 8250/16550-type serial ports 22 #include <linux/delay.h> 255 * tx_loadsz is set to 63-bytes instead of 64-bytes to implement 256 * workaround of errata A-008006 which states that tx_loadsz should 268 .name = "Palmchip BK-3103", 354 offset = offset << p->regshift; in hub6_serial_in() 355 outb(p->hub6 - 1 + offset, p->iobase); in hub6_serial_in() 356 return inb(p->iobase + 1); in hub6_serial_in() 361 offset = offset << p->regshift; in hub6_serial_out() [all …]
|
/openbmc/linux/drivers/tty/serial/ |
H A D | serial_core.c | 1 // SPDX-License-Identifier: GPL-2.0+ 8 * Copyright (C) 2000-2001 Deep Blue Solutions Ltd. 27 #include <linux/delay.h> 43 * lockdep: port->lock is initialized in two places, but we 44 * want only one lock-class: 48 #define HIGH_BITS_OFFSET ((sizeof(long)-sizeof(int))*8) 51 * Max time with active RTS before/after data is sent. 62 return !!(uport->status & UPSTAT_DCD_ENABLE); in uart_dcd_enabled() 67 if (atomic_add_unless(&state->refcount, 1, 0)) in uart_port_ref() 68 return state->uart_port; in uart_port_ref() [all …]
|
H A D | imx.c | 1 // SPDX-License-Identifier: GPL-2.0+ 22 #include <linux/delay.h> 30 #include <linux/dma-mapping.h> 33 #include <linux/dma/imx-dma.h> 74 #define UCR1_RTSDEN (1<<5) /* RTS delta interrupt enable */ 82 #define UCR2_IRTS (1<<14) /* Ignore RTS pin */ 125 #define UFCR_RFDIV_REG(x) (((x) < 7 ? 6 - (x) : 6) << 7) 128 #define USR1_RTSS (1<<14) /* RTS pin status */ 130 #define USR1_RTSD (1<<12) /* RTS delta */ 148 #define USR2_RTSF (1<<4) /* RTS edge interrupt flag */ [all …]
|
H A D | omap-serial.c | 1 // SPDX-License-Identifier: GPL-2.0+ 3 * Driver for OMAP-UART controller. 16 * this driver as required for the omap-platform. 24 #include <linux/delay.h> 38 #include <linux/platform_data/serial-omap.h> 79 #define OMAP_UART_DMA_CH_FREE -1 176 offset <<= up->port.regshift; in serial_in() 177 return readw(up->port.membase + offset); in serial_in() 182 offset <<= up->port.regshift; in serial_out() 183 writew(value, up->port.membase + offset); in serial_out() [all …]
|
H A D | max310x.c | 1 // SPDX-License-Identifier: GPL-2.0+ 5 * Copyright (C) 2012-2016 Alexander Shiyan <shc_work@mail.ru> 14 #include <linux/delay.h> 104 #define MAX310X_SPCHR_MULTIDROP_BIT (1 << 5) /* 9-bit multidrop addr char */ 117 #define MAX310X_MODE1_TXHIZ_BIT (1 << 2) /* TX pin three-state */ 118 #define MAX310X_MODE1_RTSHIZ_BIT (1 << 3) /* RTS pin three-state */ 131 #define MAX310X_MODE2_MULTIDROP_BIT (1 << 6) /* 9-bit multidrop enable */ 139 * 00 -> 5 bit words 140 * 01 -> 6 bit words 141 * 10 -> 7 bit words [all …]
|
H A D | sc16is7xx.c | 1 // SPDX-License-Identifier: GPL-2.0+ 3 * SC16IS7xx tty serial driver - Copyright (C) 2014 GridPoint 13 #include <linux/delay.h> 47 * - only on 75x/76x 50 * - only on 75x/76x 53 * - only on 75x/76x 56 * - only on 75x/76x 84 /* IER register bits - write only if (EFR[4] == 1) */ 97 /* FCR register bits - write only if (EFR[4] == 1) */ 107 #define SC16IS7XX_IIR_RTOI_SRC 0x0c /* RX time-out interrupt */ [all …]
|
H A D | atmel_serial.c | 1 // SPDX-License-Identifier: GPL-2.0+ 18 #include <linux/clk-provider.h> 24 #include <linux/dma-mapping.h> 46 * These two offsets are substracted from the RX FIFO size to define the RTS 62 /* Use device name ttyAT, major 204 and minor 154-169. This is necessary if we 71 /* Use device name ttyS, major 4, minor 64-68. This is the usual serial port 165 bool hd_start_rx; /* can start RX during half-duplex operation */ 195 { .compatible = "atmel,at91rm9200-usart-serial" }, 208 return __raw_readl(port->membase + reg); in atmel_uart_readl() 213 __raw_writel(value, port->membase + reg); in atmel_uart_writel() [all …]
|
H A D | amba-pl011.c | 1 // SPDX-License-Identifier: GPL-2.0+ 9 * Copyright (C) 2010 ST-Ericsson SA 11 * This is a generic driver for ARM AMBA-type serial ports. They 12 * have a lot of 16550-like features, but are not register compatible. 14 * not have an RI input, nor do they have DTR or RTS outputs. If 35 #include <linux/dma-mapping.h> 37 #include <linux/delay.h> 82 /* The size of the array - must be last */ 262 unsigned int fifosize; /* vendor-specific */ 263 unsigned int fixed_baud; /* vendor-set fixed baud rate */ [all …]
|
/openbmc/linux/arch/x86/platform/ts5500/ |
H A D | ts5500.c | 1 // SPDX-License-Identifier: GPL-2.0-or-later 3 * Technologic Systems TS-5500 Single Board Computer support 5 * Copyright (C) 2013-2014 Savoir-faire Linux Inc. 8 * This driver registers the Technologic Systems TS-5500 Single Board Computer 11 * Documentation/ABI/testing/sysfs-platform-ts5500. 13 * This code may be extended to support similar x86-based platforms. 14 * Actually, the TS-5500 and TS-5400 are supported. 17 #include <linux/delay.h> 28 #define TS5500_PRODUCT_CODE 0x60 /* TS-5500 product code */ 29 #define TS5400_PRODUCT_CODE 0x40 /* TS-5400 product code */ [all …]
|
/openbmc/linux/arch/arm/boot/dts/nxp/imx/ |
H A D | imx7-mba7.dtsi | 1 // SPDX-License-Identifier: GPL-2.0 OR X11 3 * Device Tree Include file for TQ-Systems MBa7 carrier board. 5 * Copyright (C) 2016 TQ-Systems GmbH 6 * Author: Markus Niebel <Markus.Niebel@tq-group.com> 13 #include <dt-bindings/input/input.h> 14 #include <dt-bindings/net/ti-dp83867.h> 20 /delete-property/ mmc2; 24 compatible = "gpio-beeper"; 29 stdout-path = &uart6; 32 gpio_buttons: gpio-keys { [all …]
|
H A D | mba6ulx.dtsi | 1 // SPDX-License-Identifier: (GPL-2.0-or-later OR MIT) 3 * Copyright 2018-2022 TQ-Systems GmbH 4 * Author: Markus Niebel <Markus.Niebel@tq-group.com> 8 model = "TQ-Systems MBA6ULx Baseboard"; 18 stdout-path = &uart1; 22 compatible = "pwm-backlight"; 23 power-supply = <®_mba6ul_3v3>; 24 enable-gpios = <&expander_out0 4 GPIO_ACTIVE_HIGH>; 29 compatible = "gpio-beeper"; 33 gpio_buttons: gpio-keys { [all …]
|
H A D | imx6dl-plybas.dts | 1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT 7 /dts-v1/; 8 #include <dt-bindings/gpio/gpio.h> 9 #include <dt-bindings/leds/common.h> 17 stdout-path = &uart4; 21 compatible = "gpio-keys"; 24 button-start { 30 button-clean { 38 compatible = "gpio-leds"; 39 pinctrl-names = "default"; [all …]
|
/openbmc/u-boot/arch/arm/dts/ |
H A D | am335x-pdu001.dts | 6 * Copyright (C) 2018 EETS GmbH - http://www.eets.ch/ 8 * Copyright (C) 2011, Texas Instruments, Incorporated - http://www.ti.com/ 10 * SPDX-License-Identifier: GPL-2.0+ 13 /dts-v1/; 16 #include <dt-bindings/interrupt-controller/irq.h> 17 #include <dt-bindings/leds/leds-pca9532.h> 24 stdout-path = &uart3; 29 cpu0-supply = <&vdd1_reg>; 39 compatible = "regulator-fixed"; 40 regulator-name = "vbat"; [all …]
|