Skip to contentSkip to conversation

qemu pcnet emulation problems.

DISCUSSION Don Fry 3 participants 3 messages Mar 22, 2006

lore
Share & tools
lore

Don Fry

author
#0 lore raw

There are/may be several other bugs with the qemu pcnet emulation. I do not know if there is any other serialization outside of this code, but if both a transmit and a receive operation were to be performed at the same time on different cpus, since the same buffer is used for both transmit and receive, that would also cause data corruption.

Does anyone else know how this is prevented, or is this another source of corruption?

Another thing I noticed, that will reduce throughput if corrected, is that the wrong bit is being examined in the receive path, to determine if mac level crc should be computed. Right now, the wrong bit is being checked and no mac level crc is being calculated. If the right bit were looked at, mac level crc would need to be computed, slowing down the transfers. However, since no driver cares about the crc right now, since neither Linux or XP complain, could the code to compute the crc be deleted? Maybe just comment that the crc should be computed.

Any recommendations?

Signature · 2 lines
Don Fry
[email protected]
#1 lore raw
Quoted 1 line · Don Fry

There are/may be several other bugs with the qemu pcnet emulation. I do

Not sure if Don mentioned this earlier, but for the benefit of those who might need the context, please see Xen Bugzilla #574/#575.

Quoted 17 lines

not know if there is any other serialization outside of this code, but if both a transmit and a receive operation were to be performed at the same time on different cpus, since the same buffer is used for both transmit and receive, that would also cause data corruption.

Does anyone else know how this is prevented, or is this another source of corruption?

Another thing I noticed, that will reduce throughput if corrected, is that the wrong bit is being examined in the receive path, to determine if mac level crc should be computed. Right now, the wrong bit is being checked and no mac level crc is being calculated. If the right bit were looked at, mac level crc would need to be computed, slowing down the transfers. However, since no driver cares about the crc right now, since neither Linux or XP complain, could the code to compute the crc be deleted? Maybe just comment that the crc should be computed.

Quoted 1 line

Any recommendations?

I'd really like to continue to avoid the CRC computation between domains, but intentionally, this time, in a clean way :).

thanks,
Nivedita

#2 lore raw
Quoted 10 lines · Nivedita Singhvi
Quoted 9 lines

Another thing I noticed, that will reduce throughput if corrected, is that the wrong bit is being examined in the receive path, to determine if mac level crc should be computed. Right now, the wrong bit is being checked and no mac level crc is being calculated. If the right bit were looked at, mac level crc would need to be computed, slowing down the transfers. However, since no driver cares about the crc right now, since neither Linux or XP complain, could the code to compute the crc be deleted? Maybe just comment that the crc should be computed. Any recommendations?

Quoted 2 lines

I'd really like to continue to avoid the CRC computation between domains, but intentionally, this time, in a clean way :).

The code should be deleted as the underlying physical transport (e.g., shared memory, physical Ethernet) will ensure link-layer integrity.

-- Keir