]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ACPI / APEI: fix error return code in einj_init()
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>
Wed, 5 Jun 2013 02:17:35 +0000 (02:17 +0000)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 5 Jun 2013 10:49:40 +0000 (12:49 +0200)
Fix to return -ENOMEM in the debugfs_create_xxx() error handling
case instead of 0, as done elsewhere in this function.

Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
Reviewed-by: Chen Gong <gong.chen@linux.intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/apei/einj.c

index 9a47d85dc9ac7e5864c1b753005c27091fa779d9..9d60bdd1b6f57cdc9181a24251dfb23d6ef0bb64 100644 (file)
@@ -732,6 +732,7 @@ static int __init einj_init(void)
        if (rc)
                goto err_release;
 
+       rc = -ENOMEM;
        einj_param = einj_get_parameter_address();
        if ((param_extension || acpi5) && einj_param) {
                fentry = debugfs_create_x64("param1", S_IRUSR | S_IWUSR,