Skip to content

Commit 7fce59a

Browse files
committed
fix warn: remove redefinition of PAGE_SIZE
1 parent 94db2b3 commit 7fce59a

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

api/virtio/virtio.hpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,13 @@
3434

3535
#include "../hw/pci_device.hpp"
3636
#include <net/inet_common.hpp>
37+
#include <limits.h>
3738
#include <stdint.h>
3839
#include <vector>
3940

40-
#define PAGE_SIZE 4096
41+
#if ! defined(PAGE_SIZE)
42+
#error "PAGE_SIZE not defined. Expected it to be defined by musl's limits.h"
43+
#endif
4144

4245
#define VIRTIO_F_NOTIFY_ON_EMPTY 24
4346
#define VIRTIO_F_ANY_LAYOUT 27

0 commit comments

Comments
 (0)