13 Jan, 2012

1 commit


12 Jan, 2012

1 commit

  • * git://git.infradead.org/battery-2.6: (68 commits)
    power_supply: Mark da9052 driver as broken
    power_supply: Drop usage of nowarn variant of sysfs_create_link()
    s3c_adc_battery: Average over more than one adc sample
    power_supply: Add DA9052 battery driver
    isp1704_charger: Fix missing check
    jz4740-battery: Fix signedness bug
    power_supply: Assume mains power by default
    sbs-battery: Fix devicetree match table
    ARM: rx51: Add bq27200 i2c board info
    sbs-battery: Change power supply name
    devicetree-bindings: Propagate bq20z75->sbs rename to dt bindings
    devicetree-bindings: Add vendor entry for Smart Battery Systems
    sbs-battery: Rename internals to new name
    bq20z75: Rename to sbs-battery
    wm97xx_battery: Use DEFINE_MUTEX() for work_lock
    max8997_charger: Remove duplicate module.h
    lp8727_charger: Some minor fixes for the header
    lp8727_charger: Add header file
    power_supply: Convert drivers/power/* to use module_platform_driver()
    power_supply: Add "unknown" in power supply type
    ...

    Linus Torvalds
     

11 Jan, 2012

1 commit


10 Jan, 2012

1 commit

  • There are some problems with MFD part of this driver, so the
    driver fails to build:

    drivers/power/da9052-battery.c: In function 'da9052_bat_read_volt':
    drivers/power/da9052-battery.c:293:2: error: implicit declaration of function 'da9052_adc_manual_read' [-Werror=implicit-function-declaration]
    drivers/power/da9052-battery.c: In function 'da9052_bat_check_presence':
    drivers/power/da9052-battery.c:306:2: error: implicit declaration of function 'da9052_adc_read_temp' [-Werror=implicit-function-declaration]
    drivers/power/da9052-battery.c: In function 'da9052_determine_vc_tbl_index':
    drivers/power/da9052-battery.c:348:1: warning: control reaches end of non-void function [-Wreturn-type]
    cc1: some warnings being treated as errors

    The fix for MFD part will probably go post -rc1 (or in the next merge
    window), so let's disable the driver for now.

    Reported-by: Stephen Rothwell
    Signed-off-by: Anton Vorontsov

    Anton Vorontsov
     

07 Jan, 2012

1 commit

  • The function is not exported to modules, plus we do want to catch anyone
    who tries to create complex hierarchy (in that case we'd need to change
    'powers' symlink to a directory, probably under a different name to not
    break ABI).

    This patch fixes the following build error:

    ERROR: "sysfs_create_link_nowarn" [drivers/power/power_supply.ko] undefined!

    Reported-by: Stephen Rothwell
    Signed-off-by: Anton Vorontsov

    Anton Vorontsov
     

06 Jan, 2012

11 commits

  • Some sources for adc battery information provide only inaccurate results
    where the read value differs from the real value with positive and negative
    offsets. For such sources it can be more accurate to collect two or more
    value sample and use the average of all collected values.

    This patch adds pdata options volt_samples, current_samples and
    backup_volt_samples to specifiy the number of samples to collect,
    reads the specified number of samples and calculates the average of those.
    For unset sample-number-values a default of 1 is assumed.

    Signed-off-by: Heiko Stuebner
    Signed-off-by: Anton Vorontsov

    Heiko Stübner
     
  • Driver for DA9052 battery charger. This driver depends on DA9052 MFD core
    dirver for definitions and methods.

    This patch is functionally tested on Samsung SMDKV6410.

    Signed-off-by: David Dajun Chen
    Signed-off-by: Ashish Jangam
    Signed-off-by: Anton Vorontsov

    Ashish Jangam
     
  • A segfault happens if there's no board information.

    Signed-off-by: Felipe Contreras
    Acked-by: Heikki Krogerus
    Signed-off-by: Anton Vorontsov

    Felipe Contreras
     
  • wait_for_completion_interruptible_timeout() may return negative value.
    In this case, checking if (t > 0) will return true if t is unsigned.

    Signed-off-by: Axel Lin
    Acked-by: Lars-Peter Clausen
    Signed-off-by: Anton Vorontsov

    Axel Lin
     
  • 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
    Cc: David Woodhouse
    Cc: Matthew Garrett
    Cc: Alex Deucher
    Signed-off-by: Anton Vorontsov

    Jean Delvare
     
  • It should be an of module table, not i2c.

    Signed-off-by: Olof Johansson
    Acked-by: Rhyland Klein
    Signed-off-by: Anton Vorontsov

    Olof Johansson
     
  • The power supply name used to be fixed as "battery". This change allows
    for multiple batteries by generating the name rather than using a fixed
    value.

    Signed-off-by: Rhyland Klein
    Signed-off-by: Anton Vorontsov

    Rhyland Klein
     
  • Now that this driver is named more generally, this change updates
    the internal variables, defines and functions to use this new name.

    Signed-off-by: Rhyland Klein
    Signed-off-by: Anton Vorontsov

    Rhyland Klein
     
  • This driver for the bq20z75 implemented the register spec defined
    by the SBS standard. As this is not unique to this the TI part this
    was originally written for, we can generalize this driver to
    show its support for any SBS compliant battery.

    Signed-off-by: Rhyland Klein
    Signed-off-by: Anton Vorontsov

    Rhyland Klein
     
  • work_lock can be initialized automatically with
    DEFINE_MUTEX() rather than explicitly calling mutex_init().

    This patch also removes an unused bat_lock mutex.

    Signed-off-by: Axel Lin
    Signed-off-by: Anton Vorontsov

    Axel Lin
     
  • module.h was included twice.

    Signed-off-by: Jonghwan Choi
    Acked-by: MyungJoo Ham
    Signed-off-by: Anton Vorontsov

    Jonghwan Choi
     

04 Jan, 2012

9 commits


10 Dec, 2011

2 commits

  • If a power supply has a scope of "Device", then allow the power supply
    to indicate what device it actually powers. This is represented in the
    power supply's sysfs directory as a symlink named "powers", which points to
    the sysfs directory of the powered device.

    If the device has children, then the sub-devices are also powered by
    the same power supply.

    Signed-off-by: Jeremy Fitzhardinge
    Cc: Richard Hughes

    Jeremy Fitzhardinge
     
  • This adds a "scope" attribute to a power_supply, which indicates how
    much of the system it powers. It appears in sysfs as "scope" or in
    the uevent file as POWER_SUPPLY_SCOPE=. There are presently three
    possible values:
    Unknown - unknown power topology
    System - the power supply powers the whole system
    Device - it powers a specific device, or tree of devices

    A power supply which doesn't have a "scope" attribute should be assumed to
    have "System" scope.

    In general, usermode should assume that loss of all System-scoped power
    supplies will power off the whole system, but any single one is sufficient
    to power the system.

    Signed-off-by: Jeremy Fitzhardinge
    Cc: Richard Hughes

    Jeremy Fitzhardinge
     

06 Dec, 2011

1 commit

  • When DCDC input line over current detecting, PMIC will change
    charging current automatically. Logging event is enough.

    Signed-off-by: Major Lee
    Signed-off-by: Alan Cox
    Cc: Mathias Nyman
    Cc: Feng Tang
    Cc: "H. Peter Anvin"
    [fix build]
    Signed-off-by: Andrew Morton
    Signed-off-by: Ingo Molnar

    Major Lee
     

26 Nov, 2011

12 commits