lkml.org 
[lkml]   [2012]   [Jan]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] power: Assume mains power by default
On Sat, Dec 10, 2011 at 10:53:36PM +0100, Jean Delvare wrote:
> If no power class device is found in power_supply_is_system_supplied(),
> the function currently returns 0, which basically means that the system
> is supposed to be running on battery. In practice, mobile devices tend
> to always implement at least one power class device and more often two
> (battery and AC adapter). Systems with no registered power class
> devices are more likely to be desktop systems, where the system is
> always powered by mains.
>
> So, change the default return value of
> power_supply_is_system_supplied() from 0 (running on battery) to 1
> (running on mains.)
>
> Signed-off-by: Jean Delvare <jdelvare@suse.de>
> Cc: Anton Vorontsov <cbou@mail.ru>
> Cc: David Woodhouse <dwmw2@infradead.org>
> Cc: Matthew Garrett <mjg59@srcf.ucam.org>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> ---

Applied, thanks!

--
Anton Vorontsov
Email: cbouatmailru@gmail.com


\
 
 \ /
  Last update: 2012-01-06 02:55    [W:0.080 / U:0.592 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site