Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Networking #8

Open
easydaniel opened this issue Dec 1, 2018 · 1 comment
Open

Networking #8

easydaniel opened this issue Dec 1, 2018 · 1 comment

Comments

@easydaniel
Copy link

easydaniel commented Dec 1, 2018

I wonder how do we add interfaces or how do we modify biscuit to let it be able to connect to the internet. When I tried the command lnc to connect to my custom host outside QEMU, it has the message saying no route to host. After I dig into the kernel, I noticed that it only has 127.0.0.1 and a magic ip and gateway defined in src/ixgbe/ixgbe.go as follow:

// 18.26.5.49 (bhw)
me := Ip4_t(0x121a0531)
x.ip = me
bnet.Nic_insert(me, x)

netmask := Ip4_t(0xfffffe00)
// 18.26.5.1
gw := Ip4_t(0x121a0401)

I wonder if I am correct that this is the place where biscuit setup its network interface and how the ip and gateway is selected. In addition, how we should configure to make biscuit able to connect to hosts outside QEMU. Also, does biscuit provide ping and ICMP packet processing? Thanks.

@grodranlorth
Copy link
Collaborator

grodranlorth commented Dec 2, 2018

To get networking to work in QEMU, we should only need a driver for hardware that QEMU supports. Then we could add the NIC to the network stack manually like the ixgbe code you already found (or we could implement DHCP support and an interface to configure the network stack).

QEMU can emulate an Intel E1000 NIC and the E1000 NIC is basically a simpler version of the ixgbe NIC. Thus it may not take much work to get Biscuit's ixgbe driver to support QEMU's E1000.

Biscuit does support ICMP pings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants