[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH] enable network without dhcp
From: |
higepon |
Subject: |
[Qemu-devel] [PATCH] enable network without dhcp |
Date: |
Mon, 25 Jun 2007 00:04:43 +0900 |
Hi folks,
I added a default mac address for a Guest OS which can't send a DHCP request.
Without this patch, client_ethaddr at slirp.c variable is
00:00:00:00:00:00, so an ether header dest address is also zero.
Tested withc gcc 3.3.6 (Ubuntu 1:3.3.6-13ubuntu2).
2007-06-24 higepon <address@hidden>
* slirp.c (slirp_init): Added a default mac address for a
Guest OS which can't send a DHCP request.
--- qemu-0.9.0/slirp/slirp.c.orig 2007-06-24 23:36:01.000000000 +0900
+++ qemu-0.9.0/slirp/slirp.c 2007-06-24 23:36:41.000000000 +0900
@@ -149,6 +149,12 @@
/* set default addresses */
inet_aton("127.0.0.1", &loopback_addr);
+ client_ethaddr[0] = 0x52;
+ client_ethaddr[1] = 0x54;
+ client_ethaddr[2] = 0x00;
+ client_ethaddr[3] = 0x12;
+ client_ethaddr[4] = 0x34;
+ client_ethaddr[5] = 0x56;
if (get_dns_addr(&dns_addr) < 0) {
dns_addr = loopback_addr;
--
higepon : http://www.monaos.org
qemu-0.9.0-slirp-macaddr-20070624.diff
Description: Text Data
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Qemu-devel] [PATCH] enable network without dhcp,
higepon <=