aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/platform/x86/intel-rst.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/platform/x86/intel-rst.c')
-rw-r--r--drivers/platform/x86/intel-rst.c23
1 files changed, 2 insertions, 21 deletions
diff --git a/drivers/platform/x86/intel-rst.c b/drivers/platform/x86/intel-rst.c
index 7344d841f4d9..3b81cb896fed 100644
--- a/drivers/platform/x86/intel-rst.c
+++ b/drivers/platform/x86/intel-rst.c
@@ -1,26 +1,11 @@
1// SPDX-License-Identifier: GPL-2.0+
1/* 2/*
2 * Copyright 2013 Matthew Garrett <mjg59@srcf.ucam.org> 3 * Copyright 2013 Matthew Garrett <mjg59@srcf.ucam.org>
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License along
15 * with this program; if not, write to the Free Software Foundation, Inc.,
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
17 */ 4 */
18 5
19 6#include <linux/acpi.h>
20#include <linux/init.h>
21#include <linux/module.h> 7#include <linux/module.h>
22#include <linux/slab.h> 8#include <linux/slab.h>
23#include <linux/acpi.h>
24 9
25MODULE_LICENSE("GPL"); 10MODULE_LICENSE("GPL");
26 11
@@ -53,12 +38,10 @@ static ssize_t irst_store_wakeup_events(struct device *dev,
53 acpi = to_acpi_device(dev); 38 acpi = to_acpi_device(dev);
54 39
55 error = kstrtoul(buf, 0, &value); 40 error = kstrtoul(buf, 0, &value);
56
57 if (error) 41 if (error)
58 return error; 42 return error;
59 43
60 status = acpi_execute_simple_method(acpi->handle, "SFFS", value); 44 status = acpi_execute_simple_method(acpi->handle, "SFFS", value);
61
62 if (ACPI_FAILURE(status)) 45 if (ACPI_FAILURE(status))
63 return -EINVAL; 46 return -EINVAL;
64 47
@@ -99,12 +82,10 @@ static ssize_t irst_store_wakeup_time(struct device *dev,
99 acpi = to_acpi_device(dev); 82 acpi = to_acpi_device(dev);
100 83
101 error = kstrtoul(buf, 0, &value); 84 error = kstrtoul(buf, 0, &value);
102
103 if (error) 85 if (error)
104 return error; 86 return error;
105 87
106 status = acpi_execute_simple_method(acpi->handle, "SFTV", value); 88 status = acpi_execute_simple_method(acpi->handle, "SFTV", value);
107
108 if (ACPI_FAILURE(status)) 89 if (ACPI_FAILURE(status))
109 return -EINVAL; 90 return -EINVAL;
110 91