From 0747e94f897657bc4529e7601b803f441c3ed108 Mon Sep 17 00:00:00 2001 From: Christoffer Sandberg Date: Mon, 4 Oct 2021 14:55:48 +0200 Subject: [PATCH] tuxedo_io: Update id check data for uw on ioctl id check request Should fix failing to identify uniwill device if tuxedo_io module loaded before interface registration. --- src/tuxedo_io/tuxedo_io.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/tuxedo_io/tuxedo_io.c b/src/tuxedo_io/tuxedo_io.c index 80c968d..685f873 100644 --- a/src/tuxedo_io/tuxedo_io.c +++ b/src/tuxedo_io/tuxedo_io.c @@ -346,6 +346,7 @@ static long fop_ioctl(struct file *file, unsigned int cmd, unsigned long arg) copy_result = copy_to_user((void *) arg, (void *) &id_check_clevo, sizeof(id_check_clevo)); break; case R_HWCHECK_UW: + id_check_uniwill = uniwill_identify(); copy_result = copy_to_user((void *) arg, (void *) &id_check_uniwill, sizeof(id_check_uniwill)); break; } @@ -380,7 +381,7 @@ static int __init tuxedo_io_init(void) #ifdef DEBUG if (id_check_clevo == 0 && id_check_uniwill == 0) { - pr_debug("No matching hardware found\n"); + pr_debug("No matching hardware found on module load\n"); } #endif