nixpkgs/pkgs/os-specific/linux/nvidiabl/linux4compat.patch
William A. Kennington III 6602f49495 Revert "Revert "Merge pull request #9543 from NixOS/staging.post-15.06""
This reverts commit 741bf840dad05cd1728481045466811ae8ae8281.

This reverts the fallout from reverting the major changes.
2015-11-14 12:32:51 -08:00

23 lines
878 B
Diff

From 2bf6f08b2492cc04a2c39fdcb22a2d0c18963d1c Mon Sep 17 00:00:00 2001
From: sonic414 <sonic414@gmail.com>
Date: Tue, 28 Apr 2015 19:30:15 +0530
Subject: [PATCH] strnicmp to strncasecmp in Linux 4.0.0
---
nvidiabl-module.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/nvidiabl-module.c b/nvidiabl-module.c
index b789ea4..b306579 100644
--- a/nvidiabl-module.c
+++ b/nvidiabl-module.c
@@ -214,7 +214,7 @@ static int __init nvidiabl_init(void)
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,39)
for (iii = 0 ; iii < sizeof(backlight_type_ids) ; iii++) {
- if (strnicmp(bl_type, backlight_type_ids[iii].id, sizeof(bl_type)) == 0) {
+ if (strncasecmp(bl_type, backlight_type_ids[iii].id, sizeof(bl_type)) == 0) {
props.type = backlight_type_ids[iii].type;
printk(KERN_INFO "nvidiabl: backlight type is %s\n", backlight_type_ids[iii].id);
}