mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-03 12:16:39 +07:00
virtio_console: Let unconnected rproc device receive data.
Allow rproc serial ports to receive data before the port is connected. Rproc serial ports usually talk to very simple remote devices with no control queue managing open/close events. So we must let remote devices write to the virtio ring even if the device is not yet fully initialized. Signed-off-by: Sjur Brændeland <sjur.brandeland@stericsson.com> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
226364766f
commit
1f8051876a
@ -1763,8 +1763,11 @@ static void in_intr(struct virtqueue *vq)
|
||||
* tty is spawned) and the host sends out data to console
|
||||
* ports. For generic serial ports, the host won't
|
||||
* (shouldn't) send data till the guest is connected.
|
||||
* However a remote device might send data before the port is
|
||||
* connected. So don't remove data from a rproc_serial device.
|
||||
*/
|
||||
if (!port->guest_connected)
|
||||
|
||||
if (!port->guest_connected && !is_rproc_serial(port->portdev->vdev))
|
||||
discard_port_data(port);
|
||||
|
||||
spin_unlock_irqrestore(&port->inbuf_lock, flags);
|
||||
|
Loading…
Reference in New Issue
Block a user