about summary refs log tree commit diff
path: root/nixpkgs/pkgs/os-specific/linux/ch9344/fix-incompatible-pointer-types.patch
blob: 89c95347ed654184352ef3f870fda7f9ea3b4f37 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
diff --git a/ch9344.c b/ch9344.c
index bfa10bb..76a94a7 100644
--- a/ch9344.c
+++ b/ch9344.c
@@ -837,7 +837,11 @@ static void ch9344_tty_close(struct tty_struct *tty, struct file *filp)
 	}
 }
 
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6, 6, 0))
+static ssize_t ch9344_tty_write(struct tty_struct *tty, const u8 *buf, size_t count)
+#else
 static int ch9344_tty_write(struct tty_struct *tty, const unsigned char *buf, int count)
+#endif
 {
 	struct ch9344 *ch9344 = tty->driver_data;
 	int stat;