I'm using Isaku Yamahata's q35 chipset model in Qemu0.14 and I'm trying to
figure out why the Qemu dhcpd server is not responding back to the nic device
in the guest OS when used with user mode networking.
The guest OS sees the network device and initialises it but I think the Qemu
DHCP server/firewall never gets back, since the network device doesn't even get
a 10.0.2.15 ip address during bootup and the guest dhcp client never gets an ip
address,
eth0 device: Intel Corporation 82540EM Gigabit Ethernet Controller (rev 03)
eth0 Starting DHCP4 client. . . . . . . .
eth0 DHCP4 continues in background
eth0 device: Intel Corporation 82540EM Gigabit Ethernet Controller (rev 03)
eth0 DHCP4 client (dhcpcd) is running
eth0 . . . but is still waiting for data
eth0 interface could not be set up until now
So doing an ifconfig later on just shows
eth0 Link encap:Ethernet HWaddr 52:54:00:12:34:56
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
lo Link encap:Local loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNING MTU:16436 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
The NIC device is an Intel e1000 however, even if I use a pci ne2k, I get the
same result. I've enabled debugging in the hw/e1000.c and in comparing the good
debug output with the bad debug output, I noticed the point of deviation. The
two traces are identical up till that point. Given that the problem is not the
e1000 model itself, I doubt these traces are anything but symptomatic of the
underlying problem in the Qemu portion that handles network traffic.
Any ideas on what I can check next to see where the underlying problem might be?
-AK
This is a trace of the e1000.c debug messages from boot up for the good case on
the left (where networking works) and the bad case on the right (where it
doesn't).
Good - Debug out Bad -
Debug out
================
===============
e1000: e1000_ioport_map addr=0xc040 size=0x00000040
e1000: e1000_ioport_map addr=0xc040 size=0x00000040
e1000: RCTL: 0, mac_reg[RCTL] = 0x0
e1000: tx disabled
e1000: RCTL: 0, mac_reg[RCTL] = 0x0
e1000: tx disabled
e1000: MMIO unknown write addr=0x00005800,val=0x00000000
e1000: tx disabled
e1000: MMIO unknown write addr=0x00000030,val=0x00008808
e1000: MMIO unknown write addr=0x0000002c,val=0x00000100
e1000: MMIO unknown write addr=0x00000028,val=0x00c28001
e1000: MMIO unknown write addr=0x00000170,val=0x00000680
e1000: MMIO unknown write addr=0x00002160,val=0x00000000
e1000: MMIO unknown write addr=0x00002168,val=0x00000000
e1000: MMIO unknown read addr=0x00004014
e1000: MMIO unknown read addr=0x00004018
e1000: MMIO unknown read addr=0x0000401c
e1000: MMIO unknown read addr=0x00004020
:
e1000: MMIO unknown read addr=0x000040b4
e1000: MMIO unknown read addr=0x000040b8
e1000: MMIO unknown read addr=0x000040bc
e1000: MMIO unknown write addr=0x00000458,val=0x00000000
e1000: RCTL: 0, mac_reg[RCTL] = 0x40000
e1000: tx disabled
e1000: MMIO unknown write addr=0x00000410,val=0x00602008
e1000: MMIO unknown write addr=0x00003820,val=0x00000008
e1000: MMIO unknown write addr=0x0000382c,val=0x00000020
e1000: tx disabled
e1000: tx disabled
e1000: RCTL: 0, mac_reg[RCTL] = 0x48002
e1000: RCTL: 0, mac_reg[RCTL] = 0x48000
e1000: MMIO unknown write addr=0x00002820,val=0x00000000
e1000: MMIO unknown write addr=0x0000282c,val=0x00000008
e1000: MMIO unknown write addr=0x000000c4,val=0x000000c3
e1000: MMIO unknown read addr=0x00005000
e1000: MMIO unknown write addr=0x00005000,val=0x00000200
e1000: RCTL: 0, mac_reg[RCTL] = 0x48002 e1000: RCTL: 0, mac_reg[RCTL] =
0x48002
e1000: MMIO unknown write addr=0x000000c4,val=0x000003d0 e1000: RCTL: 254,
mac_reg[RCTL] = 0x48002 <= Point at which 1st difference appears
e1000: RCTL: 254, mac_reg[RCTL] = 0x48002 e1000: RCTL: 254, mac_reg[RCTL] =
0x48002
e1000: tx disabled e1000: RCTL: 254, mac_reg[RCTL] = 0x48002
e1000: MMIO unknown read addr=0x00004088 e1000: RCTL: 254, mac_reg[RCTL] =
0x48002
e1000: MMIO unknown read addr=0x0000408c e1000: RCTL: 254, mac_reg[RCTL] =
0x48002
e1000: MMIO unknown read addr=0x00004078 e1000: RCTL: 254, mac_reg[RCTL] =
0x48002
e1000: MMIO unknown read addr=0x0000407c e1000: RCTL: 254, mac_reg[RCTL] =
0x48002
e1000: MMIO unknown read addr=0x000040ac e1000: RCTL: 254, mac_reg[RCTL] =
0x0
e1000: MMIO unknown read addr=0x0000405c e1000: tx disabled
e1000: MMIO unknown read addr=0x00004060 e1000: MMIO unknown write
addr=0x00005800,val=0x00000000
e1000: MMIO unknown read addr=0x00004064 e1000: tx disabled
e1000: MMIO unknown read addr=0x00004068 e1000: MMIO unknown write
addr=0x00000030,val=0x00008808
e1000:
MMIO unknown write addr=0x0000002c,val=0x00000100
e1000:
MMIO unknown write addr=0x00000028,val=0x00c28001
e1000:
MMIO unknown write addr=0x00000170,val=0x00000680
e1000:
MMIO unknown write addr=0x00002160,val=0x00000000