<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/power, branch v3.13.2</title>
<subtitle>Linux kernel source tree</subtitle>
<id>https://git.amat.us/linux/atom/drivers/power?h=v3.13.2</id>
<link rel='self' href='https://git.amat.us/linux/atom/drivers/power?h=v3.13.2'/>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/'/>
<updated>2013-12-01T22:25:03Z</updated>
<entry>
<title>max17042_battery: Fix build errors caused by missing REGMAP_I2C config</title>
<updated>2013-12-01T22:25:03Z</updated>
<author>
<name>Austin Boyle</name>
<email>boyle.austin@gmail.com</email>
</author>
<published>2013-11-24T10:41:49Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=93353e8088057dd988362e6cae727af43734b494'/>
<id>urn:sha1:93353e8088057dd988362e6cae727af43734b494</id>
<content type='text'>
max17042 now uses regmap interface but does not enable config option. This
patch fixes the following build errors:

drivers/power/max17042_battery.c:661:15: error: variable ‘max17042_regmap_config’ has initializer but incomplete type
drivers/power/max17042_battery.c:662:2: error: unknown field ‘reg_bits’ specified in initializer
drivers/power/max17042_battery.c:662:2: warning: excess elements in struct initializer
drivers/power/max17042_battery.c:662:2: warning: (near initialization for ‘max17042_regmap_config’)
drivers/power/max17042_battery.c:663:2: error: unknown field ‘val_bits’ specified in initializer
drivers/power/max17042_battery.c:663:2: warning: excess elements in struct initializer
drivers/power/max17042_battery.c:663:2: warning: (near initialization for ‘max17042_regmap_config’)
drivers/power/max17042_battery.c:664:2: error: unknown field ‘val_format_endian’ specified in initializer
drivers/power/max17042_battery.c:664:23: error: ‘REGMAP_ENDIAN_NATIVE’ undeclared here (not in a function)
drivers/power/max17042_battery.c:664:2: warning: excess elements in struct initializer
drivers/power/max17042_battery.c:664:2: warning: (near initialization for ‘max17042_regmap_config’)
drivers/power/max17042_battery.c: In function ‘max17042_probe’:
drivers/power/max17042_battery.c:684:2: error: implicit declaration of function ‘devm_regmap_init_i2c’

Signed-off-by: Austin Boyle &lt;boyle.austin@gmail.com&gt;
Acked-by: Jonghwa Lee &lt;jonghwa3.lee@samsung.com&gt;
Signed-off-by: Anton Vorontsov &lt;anton@enomsg.org&gt;
</content>
</entry>
<entry>
<title>power_supply: Fix Oops from NULL pointer dereference from wakeup_source_activate</title>
<updated>2013-12-01T21:41:31Z</updated>
<author>
<name>Shuah Khan</name>
<email>shuah.kh@samsung.com</email>
</author>
<published>2013-11-22T17:54:28Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=80c6463e2fa3377febfc98a6672d92d07f3c26c1'/>
<id>urn:sha1:80c6463e2fa3377febfc98a6672d92d07f3c26c1</id>
<content type='text'>
power_supply_register() calls device_init_wakeup() to register a wakeup
source before initializing dev_name. As a result, device_wakeup_enable()
end up registering wakeup source with a null name when
wakeup_source_register() gets called with dev_name(dev) which is null at
the time.

When kernel is booted with wakeup_source_activate enabled, it will panic
when the trace point code tries to dereference ws-&gt;name.

Fixed the problem by moving up the kobject_set_name() call prior to
accesses to dev_name(). Replaced kobject_set_name() with dev_set_name()
which is the right interface to be called from drivers. Fixed the call to
device_del() prior to device_add() in for wakeup_init_failed error
handling code.

Trace after the change:

            bash-2143  [003] d...   132.280697: wakeup_source_activate: BAT1 state=0x20001
     kworker/3:2-1169  [003] d...   132.281305: wakeup_source_deactivate: BAT1 state=0x30000

Oops message:

[  819.769934] device: 'BAT1': device_add
[  819.770078] PM: Adding info for No Bus:BAT1
[  819.770235] BUG: unable to handle kernel NULL pointer dereference at           (null)
[  819.770435] IP: [&lt;ffffffff813381c0&gt;] skip_spaces+0x30/0x30
[  819.770572] PGD 3efd90067 PUD 3eff61067 PMD 0
[  819.770716] Oops: 0000 [#1] SMP
[  819.770829] Modules linked in: arc4 iwldvm mac80211 x86_pkg_temp_thermal coretemp kvm_intel joydev i915 kvm uvcvideo ghash_clmulni_intel videobuf2_vmalloc aesni_intel videobuf2_memops videobuf2_core aes_x86_64 ablk_helper cryptd videodev iwlwifi lrw rfcomm gf128mul glue_helper bnep btusb media bluetooth parport_pc hid_generic ppdev snd_hda_codec_hdmi drm_kms_helper snd_hda_codec_realtek cfg80211 drm tpm_infineon samsung_laptop snd_hda_intel usbhid snd_hda_codec hid snd_hwdep snd_pcm microcode snd_page_alloc snd_timer psmouse i2c_algo_bit lpc_ich tpm_tis video wmi mac_hid serio_raw ext2 lp parport r8169 mii
[  819.771802] CPU: 0 PID: 2167 Comm: bash Not tainted 3.12.0+ #25
[  819.771876] Hardware name: SAMSUNG ELECTRONICS CO., LTD. 900X3C/900X3D/900X4C/900X4D/SAMSUNG_NP1234567890, BIOS P03AAC 07/12/2012
[  819.772022] task: ffff88002e6ddcc0 ti: ffff8804015ca000 task.ti: ffff8804015ca000
[  819.772119] RIP: 0010:[&lt;ffffffff813381c0&gt;]  [&lt;ffffffff813381c0&gt;] skip_spaces+0x30/0x30
[  819.772242] RSP: 0018:ffff8804015cbc70  EFLAGS: 00010046
[  819.772310] RAX: 0000000000000003 RBX: ffff88040cfd6d40 RCX: 0000000000000018
[  819.772397] RDX: 0000000000020001 RSI: 0000000000000000 RDI: 0000000000000000
[  819.772484] RBP: ffff8804015cbcc0 R08: 0000000000000000 R09: ffff8803f0768d40
[  819.772570] R10: ffffea001033b800 R11: 0000000000000000 R12: ffffffff81c519c0
[  819.772656] R13: 0000000000020001 R14: 0000000000000000 R15: 0000000000020001
[  819.772744] FS:  00007ff98309b740(0000) GS:ffff88041f200000(0000) knlGS:0000000000000000
[  819.772845] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[  819.772917] CR2: 0000000000000000 CR3: 00000003f59dc000 CR4: 00000000001407f0
[  819.773001] Stack:
[  819.773030]  ffffffff81114003 ffff8804015cbcb0 0000000000000000 0000000000000046
[  819.773146]  ffff880409757a18 ffff8803f065a160 0000000000000000 0000000000020001
[  819.773273]  0000000000000000 0000000000000000 ffff8804015cbce8 ffffffff8143e388
[  819.773387] Call Trace:
[  819.773434]  [&lt;ffffffff81114003&gt;] ? ftrace_raw_event_wakeup_source+0x43/0xe0
[  819.773520]  [&lt;ffffffff8143e388&gt;] wakeup_source_report_event+0xb8/0xd0
[  819.773595]  [&lt;ffffffff8143e3cd&gt;] __pm_stay_awake+0x2d/0x50
[  819.773724]  [&lt;ffffffff8153395c&gt;] power_supply_changed+0x3c/0x90
[  819.773795]  [&lt;ffffffff8153407c&gt;] power_supply_register+0x18c/0x250
[  819.773869]  [&lt;ffffffff813d8d18&gt;] sysfs_add_battery+0x61/0x7b
[  819.773935]  [&lt;ffffffff813d8d69&gt;] battery_notify+0x37/0x3f
[  819.774001]  [&lt;ffffffff816ccb7c&gt;] notifier_call_chain+0x4c/0x70
[  819.774071]  [&lt;ffffffff81073ded&gt;] __blocking_notifier_call_chain+0x4d/0x70
[  819.774149]  [&lt;ffffffff81073e26&gt;] blocking_notifier_call_chain+0x16/0x20
[  819.774227]  [&lt;ffffffff8109397a&gt;] pm_notifier_call_chain+0x1a/0x40
[  819.774316]  [&lt;ffffffff81095b66&gt;] hibernate+0x66/0x1c0
[  819.774407]  [&lt;ffffffff81093931&gt;] state_store+0x71/0xa0
[  819.774507]  [&lt;ffffffff81331d8f&gt;] kobj_attr_store+0xf/0x20
[  819.774613]  [&lt;ffffffff811f8618&gt;] sysfs_write_file+0x128/0x1c0
[  819.774735]  [&lt;ffffffff8118579d&gt;] vfs_write+0xbd/0x1e0
[  819.774841]  [&lt;ffffffff811861d9&gt;] SyS_write+0x49/0xa0
[  819.774939]  [&lt;ffffffff816d1052&gt;] system_call_fastpath+0x16/0x1b
[  819.775055] Code: 89 f8 48 89 e5 f6 82 c0 a6 84 81 20 74 15 0f 1f 44 00 00 48 83 c0 01 0f b6 10 f6 82 c0 a6 84 81 20 75 f0 5d c3 66 0f 1f 44 00 00 &lt;80&gt; 3f 00 55 48 89 e5 74 15 48 89 f8 0f 1f 40 00 48 83 c0 01 80
[  819.775760] RIP  [&lt;ffffffff813381c0&gt;] skip_spaces+0x30/0x30
[  819.775881]  RSP &lt;ffff8804015cbc70&gt;
[  819.775949] CR2: 0000000000000000
[  819.794175] ---[ end trace c4ef25127039952e ]---

Signed-off-by: Shuah Khan &lt;shuah.kh@samsung.com&gt;
Acked-by: Anton Vorontsov &lt;anton@enomsg.org&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Anton Vorontsov &lt;anton@enomsg.org&gt;
</content>
</entry>
<entry>
<title>Merge tag 'for-v3.13' of git://git.infradead.org/battery-2.6</title>
<updated>2013-11-18T23:35:09Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2013-11-18T23:35:09Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=a709bd585f291b9a6d0a3691ab4a0b9d3300a7a1'/>
<id>urn:sha1:a709bd585f291b9a6d0a3691ab4a0b9d3300a7a1</id>
<content type='text'>
Pull battery updates from Anton Vorontsov:
 "Highlights:
   - A new driver for TI BQ24735 Battery Chargers, courtesy of NVidia.
   - Device tree bindings for TWL4030 chips.
   - Random fixes and cleanups"

* tag 'for-v3.13' of git://git.infradead.org/battery-2.6:
  pm2301-charger: Remove unneeded NULL checks
  twl4030_charger: Add devicetree support
  power_supply: Fix documentation for TEMP_*ALERT* properties
  max17042_battery: Support regmap to access device's registers
  max17042_battery: Use SIMPLE_DEV_PM_OPS
  charger-manager : Replace kzalloc to devm_kzalloc and remove uneccessary code
  bq2415x_charger: Fix max battery regulation voltage
  tps65090-charger: Use "IS_ENABLED(CONFIG_OF)" for DT code
  tps65090-charger: Drop devm_free_irq of devm_ allocated irq
  power_supply: Add support for bq24735 charger
  pm2301-charger: Staticize pm2xxx_charger_die_therm_mngt
  pm2301-charger: Check return value of regulator_enable
  ab8500-charger: Remove redundant break
  ab8500-charger: Check return value of regulator_enable
  isp1704_charger: Fix driver to work with changes introduced in v3.5
</content>
</entry>
<entry>
<title>tree-wide: use reinit_completion instead of INIT_COMPLETION</title>
<updated>2013-11-15T00:32:21Z</updated>
<author>
<name>Wolfram Sang</name>
<email>wsa@the-dreams.de</email>
</author>
<published>2013-11-14T22:32:02Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=16735d022f72b20ddbb2274b8e109f69575e9b2b'/>
<id>urn:sha1:16735d022f72b20ddbb2274b8e109f69575e9b2b</id>
<content type='text'>
Use this new function to make code more comprehensible, since we are
reinitialzing the completion, not initializing.

[akpm@linux-foundation.org: linux-next resyncs]
Signed-off-by: Wolfram Sang &lt;wsa@the-dreams.de&gt;
Acked-by: Linus Walleij &lt;linus.walleij@linaro.org&gt; (personally at LCE13)
Cc: Ingo Molnar &lt;mingo@kernel.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>pm2301-charger: Remove unneeded NULL checks</title>
<updated>2013-11-13T06:36:34Z</updated>
<author>
<name>Dan Carpenter</name>
<email>dan.carpenter@oracle.com</email>
</author>
<published>2013-11-07T08:06:17Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=c8024234c20eaf7b163cc4dbd963cb9cd03a4ff1'/>
<id>urn:sha1:c8024234c20eaf7b163cc4dbd963cb9cd03a4ff1</id>
<content type='text'>
If "pm2" were NULL we would oops printing the error message.
Fortunately, that's not possible so I have removed the NULL checks.

Signed-off-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Anton Vorontsov &lt;anton@enomsg.org&gt;
</content>
</entry>
<entry>
<title>twl4030_charger: Add devicetree support</title>
<updated>2013-11-13T06:35:45Z</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.de</email>
</author>
<published>2013-10-31T06:05:50Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=ec0b380245d7b7d4d8e4201facca780a14352cda'/>
<id>urn:sha1:ec0b380245d7b7d4d8e4201facca780a14352cda</id>
<content type='text'>
This allows the charger to be enabled with devicetree, and allows the
parameters for charging the backup battery to be set.

Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
Acked-by: Kumar Gala &lt;galak@codeaurora.org&gt;
Acked-by: Grant Likely &lt;grant.likely@linaro.org&gt;
Signed-off-by: Anton Vorontsov &lt;anton@enomsg.org&gt;
</content>
</entry>
<entry>
<title>max17042_battery: Support regmap to access device's registers</title>
<updated>2013-10-25T23:54:33Z</updated>
<author>
<name>Jonghwa Lee</name>
<email>jonghwa3.lee@samsung.com</email>
</author>
<published>2013-10-25T04:55:02Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=39e7213edc4f31b0650dcc5630e175a6bd278b9b'/>
<id>urn:sha1:39e7213edc4f31b0650dcc5630e175a6bd278b9b</id>
<content type='text'>
This patch makes max17042 fuelguage driver uses regmap API to access its
device's registers.

Signed-off-by: Jonghwa Lee &lt;jonghwa3.lee@samsung.com&gt;
Signed-off-by: Myungjoo Ham &lt;myungjoo.ham@samsung.com&gt;
Signed-off-by: Anton Vorontsov &lt;anton@enomsg.org&gt;
</content>
</entry>
<entry>
<title>max17042_battery: Use SIMPLE_DEV_PM_OPS</title>
<updated>2013-10-25T23:48:30Z</updated>
<author>
<name>Manish Badarkhe</name>
<email>badarkhe.manish@gmail.com</email>
</author>
<published>2013-10-14T05:26:51Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=3d23c7f457ed86f27425cb3f229b76720855a26d'/>
<id>urn:sha1:3d23c7f457ed86f27425cb3f229b76720855a26d</id>
<content type='text'>
Use the SIMPLE_DEV_PM_OPS macro to declare the driver's pm_ops.

Signed-off-by: Manish Badarkhe &lt;badarkhe.manish@gmail.com&gt;
Signed-off-by: Anton Vorontsov &lt;anton@enomsg.org&gt;
</content>
</entry>
<entry>
<title>charger-manager : Replace kzalloc to devm_kzalloc and remove uneccessary code</title>
<updated>2013-10-25T23:28:54Z</updated>
<author>
<name>Jonghwa Lee</name>
<email>jonghwa3.lee@samsung.com</email>
</author>
<published>2013-10-25T02:47:31Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=883c10a9dd8099e7519cdc43b75ac4066a6ae98d'/>
<id>urn:sha1:883c10a9dd8099e7519cdc43b75ac4066a6ae98d</id>
<content type='text'>
Use devm function for dynamic memory allocation.

Signed-off-by: Jonghwa Lee &lt;jonghwa3.lee@samsung.com&gt;
Signed-off-by: Myungjoo Ham &lt;myungjoo.ham@samsung.com&gt;
Signed-off-by: Anton Vorontsov &lt;anton@enomsg.org&gt;
</content>
</entry>
<entry>
<title>bq2415x_charger: Fix max battery regulation voltage</title>
<updated>2013-10-25T23:24:22Z</updated>
<author>
<name>Alexandre Belloni</name>
<email>alexandre.belloni@free-electrons.com</email>
</author>
<published>2013-10-16T14:08:31Z</published>
<link rel='alternate' type='text/html' href='https://git.amat.us/linux/commit/?id=3ed5cd79b82e9a055e0df3275eeb471ea0f1e2d7'/>
<id>urn:sha1:3ed5cd79b82e9a055e0df3275eeb471ea0f1e2d7</id>
<content type='text'>
As per the datasheets, maximum battery regulation voltage is 4440mV.

The formula is (voltage - offset) / step, so the maximum value is:
(4440 - 3500) / 20 = 47

Signed-off-by: Alexandre Belloni &lt;alexandre.belloni@free-electrons.com&gt;
Thanks-to: Pali Rohár &lt;pali.rohar@gmail.com&gt;
Signed-off-by: Anton Vorontsov &lt;anton@enomsg.org&gt;
</content>
</entry>
</feed>
