From mboxrd@z Thu Jan 1 00:00:00 1970 From: =?UTF-8?q?Thomas=20Wei=C3=9Fschuh?= Subject: [PATCH v2 3/3] platform/x86: thinkpad_acpi: restore old battery charge attributes Date: Fri, 31 Jan 2020 15:36:50 +0100 Message-ID: <20200131143650.4149-4-linux@weissschuh.net> References: <20200131143650.4149-1-linux@weissschuh.net> <20200131143650.4149-2-linux@weissschuh.net> <20200131143650.4149-3-linux@weissschuh.net> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Return-path: In-Reply-To: <20200131143650.4149-3-linux@weissschuh.net> Sender: linux-kernel-owner@vger.kernel.org To: Henrique de Moraes Holschuh , Darren Hart , Andy Shevchenko Cc: ibm-acpi-devel@lists.sourceforge.net, platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org, =?UTF-8?q?Thomas=20Wei=C3=9Fschuh?= List-Id: platform-driver-x86.vger.kernel.org Alias the new standard attributes to their previous names, preserving backwards compatibility. Signed-off-by: Thomas Weißschuh --- drivers/platform/x86/thinkpad_acpi.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/drivers/platform/x86/thinkpad_acpi.c b/drivers/platform/x86/thinkpad_acpi.c index 5f0e3299778a..2cbcd2e3092f 100644 --- a/drivers/platform/x86/thinkpad_acpi.c +++ b/drivers/platform/x86/thinkpad_acpi.c @@ -9638,10 +9638,24 @@ static ssize_t charge_control_end_threshold_store(struct device *dev, static DEVICE_ATTR_RW(charge_control_start_threshold); static DEVICE_ATTR_RW(charge_control_end_threshold); +struct device_attribute dev_attr_charge_start_threshold = __ATTR( + charge_start_threshold, + 0644, + charge_control_start_threshold_show, + charge_control_start_threshold_store +); +struct device_attribute dev_attr_charge_stop_threshold = __ATTR( + charge_stop_threshold, + 0644, + charge_control_end_threshold_show, + charge_control_end_threshold_store +); static struct attribute *tpacpi_battery_attrs[] = { &dev_attr_charge_control_start_threshold.attr, &dev_attr_charge_control_end_threshold.attr, + &dev_attr_charge_start_threshold.attr, + &dev_attr_charge_stop_threshold.attr, NULL, }; -- 2.25.0