Commit graph

40 commits

Author SHA1 Message Date
Christopher N. Hesse
fb5669e851 power: Keep boost fd opened as well
Change-Id: I016b28c29786fc948a007d4ec3106be8a662eafd
2017-07-31 00:01:00 +00:00
Christopher N. Hesse
1146f1a616 Revert "power: Temporary logging fix"
This reverts commit ff86846e97.

Change-Id: I46aa4d6606c3c519322b2e2cd048bd312a15fa4d
2017-07-13 21:17:23 +02:00
Christopher N. Hesse
7ad73bc372 power: Allow for a dynamic cluster configuration
Change-Id: I542b36d26cad23f29e70ab70d996c95ca3ab11a7
2017-07-13 19:13:51 +00:00
Christopher N. Hesse
ff86846e97 power: Temporary logging fix
This will be reverted once the more advanced mechanism
(https://review.lineageos.org/#/c/179092/) goes in.

The boost fd logging will be restored once
https://review.lineageos.org/#/c/180313/ makes it into
the code base.

Change-Id: Ifc1b4a2ba3e1c4283d74eafec45c5fbf07153f03
2017-07-09 23:08:10 +02:00
Christopher N. Hesse
775bce8f14 power: Print information on boot
Change-Id: I1a8ba54f1b27c2e96c6bae77046dc207cdf35025
2017-07-09 20:40:38 +00:00
Christopher N. Hesse
0da5fbf3e2 power: sysfs_read: Do not store newlines
Change-Id: If20b509b489b056ac3b37c208c42bc5407f61802
2017-07-09 20:36:32 +00:00
Christopher N. Hesse
63b5bd7d6b power: Write IO busy parameter for big cluster
Change-Id: I9e09f640b956be87729df735225fcfe8f066ab48
2017-05-29 20:45:14 +02:00
Christopher N. Hesse
5eca5aa565 power: Allow POWER_HINT_LOW_POWER hint to disable power save mode
Change-Id: I3b4c90f05267ca4182187361e5d373adb6de25d7
2017-05-06 20:27:04 +00:00
Paul Keith
5e4fbe091d power: Sanity check touchscreen path
* Let's not always assume this isn't NULL

Change-Id: I181cb014fc06d0f0ca795c3ecc374ccf9dbb57f1
Signed-off-by: Paul Keith <javelinanddart@bestas.gr>
2017-04-24 14:14:53 -05:00
Christopher N. Hesse
3fa2b6951e power: Align to AOSP API
AOSP power hints can have a NULL data parameter,
only our custom hints are guaranteed to provide data.

Change-Id: Ibea874e75a7092b3f9c1c56dc5182cdf73f35532
2017-04-05 18:58:09 +02:00
Christopher N. Hesse
5781c8ec57 power: Remove unused variables
Change-Id: I805a12837bd013e71c098479279dcc5895ea1e1d
2017-04-05 18:58:09 +02:00
Christopher N. Hesse
f9b8e83975 power: Add POWER_HINT_DISABLE_TOUCH support
Change-Id: I363df278598e3402692424539638f3547c648e26
2017-04-02 13:15:40 +02:00
Martin Bouchet
4bf8a7978e PowerHAL: Update the hispeed_freq value before using it
The hispeed_freq value is read only in the inizialization process.
If we decide to change it later writing a new value to the node
this new value wont be taken into consideration by the power hal.
Lets update the hispeed_freq value in the power hal before using
it to limit the max cpu freq when we go into power save mode.

Change-Id: I4b8c7f67259750b2931b18c3871874022aa6054d
2017-03-28 19:28:29 +00:00
Christopher N. Hesse
81f714d57a power: Rework governor path abstraction
Construct the paths for the driver based on the device
specific header data.

Change-Id: Ic7c72a2bbe6f199e1297f41817840059595f516d
2017-03-18 17:48:13 +00:00
Christopher N. Hesse
2981f792c4 power: Cleanup hint handling
Change-Id: I828a68105272fef3fe454561d98825f8703bca0b
2017-03-14 08:05:53 +00:00
Christopher N. Hesse
15b63090f2 power: Discard hints in power save mode
Change-Id: I9c3701261e49023761599ebaa8cd3e09a88a40c6
2017-03-14 08:05:31 +00:00
Christopher N. Hesse
f21fbdb02e power: Keep boostpulse fd opened
No one else should be writing to this, so keep the fd
opened.

Change-Id: I4258f7f7d69250f4832a67807031ab3faa9ff586
2017-03-14 08:04:43 +00:00
Christopher N. Hesse
65c65bd186 power: Initialize device power paths
Change-Id: I56481946e2e3f4a80f2d3a7713ce61ed7923666d
2017-03-07 23:02:10 +01:00
Christopher N. Hesse
d9106e98b2 power: Cleanup touchkey handling
* Simplify interactive changes
 * Better support for non-touchkey devices
 * Only perform read I/O in samsung_power_set_interactive
   if needed (improves wake->panel_on delay)

Change-Id: If7bd6a1833ac7605db437ef3664230f9a452d58b
2017-03-07 22:50:41 +01:00
Christopher N. Hesse
354f713a56 power: Remove superfluous log newlines
Change-Id: I33da39a89544f3580d395f4165b8cff4de5a4224
2017-03-04 14:58:48 +01:00
Christopher N. Hesse
5fada9b0c8 power: Add support for POWER_HINT_CPU_BOOST
Change-Id: I75030eb2dabfed518e961d71efb9d55670d2808a
2017-02-09 19:54:30 +00:00
Christopher N. Hesse
ccd970ddeb power: Make boostpulse_warned static
Change-Id: I8bd557c637402922702fcb75a1c0633947ded41a
2017-01-25 22:41:05 +01:00
Christopher N. Hesse
58f2ca07ed power: Add PROFILE_MAX to enum
Change-Id: If7349c98598d346f5b03b32dceb5f797c8b02ce7
2017-01-25 21:34:09 +00:00
Christopher N. Hesse
d928574407 power: Directly compare chars
Change-Id: I6da2d9cfcecd7177e2c1a74051e2ad46e2349f64
2017-01-25 21:32:06 +00:00
Christopher N. Hesse
0e14f27f72 power: Remove unused local variables
Change-Id: I8f45398eba884fee3c3833a67f37ffd28186cf24
2017-01-17 00:20:36 +01:00
Christopher N. Hesse
f05f9021a7 power: Consolidate verbose logging
Change-Id: I8b2a5d9c625273220d43a3d39e6fd977bbc1247d
2017-01-17 00:20:36 +01:00
Christopher N. Hesse
aa75be4875 power: Update module author
Change-Id: I4ec64beb57729f5dd299ae04a68770e4f5943c61
2017-01-17 00:20:36 +01:00
Christopher N. Hesse
f629672e63 power: Remove outdated comments
Always redirect to power.h for updated documentation.

Change-Id: I066f3b6f83483bdf3a0db315c1381c670df47b12
2017-01-17 00:20:35 +01:00
Christopher N. Hesse
1226350ee7 power: Get panel backlight brightness from lights helper
Change-Id: I3f28fc4abac947cc4a30d95ba74f45bf24c12c20
2016-12-21 14:24:03 -08:00
Christopher N. Hesse
4139d85cc6 power: Allow devices to override node paths
Change-Id: Ida7f41ddce2ef458cc77348c0b44ec0a7a86df72
2016-12-08 15:11:18 +01:00
ishantvivek
987dcca825 power: Update DT2W_PATH
* TARGET_TAP_TO_WAKE_NODE is defined in if condition. But in DT2W_PATH, TARGET_DT2W_PATH is defined. Why?
* Use same flag for both, otherwise we need to define two flags for the dt2w path.
* Use TARGET_TAP_TO_WAKE_NODE instead of TARGET_DT2W_PATH, for similarity with qcom powerHAL.

Change-Id: I87cbdc3f2aa1a3f9f6509580f2c1f001129a0fda
2016-11-21 06:29:20 +00:00
Christopher N. Hesse
1c47466906 power: Fix unused argument
Change-Id: Ia4048aa48b32ea344c303ca24289ade1b7dfae7a
2016-11-18 18:59:55 +01:00
Christopher N. Hesse
e143419bff power: Simplify read_panel_brightness()
Overengineering.

Change-Id: Ifef79a7e8f2249fdd22099a043303f9686ac014b
2016-11-18 18:56:19 +01:00
Christopher N. Hesse
e480d89ce5 power: Add double tap to wake support
Change-Id: Icb0b6d442544b39576ec74e70e97751d6bc70590
2016-07-13 01:59:31 -07:00
Ethan Chen
3ecf3c4648 power: Fix compilation failure
Change-Id: Ib0923ba5c0976e2d00e6f190b370936a14a9b6df
2016-07-12 18:38:00 -07:00
Christopher N. Hesse
2879c69f2b power: Fix I/O business parameter setting
This parameter should be set even if we bail out early.

Change-Id: Iae78a13db229538960f1c7ec4c1f95f530810d71
2016-07-12 17:32:47 -07:00
Christopher N. Hesse
3360b09389 power: Add support for auto power modes
Do not disable input devices in case of the screen still
being enabled.

Change-Id: Ide6bd7ca3d41ac64b472c5e68fdc545c8f851b2b
2016-07-12 17:32:30 -07:00
Andreas Schneider
f15d7f4b0b powerhal: Add set_profile support
Change-Id: I0d7fb8c5a7e5e06c300cbb4b78b6e1013d7bff6a
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
2016-03-06 13:26:07 +01:00
Christopher N. Hesse
22da313eb2 power: Ensure node_path is a string literal
Change-Id: I20a87b04789e7fe2ae5938331e9d2fcef8134035
2016-02-01 12:36:54 +01:00
Christopher N. Hesse
de5e3c618d Initial unified Samsung power HAL
This is a power HAL for non-qcom Samsung devices.

It currently supports standard multi-core systems as well as
big.LITTLE configurations.

This HAL auto-detects your touchscreen and touchkey input switches
and handles the interactive state requests.

I also implemented a check to make sure your touchkeys won't turn
on when they're not supposed to (for example when a CMHW class disables
the capacitive buttons and activates a software navigation solution).
This previously needed a kernel hack to make sure the touchkeys wouldn't
be activated when resuming from suspend.

Change-Id: I22888c5ac490c85c417c5457ea4f457f78ed3521
2016-01-21 16:01:27 +01:00