Merge pull request #231303 from MakiseKurisu/ch9344_failure

ch9344: fix build on Linux 6.3
This commit is contained in:
Ryan Lahfa 2023-05-11 20:09:45 +02:00 committed by GitHub
commit 9a142a6244
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 16 additions and 0 deletions

View file

@ -13,6 +13,9 @@ stdenv.mkDerivation rec {
patches = lib.optionals (lib.versionAtLeast kernel.modDirVersion "6.1") [
# https://github.com/torvalds/linux/commit/a8c11c1520347be74b02312d10ef686b01b525f1
./fix-incompatible-pointer-types.patch
] ++ lib.optionals (lib.versionAtLeast kernel.modDirVersion "6.3") [
# https://github.com/torvalds/linux/commit/5d420399073770134d2b03e004b2c0201c7fa26f
./fix-incompatible-pointer-types_6_3.patch
];
sourceRoot = "${src.name}/driver";

View file

@ -0,0 +1,13 @@
diff --git a/ch9344.c b/ch9344.c
index a16af82..8922ed9 100644
--- a/ch9344.c
+++ b/ch9344.c
@@ -774,7 +774,7 @@ static inline void *tty_get_portdata(struct ch9344_ttyport *port)
return (port->portdata);
}
-static void ch9344_port_dtr_rts(struct tty_port *port, int raise)
+static void ch9344_port_dtr_rts(struct tty_port *port, bool raise)
{
struct ch9344_ttyport *ttyport = container_of(port, struct ch9344_ttyport, port);
struct ch9344 *ch9344 = tty_get_portdata(ttyport);