| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In the interest of making long-term branch maintenance incur as little
technical debt on us as possible, we should not maintain any files on
the branch we are not actually using.
This has the added effect of making it extremely clear when merging CLs
from the main branch when changes have the possibility to affect us.
The follow-on CL adds a convenience script to actually pull updates from
the main branch and generate a CL for the update.
BUG=b:204206272
BRANCH=ish
TEST=make BOARD=arcada_ish && make BOARD=drallion_ish
Signed-off-by: Jack Rosenthal <jrosenth@chromium.org>
Change-Id: I17e4694c38219b5a0823e0a3e55a28d1348f4b18
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3262038
Reviewed-by: Jett Rink <jettrink@chromium.org>
Reviewed-by: Tom Hughes <tomhughes@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When compiling with clang it warns that the function is unused:
driver/accelgyro_lsm6dsm.c:45:29: error: unused function 'get_fifo_type'
[-Werror,-Wunused-function]
static inline enum dev_fifo get_fifo_type(const struct motion_sensor_t
*s)
BRANCH=none
BUG=b:172020503
TEST=make CC=clang V=1 BOARD=arcada_ish
Signed-off-by: Tom Hughes <tomhughes@chromium.org>
Change-Id: Ibc52e25a2f750e8da8335e7835475db7a5d42670
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3193275
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Many platforms have requirements to support more than one charge
source (eg. pirika). It can't be supported by just enabling two
different CONFIGS as that can lead to conflicts.
Eg.USD_PD_VBUS_DETECT_TCPC vs USB_PD_VBUS_DETECT_DISCHARGE.
This change provides a framework that supports two different charger
sources in the same build. Please see the CL for relevant logs.
BRANCH=None
BUG=b:194375840
TEST=make -j buildall
Signed-off-by: Parth Malkan <parthmalkan@google.com>
Change-Id: I309cc5930233983e615d90a4290fc749abf7aa2d
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3088232
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Thermistor drivers now query the device tree for configuration.
Thermistor tests have been updated to be parameterized
on all thermistors enabled in the device tree.
BRANCH=none
BUG=b:184374937
TEST= 1) zmake testall
2) make runhosttests
Cq-Depend: chromium:3161332
Signed-off-by: Aaron Massey <aaronmassey@chromium.org>
Change-Id: Ic5330cd5c33e79e192428ca857651de9a225856e
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3133812
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
Tested-by: Aaron Massey <aaronmassey@google.com>
Commit-Queue: Aaron Massey <aaronmassey@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the pd port has previous connection and supplies
Vconn, then RO jumping to RW reset the system,
we never know which cc is the previous Vconn pin,
so we always turn both cc pins off when disable
Vconn power switch.
BUG=b:199461325
BRANCH=none
TEST=on board haboki, RO jump to RW, check Vconn low
and pd can nego
Signed-off-by: Ruibin Chang <Ruibin.Chang@ite.com.tw>
Change-Id: I526af287d3f52ca27c38f342553aac9b3a241d84
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3178341
Reviewed-by: Diana Z <dzigterman@chromium.org>
Reviewed-by: Zick Wei <zick.wei@quanta.corp-partner.google.com>
Tested-by: Zick Wei <zick.wei@quanta.corp-partner.google.com>
Commit-Queue: Diana Z <dzigterman@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If the pd port has previous connection and supplies
Vconn, then RO jumping to RW reset the system,
we never know which cc is the previous Vconn pin,
so we always turn both cc pins off when disable
Vconn power switch.
This change is leveraged from it83xx (CL:3178341),
although Vconn is controlled by ppc on asurada series
and asurada series don't happen the bug, but we still
need this change for the future that if there is a
project control Vconn by GPIO.
BUG=none
BRANCH=none
TEST=make board hayato
Signed-off-by: Ruibin Chang <Ruibin.Chang@ite.com.tw>
Change-Id: I66e7961d5ba412c18948a433103c17b79e7c5e08
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3180703
Reviewed-by: Eric Yilun Lin <yllin@google.com>
Commit-Queue: Eric Yilun Lin <yllin@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove load_fifo_sensor_state_t since timestamp spreading is done in
common code.
Fixes: 4e6d315948 ("common: motion_sense: Spread timestamps in motion sense fifo")
BUG=b:172342141
BRANCH=none
TEST=buildall
Change-Id: If47fdd5dc800e6b75bdea4fcef80cf6874debdaa
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3150052
Reviewed-by: Yuval Peress <peress@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit f0985f8a11585f6a704aa94a8354bd5b934619ac.
Reason for revert: Issue is resolved after setting the Force BB Retimer GPIO
(GPP_E4) to 0. It is a coreboot change.
BUG=b:195375738
BRANCH=None
TEST=TBT enumerated no lane bonding issue is observed with above
coreboot code change with reverted EC WA.
Signed-off-by: madhusudanarao amara <madhusudanarao.amara@intel.corp-partner.google.com>
Change-Id: I09a8a53aec9ba3757189a091606922bc7a133ba7
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3162936
Reviewed-by: Deepti Deshatty <deepti.deshatty@intel.corp-partner.google.com>
Reviewed-by: caveh jalali <caveh@chromium.org>
Reviewed-by: Vijay Hiremath <vijay.p.hiremath@intel.com>
Commit-Queue: caveh jalali <caveh@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Remove unnecessary structure:
- bmi3_fifo_data, bmi3xx_drv_data
- put static buffer in local bmi3_fifo_frame
- Tighten interrupt routine
- Use word to avoid intermediate copy
- Trust fifo configuration from fifo_enable.
- Process FIFO until interrupt indicates it is empty.
- Simplify bmi3_parse_fifo_data
- Use loop to avoid code duplication.
- Remove intermediate variable.
- Use word to process FIFO.
- Remove blank lines, use inverted christmas tree convention.
- Use constant when appropriate.
- Set FIFO watermark to 3 words to catch single acceleromter
event when gyroscope is disabled.
BUG=b:195264765,b:178398789
BRANCH=none
TEST=Run `tast run guybrushlocal hardware.SensorIioserviceHard'
in loop.
Change-Id: I55da91a557b8c51f707dc29b4867cc715dce2cca
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3170618
Reviewed-by: Diana Z <dzigterman@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 5786cdd32f9d8ba7da8b2d9764b06dfeb991f5ff.
FIFO is not always 6 words: When the gyroscope is disabled,
the FIFO will only contains 3 words.
BUG=b:178398789,b:195264765
BRANCH=none
TEST=Compile
Cq-Depend: chromium:3170618
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Change-Id: I1cc0f6e31bb06a2ea11a815ea1f360766fb5d474
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3172267
Reviewed-by: Diana Z <dzigterman@chromium.org>
Reviewed-by: Rob Barnes <robbarnes@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CCGXXF exposes I2C addresses 0x0B for 1st port & 0x1B for second port
hence corrected the I2C address flags in header file.
BUG=none
BRANCH=none
TEST=Able to initialize second Type-C port
Change-Id: I9dc955d1035b1f488e92a47cdac49bdd6154f4ae
Signed-off-by: Vijay Hiremath <vijay.p.hiremath@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3172253
Reviewed-by: Tanu Malhotra <tanu.malhotra@intel.com>
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The loop condition for the soft reset was incorrect, on a failure to
read the soft reset register, the loop would hit the `continue`
command which would then test
(status & LIS2DW12_SOFT_RESET_MASK) != 0 and leave us at the mercy
of the status value left on the stack.
BRANCH=none
BUG=b:200046770
TEST=zmake configure --test zephyr/projects/drivers
Signed-off-by: Yuval Peress <peress@chromium.org>
Change-Id: Iebeafe9c57c71713a1df5230e60ac067209ec5b2
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3170538
Commit-Queue: Yuval Peress <peress@google.com>
Tested-by: Yuval Peress <peress@google.com>
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Use the value in ret during the lis2dw12_init function to differentiate
between errors.
BRANCH=none
BUG=b:200046770
TEST=make buildall -j
Signed-off-by: Yuval Peress <peress@chromium.org>
Change-Id: Id31f01e09ff1305a4cd0ab14d56a05172a263760
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3170536
Commit-Queue: Yuval Peress <peress@google.com>
Tested-by: Yuval Peress <peress@google.com>
Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This adds the low level chip ID of the ps8815 A2 so we can recognize the
chip when its main firmware is inoperative.
BRANCH=none
BUG=b:186189039
TEST=with next patch in series, verified the brya EC reports the correct
device ID when the firmware is corrupted.
Change-Id: I2696b9c20fdefd8afd02f7394a45f1c4c5636d71
Signed-off-by: Caveh Jalali <caveh@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2857796
Reviewed-by: Boris Mittelberg <bmbm@google.com>
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now that the BB retimer has its own HPD update function, the extra mux
set can be removed from the general USB mux code.
BRANCH=None
BUG=b:195773400
TEST=on voxel, pass tast typec.Mode*.manual
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: Ica83c2c568799d7686d8cfdbc5b0f446a6ebcb8f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3163931
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The BB retimer may use a simple read/modify/write on its configuration
register to set HPD fields, rather than needing to rely on a call to a
full mux set later to achieve this. Introduce an API so boards using
the BB retimer may move to using this function.
BRANCH=None
BUG=b:195773400
TEST=make -j buildall
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: Iae87c0860350fed32f69e0ea3b6530cd7e5ba111
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3163929
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, the EC doesn't always wait for an ACK from the virtual mux
but it will still always send the AP ACK onto the PD task. This means
we have some risk of a previous ACK being present in the task events
already when we begin a new wait. Remove this risk by only sending the
event to the task when there is a task waiting.
BRANCH=None
BUG=b:186777984
TEST=tast typec.Mode*.manual tests on voxel
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: I1e4cf96af838c0cbe4ef549337b304679b59d641
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3078414
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, there are three separate tasks which can access the muxes at
once (host command, PD, and chipset). As such, locking should help
coordinate sets and gets to each port.
BRANCH=None
BUG=b:172222942
TEST=tast typec.Mode*.manual on voxel
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: I003a2eee06e4b44241308d8b64da597bd17c8878
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3078413
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since the drivers are now taking a mux_state_t set of flags to update,
go ahead and unify the usb_mux API this way as well. It makes the
parameters more apparent than the 1/0 inputs, and aligns the stack to
use the same parameters.
BRANCH=None
BUG=b:172222942
TEST=make -j buildall
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: Ie943dbdf03818d8497c0e328adf2b9794585d96e
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3095438
Commit-Queue: Abe Levkoy <alevkoy@chromium.org>
Reviewed-by: Abe Levkoy <alevkoy@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This CL moves RT1718S gpio control from board file to common driver
codebase, and implements the set flag and get/set level functions.
Note that this CL does not fully implement IOEX interface because TCPC
has different init process than usual ioexpanders.
BUG=none
TEST=1) pass faft_pd
2) manually test pd source/sink/frs on port 1
BRANCH=main
Signed-off-by: Ting Shen <phoenixshen@google.com>
Change-Id: If2a0bca2b13ad4748eea54b4c8004da7dc6fc6a5
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3159643
Reviewed-by: Rong Chang <rongchang@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The sensor_num should match the sensor index of the sensor that produced
the data. It was incorrectly set to sens_cnt, which is just the offset
of the sensors on the bmi3xx.
BUG=b:195264765, b:197186738
TEST=Passed the following tests on guybrush:
iioservice_simpleclient --channels='accel_x' --frequency=12.5 --device_id=2 --samples=1
run cts -m CtsSensorTestCases -t android.hardware.cts.SensorBatchingTests#testAccelUncalibrated_50hz_batching
BRANCH=None
Change-Id: Id51ea52a0426fc50a5001437e720eedf41c333ad
Signed-off-by: Rob Barnes <robbarnes@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3150058
Reviewed-by: Diana Z <dzigterman@chromium.org>
Reviewed-by: Gwendal Grignou <gwendal@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Allow better code coverage by checking return codes in various internal
static functions.
BRANCH=none
BUG=b:184856083
TEST=make buildall -j
Signed-off-by: Yuval Peress <peress@chromium.org>
Change-Id: I28afe0538ed9ac98d4ecb9c499d218cd11cbc1ca
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3158736
Commit-Queue: Yuval Peress <peress@google.com>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Tested-by: Yuval Peress <peress@google.com>
Auto-Submit: Yuval Peress <peress@google.com>
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Abe Levkoy <alevkoy@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
KSO mapping array need to follow the different circuit design,
so change this array to overridable.
BUG=b:199337186
BRANCH=none
TEST=make buildall -j4
Signed-off-by: Tim Lin <tim2.lin@ite.corp-partner.google.com>
Change-Id: I3ee0ceffbdb50cf9282cda6039c4a44ebe445bd0
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3151045
Reviewed-by: Eric Yilun Lin <yllin@google.com>
Commit-Queue: Eric Yilun Lin <yllin@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Put list_activities in common code, as it is used by both BMI160 and
BMI260 driver.
Fixes cb3771973de ("Coachz: MotionSensor: Avoid redefine gesture function list_activites")
Fixes fc298a0ada0 ("driver: bmi260: integrate body detection")
BUG=b:195908820
BRANCH=trogdor
TEST=buildall
Change-Id: I05591954c825802502328c842b03e8934c497f08
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3150056
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a loop in irq_handler to match datasheet documentation:
"""
1. Read the FIFO_STATUS1 and FIFO_STATUS2 registers to check how many
words are stored in the FIFO. This information is contained in the
DIFF_FIFO_[9:0] bits.
2. For each word in FIFO, read the FIFO word (tag and output data) and
interpret it on the basis of the FIFO
tag.
3. Go to step 1.
"""
We need to read the FIFO length at the end of the IRQ handler to be
sure a new item has not been put while the FIFO was being read.
Otherwise, we will not get interrupt and will stop processing FIFO when
the FIFO status register still shows the FIFO as not empty.
However, using linux kernel st_lsm6dsx_read_tagged_fifo() as model,
read only one word at a time:
When reading 2 7bytes word at time, the FIFO would still claim one entry
remains: The 3rd entry would be a copy of the accelerometer data, but
with a corrupted z axis.That why we fail the data test, the gravity
vector is not measured at 9.81m/s^2.
There was a bug in the interrupt handler that would read the FIFO twice,
which was presenting the data: both gyro and accel at the same ODR:
[7623.475256 Base Accel FIFO status: 8002]
[7623.476548 Base Gyro sending vector num: 2
raw: 0x00000007 - 0xFFFFFFF6 - 0xFFFFFFF9]
[7623.477526 Base Accel sending vector num: 1
raw: 0xFFFFFFCC - 0xFFFFE275 - 0xFFFFE818]
[7623.479271 Base Accel FIFO status: 8001]
[7623.480333 Base Accel sending vector num: 1
raw: 0xFFFFFFCC - 0xFFFFE275 - 0x00000C18]
[7623.481699 Base Accel FIFO status: 0000]
We must only run the irq_hanlder for the main/accelerometer sensor.
Restructure irq_hanlder to match other driver, like accelgyro_bm160.c.
BUG=b:195700255,b:192219470
BRANCH=dedede
TEST=Running tast run <ip> hardware.SensorIioserviceHard
Check we get the right amount of samples.
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Change-Id: I5820dec4c7c5ccb1ebeda854398738d1af60290c
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3150679
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Rename LSM6DSO_FIFO_ODR_TO_REG into LSM6DSO_FIFO_ODR_MASK as the macro
return the mask to use to set the FIFO ODR.
Remove CONFIG_EC_MAX_SENSOR_FREQ_MILLIHZ in code, as already used in
LSM6DSO_ODR_MAX_VAL.
Simplify LSM6DSO_ST_DATA by using . instead of ->.
BUG=none
BRANCH=deded
TEST=buildall
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Change-Id: I4253368415635c858ce181f228591e8bf93eacb9
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3150678
Reviewed-by: Keith Short <keithshort@chromium.org>
Reviewed-by: Yuval Peress <peress@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The buffer is allocated on the stack. It is currently 32*6 bytes.
This is unnecessarily large as we set the FIFO threshold at 1.
Reduce it to 8*6 bytes, the gain of long I2C transactions is negligible
and we save some space in the stack.
BUG=none
BRANCH=none
TEST=buildall
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Change-Id: I8b6f9f2bdfe27206d049c1fe0b82df4caaadce09
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3150677
Reviewed-by: Keith Short <keithshort@chromium.org>
Reviewed-by: Yuval Peress <peress@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Added code to enable GPIO based interrupts on it8801
I/O Expander.
BUG=b:197659347
BRANCH=none
TEST=Tested on ADL-RVP able to get ISR triggered
Change-Id: I7f5f460f48fc21e51bb93bede5a05da89b7dc807
Signed-off-by: Vijay Hiremath <vijay.p.hiremath@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3076469
Reviewed-by: Keith Short <keithshort@chromium.org>
Reviewed-by: Dino Li <Dino.Li@ite.com.tw>
Commit-Queue: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To avoid BOM stuffing options on RVP, it8801 discrete keyboard with
I/O expander is added on RVP as an AIC in MECC1.1. This config allows
MECC vendors to easily switch between RAW keyboard or discrete
keyboard.
BUG=b:197659347
BRANCH=none
TEST=make buildall -j
Change-Id: I3b55eff0f5a1582daf63fca955954b8a42c1b7b2
Signed-off-by: Vijay Hiremath <vijay.p.hiremath@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3115433
Commit-Queue: Keith Short <keithshort@chromium.org>
Reviewed-by: Keith Short <keithshort@chromium.org>
Reviewed-by: Li Feng <li1.feng@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
To avoid the I2C address contention between multiple I2C devices
on same bus, added code to support multiple I2C addresses for
it8801 I/O expander.
BUG=none
BRANCH=none
TEST=make buildall -j
Change-Id: I6985973f9ae3ce91383d3b568a851169e6a308af
Signed-off-by: Vijay Hiremath <vijay.p.hiremath@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3115426
Commit-Queue: Keith Short <keithshort@chromium.org>
Reviewed-by: Keith Short <keithshort@chromium.org>
Reviewed-by: Ting Shen <phoenixshen@chromium.org>
Reviewed-by: Eric Yilun Lin <yllin@google.com>
Reviewed-by: Li Feng <li1.feng@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Two different functions controls the BC12_SNK_FUNC register, one is
bc12_init, another one is usb_charger_task. This causes a racing
condition happens during EC soft reset: bc12_init resets the
BC12_SNK_FUNC register to its initial value when usb_chg task starts
bc1.2 detection.
To solve this, let usb_chg task has full control of the register.
BUG=b:199226158
TEST=bc1.2 detection works after ec soft reset.
BRANCH=none
Signed-off-by: Ting Shen <phoenixshen@google.com>
Change-Id: Ie423e2d9ddad1e1fadb97e1b73b8b5e535121601
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3147512
Reviewed-by: Rong Chang <rongchang@chromium.org>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
| |
BUG=b:198689488
BRANCH=none
TEST=make -j BOARD=gimble
Signed-off-by: Scott Chao <scott_chao@wistron.corp-partner.google.com>
Change-Id: Ic9bd989bc8ff19d93e9b350a74ff9a0ddeb3cf60
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3139516
Reviewed-by: Boris Mittelberg <bmbm@google.com>
Commit-Queue: Boris Mittelberg <bmbm@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit is for motion sensor combine(BMI160 & BMI260),Avoid redefine
gesture function `list_activites`.
BUG=b:195908820
TEST=make -j BOARD=coachz
Verify build on SIT board
BRANCH=Trogdor
Signed-off-by: pengjunhao5 <pengjunhao5@huaqin.corp-partner.google.com>
Reviewed-by: tongjian <tongjian@huaqin.corp-partner.google.com>
Reviewed-by: yudengwu <yudengwu@huaqin.corp-partner.google.com>
Change-Id: If31442d0c00745d124b20188b4e5fad8a9a1d173
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3133188
Reviewed-by: Jian Tong <tongjian@huaqin.corp-partner.google.com>
Reviewed-by: Wai-Hong Tam <waihong@google.com>
Reviewed-by: Keith Short <keithshort@chromium.org>
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Commit-Queue: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There are two FIFO buffers for USB-PD packet reception. One is located
in TCPC, another was added in EC layer in crrev/c/1185727 . There are
scenarios that may lead to overflow.
In these scenarios, the EC RX circular buffer overflows without clearing
the TCPC ALERT# signal. This in turn results in a tight-loop in the TCPC
interrupt handler, leading to port "suspend".
This CL is a reduced hotfix to mitigate this scenario. Further CL is
needed to perform proper TCPCI spec-compliant overflow handling.
BRANCH=none
BUG=b:192382194
TEST=1. Connect CB282K via DP to G5 dock on old FW
2. Connect G5 dock to AKEMI on TCPMv1
3. Allow MST VDM:Attention communication to occur
4. Observe EC console prints via SuzyQ
Change-Id: Ic579a3763fc595b8250d4ca78c3942675450295a
Signed-off-by: Nathan K <nkolluru@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3135041
Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add BB retimer emulator on i2c bus. Emulator properties can be defined
using device tree or runtime emulator API. Emulator checks if RO
registers and reserved bits are accessed correctly. API allows to set
custom read/write i2c messagess handlers to emulate complex behaviour.
BUG=b:184856919
BRANCH=none
TEST=none
Signed-off-by: Tomasz Michalec <tm@semihalf.com>
Change-Id: I4b641a90e6fb55e89aaee388c0ac04ab7bf367ba
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3110085
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Yuval Peress <peress@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
CL:3084331 added logic to retry reading the PS8xxx FW version register
to ensure the chip has woken up from low power mode. If the PS8xxx
device is damaged/missing, there was an unbounded loop so the
initialization never completed, hanging the corresponding PD task.
BUG=b:198619831
BRANCH=none
TEST=Verify herobrine boots AP when the battery and right I/O board are
disconnected. Also observe "LPM recovery failed" reported on the
console for the missing type-C port.
Signed-off-by: Keith Short <keithshort@chromium.org>
Change-Id: I578f20a9a63dd54fc777dcc0acc26a7540a1bb46
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3139975
Reviewed-by: Michał Barnaś <mb@semihalf.com>
Reviewed-by: Wai-Hong Tam <waihong@google.com>
Commit-Queue: Wai-Hong Tam <waihong@google.com>
|
|
|
|
|
|
|
|
|
|
|
| |
BRANCH=none
BUG=none
TEST=make buildall -j
Signed-off-by: Yuval Peress <peress@chromium.org>
Change-Id: I7963baa87d6edbd208fb8bad5c80866f26527748
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3138385
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Same bug as CL:3113487. charge_manager accidentally overwrites other
global variable when supplier = -1.
BUG=b:198552518
TEST=Add debug log in charge_manager.c, make sure charge_manager does
not receive invalid arguments.
BRANCH=main
Signed-off-by: Ting Shen <phoenixshen@google.com>
Change-Id: I12787ab66fba7d8328440835867262e3828ac723
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3140013
Reviewed-by: Eric Yilun Lin <yllin@google.com>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Tasks should have a void pointer parameter.
BUG=None
TEST=Build all
BRANCH=None
Change-Id: I6d8e289929862b60cef4901b59c78448173090ea
Signed-off-by: Rob Barnes <robbarnes@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3136035
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-by: Diana Z <dzigterman@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Return the status of the init function. This will be used in
testing to verify that initialization was correct.
BRANCH=none
BUG=b:184856083
TEST=make buildall -j
Signed-off-by: Yuval Peress <peress@chromium.org>
Change-Id: I578b32b24b3ee59abf646307fb9670d2db74fe3b
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3133624
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
STT interface is not available outside of S0, so report that the
interface is not powered and allow the STT hook to exit quickly in this
condition.
BRANCH=None
BUG=b:197745639
TEST=No STT errors with board in G3 state
Change-Id: Id0c926ce896cdb4d3096746b3e7cc99db83bdd2d
Signed-off-by: Rob Barnes <robbarnes@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3126700
Tested-by: Diana Z <dzigterman@chromium.org>
Reviewed-by: Diana Z <dzigterman@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There's a bug in the chip_revision calculation. Also, add a missing
include which causes a warning during build.
BUG=none
BRANCH=none
TEST=make buildall -j
Change-Id: Id636f4abcfffc0158d879d4b9333c7cb3ac1ee21
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3133800
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
Commit-Queue: Denis Brockus <dbrockus@chromium.org>
Tested-by: Yuval Peress <peress@chromium.org>
Auto-Submit: Yuval Peress <peress@chromium.org>
Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Denis Brockus <dbrockus@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As a followup to CL:3104290, give the TCPCI TRANSMIT and
RX_BUF_FRAME_TYPE types more consistent names. Most of them can be used
for receiving, not just transmitting. Fix lint errors thus revealed.
BUG=b:155476419
TEST=make buildall
BRANCH=none
Signed-off-by: Abe Levkoy <alevkoy@chromium.org>
Change-Id: I399ec479eacc18622fc4d3f55f8bdabf4560fcff
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3125995
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since we have definitions for HPD IRQ and level in the mux flags, extend
this to the HPD update function in the usb_mux structure as well.
BRANCH=None
BUG=b:172222942
TEST=make -j buildall
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: I19c3a65fc821a341338d73fabd7876339b37fe7d
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3095437
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The mux HPD update is the only function not currently going through
configure_mux(). Pull out its contents so it may be run with the rest
of the mux changes.
BRANCH=None
BUG=b:186777984
TEST=tast typec.Mode*.manual on voxel
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: I5d91ca89dcdab0dcb0ba844494f9009948ee5abc
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3078412
Reviewed-by: Keith Short <keithshort@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since the ANX7451 is unpowered in Z1/G3, return an error for mux sets
during this time. This will let the usb_mux.c code know that any set it
attempted to perform was unsuccessful. Otherwise, it will be assumed
that setting mux mode of None succeeded, when we'll actually power up to
default USB mode.
BRANCH=None
BUG=b:195045790
TEST=on guybrush, power on board and ensure that C1 is put into None
mode successfully after its powered
Signed-off-by: Diana Z <dzigterman@chromium.org>
Change-Id: Ic98be3bc15e8f0affeda25d7d7170b89e3aecf10
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3093087
Reviewed-by: Rob Barnes <robbarnes@google.com>
Reviewed-by: Denis Brockus <dbrockus@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
TMP112 supports .0625 degrees of resolution. Retain this resolution and
support reading the temp in degrees millikelvin.
BUG=b:176994331
TEST=Build and run on guybrush
BRANCH=None
Change-Id: I2802016b1edb08678953238e7f01acdd320c37cf
Signed-off-by: Rob Barnes <robbarnes@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3001391
Commit-Queue: Diana Z <dzigterman@chromium.org>
Reviewed-by: Diana Z <dzigterman@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
BUG=b:190348051
TEST=Combined with other CLs in the chain, verify FRS workable on Tomato
BRANCH=none
Signed-off-by: Ting Shen <phoenixshen@google.com>
Change-Id: I52a020b1288928eb9a0f3ada1364776cd8e78337
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3109709
Reviewed-by: Eric Yilun Lin <yllin@google.com>
Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Tested-by: Ting Shen <phoenixshen@chromium.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When TCPC PS8755 is upgraded to PS8805 firmware, the product id cannot
distinguish whether the chip is PS8755 or PS8805. Only the hidden
register value of PS8755 is 0x80, so use this hidden register to
distinguish whether it is PS8755.
BRANCH=trogdor
BUG=b:196889096
TEST=emerge-strongbad chromeos-ec
Change-Id: I99b50dfb2f5ae47c3d4dbb3334dcdae20c281478
Signed-off-by: xuxinxiong <xuxinxiong@huaqin.corp-partner.google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3113261
Reviewed-by: Wai-Hong Tam <waihong@google.com>
Reviewed-by: wen zhang <zhangwen6@huaqin.corp-partner.google.com>
Commit-Queue: Wai-Hong Tam <waihong@google.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
And just to make it clearer, don't return ret at the bottom of a
if all other cases already do if (ret) return ret;
As it turns out, building with coverage doesn't initialize vars to 0.
BUG=None
TEST=zmake coverage.
BRANCH=none
Change-Id: Iae5368673517724fd23cb01425c027db9a50644b
Signed-off-by: Jeremy Bettis <jbettis@google.com>
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3115428
Tested-by: Jeremy Bettis <jbettis@chromium.org>
Auto-Submit: Jeremy Bettis <jbettis@chromium.org>
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-by: Keith Short <keithshort@chromium.org>
Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
|