net/cadence_gem: Don't assert against 0 buffer address
This has no real hardware analog and asserting correctness of DMA addresses is not a perhiperal level problem. Delete. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Message-id: fc02417eb1874cb05e4f20531c6203c5a00110f1.1386136219.git.peter.crosthwaite@xilinx.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
This commit is contained in:
parent
3b2c97f991
commit
11785f5352
|
@ -688,15 +688,6 @@ static ssize_t gem_receive(NetClientState *nc, const uint8_t *buf, size_t size)
|
||||||
DB_PRINT("copy %d bytes to 0x%x\n", MIN(bytes_to_copy, rxbufsize),
|
DB_PRINT("copy %d bytes to 0x%x\n", MIN(bytes_to_copy, rxbufsize),
|
||||||
rx_desc_get_buffer(desc));
|
rx_desc_get_buffer(desc));
|
||||||
|
|
||||||
/*
|
|
||||||
* Let's have QEMU lend a helping hand.
|
|
||||||
*/
|
|
||||||
if (rx_desc_get_buffer(desc) == 0) {
|
|
||||||
DB_PRINT("Invalid RX buffer (NULL) for descriptor 0x%x\n",
|
|
||||||
(unsigned)packet_desc_addr);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Copy packet data to emulated DMA buffer */
|
/* Copy packet data to emulated DMA buffer */
|
||||||
cpu_physical_memory_write(rx_desc_get_buffer(desc) + rxbuf_offset,
|
cpu_physical_memory_write(rx_desc_get_buffer(desc) + rxbuf_offset,
|
||||||
rxbuf_ptr, MIN(bytes_to_copy, rxbufsize));
|
rxbuf_ptr, MIN(bytes_to_copy, rxbufsize));
|
||||||
|
|
Loading…
Reference in New Issue