Skip to content

Commit

Permalink
Compiles and works for Workstation 17.5.2 and Mainline kernel 6.9.1. …
Browse files Browse the repository at this point in the history
  • Loading branch information
nan0desu committed May 18, 2024
1 parent 2c6d66f commit 48866f7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion vmmon-only/include/x86msr.h
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ typedef struct MSRReply {
typedef struct MSRQuery {
uint32 msrNum; // IN
uint32 numLogicalCPUs; // IN/OUT
MSRReply logicalCPUs[0]; // OUT
MSRReply logicalCPUs[]; // OUT
} MSRQuery;
#pragma pack(pop)

Expand Down
9 changes: 7 additions & 2 deletions vmnet-only/vmnetInt.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,13 @@
compat_skb_set_network_header(skb, sizeof (struct ethhdr)), \
dev_queue_xmit(skb) \
)
#define dev_lock_list() read_lock(&dev_base_lock)
#define dev_unlock_list() read_unlock(&dev_base_lock)
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 9, 0)
# define dev_lock_list() rcu_read_lock()
# define dev_unlock_list() rcu_read_unlock()
#else
# define dev_lock_list() read_lock(&dev_base_lock)
# define dev_unlock_list() read_unlock(&dev_base_lock)
#endif


extern struct proto vmnet_proto;
Expand Down

0 comments on commit 48866f7

Please sign in to comment.