xemu/hw/char
Peter Crosthwaite d0ac820fe4 char/cadence_uart: Fix can_receive logic
The can_receive logic was only taking into account the RxFIFO
occupancy. RxFIFO population is only used for the echo and normal modes
however. Improve the logic to correctly return the true number of
receivable characters based on the current mode:

Normal mode: RxFIFO vacancy.
Remote loopback: TxFIFO vacancy.
Echo mode: The min of the TxFIFO and RxFIFO vacancies.
Local Loopback: Return non-zero (to implement droppage)

Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
Message-id: 36a58440c9ca5080151e95765c2c81342de8a8df.1388626249.git.peter.crosthwaite@xilinx.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2014-01-08 19:07:21 +00:00
..
Makefile.objs hw/arm/digic: add UART support 2013-12-17 20:12:51 +00:00
cadence_uart.c char/cadence_uart: Fix can_receive logic 2014-01-08 19:07:21 +00:00
debugcon.c devices: Associate devices to their logical category 2013-07-29 10:37:09 -05:00
digic-uart.c hw/arm/digic: add UART support 2013-12-17 20:12:51 +00:00
escc.c escc: QOM cast cleanup 2013-07-29 21:06:27 +02:00
etraxfs_ser.c etraxfs_ser: QOM cast cleanups 2013-07-29 20:45:33 +02:00
exynos4210_uart.c exynos4210_uart: QOM cast cleanup 2013-07-29 21:06:27 +02:00
grlib_apbuart.c grlib_apbuart: QOM cast cleanup 2013-07-29 21:06:27 +02:00
imx_serial.c imx_serial: QOM cast cleanup 2013-07-29 21:06:27 +02:00
ipack.c qdev: Pass size to qbus_create_inplace() 2013-08-30 21:15:35 +02:00
ipack.h ipack: Pass size to ipack_bus_new_inplace() 2013-08-30 20:14:38 +02:00
ipoctal232.c devices: Associate devices to their logical category 2013-07-29 10:37:09 -05:00
lm32_juart.c lm32_juart: QOM cast cleanup 2013-07-29 21:06:28 +02:00
lm32_uart.c lm32_uart: QOM cast cleanup 2013-07-29 21:06:28 +02:00
mcf_uart.c memory: add owner argument to initialization functions 2013-07-04 17:42:44 +02:00
milkymist-uart.c milkymist-uart: Use Device::realize instead of SysBusDevice::init 2013-11-05 17:47:29 +01:00
omap_uart.c memory: add owner argument to initialization functions 2013-07-04 17:42:44 +02:00
parallel.c devices: Associate devices to their logical category 2013-07-29 10:37:09 -05:00
pl011.c pl011: QOM'ify pl011 and pl011_luminary 2013-07-29 21:06:28 +02:00
sclpconsole-lm.c s390/sclplmconsole: Add support for SCLP line-mode console 2013-09-20 13:55:30 +02:00
sclpconsole.c s390/eventfacility: allow childs to handle more than 1 event type 2013-09-20 13:55:30 +02:00
serial-isa.c devices: Associate devices to their logical category 2013-07-29 10:37:09 -05:00
serial-pci.c hw: set interrupts using pci irq wrappers 2013-10-14 17:11:45 +03:00
serial.c Merge remote-tracking branch 'stefanha/block' into staging 2013-08-26 09:19:50 -05:00
sh_serial.c sh4: Fix serial line access for Linux kernels later than 3.2 2013-10-02 22:55:28 +04:00
spapr_vty.c spapr: add vio-bus devices to categories 2013-11-08 04:33:18 +01:00
tpci200.c hw: set interrupts using pci irq wrappers 2013-10-14 17:11:45 +03:00
virtio-console.c virtio-console: Use exitfn for virtserialport, too 2013-08-01 11:18:32 -05:00
virtio-serial-bus.c virtio: Convert exit to unrealize 2013-12-09 21:46:49 +01:00
xen_console.c sysemu: avoid proliferation of include/ subdirectories 2013-04-15 18:19:25 +02:00
xilinx_uartlite.c xilinx_uartlite: QOM cast cleanups 2013-07-29 20:45:45 +02:00