opencores_eth: flush queue whenever can_receive can go from false to true
commit6e50d18847a76704c8a49e406084a2321117b954
authorMax Filippov <jcmvbkbc@gmail.com>
Mon, 3 Feb 2014 04:20:02 +0000 (3 08:20 +0400)
committerStefan Hajnoczi <stefanha@redhat.com>
Tue, 25 Feb 2014 10:50:16 +0000 (25 11:50 +0100)
tree58526067d34a04743e940fb600351e4b9f2fda8f
parentc58e291591dbc1c846fa152d4792554803405ebb
opencores_eth: flush queue whenever can_receive can go from false to true

The following registers control whether MAC can receive frames:
- MODER.RXEN bit that enables/disables receiver;
- TX_BD_NUM register that specifies number of RX descriptors.
Notify QEMU networking core when the MAC is ready to receive frames.
Discard frame and raise BUSY interrupt when the frame arrives but the
current RX descriptor is not empty.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
hw/net/opencores_eth.c