]> git.ipfire.org Git - thirdparty/qemu.git/commit
net: rtl8139: limit processing of ring descriptors
authorPrasad J Pandit <pjp@fedoraproject.org>
Fri, 21 Oct 2016 12:09:29 +0000 (17:39 +0530)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Wed, 2 Nov 2016 23:19:01 +0000 (18:19 -0500)
commit2817466c555d89c22bdd1ec8626bce09ee96922e
tree5e84db9090c45cb2c897916096c860f0c933a87a
parente389e44a351dfeb5ebff15662c08816a8f1c6324
net: rtl8139: limit processing of ring descriptors

RTL8139 ethernet controller in C+ mode supports multiple
descriptor rings, each with maximum of 64 descriptors. While
processing transmit descriptor ring in 'rtl8139_cplus_transmit',
it does not limit the descriptor count and runs forever. Add
check to avoid it.

Reported-by: Andrew Henderson <hendersa@icculus.org>
Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
Signed-off-by: Jason Wang <jasowang@redhat.com>
(cherry picked from commit c7c35916692fe010fef25ac338443d3fe40be225)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
hw/net/rtl8139.c