This allows the last few characters to be * sent over the wire. */ #define TX_BUF_SIZE 32 /* * The number of jiffies to wait after receiving a close command before the * device is actually closed. */ #define RX_BUF_SIZE 32 /* The maximum size of the character buffer for a single TX BD. */ #define TX_NUM_FIFO 4 /* The maximum size of the character buffer for a single RX BD. */ #define RX_NUM_FIFO 4 /* The number of buffer descriptors for transmitting characters. */ #define SERIAL_QE_MAJOR 204 #define SERIAL_QE_MINOR 46 /* Since we only have minor numbers 46 - 49, there is a hard limit of 4 ports */ #define UCC_MAX_UART 4 /* The number of buffer descriptors for receiving characters. This decision was made because no Freescale part * has both a CPM and a QE. For the QE * UART, we have major number 204 and minor numbers 46 - 49, which are the * same as for the CPM2. */ static int firmware_loaded /* Enable this macro to configure all serial ports in internal loopback mode */ /* #define LOOPBACK */ /* The major and minor device numbers are defined in *. */ #define UCC_SLOW_GUMR_H_SUART 0x00004000 /* Soft-UART */ /* * soft_uart is 1 if we need to use Soft-UART mode */ static int soft_uart /* * firmware_loaded is 1 if the firmware has been loaded, 0 otherwise. This would normally be defined in qe.h, * but Soft-UART is a hack and we want to keep everything related to it in * this file. ![]() */ #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #ifdef CONFIG_PPC32 #include /* mfspr, SPRN_SVR */ #endif /* * The GUMR flag for Soft UART. 8323), and YZ is the revision of the SOC, * (e.g. The * filename of the microcode should be fsl_qe_ucode_uart_X_YZ.bin, where "X" * is the name of the SOC (e.g. * * If Soft-UART support is needed but not already present, then this driver * will request and upload the "Soft-UART" microcode upon probe. * * This driver adds support for UART devices via Freescale's QUICC Engine * found on some Freescale SOCs. > diff -git a/drivers/tty/n_tty.c b/drivers/tty/n_tty.// SPDX-License-Identifier: GPL-2.0 /* * Freescale QUICC Engine UART device driver * * Author: Timur Tabi * * Copyright 2007 Freescale Semiconductor, Inc. > 1 file changed, 11 insertions(+), 1 deletion(-) > use driver type to judge tty device type ![]() > remove unnecessary macro definition and debugging code > fix wrong expression in path description ![]() Why would we ever want to wait longer than 60 seconds? What problemsÄoes this cause if we just always set the timeout to 60 seconds? > for serial port, set the timeout value of wait_woken function to 60s. > the serial port runs well, wait_woken wait time will not exceed 60 seconds. > wait_woken and the process is trapped in a loop waiting. The concrete representation is n_tty_write blocking in > the serial port's TX and RX are short circuited, there is a certain probability > Serial port writing will be suspended when the buffer is continuously full.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |