Skip to content

Commit d87e2dc

Browse files
committed
Add struct virtio_net_dev Entry in struct vm_t
This commit adds a struct `virtio_net_dev` entry within the struct `vm_t` structure to facilitate the implementation of the virtio-net device. This addition is necessary to integrate and manage the virtio-net device within the broader context of the virtual machine.
1 parent 79d0a3e commit d87e2dc

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/vm.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
#include "pci.h"
66
#include "serial.h"
77
#include "virtio-blk.h"
8+
#include "virtio-net.h"
89

910
typedef struct {
1011
int kvm_fd, vm_fd, vcpu_fd;
@@ -15,6 +16,7 @@ typedef struct {
1516
struct pci pci;
1617
struct diskimg diskimg;
1718
struct virtio_blk_dev virtio_blk_dev;
19+
struct virtio_net_dev virtio_net_dev;
1820
void *priv;
1921
} vm_t;
2022

0 commit comments

Comments
 (0)