mirror of
https://github.com/intrepidcs/intrepid-socketcan-kernel-module.git
synced 2026-08-05 01:18:37 +02:00
Fix for newer 6.5 Kernel, class_create() sig changed
This commit is contained in:
@@ -1156,7 +1156,11 @@ static __init int intrepid_init(void)
|
|||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if LINUX_VERSION_CODE < KERNEL_VERSION(6, 4, 0)
|
||||||
intrepid_dev_class = class_create(THIS_MODULE, INTREPID_CLASS_NAME);
|
intrepid_dev_class = class_create(THIS_MODULE, INTREPID_CLASS_NAME);
|
||||||
|
#else
|
||||||
|
intrepid_dev_class = class_create(INTREPID_CLASS_NAME);
|
||||||
|
#endif
|
||||||
if (IS_ERR(intrepid_dev_class)) {
|
if (IS_ERR(intrepid_dev_class)) {
|
||||||
ret = PTR_ERR(intrepid_dev_class);
|
ret = PTR_ERR(intrepid_dev_class);
|
||||||
pr_alert("intrepid: failed to create device class, got %d\n", ret);
|
pr_alert("intrepid: failed to create device class, got %d\n", ret);
|
||||||
|
|||||||
Reference in New Issue
Block a user