From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751853AbdFKFHO (ORCPT ); Sun, 11 Jun 2017 01:07:14 -0400 Received: from mail-pf0-f170.google.com ([209.85.192.170]:32904 "EHLO mail-pf0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751675AbdFKFHM (ORCPT ); Sun, 11 Jun 2017 01:07:12 -0400 Subject: Re: [PATCH] platform/x86: ideapad-laptop: Expose conservation mode switch From: Hao Wei Tee To: Andy Shevchenko Cc: Platform Driver , "linux-kernel@vger.kernel.org" , Andy Shevchenko , Darren Hart , Ike Panhc References: <264a8ced-4336-06b9-d760-babc08ccde5c@angelsl.xyz> <7ba76865-7fb2-615a-8bcd-35e14b862a8e@angelsl.xyz> Message-ID: <47e2af96-1b97-6654-e65c-eea570383abb@angelsl.xyz> Date: Sun, 11 Jun 2017 13:07:07 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:54.0) Gecko/20100101 Thunderbird/54.0 MIME-Version: 1.0 In-Reply-To: <7ba76865-7fb2-615a-8bcd-35e14b862a8e@angelsl.xyz> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/30/17 10:05 PM, Hao Wei Tee wrote: > On 5/30/17 9:22 PM, Andy Shevchenko wrote: >> On Sun, May 28, 2017 at 4:47 PM, Hao Wei Tee wrote: >>> On 5/27/17 3:31 PM, Hao Wei Tee wrote: >>>> This exposes the battery conservation mode present on some (?) IdeaPads. >>>> The mode is set by calling ACPI method SBMC with argument 3 (on) or >>>> 5 (off). Status is reported in bit 5 of the return value of ACPI method >>>> GBMD. >>>> >>>> This patch was written based on an IdeaPad U430p. I'm not sure if the ACPI >>>> methods are the same across all IdeaPads, so it would be great if this got more >>>> testing across other models before it's merged. >>> >>> I got someone to test on an IdeaPad Y510p. It works on that too. >> >> Do we have any other option that expose something via sysfs? >> > > Sorry, not sure what you meant. > > If you meant > >> Do we have any other options than expose something via sysfs? > > I'm not sure, maybe an ioctl? That wouldn't be very convenient though. > > The tp_smapi module (not in mainline) that exposes the battery threshold > functionality for ThinkPads also uses sysfs. > > If you meant > >> Do we have any other options that expose something via sysfs? > > yes, camera_power, fan_mode, touchpad and conservation_mode. Any thoughts on this? -- Hao Wei