qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Re: [kvm-devel] [ kvm-Bugs-1802223 ] nics have same hw addr


From: Laurent Vivier
Subject: [Qemu-devel] Re: [kvm-devel] [ kvm-Bugs-1802223 ] nics have same hw address (rtl8139)
Date: Wed, 26 Sep 2007 17:47:20 +0200
User-agent: Thunderbird 1.5.0.2 (X11/20060420)

Hi,

I think there is a bug in qemu RTL8139.

RTL8139 uses:

cpu_register_physical_memory(addr + 0, 0x100, s->rtl8139_mmio_io_addr);

But in the comment of cpu_register_physical_memory() we have:

"'size' must be a multiple of the target page size."

And I think 0x100 is not a multiple of target page size.... :-P

The attached patch corrects the problem.

Laurent

SourceForge.net wrote:
> Bugs item #1802223, was opened at 2007-09-25 22:59
> Message generated for change (Tracker Item Submitted) made by Item Submitter
> You can respond by visiting: 
> https://sourceforge.net/tracker/?func=detail&atid=893831&aid=1802223&group_id=180599
> 
> Please note that this message will contain a full copy of the comment thread,
> including the initial issue submission, for this request,
> not just the latest update.
> Category: None
> Group: None
> Status: Open
> Resolution: None
> Priority: 5
> Private: No
> Submitted By: xeb (xebd)
> Assigned to: Nobody/Anonymous (nobody)
> Summary: nics have same hw address (rtl8139)
> 
> Initial Comment:
> Hello!
> 
> Host:Linux 2.6.22-gentoo-r2 #2 SMP Fri Aug 3 07:01:46 MSD 2007 x86_64 AMD 
> Athlon(tm) 64 X2 Dual Core Processor 5600+ AuthenticAMD GNU/Linux,Gentoo, 
> kvm-44
> 
> Guest:Linux 2.6.22-hardened-r4
> 
> command line:
> qemu-system-x86_64 -hda server_base_x86.img -hdc server_swap.img -localtime 
> -m 128 \
>     -net nic,vlan=0,macaddr=52:54:00:12:34:56,model=rtl8139 -net 
> tap,vlan=0,ifname=tap3,script=no \
>     -net nic,vlan=1,macaddr=52:54:00:12:34:57,model=rtl8139 -net 
> tap,vlan=1,ifname=tap4,script=no \
>     -net nic,vlan=2,macaddr=52:54:00:12:34:58,model=rtl8139 -net 
> tap,vlan=2,ifname=tap5,script=no \
>     -nographic
> 
> ifconfig on guest:
> eth0      Link encap:Ethernet  HWaddr 52:54:00:12:34:58
>           UP BROADCAST RUNNING 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)
>           Interrupt:11 Base address:0x4000
> 
> eth1      Link encap:Ethernet  HWaddr 52:54:00:12:34:58
>           inet addr:192.168.11.1  Bcast:192.168.11.255  Mask:255.255.255.0
>           UP BROADCAST RUNNING 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)
>           Interrupt:9 Base address:0x6100
> 
> eth2      Link encap:Ethernet  HWaddr 52:54:00:12:34:58
>           inet addr:192.168.13.1  Bcast:192.168.13.255  Mask:255.255.255.0
>           UP BROADCAST RUNNING 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)
>           Interrupt:11 Base address:0x8200
> 
> As can you see they have same hwaddr.
> With model=ne2k_pci nics have correct hw addresses 

Laurent
-- 
------------- address@hidden  --------------
          "Software is hard" - Donald Knuth

Attachment: rtl8139.patch
Description: application/mbox

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]