浏览代码

asus-laptop: Fix is_visible return value

With a Lucid platform, asus_sysfs_is_visible() returned a boolean for
ls_switch and ls_level attributes.

Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Vivien Didelot 10 年之前
父节点
当前提交
03070e7c9d
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/platform/x86/asus-laptop.c

+ 1 - 1
drivers/platform/x86/asus-laptop.c

@@ -1616,7 +1616,7 @@ static umode_t asus_sysfs_is_visible(struct kobject *kobj,
 		else
 			goto normal;
 
-		return supported;
+		return supported ? attr->mode : 0;
 	}
 
 normal: