Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion driver/ch9344.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,12 @@
#include <linux/timer.h>
#include <linux/kfifo.h>
#include <asm/byteorder.h>
#include <asm/unaligned.h>

#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 12, 0)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Recommend using >= to match with the style of the rest of the file. But other than that, LGTM.

#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 12, 0))
...

#include <asm/unaligned.h> // For kernels before 6.12
#else
#include <linux/unaligned.h> // For kernels 6.12 and above
#endif

#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 11, 0))
#include <linux/sched/signal.h>
Expand Down