| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
BRANCH=grunt
BUG=b:143095616
TEST=GPIO is locked as input
Change-Id: I36b123ed068db268d1cd02e990dd720663eaae57
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1873008
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
BUG=b:140452269
BRANCH=grunt
TEST=Test on charging/discharging/battery cut off pass.
Change-Id: Iba19c113d94ed0c88372b5bd4317b333dee6d146
Signed-off-by: Devin Lu <Devin.Lu@quantatw.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1782398
Reviewed-by: Edward Hill <ecgh@chromium.org>
Commit-Queue: Edward Hill <ecgh@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change is needed to allow better testing of the fifo
behavior. Additionally, motion_sense_fifo.c will only be compiled
if CONFIG_ACCEL_FIFO is defined. This behaviour requires a few
small changes to several boards and baseboards to make
sure that we only define CONFIG_ACCEL_FIFO when the MOTIONSENSE
task is present (some times that may be only in one section RW or
RO).
BUG=b:137758297
BRANCH=None
TEST=buildall and ran CTS on arcada
Change-Id: I2f7e4e436ba9568a35b7a0b2c8d53a73f198ba73
Signed-off-by: Yuval Peress <peress@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1704163
Reviewed-by: Alexandru M Stan <amstan@chromium.org>
Commit-Queue: Alexandru M Stan <amstan@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Merge common TCPC code into baseboard, and add choice of ANX3429 or
ANX3447 for port 0 TCPC.
Treeya uses ANX3447, all others use ANX3429.
BUG=b:138744661
BRANCH=none
TEST=build -j BOARD=treeya
Change-Id: I66f84ae50be0b5fe80479dfdc699717427e4457c
Signed-off-by: Paul Ma <magf@bitland.corp-partner.google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1751302
Reviewed-by: Jett Rink <jettrink@chromium.org>
Reviewed-by: Martin Roth <martinroth@chromium.org>
Tested-by: Martin Roth <martinroth@chromium.org>
Commit-Queue: Martin Roth <martinroth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add GPIO_EC_RST_ODL to hibernate_wake_pins[] for Aleena + Careena + Liara
since the HW supports this as a PSL wake input.
BUG=b:122833270
BRANCH=grunt
TEST='dut-control cold_reset:on cold_reset:off' with ServoV2
Change-Id: I24a878be5e2c822b052a7d65b1964dcb6ed2ce94
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1658524
Reviewed-by: Raul E Rangel <rrangel@chromium.org>
Reviewed-by: Diana Z <dzigterman@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It's simply a bad idea to describe a macro in multiple locations.
It'll make it hard to change. It'll be difficult to keep all
locations in sync.
This patch replaces the comment duplicated in all ec.tasklist with
a pointer to the CONFIG_TASK_LIST definition. The macro will be
described in a single place (just like all/most other macros).
Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org>
BUG=none
BRANCH=none
TEST=buildall
Change-Id: Id658b9d68e742e4334c692b804d9c98c8de21313
Reviewed-on: https://chromium-review.googlesource.com/1551579
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Tested-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Send MKBP events (for sensor data) over GPIO instead of host event.
BUG=b:123750725
BRANCH=grunt
TEST=MKBP events still received
Change-Id: Ie1b02bbb8df44ade5ec6f1a4ba5dc4c5142e9f39
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1452936
Reviewed-by: Enrico Granata <egranata@chromium.org>
Reviewed-by: Raul E Rangel <rrangel@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The Type-C Power Path Controllers provide overcurrent protection. This
commit adds support into the USB PD task for overcurrent events while we
are in source role. The USB PD 3.0 spec recommends that ports issue a
hard reset when an overcurrent condition occurs on a port.
Additionally, we'll allow a source port to overcurrent 3 times before
latching off VBUS from the port entirely. The source path will be
re-enabled after ~1s after each overcurrent event.
BUG=b:69935262,b:114680657
BRANCH=None
TEST=Boot to ChromeOS in grabbiter. No overcurrent events reported when
the sink is drawing <= 3.20 A. Overcurrent events are reported when the
sink is drawing > 3.25 A. After 3 reports, the port is latched off and
power delivery is stopped. The port is re-enabled only after the sink is
disconnected. Also when the sink is drawing current at 3.24 A, there is
one report of overcurrent. The port gets disabled in response to that
event. But the port is re-enabled after 1 second since overcurrent event
is reported only once. After the port is re-enabled, the sink is able to
draw the set current. When the overcurrent event is reported, I can see in
the kernel logs that the overcurrent condition is detected by the kernel.
EC Logs:
[3391.984462 C1: PPC detected Vbus overcurrent!]
[3391.984953 C1: overcurrent!]
[3392.044935 C1: PPC detected Vbus overcurrent!]
[3392.045425 C1: overcurrent!]
[3392.061404 C1: PPC detected Vbus overcurrent!]
[3392.061894 C1: overcurrent!]
[3392.062142 C1: OC event limit reached! Source path disabled until
physical disconnect.]
[3392.077226 C1: PPC detected Vbus overcurrent!]
[3392.077532 C1: overcurrent!]
[3392.077891 C1: OC event limit reached! Source path disabled until
physical disconnect.]
[3392.092660 C1: PPC detected Vbus overcurrent!]
[3392.092966 C1: overcurrent!]
[3392.093213 C1: OC event limit reached! Source path disabled until
physical disconnect.]
Kernel Logs:
[ 3356.560456] usb usb2-port1: over-current condition
[ 3356.768434] usb usb2-port2: over-current condition
[ 3356.976446] usb usb2-port4: over-current condition
[ 3357.184441] usb usb2-port5: over-current condition
[ 3357.392445] usb usb2-port6: over-current condition
Change-Id: Ib070f261e98264cd88725ebce7d10e0798267e3b
Signed-off-by: Aseda Aboagye <aaboagye@google.com>
Signed-off-by: Karthikeyan Ramasubramanian <kramasub@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/1286300
Tested-by: Aseda Aboagye <aaboagye@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
Commit-Queue: Jett Rink <jettrink@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/807633
Commit-Ready: Karthikeyan Ramasubramanian <kramasub@chromium.org>
Tested-by: Karthikeyan Ramasubramanian <kramasub@chromium.org>
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Enabling CONFIG_LOW_POWER_S0 (CL:1347014) caused the keyboard backlight
to flash. Fix this by setting the PWM_CONFIG_DSLEEP flag.
BUG=b:120400520,b:120447176
BRANCH=grunt
TEST=Liara keyboard backlight no longer flashes
Change-Id: I2808c40bc3f833acebd0246992f3763dab76a752
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1363673
Commit-Ready: Ryan Zhang <ryan.zhang@quanta.corp-partner.google.com>
Reviewed-by: Jett Rink <jettrink@chromium.org>
Reviewed-by: Diana Z <dzigterman@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Adjust Grunt baseboard to allow for per-sku support for motion sensors.
Use this to enable motion sensors for SKU 82 (Kasumi360).
Only enable the interrupt if the sensor is present.
BUG=b:119795894
BRANCH=grunt
TEST=Kasumi360 `ectool motionsense lid_angle` shows correct angles.
Change-Id: Icb34359d7ac4cd894776e134c2c1fb7032741f03
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1361987
Tested-by: Ryan Zhang <ryan.zhang@quanta.corp-partner.google.com>
Reviewed-by: Ryan Zhang <ryan.zhang@quanta.corp-partner.google.com>
Reviewed-by: Jett Rink <jettrink@chromium.org>
Reviewed-by: Diana Z <dzigterman@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A rough early (and therefore liberal) analysis of grunt task stacks
shows that some of them will overrun on some infrequently-executed
debugging statements. Raise those task sizes to reduce the risk of an
overflow.
On Careena:
Task: HOOKS, Max size: 320 (96 + 224), Allocated size: 800
Task: USB_CHG_P0, Max size: 548 (324 + 224), Allocated size: 672
Task: USB_CHG_P1, Max size: 548 (324 + 224), Allocated size: 672
Task: CHARGER, Max size: 844 (620 + 224), Allocated size: 928
Task: MOTIONSENSE, Max size: 588 (364 + 224), Allocated size: 928
Task: CHIPSET, Max size: 812 (588 + 224), Allocated size: 928
Task: KEYPROTO, Max size: 516 (292 + 224), Allocated size: 672
Task: PDCMD, Max size: 344 (120 + 224), Allocated size: 800
Task: HOSTCMD, Max size: 524 (300 + 224), Allocated size: 800
Task: CONSOLE, Max size: 484 (260 + 224), Allocated size: 928
Task: POWERBTN, Max size: 812 (588 + 224), Allocated size: 928
Task: KEYSCAN, Max size: 556 (332 + 224), Allocated size: 672
Task: PD_C0, Max size: 820 (596 + 224), Allocated size: 928
Task: PD_C1, Max size: 820 (596 + 224), Allocated size: 928
Task: PD_INT_C0, Max size: 296 (72 + 224), Allocated size: 672
Task: PD_INT_C1, Max size: 296 (72 + 224), Allocated size: 672
Note that '224' is conservative right now with CONFIG_FPU cleared on
Grunt.
BUG=b:116610278
TEST=buildall and analyzestack
BRANCH=grunt
Change-Id: Ibf721acc3250aa1d1195546e943031c5c8617b95
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1262101
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Considerably more work is needed to support the various driver
indirections that Grunt is using. This is a 'liberal' analysis, in the
sense that it is failing to include some driver paths in its stack
consumption analysis.
BRANCH=grunt
BUG=b:116610278
TEST=make BOARD=grunt analyzestack.
Change-Id: I6ff034935a749049b1ce6b544ea627b1772c7a80
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1262100
Reviewed-by: Edward Hill <ecgh@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These members of the grunt family do not include any motion sensors.
Remove them entirely, both to save space and to disable some factory
tests.
build/aleena/RW/space_free_flash grew by 12716 bytes: (62400 to 75116)
build/aleena/RW/space_free_ram grew by 9888 bytes: (30272 to 40160)
build/careena/RW/space_free_flash grew by 12864 bytes: (61664 to 74528)
build/careena/RW/space_free_ram grew by 9856 bytes: (30304 to 40160)
build/liara/RW/space_free_flash grew by 12724 bytes: (61364 to 74088)
build/liara/RW/space_free_ram grew by 9856 bytes: (30272 to 40128)
BRANCH=grunt
BUG=b:115649135
TEST=boot Careena. Observe that `ectool motionsense` returns an INVALID
COMMAND error, and that the EC console shows no attempt is made to
communicate with the sensors.
Change-Id: I322978fc80e36b999e77f9e3d54b175c6814fdcf
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1262099
Reviewed-by: Edward Hill <ecgh@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The BQ24392 driver was renamed to MAX14637 (CL:1250031) and no
longer requires GPIO_EN_PP5000 to be defined (CL:1250032), so
this can be removed from grunt-family gpio.inc.
BUG=none
BRANCH=grunt
TEST=make -j buildall
Change-Id: I186ece073e544760d487489f874659226c820bd8
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1257644
Reviewed-by: Scott Collyer <scollyer@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The MAX14637 BC 1.2 USB charger detection chip is functionally similar
to the bq24392 and can use the same driver. Rather than have 2 copies
of the same driver, or a generic named driver than can be used for
both chips, rename the existing bq24392 driver to max14637 as that's
the BC 1.2 chip that our current designs are using.
BUG=b:113267982
BRANCH=none
TEST=make -j buildall
Change-Id: I03cfb4918513d756c2a41341001a8162652a29b6
Signed-off-by: Scott Collyer <scollyer@google.com>
Reviewed-on: https://chromium-review.googlesource.com/1250031
Commit-Ready: Scott Collyer <scollyer@chromium.org>
Tested-by: Scott Collyer <scollyer@chromium.org>
Reviewed-by: Edward Hill <ecgh@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Some factory tests are evaluating behavior that is sensitive to RO
firmware behaving like a locked system image. Caveat: EC engineers will
need to manually `sysjump rw` or use flashrom to update the entire
system firmware image as described in the grunt care and feeding guide.
TEST=buildall; flash and boot a Careena pre-release system.
BRANCH=grunt
BUG=b:114686468
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Change-Id: Ida253bd9e0197a4a70abed3f3670b720fa0e33bb
Reviewed-on: https://chromium-review.googlesource.com/1246268
Commit-Ready: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Tested-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-by: Edward Hill <ecgh@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The body frame motion sensor will not be installed for Careena.
BUG=b:115649135
TEST=observe that the EC does not attempt to initialize any of its
motion sensors in the EC log.
BRANCH=grunt
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Change-Id: I0e7c2e9e39d290c21f20b766da4347a2e2902942
Reviewed-on: https://chromium-review.googlesource.com/1231474
Commit-Ready: Jett Rink <jettrink@chromium.org>
Tested-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-by: Edward Hill <ecgh@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
See also go/usb-pd-slow-response-time. Lift tcpc_alert_event interrupt
handler to baseboard.c to reduce duplication.
BUG=b:112848644, b:111909282
BRANCH=none
TEST=Observe response time after SrcCap to Sink Request is 15ms on
Careena and Grunt hardware after forcing a sysjump. Repeat test on
Careena Port 0 with the DB disconnected (containing Port 1), also 15ms.
Change-Id: I501bd86d84ba84eea0a705731e59e2431fc9a2ac
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1194669
Commit-Ready: Jett Rink <jettrink@chromium.org>
Tested-by: Jett Rink <jettrink@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch add two simplo batteries for careena, one is coslight pack,
another one is ATL pack.
BUG=b:111288497,b:111287943
BRANCH=none
TEST=Check DUT can recognize this two batteries.
Check software battery cutoff and hardware battery cutoff could be
woke up after charger attached.
Change-Id: If22be1e84c0dee28e4d12dc64c3102b7d80dacc4
Signed-off-by: Devin Lu <Devin.Lu@quantatw.com>
Reviewed-on: https://chromium-review.googlesource.com/1174145
Commit-Ready: Devin Lu <devin.lu@quanta.corp-partner.google.com>
Reviewed-by: Edward Hill <ecgh@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Measure the cell imbalance with method dispatch to a per-battery
method, such that families with a plurality of configurable batteries
can support them all. By default, cell imbalance is taken to be 'zero'
in case we don't support that battery's management IC. Provide a driver
for reading cell voltages for the TI BQ4050 family. This IC is quite
popular, but by no means universal.
BUG=b:111214767
BRANCH=none
TEST=Boot on Careena with a custom debug print statement, showing that
we can measure the typical battery voltages during and after the boot at
the battery status polling interval.
Change-Id: I235389b252ac9c373aa9706dbd1066f7c0bbce71
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1162663
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Port 1 is provided by a daughterboard. In the event that the
daughterboard is disconnected, these pins are floating. Pull them in
the appropriate direction for their logic when the board is
disconnected.
BUG=b:111942717
BRANCH=none
TEST=make -j buildall; Test startup on Careena hardware both with and
without port 1 connected to the mainboard.
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Change-Id: Ica06ea16c2c76c624c542ba9b803197a4fd852bd
Reviewed-on: https://chromium-review.googlesource.com/1155713
Commit-Ready: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Tested-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-by: Edward Hill <ecgh@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The Careena baseboard IMU principle axes are rotated relative to the
Grunt reference design for manufacturability. Also, refactor
common/spi_flash_reg.c to avoid a name collision with axis definitions
in math_util.
BRANCH=none
BUG=b:111983307
TEST=make -j buldall; Observe `accelread 1` output with the base in
orientations: flat, perturbed by rotation about +y, and perturbed by
rotation about +x.
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Change-Id: Ib85d657ef47a89aaa63134b2bdf43920caf6c06e
Reviewed-on: https://chromium-review.googlesource.com/1155628
Commit-Ready: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Tested-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-by: Edward Hill <ecgh@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Caveat: Careena early generation hardware was reworked to a state which
does not map SYS_RESET_L to any pin on the EC. This change updates the
config to the next hardware gen.
TEST=make -j buildall, schematic review
BRANCH=none
BUG=b:111593365, b:109874594
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Change-Id: Icb1ca7ccbacd98f960e4f44041281d1b2ca94e6e
Reviewed-on: https://chromium-review.googlesource.com/1142236
Commit-Ready: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Tested-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-by: Edward Hill <ecgh@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch is referring to CL:332322.
BUG=none
BRANCH=none
TEST=Short keyboard pins and make sure "ectool kbfactorytest" works.
Change-Id: Ic943753c8cec8dde79842de48e5d21ff4dc01c00
Signed-off-by: Devin Lu <Devin.Lu@quantatw.com>
Reviewed-on: https://chromium-review.googlesource.com/1114400
Reviewed-by: Edward Hill <ecgh@chromium.org>
Reviewed-by: Shawn N <shawnn@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The NPCX only supports two modes per pin: Peripheral function or GPIO.
The chip and its driver do not support alternate peripheral functions.
TEST=buildall -j
BRANCH=none
BUG=b:79686781
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Change-Id: Ib5d7ba81b5224ed9c121887d664dac659962b2c2
Reviewed-on: https://chromium-review.googlesource.com/1136942
Commit-Ready: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Tested-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the case that the lid switch becomes loose/disconnected, default to
the 'lid open' state by pulling up the GPIO. Grunt is not affected, but
we want to demonstrate best practices for the grunt family with its
configuration.
BUG=b:110836185
BRANCH=none
TEST=disconnected lid switch on careena and observed lid state remained
open and stable. Reconnected lid switch and observed lid state followed
physical lid position.
Change-Id: I951594ed7f6d98cf1b5258a894d0b95b6ca98ecc
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1115859
Commit-Ready: Martin Roth <martinroth@chromium.org>
Reviewed-by: Edward Hill <ecgh@chromium.org>
Reviewed-by: Martin Roth <martinroth@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove CONFIG_BATTERY_HW_PRESENT_CUSTOM, CONFIG_BATTERY_PRESENT_CUSTOM,
and associated code in battery.c, and delay in board_tcpc_init.
Add CONFIG_BATTERY_PRESENT_GPIO.
This allows CONFIG_BATTERY_REVIVE_DISCONNECT to work correctly to
revive a cut-off battery, using battery_get_disconnect_state().
Before this change, the call to battery_get_disconnect_state() in
the main loop of charge_state_v2's charger_task would not be
reached with cut-off battery, due to the earlier:
"if (curr.batt.is_present == BP_NO) goto wait_for_it;"
With this change, curr.batt.is_present changes to BP_YES based on the
simple test of GPIO_EC_BATT_PRES_L. This allows charger_task to
"try to wake battery", then call battery_get_disconnect_state()
and "found battery in disconnect state". This succeeds in getting
the battery out of the disconnect state.
The delay in board_tcpc_init() is removed because TCPC init doesn't
disturb the AC power supply. If it did, powering on with AC only
(no battery) would fail.
BUG=b:109894491
BRANCH=none
TEST=these combinations on grunt and careena:
grunt, unplug AC, cutoff battery, on AC plug: pass (AP boots)
grunt, unplug AC, normal battery, on EC reboot: pass (AP boots)
grunt, unplug AC, unplug battery, on AC plug: pass (AP boots)
grunt, unplug AC, discharge battery to cutoff,
on AC plug: pass (AP boots)
careena, unplug AC, cutoff battery, on AC plug: pass (AP boots)
careena, unplug AC, normal battery, on EC reboot: pass (AP boots)
careena, unplug AC, unplug battery, on AC plug: pass (AP boots)
careena, unplug AC, discharge battery to cutoff,
on AC plug: pass (AP boots)
Change-Id: Ieceaa51535b9fcabc8b42681472689bfa9d0e498
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1105338
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Reviewed-by: Furquan Shaikh <furquan@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch add batteries configuration for careena.
BUG=b:109638172
BRANCH=none
TEST=Verified battery charging and discharging and that 'cutoff'
EC console command works.
Change-Id: Ia338efa5730e5039d9a2b1a0873ca90d13ff85fa
Signed-off-by: Devin Lu <Devin.Lu@quantatw.com>
Reviewed-on: https://chromium-review.googlesource.com/1088273
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Reviewed-by: Edward Hill <ecgh@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Pin rename only; no functional changes. See also b/72426192 for
earlier functional changes.
BUG=b:77301519
TEST=make -j buildall
BRANCH=none
Change-Id: I18e71118e584a5b36ba001bac24951929d2c93ff
Signed-off-by: Jonathan Brandmeyer <jbrandmeyer@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1087207
Reviewed-by: Edward Hill <ecgh@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Move fuel gauge code to common to avoid duplication in octopus and
grunt baseboards.
BUG=b:79704826,b:74018100
BRANCH=none
TEST=make -j buildall
Change-Id: I58a615c9ed7906cb19b49c2baa36aaa619838cf1
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1072637
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Reviewed-by: Furquan Shaikh <furquan@chromium.org>
Reviewed-by: Vijay Hiremath <vijay.p.hiremath@intel.corp-partner.google.com>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Split battery info between baseboard and board, following the
Octopus example. This will allow Grunt and Careena to define their
own lists of supported battery types.
This also adds CONFIG_BATTERY_REVIVE_DISCONNECT support, and
checks the charge/discharge FET status.
BUG=b:79704826,b:74018100
BRANCH=none
TEST=Grunt still boots ok.
Change-Id: I6e82ac5e48f9aabf59b63add253108513f0a6b60
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1072039
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Careena has non-PWM White/Orange LEDs.
BUG=b:79704826,b:79894166
BRANCH=none
TEST=make -j buildall
Change-Id: Ie85de84fbd6e4ac4c6139d8407a7a25b5f6d5e7e
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1072898
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Update GPIO definitions for Careena to match hardware.
BUG=b:79704826
BRANCH=none
TEST=make BOARD=careena
Change-Id: I755e5fd8123eefdfa8d30ca2314435c28340e488
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1070989
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
Move code that will be common to Grunt and Careena to baseboard
to avoid duplication when creating the Careena board.
Add Careena board files. These are currently just a copy of Grunt
and will be modified for Careena next.
BUG=b:79704826
BRANCH=none
TEST=Grunt still boots ok.
Change-Id: I6dd0035bdd62e92a7f3664120fc6ac3f23a0af4d
Signed-off-by: Edward Hill <ecgh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1070988
|