| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
After kukui rev 4, we use an external chip to provide db voltage
(CL:*1584487), limit the display bias setup code to rev 2&3 only.
BUG=b:140136293
TEST=manually
BRANCH=master
Change-Id: I689b0f0e5995dd0fcef0d69b8ecb9052ac62db46
Signed-off-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1790568
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Sean Abraham <seanabraham@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Recent tcs3400 driver change requires board file to provide a conversion
matrix to convert raw data into lux value. The coeffcients requires some
complex step to measure (b:139366662), before the measurement is done,
we need some non-precise value instead of the default zero matrix for
functional test in next build.
Based on the observation in b:135166710, I pick Y(lux) = C/10 in this
CL.
BUG=b:139366662
TEST=`cat /sys/bus/iio/devices/*/in_illuminance_input`,
verify that the sensor readings is around 250 on my desk.
(according to wikipedia, office lighting is around 320~500 lux, 250
is a little bit low, but good enough for ALS functional test)
BRANCH=master
Change-Id: I46cb417b919c40de6a81ce9254fcd2bcb51c0d5f
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1763897
Tested-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Sean Abraham <seanabraham@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The function is shared across all mt6370 users, move it to a common
place.
BUG=b:140156596
TEST=make
BRANCH=master
Change-Id: I7a9dafa5aafd078d997afe82fe7e0c555ecb5006
Signed-off-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1797196
Tested-by: Xiong Huang <xiong.huang@bitland.corp-partner.google.com>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Reviewed-by: Xiong Huang <xiong.huang@bitland.corp-partner.google.com>
Commit-Queue: Zhuohao Lee <zhuohao@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The switch should be set to inform AP of base status change.
TEST=event_path=$(grep cros_ec_buttons /sys/class/input/event*/device/name \
| sed -nE 's|.*(/input/event[0-9]*)/.*|/dev\1|p' | head -n 1)
evtest --query "${event_path}" EV_SW SW_TABLET_MODE
ensure the return code is 0 (for success).
BUG=b:140608847
BRANCH=none
Change-Id: I4ae2a783e7fc3ebbf42fdf0ff0e9a17630631e5d
Signed-off-by: Yilun Lin <yllin@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1795723
Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
Commit-Queue: Nicolas Boichat <drinkcat@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BUG=b:139012899
TEST=observe the charging curve (see issue above for result)
BRANCH=none
Change-Id: Ic4e6368763db4d741d82fc233e63e428fb67e610
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1755882
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
enable dp on jacuzzi, and add back the dp implementation before
CL:1660524 for all new devices including jacuzzi.
usb_pd_policy now supports two different configs:
- kukui/krane, rev <= 4: no mux (CONFIG_USB_MUX_VIRTUAL defined)
- all new devices: have a real mux
BUG=b:135895590,b:135079572
TEST=attach a usb hub and moniter to the dut,
verify that dp/dp+mux mode and both polarities can detected
correctly
BRANCH=master
Change-Id: I3e4757c97d555a4afb48076fc4785305c96b0a7f
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1723892
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
An it5205 is added in kukui/krane rev 5, and deprecated gpio pin
USB_C0_DP_OE_L and USB_C0_DP_POLARITY.
This CL is intended to make the fw works for both old and new boards:
1) the default usb_mux driver is updated to rev 5, and board_rev_init
may change it back for old boards.
2) keep VARIANT_KUKUI_DP_MUX_GPIO in kukui/board.h, and add a customized
function to set/clear these gpio pins.
BUG=b:135079572
TEST=verify that type c display works on board rev 4/5
BRANCH=master
Change-Id: Ibe28816eed026ccb8a9a5234a612f80b038884f1
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1785197
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
RESET_FLAGS_* are used when setting/reading the field ec_reset_flags of
struct ec_response_uptime_info, which is defined in ec_commands.h. So it
might be better to put those macros there.
To be consistent with the other macros in the file, add "EC_" prefixes
to them.
BUG=b:109900671,b:118654976
BRANCH=none
TEST=make buildall -j
Cq-Depend: chrome-internal:1054910, chrome-internal:1054911, chrome-internal:1045539
Change-Id: If72ec25f1b34d8d46b74479fb4cd09252102aafa
Signed-off-by: You-Cheng Syu <youcheng@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1520574
Tested-by: Yu-Ping Wu <yupingso@chromium.org>
Commit-Ready: Yu-Ping Wu <yupingso@chromium.org>
Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Reviewed-by: Daisuke Nojiri <dnojiri@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>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Update board files for akemi, flapjack, hatch, kohaku,
and kukui to use new field names in als_calibration_t and
als_channel_scale_t.
BUG=b:124512628
BRANCH=master
TEST='make buildall' of the EC, verified builds succeed.
Cq-Depend: chromium:1633269
Change-Id: I7ee324ce3de3377cd1538b631f4ec6294d2e9078
Signed-off-by: Nick Vaccaro <nvaccaro@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1711958
Reviewed-by: Gwendal Grignou <gwendal@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Apply the new option in CL:1575050 to Kukui devices with MT6370.
TEST=Verify that krane is able to detect BC12 DCP.
BUG=b:122866184
BRANCH=None
Change-Id: I18f17af3672a364952779dcc2ee19b05b0459e20
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1753566
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Functions such as board_fill_source_power_info are overridable. This
patch annotates them properly using override macros, and removes their
declarations from board.h.
These functions are declared in both charge_manager.h and
{kukui,krane,kodama}/board.h. The latter causes comm-dev.c to fail
to be compiled in chrome-base/diagnostics.
BUG=none
BRANCH=none
TEST=buildall
Change-Id: I27d6dfe2fa9299550ac5205c34095a4fe02dabdb
Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1752597
Tested-by: Yu-Ping Wu <yupingso@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Calling board_pogo_charge_init() when DEDICATED_CHARGE_PORT disabled
causes buffer overflow inside charge manager, move the function to a
suitable place to fix the issue.
BUG=b:138741956
TEST=flash and verify that kukui is bootable
BRANCH=master
Change-Id: I43d8aabf8fd21ed62a37671ba7cd471c8c188b9f
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1731212
Tested-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Yilun Lin <yllin@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
i2c_ports[] should have one entry for each port, not for each i2c
slave
BUG=None
TEST=verify that `i2cscan` only scans port 0 and 1 once.
BRANCH=master
Change-Id: I457c780fabd7bb68a5dc8871236a080d2fc6f332
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1729097
Tested-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This CL includes two major changes:
- set input current in board_set_charge_limit() instead of
charger_profile_override().
- remove board revision constraint, apply the fix to all kukui/kranes.
BUG=b:134227872
TEST=manually, boot with new fw and measure the power.
BRANCH=master
Change-Id: Ib826e805990fe3e9af5a88c231825bd477592e49
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1730378
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Initial version of jacuzzi ec.
The files are basically copied from board/kukui/, battery and charger
configured to the correct i2c port and component, and pogo / sensor
removed.
BUG=b:135895590
TEST=verify that this is bootable on a Jacuzzi, charger and battery
looks good, and no error message spamming on ec console.
BRANCH=master
Change-Id: Ia786076c08019dd2aa1711a68ff1c82cc7fa45ed
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1673955
Tested-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Alexandru M Stan <amstan@chromium.org>
Reviewed-by: Alexandru M Stan <amstan@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This CL introduces config option VARIANT_KUKUI_BATTERY_* and
VARIANT_KUKUI_CHARGER_* for derivatives to pick their battery / charger
option.
BUG=b:137172860
TEST=build and deploy on Krane, verify that `battery` and `charger`
console output looks reasonable.
BRANCH=master
Change-Id: Ic5c33a233ec30c9bc71414c95603157301281041
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1697781
Reviewed-by: Alexandru M Stan <amstan@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Create a baseboard to reduce the effort of forking and maintaining kukui
derivatives.
This CL is intended to just moving things around, with minimal changes
to make compiler happy, complex logic changes will implement in subsequent
CLs.
BUG=b:137172860
TEST=build and deploy on a Krane
BRANCH=master
Change-Id: Ifd3ad5c3b03dce101cd15cbcec304f5e3a1081ac
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1695562
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This should apply to all Kranes.
BUG=b:131081336
TEST=factory accelometer test
BRANCH=master
Change-Id: I44313d73bf6dd484101973e153c6b5209128a789
Signed-off-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1687832
Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Confirmed by HW eng, this fix should apply to all board revisions.
BUG=b:133655155
TEST=none
BRANCH=master
Change-Id: I20a72ec744c6d6fbf08d0cf57ad78902e35c2df9
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1679784
Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The extentions were added to make the compiler perform most
of the verification that the conversion was being done correctly
to remove 8bit addressing as the standard I2C/SPI address type.
Now that the compiler has verified the code, the extra
extentions are being removed
BUG=chromium:971296
BRANCH=none
TEST=make buildall -j
TEST=verify sensor functionality on arcada_ish
Change-Id: I36894f8bb9daefb5b31b5e91577708f6f9af2a4f
Signed-off-by: Denis Brockus <dbrockus@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1704792
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Opt for 7bit slave addresses in EC code. If 8bit is
expected by a driver, make it local and show this in
the naming.
Use __7b, __7bf and __8b as name extensions for i2c/spi
addresses used in the EC codebase. __7b indicates a
7bit address by itself. __7bf indicates a 7bit address
with optional flags attached. __8b indicates a 8bit
address by itself.
Allow space for 10bit addresses, even though this is
not currently being used by any of our attached
devices.
These extensions are for verification purposes only and
will be removed in the last pass of this ticket. I want
to make sure the variable names reflect the type to help
eliminate future 7/8/7-flags confusion.
BUG=chromium:971296
BRANCH=none
TEST=make buildall -j
Change-Id: I2fc3d1b52ce76184492b2aaff3060f486ca45f45
Signed-off-by: Denis Brockus <dbrockus@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1699893
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove unused clode blocks and includes.
BUG=None
TEST=make
BRANCH=master
Change-Id: I66994039e4c215ce652cdef227207a6bbd94b316
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1692364
Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is needed to support CCD testing of UART to USB bridging.
BRANCH=none
BUG=b:38448364
TEST=ran 'make BOARD=kukui -j', verified that command is included in
the symbol map.
Change-Id: I675df026c16b5c0b07ed55c99aa5e8b333fd0fab
Signed-off-by: Vadim Bendebury <vbendeb@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1688136
Reviewed-by: Yilun Lin <yllin@chromium.org>
Reviewed-by: Namyoon Woo <namyoon@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
According to the comments in CL:1666260, we don't need it anymore.
BUG=b:129430139
TEST=make
BRANCH=master
Change-Id: I98944518e1e70d2a2ea2a607b3dfd478f9c09e55
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1679855
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CONFIG_MKBP_WAKEUP_MASK is a bit confusing and is wrongly named. The
comment stated that "With this option, we can define the MKBP wakeup
events in this mask (as a white list) in board level, those evets allow
to interrupt AP during S3.". However, these events are NOT MKBP events
at all but are instead host events. This commit tries to clear things
up by renaming CONFIG_MKBP_WAKEUP_MASK to
CONFIG_MKBP_HOST_EVENT_WAKEUP_MASK to better show that these events are
in fact host events.
BUG=b:136282898
BRANCH=None
TEST=`make -j buildall`
Change-Id: I42beadec8217435fd30e679ccf52d784a8ef99a0
Signed-off-by: Aseda Aboagye <aaboagye@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1685784
Tested-by: Aseda Aboagye <aaboagye@chromium.org>
Reviewed-by: Alexandru M Stan <amstan@chromium.org>
Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
TEST=make BOARD=krane analyzestack section=RW, and see no tasks
uses stack more than it could.
BUG=b:135992789
BRANCH=none
Change-Id: Ic28b5fed5db35f001fad71ec64db511c700cf614
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1677979
Tested-by: Youcheng Syu <youcheng@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Yilun Lin <yllin@chromium.org>
Auto-Submit: Yilun Lin <yllin@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
TEST=make BOARD=kukui analyzestack
BUG=b:135992789
BRANCH=none
Change-Id: Ie5e6447a353e9115199cbab1c5147b95ecfbfdb6
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1677978
Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
Tested-by: Yilun Lin <yllin@chromium.org>
Auto-Submit: Yilun Lin <yllin@chromium.org>
Commit-Queue: Nicolas Boichat <drinkcat@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a new kodama folder and BOARD configuration for
Kodama.
BUG=b:135490566
BRANCH=None
TEST=1. emerge-kukui chromeos-ec
2. check coreboot binary could be generated under
the /build/chroot/kukui/firmware/kodama/.
Change-Id: Ia48243ce59597e7f0b85ff46a4c71eb5bbb30661
Signed-off-by: peichao.wang <peichao.wang@bitland.corp-partner.google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1666340
Reviewed-by: Zhuohao Lee <zhuohao@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BUG=b:129419982
TEST=Combined with CL:1621449, run ectool motionsense.
BRANCH=None
Change-Id: I028f9a286ba96d7813bb76ba5e1e5235955e40b3
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1628630
Reviewed-by: Yilun Lin <yllin@chromium.org>
Reviewed-by: Nick Vaccaro <nvaccaro@google.com>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Kukui doesn't have superspeed lanes, we should avoid
using such pin assginments.
Also,
1. update usb_mux on receiving DP config packet accordingly, and
2. fix usb_mux setting by removing usb_mux update when receiving DP
attention packet. We should inform DP mux on at DP config, and
DP mux off at DP safe mode.
TEST=print choosed pin mode, and see it choose PIN_C rather than PIN_D.
TEST=Plug hub JCA-374 and see the external display is functional.
BUG=b:135079572
BRANCH=master
Change-Id: Id1edfc5b1962dbef7e5ab79c512d8f2c568777e8
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1660524
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Tested-by: Yilun Lin <yllin@chromium.org>
Auto-Submit: Yilun Lin <yllin@chromium.org>
Commit-Queue: Yilun Lin <yllin@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1. Move the charging dock detection logic from POGO_VBUS_PRESENT
interrupt to POGO_ADC_INT_L interrupt. (see issue below for more
context).
2. Since the analog pin in STM32F0 can not trigger interrupt, the pin is
now an input pin, and programmed as an analog pin only when need to read
its value.
BUG=b:132419493
TEST=Manually, verify that the value of EN_POGO_CHARGE_L,
EN_USBC_CHARGE_L and EN_PP3300_POGO are correct when fake device
attached.
BRANCH=None
Change-Id: Idd468f06516a614e07aa357ffe215846314a435b
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1604548
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
Auto-Submit: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- checks pogo present in extpower_present()
- implemented customized discharge_on_ac, we can't really discharge on
pogo, so only set charge to NONE when force discharging.
BUG=b:127767432,b:128386458
TEST=None
BRANCH=None
Change-Id: I2ffb6a69f102b9e10eff0a7794e04516055fac9d
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1549811
Tested-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Auto-Submit: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added a dedicated(POGO) charge port and related costomization
functions.
BUG=b:128386458
TEST=`gpioset POGO_VBUS_PRESENT 0/1` to simulate pogo charger
presence, and a normal usb charger for usb port to check its behavior.
BRANCH=None
Change-Id: If102c57088f1aafee437c7cc912992dc0cf8e9da
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1535087
Reviewed-by: Yilun Lin <yllin@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Auto-Submit: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is a short term fix to prevent charger overheat.
BUG=b:134227872
TEST=manually, boot with the new fw and measure the power.
BRANCH=master
Change-Id: I88c3444f0a0c0c9a755579fcb1f9c52fc032a179
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1642478
Tested-by: Tony Lin <tonycwlin@google.com>
Tested-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Enable LTO to earn more flash spaces.
This saves 0x17cd0 - 0x1686c = 5220 bytes.
TEST=make BOARD=kukui
BUG=b:120588396
BRANCH=master
Change-Id: Id69c3f5af470d6d03170d00bc00c1e8e0699ba97
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1663540
Commit-Queue: Yilun Lin <yllin@chromium.org>
Tested-by: Yilun Lin <yllin@chromium.org>
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
Auto-Submit: Yilun Lin <yllin@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
mag should be in s0/s3, other looks good.
BUG=b:135234999
TEST=make
BRANCH=none
Change-Id: Id25f8ec5e3a6a530590025a9d337c59da9b92cfc
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1660521
Tested-by: Ting Shen <phoenixshen@chromium.org>
Auto-Submit: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
High display current results to a broken display on Krane rev3.
Karne rev3 can only support up to 90mA current to backlight LED.
We should limit this value from 120mA(maximun) to 90mA.
TEST=i2cxfer r 0 0x68 0xa4; see 0x07
i2cxfer r 0 0x68 0xa5; see 0xbf
combine these two value we have 0x5ff which is 0x7ff * 90/120;
BUG=b:133655155
BRANCH=None
Change-Id: I809628fcc71145801f9fb82815ae40f77a91e2e9
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1635138
Tested-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Yilun Lin <yllin@chromium.org>
Auto-Submit: Yilun Lin <yllin@chromium.org>
Reviewed-by: Alexandru M Stan <amstan@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
According to
chromium.googlesource.com/chromiumos/docs/+/master/debug_buttons.md,
we should support debug mode to blink LED while holding
Vol-Up + Vol-Down for ten seconds.
TEST=hold vol-up + vol-down for ten seconds, and see green led blinking.
BUG=b:134654616
BRANCH=master
Change-Id: Ic6cc2f382412a89366a145c0c309e71d98cd8cb7
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1654763
Tested-by: Yilun Lin <yllin@chromium.org>
Tested-by: Tony Lin <tonycwlin@google.com>
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Yilun Lin <yllin@chromium.org>
Auto-Submit: Yilun Lin <yllin@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reset LED prv_chstate so that the LED light can be updated immediately
when the led controlled status goes from manual to auto.
TEST=Plug charger; see blue led
ectool led battery red=1; see red led
ectool led battery auto; see blue led immediately.
BUG=None
BRANCH=master
Change-Id: I4f5029d708df8f9c31c6c5ee8b51003648a4ff9e
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1654762
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Tested-by: Yilun Lin <yllin@chromium.org>
Auto-Submit: Yilun Lin <yllin@chromium.org>
Commit-Queue: Yilun Lin <yllin@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Most DCP chargers supply 5V/2A, and we want kukui to drain as
much power as possible for such chargers.
TEST=Plug a DCP 5V/2.1A charger and see it ramps and drains up to 1.75A,
rather than original 1.34A.
BUG=b:131284131
BRANCH=None
Change-Id: I56ff4454036dd148cce6fcfbf80222a37c68e544
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1610385
Reviewed-by: Yilun Lin <yllin@chromium.org>
Commit-Queue: Yilun Lin <yllin@chromium.org>
Tested-by: Yilun Lin <yllin@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Also, remove RTC wake source, as we do not enable the option on
kukui EC (we, instead, use the PMIC RTC as a wake source).
BRANCH=none
BUG=b:134467901
TEST=powerd_dbus_suspend => lid switch wakes the system
Change-Id: Ib3eab0b63f2185a8cb0b50ee4f4a01d58d4ad20e
Signed-off-by: Nicolas Boichat <drinkcat@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1644599
Reviewed-by: Yilun Lin <yllin@chromium.org>
Reviewed-by: Claire Chang <tientzu@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, tcpc_config assumes TCPCs are on I2C bus. ITE's EC has an
embedded TCPC.
This patch adds bus_type field to struct tcpc_config_t so that a TCPC
location on other type of bus can be specified.
Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org>
BUG=none
BRANCH=none
TEST=buildall
Change-Id: Ieac733011700b351e6323f46070dcf46d9e1154b
Reviewed-on: https://chromium-review.googlesource.com/1640305
Commit-Ready: Daisuke Nojiri <dnojiri@chromium.org>
Tested-by: Daisuke Nojiri <dnojiri@chromium.org>
Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org>
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Compass removed on Krane, remove it from ec code too.
BUG=b:134550825
TEST=ectool motionsense, ectool motionsense info 0/1/2,
verify there's only 3 sensors (accel/gyro/vsync)
BRANCH=master
Change-Id: Id5c16a61462680ce9bec959a8923f7c5ca46ed29
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1645193
Reviewed-by: Yilun Lin <yllin@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes requires all boards to define the maximum number
of sensors they support. This will allow us to later create
static arrays with the appropriate length.
BUG=chromium:966506
BRANCH=None
TEST=make buildall
Change-Id: I5a2fa8f0fdcaef69065dfd4c2bfea4e3f371e986
Signed-off-by: Yuval Peress <peress@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1637414
Reviewed-by: Jett Rink <jettrink@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use the company name of battery pack, not gauge.
BUG=None
TEST=make
BRANCH=None
Change-Id: Ie7b8b807f3952c1cd58b7f36dd717ed2edc43cb4
Signed-off-by: Ting Shen <phoenixshen@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1635333
Reviewed-by: Ayo Wu <ayowu@chromium.org>
Reviewed-by: Yilun Lin <yllin@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Krane's display bias is controlled by mt6370.
Adjust the settings according to the panel which krane uses.
Also, discharge VNEG/VPOS when the rails are disabled.
TEST=i2cxfer r 0 0x68 0xb1; see output 0x36
i2xcfer r 0 0x68 0xb2; see output 0x68
i2xcfer r 0 0x68 0xb3; see output 0x64
i2xcfer r 0 0x68 0xb4; see output 0x64
BUG=b:125644770
BRANCH=None
Change-Id: Ifdda9c9ccc2486009179cbc94cfbf79cb4d04926
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/1632132
Commit-Ready: Yilun Lin <yllin@chromium.org>
Tested-by: Yilun Lin <yllin@chromium.org>
Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org>
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Correct battery charging current from 2A to 3.5A according to datasheet.
BUG=b:133584769
TEST=make BOARD=kukui/krane, check the charging current in battery info.
BRANCH=none
Change-Id: I5a4a67d078c4b53cdf30ccc99a16498f1978b34e
Signed-off-by: Tony Lin <tonycwlin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/1630130
Legacy-Commit-Queue: Commit Bot <commit-bot@chromium.org>
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Support hall covering/uncovering over lid close/open.
TEST=Emulate hall cover and see system goes down.
TEST=Emulate hall uncover and see system goes up.
BUG=b:111378000
BRANCH=None.
Change-Id: I56c0b45ba8b005c98877c2830e2320368788f04a
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/1388236
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Tested-by: Yilun Lin <yllin@chromium.org>
Reviewed-by: Nicolas Boichat <drinkcat@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The charging limitation strategy is too conservative: it turns the
charging voltage to 5V once the battery SOC hits 86 percent. However,
this will make the battery SOC bouncing between 85 and 86 percent
if connected to a external powered hub which can only do 500mA
at 5V (2.5W) and that is not enough to charge the device.
This CL looses the charging limitation strategy by taking IBAT into
consideration. The strategy is proposed by vendor. When the battery
is almost fully charged, IBAT will become smaller and smaller. This CL
sets the IBAT limit to 1A, which is still quite large current, but is
enough to charge battery SOC closing to 99 percent.
It fixes: Battery SOC won't stuck at 85 percent with such hub, now it
can reach 99 percent without damaging the chip.
BRANCH=None
BUG=b:128364884
TEST=- Charge krane with PD charger and see the PD voltage will be
limited to 5V when SOC > 85% and IBAT <= 1A.
- When PD voltage been limited to 5V, unplug charger, and wait for
the SOC drops a little (95 -> 94) then plug a PD charger, and
see the PD voltage limit been changed to 12.85V.
Change-Id: I7bbdf242ff1568e3595252346eb0a3d7b3ac57ff
Signed-off-by: Yilun Lin <yllin@google.com>
Reviewed-on: https://chromium-review.googlesource.com/1560811
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Tested-by: Yilun Lin <yllin@chromium.org>
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
|