summaryrefslogtreecommitdiff
path: root/board
Commit message (Collapse)AuthorAgeFilesLines
* LED On/Off: Remove power LED configDiana Z2021-04-2264-101/+67
| | | | | | | | | | | | | | | | | | | | | | Move the LED on/off module towards using a more flexible LED support approach. Define a weak power LED table and setter for boards to override when needed. Note that during run-time these functions will not get called since led_auto_control_is_enabled() will return false for nonexistent LEDs. This consumes an average of 165 additional bytes of flash space on boards which do not use a power LED. BRANCH=None BUG=b:185508707 TEST=make -j buildall, load on guybrush (battery LED only) and confirm no errors are seen. Load on Boten (both LEDs) and confirm behavior appears normal Signed-off-by: Diana Z <dzigterman@chromium.org> Change-Id: Iaa1e22a7f5d8be39eb8792ee13d358087d7f7482 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2832691 Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
* sasuke : fix bug during faft_pdYongBeum.Ha2021-04-221-11/+19
| | | | | | | | | | | | | | | | Some items in faft_pd is failed because of WA for S0iX power consumption. WA is fixed, based on CL:2773218 BUG=b:186022475 BRANCH=none TEST=make -j BOARD=sasuke & run faft_pd Signed-off-by: YongBeum.Ha <ybha@samsung.corp-partner.google.com> Change-Id: I9fe8a14c6e071f12d13012ec7809dad4d20e3192 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2842715 Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
* Lindar: Update lightbar 10-led cfgreno.wang2021-04-221-2/+2
| | | | | | | | | | | | | | | | | | | | Based on b:183826778's comment#17 and comment18 information to update lightbar 10-led cfg setting. The final placement adopt lightbar circuit's LED9 and LED10 which connect to KTD2061's LEDC1 and and LEDC2, not adopt LED11 and LED12 which connect to LEDC3 and LEDC4. BUG=b:183826778 BRANCH=volteer TEST=make -j BOARD=lindar Signed-off-by: reno.wang <reno.wang@lcfc.corp-partner.google.com> Change-Id: I7f7e1cac1f7361c5c21497a0cc4c1ff2763873bf Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2833031 Reviewed-by: Zhuohao Lee <zhuohao@chromium.org> Reviewed-by: Keith Short <keithshort@chromium.org> Commit-Queue: Keith Short <keithshort@chromium.org>
* cherry: add pwm keyboard backlight controlTing Shen2021-04-221-1/+1
| | | | | | | | | | | | | | BUG=b:181838424 TEST=keyboard backlight works BRANCH=main Signed-off-by: Ting Shen <phoenixshen@google.com> Change-Id: I7fd20808c6e8e6a1e22c060bb14c145256201756 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2785511 Tested-by: Ting Shen <phoenixshen@chromium.org> Auto-Submit: Ting Shen <phoenixshen@chromium.org> Reviewed-by: Eric Yilun Lin <yllin@google.com> Commit-Queue: Ting Shen <phoenixshen@chromium.org>
* sasuke : support multi-usb muxYongBeum.Ha2021-04-222-1/+34
| | | | | | | | | | | | | Select usb mux on board init with cbi_ssfc. BUG=b:182596801 BRANCH=none TEST=make -j BOARD=sasuke & check if c1 port works Signed-off-by: YongBeum.Ha <ybha@samsung.corp-partner.google.com> Change-Id: Id5886a5dbe128cbb7c32af4cb24d930be302eaa0 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2801177 Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
* thermisor: move header to include dirDawid Niedzwiecki2021-04-2237-37/+37
| | | | | | | | | | | | | | | | Move the "thermistor.h" header to the include/driver/temp_sensor directory. It is used by the Zephyr shim, so the change is useful to include the header. BUG=b:180403276 BRANCH=none TEST=make buildall Signed-off-by: Dawid Niedzwiecki <dn@semihalf.com> Change-Id: I0e83df97e50a3b324440b65ddb900ddf135f2439 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2843323 Reviewed-by: Keith Short <keithshort@chromium.org> Commit-Queue: Keith Short <keithshort@chromium.org>
* goroh: initial commitEric Yilun Lin2021-04-218-0/+724
| | | | | | | | | | | | | | | | | | copied from asurada with proper fixes: 1. rename asurada/hayato to goroh 2. change the year to 2021 in copyright notice BUG=b:185846337 TEST=make BOARD=goroh BRANCH=none Change-Id: Ifd66e5b16c5dd463dd9ad215f25a7a1ea1265495 Signed-off-by: Eric Yilun Lin <yllin@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2839384 Tested-by: Eric Yilun Lin <yllin@google.com> Auto-Submit: Eric Yilun Lin <yllin@google.com> Reviewed-by: Ting Shen <phoenixshen@chromium.org> Commit-Queue: Ting Shen <phoenixshen@chromium.org>
* drobit: Update EC thermal tableJacky Wang2021-04-211-4/+4
| | | | | | | | | | | | | | | Update EC thermal table for throttle and temp_fan_max setting. BUG=b:177777472 BRANCH=firmware-volteer-13672.B TEST=make BOARD=drobit 1. Verified pass by thermal team. Signed-off-by: Jacky Wang <jacky5_wang@pegatron.corp-partner.google.com> Change-Id: Ibfa9c543a1d99e02815882091d495aa601d3640b Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2839963 Reviewed-by: Michael5 Chen <michael5_chen1@pegatron.corp-partner.google.com> Reviewed-by: Keith Short <keithshort@chromium.org>
* brya: Define fw_config at board levelCaveh Jalali2021-04-215-10/+116
| | | | | | | | | | | | | | | | This updates the brya FW config fields based on the brya/config.star definitions. FW config fields and values are now defined at the project level rather than the program level. In other words each board (variant) defines its own FW config and no longer relies on baseboard definitions. BRANCH=none BUG=b:180434685 TEST=USB C1 port still works on brya for PD charging and SS data Change-Id: I055b0e2b051b7d41bbe116455274fe8b4a785741 Signed-off-by: Caveh Jalali <caveh@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2837417 Reviewed-by: Keith Short <keithshort@chromium.org>
* brya: Remove debug outputCaveh Jalali2021-04-211-5/+2
| | | | | | | | | | | BRANCH=none BUG=b:180980490,b:184873747 TEST=debug message no longer present when using suzyQ Change-Id: I709588b4e08263b05e49dc3c537e6515e0617b31 Signed-off-by: Caveh Jalali <caveh@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2837415 Reviewed-by: Alex Levin <levinale@google.com>
* spherion: fix kblight will blinking in DC mode.Ben Chen2021-04-202-1/+2
| | | | | | | | | | | | | | Undefine CONFIG_LOW_POWER_S0, don't enter power saving in S0 state. BUG=b:185438302 BRANCH=asurada TEST=make buildall PASS, the kb light function is PASS. Change-Id: Ife9796c0ada5213cd8d9e9cf9fbb086603b76d1d Signed-off-by: Ben Chen <ben.chen2@quanta.corp-partner.google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2830667 Reviewed-by: Ting Shen <phoenixshen@chromium.org>
* asurada: drop CONFIG_BRINGUPEric Yilun Lin2021-04-202-2/+0
| | | | | | | | | | | | | | The power sequence status is stable now. BUG=none TEST=make buildall BRANCH=asurada Change-Id: Ibdf644336f1aaefd185d983cd36efde67614d951 Signed-off-by: Eric Yilun Lin <yllin@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2835257 Reviewed-by: Ting Shen <phoenixshen@chromium.org> Commit-Queue: Ting Shen <phoenixshen@chromium.org>
* asurada: renames ADC_VBUS to ADC_VBUS_C0Eric Yilun Lin2021-04-201-1/+1
| | | | | | | | | | | | | | To make the naming clearer that's pointed to C0 port. BUG=none TEST=make buildall BRANCH=asurada Change-Id: If9cb520114b893af995aa67a2281b8e7302c2771 Signed-off-by: Eric Yilun Lin <yllin@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2814729 Reviewed-by: Ting Shen <phoenixshen@chromium.org> Commit-Queue: Ting Shen <phoenixshen@chromium.org>
* cherry: enable sensorsTing Shen2021-04-203-204/+45
| | | | | | | | | | | | | BUG=b:178158810 TEST=`accelread 0/1/2` BRANCH=main Signed-off-by: Ting Shen <phoenixshen@google.com> Change-Id: Iad128e3c94e409da000d5f11952a526a73ad64d9 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2730519 Tested-by: Ting Shen <phoenixshen@chromium.org> Reviewed-by: Eric Yilun Lin <yllin@chromium.org> Commit-Queue: Ting Shen <phoenixshen@chromium.org>
* cherry: GPIO configurationTing Shen2021-04-201-53/+31
| | | | | | | | | | | | | BUG=b:180886390,b:178158810 TEST=make BRANCH=main Signed-off-by: Ting Shen <phoenixshen@google.com> Change-Id: I99631c73112a4123dc24bd25825f59a6ff948dca Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2731395 Reviewed-by: Eric Yilun Lin <yllin@chromium.org> Commit-Queue: Ting Shen <phoenixshen@chromium.org> Tested-by: Ting Shen <phoenixshen@chromium.org>
* kracko: Update battery configTommy Chung2021-04-202-230/+6
| | | | | | | | | | | | | | | Updates the battery config on kracko. BUG=b:183664617, b:178092096 BRANCH=dedede TEST=Make sure battery charging, battery cutoff works. Signed-off-by: Tommy Chung <tommy.chung@quanta.corp-partner.google.com> Change-Id: Icc00f8bc23f73e9f7287a0f6980667c166bcba57 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2784330 Reviewed-by: Devin Lu <Devin.Lu@quantatw.com> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
* copano: Enable AP-driven alt mode entryMichael5 Chen12021-04-191-0/+2
| | | | | | | | | | | | | | | Wait for the AP to direct the EC to enter USB PD alternate modes. BUG=b:183773805 TEST=make buildall BRANCH=firmware-volteer-13672.B Signed-off-by: Michael5 Chen1 <michael5_chen1@pegatron.corp-partner.google.com> Change-Id: Ifc436f4043430f70ddba8563210b0a09cd5daf18 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2835256 Reviewed-by: Zhuohao Lee <zhuohao@chromium.org> Reviewed-by: Abe Levkoy <alevkoy@chromium.org> Commit-Queue: Zhuohao Lee <zhuohao@chromium.org>
* asurada/spherion: Remove CONFIG_SYSTEM_UNLOCKEDYu-Ping Wu2021-04-192-2/+0
| | | | | | | | | | | | | | | | Remove CONFIG_SYSTEM_UNLOCKED for asurada, hayato and spherion to avoid unnecessary sysjump when flashing EC with write protect enabled. BUG=b:160229421, b:185433646 TEST=emerge-asurada chromeos-ec TEST=firmware_WriteProtectFunc passed on Hayato BRANCH=asurada Change-Id: I76c9f381a1dd3b4f0e4e3e990ceb7a8c3c0e4128 Signed-off-by: Yu-Ping Wu <yupingso@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2834754 Reviewed-by: Eric Yilun Lin <yllin@chromium.org> Commit-Queue: Eric Yilun Lin <yllin@chromium.org>
* Homestar:BMI160:Adjust the initial orientation of the BMI160tongjian2021-04-191-2/+2
| | | | | | | | | | | | | | BUG=b:185631804 TEST=make -j BOARD=homestar Verify build on EVT board BRANCH=Trogdor Signed-off-by: tongjian <tongjian@huaqin.corp-partner.google.com> Change-Id: I91de1f34af210103b12b30f8cfa6a17e7692a301 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2833032 Reviewed-by: Wai-Hong Tam <waihong@google.com> Reviewed-by: Weimin Wu <wuweimin@huaqin.corp-partner.google.com> Tested-by: Weimin Wu <wuweimin@huaqin.corp-partner.google.com>
* voema: support kx022/bma255 with ssfc bits mapBen Chen2021-04-193-6/+76
| | | | | | | | | | | | | | | | config kx022 or bma255 motion sensor by ssfc bits map, and rename volteer ssfc bits map. BUG=b:178447173 BRANCH=main TEST=Using ectool 'motionsense' verified lid angle now goes from 0 to 360 and swtiches to tablet mode after crossing 200 threshold on re-work kx022/bma255 DUT. Change-Id: I2901b0cc980e50324eb4f20d073c5f3a4c3f80e3 Signed-off-by: Ben Chen <ben.chen2@quanta.corp-partner.google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2825719 Reviewed-by: Keith Short <keithshort@chromium.org>
* honeybuns: Add C2 initialization with power button on/offScott Collyer2021-04-174-85/+6
| | | | | | | | | | | | | | | | | | | | | | | This CL refactors code required for the user facing usbc port. This port was only being initialized at init time and therefore would not function properly following a power button off/on. To avoid duplicating code, the functions used to initialize this port and control VBUS were moved to usbc_support in baseboard so they can be common and are now guarded by a GPIO macro so this can be board specific for variants which don't have a PPC to control on this port. BUG=b:164157329 BRANCH=quiche TEST=Verifed that port C2 attaches as expected following power button off/on sequence. Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: I2f9500f7e58de674c6f7c12a95cebad45de166cc Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2785198 Reviewed-by: Diana Z <dzigterman@chromium.org> Commit-Queue: Scott Collyer <scollyer@chromium.org> Tested-by: Scott Collyer <scollyer@chromium.org>
* brya: Tune mp2964 settingsCaveh Jalali2021-04-163-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This tunes some parameters in the MP2964 IMVP9 to improve system stability. In this round, the only tuning we have identified is to change the SVID alert delay time to 200ns. The tuning is applied to the PMIC registers, then committed to the PMIC non volatile memory. On subsequent boots (including power cycle), the tuned values are used and no further tuning is required. 1st boot: mp2964_on_startup: attempting to tune PMIC mp2964: tuning reg 0x3f from 0xe001 to 0xe081 mp2964: tuning reg 0x3f from 0xe001 to 0xe081 mp2964_store_user_all: updating persistent settings mp2964: reg 0x3f already 0xe081 mp2964: reg 0x3f already 0xe081 2nd+ boot, also after removing battery: mp2964_on_startup: attempting to tune PMIC mp2964: reg 0x3f already 0xe081 mp2964: reg 0x3f already 0xe081 BRANCH=none BUG=b:185424011 TEST=unplugged battery, verified new values are persistent Change-Id: Idcb540eed6f893586853b8fed6e84e24b4a2f9e3 Signed-off-by: Caveh Jalali <caveh@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2823634 Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org> Commit-Queue: Tim Wawrzynczak <twawrzynczak@chromium.org>
* careena: Add thermal protectionDevin Lu2021-04-163-1/+23
| | | | | | | | | | | | | | This patch adds thermal protection to prevent AP runaway. BUG=b:185082703 BRANCH=firmware-grunt-11031.B TEST=Verify thermal halt/alert as expected. Signed-off-by: Devin Lu <Devin.Lu@quantatw.com> Change-Id: I4fccc93b0cb89a2e5d2784dfc0a41aa866f691f2 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2822269 Reviewed-by: Edward Hill <ecgh@chromium.org> Commit-Queue: Edward Hill <ecgh@chromium.org>
* brya: add lid_open interruptBoris Mittelberg2021-04-152-1/+2
| | | | | | | | | | | | | | | | | | | Any change on LID_OPEN line coming from GMR will trigger an interrupt. Notes: on P0 there is no magnet, so the interrupt will never be triggered on P1 the magnet is upside down, so lidstate would always report "open" BRANCH=none BUG=b:185322560 TEST=manual test with a magnet: when magnet approaches the GMR sensor with correct orientation - lid close event happens. Depending on the OS state the system shuts down or enters sleep. When the magnet is removed the system wakes up Signed-off-by: Boris Mittelberg <bmbm@google.com> Change-Id: I427c15d4f75add34266701089e05f99a924a5b3a Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2827411 Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
* mchp: Add MEC1723 board: sklrvp_mchp1723Scott Worley2021-04-157-0/+934
| | | | | | | | | | | | | | | | | | | | Add new board, sklrvp_mchp1723 using MEC1723-SZ and based upon the intelrvp baseboard. Users may switch to the MEC1727-SZ variant with internal 512KB SPI flash by changing the variant name to mec1727sz in the board's build make file. BRANCH=none BUG=none TEST=Build MEC172x chip and sklrvp_mchp1723 board. Signed-off-by: Scott Worley <scott.worley@microchip.corp-partner.google.com> Change-Id: Ia044a2149cf797aa620ad023be133c97b6183ac5 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2749516 Reviewed-by: Martin Yan <martin.yan@microchip.corp-partner.google.com> Reviewed-by: Vijay P Hiremath <vijay.p.hiremath@intel.com> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Tested-by: Martin Yan <martin.yan@microchip.corp-partner.google.com> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
* mchp: Add lfw/gpio.inc in chipmartin yan2021-04-156-260/+10
| | | | | | | | | | | | | | | | | Add gpio.inc in chip, and update build.mk; Delete lfw/gpio.inc under all mchp boards; BRANCH=none BUG=none TEST=Build sklrvp_mchp172x. Signed-off-by: martin yan <martin.yan@microchip.corp-partner.google.com> Change-Id: Icd98d4d93cb31f70592d6668e598fbc88e727450 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2810884 Reviewed-by: Martin Yan <Martin.Yan@microchip.com> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Reviewed-by: Vijay P Hiremath <vijay.p.hiremath@intel.com> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
* Metaknight: Support motion sensor 2nd sourceYu-An Chen2021-04-152-1/+67
| | | | | | | | | | | | | | | | | | Support motion sensor 2nd source: -Base : ICM-426xx BUG=b:177868819 BRANCH=dedede TEST=rework ICM-426xx to DUT, check ectool motionsense lid_angle is correct. Signed-off-by: yu-an.chen@quanta.corp-partner.google.com Change-Id: I8aa344662654d2f02d8cdd5101fcfe568931085f Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2825720 Tested-by: Yu-An Chen <yu-an.chen@quanta.corp-partner.google.com> Auto-Submit: Yu-An Chen <yu-an.chen@quanta.corp-partner.google.com> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
* Cret: Modify HDMI enable/disable conditionjohnwc_yeh2021-04-151-27/+16
| | | | | | | | | | | | | | | | | | Cret does not support DB, the HDMI implement at MB side. Need to remove HDMI enable/disable condition(by FW_Conifg) and enable function in board init directly. BUG=b:185434117 BRANCH=dedede TEST=make BOARD=cret Signed-off-by: johnwc_yeh <johnwc_yeh@compal.corp-partner.google.com> Change-Id: I2a2eedc89b163c7629c1650fdb56de9f206dfd42 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2825715 Reviewed-by: Elthan Huang <elthan_huang@compal.corp-partner.google.com> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Tested-by: Elthan Huang <elthan_huang@compal.corp-partner.google.com> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
* honeybuns: Allow for board specific mf preferenceScott Collyer2021-04-153-0/+45
| | | | | | | | | | | | | | | | | | This CL enables a given board to have its own policy regarding the mf preference bit which is used by a UFP to signal its preferred pin configuration in the DP Status message. BUG=b:175434634 BRANCH=None TEST=Verfied that the mf bit in the DP status message follows the board preference. Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: Ied7cdb72d1e302aab25dd5531856b1c7c148e64f Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2765422 Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Diana Z <dzigterman@chromium.org> Commit-Queue: Scott Collyer <scollyer@chromium.org>
* zed: update touchpad parameterTing Shen2021-04-152-10/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update touchpad parameter for zed. There's no integer solution for CONFIG_USB_HID_TOUCHPAD_PHYSICAL_MAX_Y (calculation appended below), this CL also modified the runtime check in elan tp driver to allow rounding errors. Math details: Given dpi_y = 800, LOGICAL_MAX_Y = 1811, we want to find an integer PHYSICAL_MAX_Y such that dpi == 254 * LOGICAL_MAX_Y / PHYSICAL_MAX_Y. The closest solution is 1) PHYSICAL_MAX_Y = 574, 254 * LOGICAL_MAX_Y / PHYSICAL_MAX_Y = 801.3832 != dpi_y, or 2) PHYSICAL_MAX_Y = 575, 254 * LOGICAL_MAX_Y / PHYSICAL_MAX_Y = 799.9895 != dpi_y Both cannot pass our runtime verification. BUG=None TEST=No "TP mismatch" in ec console BRANCH=trogdor Signed-off-by: Ting Shen <phoenixshen@google.com> Change-Id: I9d0c54d029bb2f9e78114341a6246857b41937b4 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2825473 Reviewed-by: Nicolas Boichat <drinkcat@chromium.org> Commit-Queue: Ting Shen <phoenixshen@chromium.org> Tested-by: Ting Shen <phoenixshen@chromium.org>
* garg: Add simplo 916QA141H batteryDevin Lu2021-04-152-0/+30
| | | | | | | | | | | BUG=b:184920909 BRANCH=firmware-octopus-11297.B TEST=Test on charging/discharging/battery cut off pass. Signed-off-by: Devin Lu <Devin.Lu@quantatw.com> Change-Id: I80d15bdef79e8e228c68d866c32e87d445bcf28e Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2817139 Reviewed-by: Diana Z <dzigterman@chromium.org>
* brya: add function to enabled/disabled keyboard backlightJosh Tsai2021-04-151-0/+17
| | | | | | | | | | | | | | | | | Enabled keyboard backlight when system resume to S0 Disabled keyboard backlight when system suspend BUG=b:184103439 BRANCH=none TEST=Keyboard backlight can work normally Signed-off-by: Josh Tsai <Josh_Tsai@compal.corp-partner.google.com> Change-Id: Idd4454bfba48d92bdfd75144141afac34c3781c6 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2822275 Reviewed-by: Josh Tsai <josh_tsai@compal.corp-partner.google.com> Reviewed-by: caveh jalali <caveh@chromium.org> Tested-by: Josh Tsai <josh_tsai@compal.corp-partner.google.com> Commit-Queue: Josh Tsai <josh_tsai@compal.corp-partner.google.com>
* Lindar: Create lightbar command for factory testreno.wang2021-04-141-1/+206
| | | | | | | | | | | | | | | | Add console/host, ectool, command for testing BUG=b:184821618 BRANCH=volteer TEST=make buildall, test command, ex. "ectool lighbar off". Lindar: Lightbar test code Signed-off-by: reno.wang <reno.wang@lcfc.corp-partner.google.com> Change-Id: I2b250d1b9bbc34ef533da34588ee969104f3b7f3 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2814721 Reviewed-by: Zhuohao Lee <zhuohao@chromium.org> Reviewed-by: Keith Short <keithshort@chromium.org> Commit-Queue: Keith Short <keithshort@chromium.org>
* Lindar: Move to SSFC for lightbar instead of SKUIDreno.wang2021-04-141-5/+68
| | | | | | | | | | | | | | | | | 1. Move to SSFC to check if system support lightbar instead of sku id 2. Add lightbar 12 led support and EC can base on SSFC_LIGHTBAR type to adopt different lightbar led cfg. BUG=b:183826778 BRANCH=volteer TEST=makee buildall, test SSFC_LIGHTBAR Signed-off-by: reno.wang <reno.wang@lcfc.corp-partner.google.com> Change-Id: Ic8fac16e846638c403e37261ecf15a72e805a8e0 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2822270 Reviewed-by: Zhuohao Lee <zhuohao@chromium.org> Reviewed-by: Keith Short <keithshort@chromium.org> Commit-Queue: Keith Short <keithshort@chromium.org>
* Lindar: Lightbar V9 SPECreno.wang2021-04-141-93/+182
| | | | | | | | | | | | | | | | | | | 1. Update code to match lightbar V9 behavior spec 2. Update lightbar led cfg to match lightbar HW design 3. Update amber (orange) color's current to increase brightness for mechanism team's request. BUG=b:183826778 BRANCH=volteer TEST=makee buildall, test lightbar behavior follow V9 SPEC, check lightbar green and amber color brightness. Signed-off-by: reno.wang <reno.wang@lcfc.corp-partner.google.com> Change-Id: I2626601aebc002fdf03fb5bb10f387a033378fa4 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2814720 Reviewed-by: Keith Short <keithshort@chromium.org> Reviewed-by: Zhuohao Lee <zhuohao@chromium.org> Commit-Queue: Keith Short <keithshort@chromium.org>
* baklava: initial EC imageScott Collyer2021-04-144-82/+17
| | | | | | | | | | | | | | | | | Baklava is a quiche variant that does not have the user facing DP capable usbc port. This CL modifies the starting quiche image to account for usbc port that is removed. BUG=b:184595837 BRANCH=quiche TEST=make -j BOARD=baklava. Verified C0 (host) port operation Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: Ic4455958d5cc6dbedfc17011113792ae3809e7be Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2727858 Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Diana Z <dzigterman@chromium.org> Commit-Queue: Scott Collyer <scollyer@chromium.org>
* sasuke : add sunwoda batteryYongBeum.Ha2021-04-142-0/+32
| | | | | | | | | | | | | Add battery information for sunwoda. BUG=b:182790995, b:181624369, b:178565802 BRANCH=None TEST=make -j BOARD=sasuke Signed-off-by: YongBeum.Ha <ybha@samsung.corp-partner.google.com> Change-Id: I592f9ade6f700138d9302ca3c4bbca0e047e975a Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2812598 Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
* Sasukette: modify ACProchot and DCProchot settingMike Lee2021-04-141-0/+4
| | | | | | | | | | | | | | | According to SENSE_RESISTOR 10milliohm and battery spec, modify ACProchot to 4096mA and DCProchot to 6000mA. BUG=b:182753738 BRANCH=dedede TEST=make BOARD=sasukette successfully,and local build test ok Signed-off-by: Mike Lee <mike5@huaqin.corp-partner.google.com> Change-Id: I52f1b0b1a6bf5e262771c01d07e803a729b30f56 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2822406 Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
* sasuke : disable alternative setting for GPIOB4/GPIOB5YongBeum.Ha2021-04-131-1/+1
| | | | | | | | | | | | | | | | | | Enable pull-down of GPIOB4 & GPIOB5. When I2C function is enabled, the pull-down option for GPIOB4,GPIOB5 is not work. So alternative setting for these GPIOs must be cleared. BUG=b:184914946 BRANCH=None TEST=make -j BOARD=sasuke Signed-off-by: YongBeum.Ha <ybha@samsung.corp-partner.google.com> Change-Id: I3d125e844816f0a7c07cb0b166390e7131100e6e Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2822277 Reviewed-by: Diana Z <dzigterman@chromium.org> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org> Tested-by: Aseda Aboagye <aaboagye@chromium.org>
* Guybrush: Add LED behaviorDiana Z2021-04-133-1/+95
| | | | | | | | | | | | | | | | Use the common LED on/off states for LED behavior. Set it up for our two colors: amber and white. BRANCH=None BUG=b:184845299 TEST=on guybrush, confirm charging shows Amber, discharging is white, shutdown shows no LED on Signed-off-by: Diana Z <dzigterman@chromium.org> Change-Id: Idc57de843fd2addaaa3006d4abd8566d76b2de6b Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2818151 Reviewed-by: Rob Barnes <robbarnes@google.com> Commit-Queue: Rob Barnes <robbarnes@google.com>
* spherion: config ADC thermal sensor and KB_BL_ENBen Chen2021-04-135-4/+100
| | | | | | | | | | | | | | config adc temp senosr enable, re-config KB_BL_EN to gpioG3 from GPIOI7 BUG=b:184885443 BRANCH=asurada TEST=make buildall PASS Change-Id: Ia0d12724ca33295f2817ee2a9a32dbff09aba87a Signed-off-by: Ben Chen <ben.chen2@quanta.corp-partner.google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2816939 Reviewed-by: Ting Shen <phoenixshen@chromium.org>
* zephyr: lazor: Enable the ps8xxx override functionSimon Glass2021-04-131-4/+1
| | | | | | | | | | | | | | This function is needed to detect the correct product ID for each port. Add it. BUG=b:183296099, b:183118990 BRANCH=none TEST=Build lazor on zephyr; no obvious changes when run Signed-off-by: Simon Glass <sjg@chromium.org> Change-Id: I1c7637a6fa6ccd1f0b82cbbd62575c43f096b641 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2822391 Reviewed-by: Wai-Hong Tam <waihong@google.com>
* brya: Enable EC hibernate using PSLCaveh Jalali2021-04-131-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | This adds the wake source pin definitions needed by the NPCX9 chip support code for brya board ID 1. Note that board ID 1 needs a rework on VCC1_RST to prevent it from falsely waking the board. BRANCH=none BUG=b:183246197 TEST=booted same image on old and new rev. of board Used "hibernate" on EC console hibernate the system. It woke up immediately (b/183412004) with cause "hibernate" indicating this was a PSL wake: --- UART initialized after reboot --- [Image: RO, brya_v2.0.8357-19a8f337db 2021-04-08 01:09:30 caveh@caveh] [Reset cause: power-on hibernate wake-pin] LID_OPEN was tested as a PSL wake source by artificially disabling CONFIG_HIBERNATE_PSL_VCC1_RST_WAKEUP to eliminate VCC1 as a false wake source. Change-Id: If4cca6d1e20ddc3c422697e6838c9df0ddd8cb15 Signed-off-by: Caveh Jalali <caveh@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2728679 Reviewed-by: Furquan Shaikh <furquan@chromium.org>
* brya: Update EC GPIOs for board ID 1Caveh Jalali2021-04-131-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This updates the GPIO functional changes to support the new rev. (ID 1) of the brya board. EC_KB_BL_EN moved from GPIO85 to GPIOA3 (was EN_SLP_Z). EC_KB_BL_EN is set to low since that's the preferred setting for the initial keyboard backlight. This does not break the old board due to a hardware bug on the old board that causes it to come out of sleep unconditionally. GPIO85 does not need to be configured here when PSL is enabled. EN_SLP_Z is no longer used. EC_RST_ODL (VCC1_RST#/GPO77) has been removed from config. This was an unused input on the old board. This pin functions as a wake source when we enable HIBERNATE_PSL_VCC1_RST_WAKEUP and does not need to be configured here. finally, PSL is enabled on pins PSL_IN1-3. BRANCH=none BUG=b:184811017,b:183246197 TEST=both old new new revision of the brya board can boot Cq-Depend: chromium:2728679 Change-Id: I4b3ab17bb44d18167328faee1a1b604bf0428dd3 Signed-off-by: Caveh Jalali <caveh@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2813460 Reviewed-by: Furquan Shaikh <furquan@chromium.org>
* ec: Filter non-FIXED PDOs in servo_v4{p1}Jeremy Bettis2021-04-134-4/+6
| | | | | | | | | | | | | | | | | | | | | | Add a new config CONFIG_USB_PD_ONLY_FIXED_PDOS. If that config is enabled, ignore non-FIXED PDOs in both the console command `ada_srccaps` and also when selecting the preferred PDO for a voltage. Enable CONFIG_USB_PD_ONLY_FIXED_PDOS for servo_v4 and servo_v4p1, since they don't expose non-fixed PDO in their srccaps. Without this change, there is a risk that the "best" PDO for a given voltage will be non-FIXED and then that voltage just won't be supported at all. BRANCH=none BUG=b:178484932 TEST=added Change-Id: I0d1187ca372120c7fe21d627e1b82b59f6334add Signed-off-by: Jeremy Bettis <jbettis@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2809353 Tested-by: Jeremy Bettis <jbettis@chromium.org> Commit-Queue: Keith Short <keithshort@chromium.org> Reviewed-by: Keith Short <keithshort@chromium.org>
* sasuke : enable pull-down of GPIOB4,GPIOB5YongBeum.Ha2021-04-131-2/+2
| | | | | | | | | | | | | Enable pull-down of GPIOB4 & GPIOB5 BUG=b:184914946 BRANCH=None TEST=make -j BOARD=sasuke Signed-off-by: YongBeum.Ha <ybha@samsung.corp-partner.google.com> Change-Id: I27e1b612956f217418178783cf28c5c466f281ba Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2817140 Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
* cret: Remove GPIO43 of ADC Alternate functionjohnwc_yeh2021-04-123-9/+2
| | | | | | | | | | | | | | | Remove GPIO43 of ADC Alternate function and set Input and Internal pull up. BUG=b:181325655 BRANCH=dedede TEST=make BOARD=cret Signed-off-by: johnwc_yeh <johnwc_yeh@compal.corp-partner.google.com> Change-Id: I3e506c0916a284a57afa93f8e100f45c285a38bb Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2817683 Reviewed-by: Elthan Huang <elthan_huang@compal.corp-partner.google.com> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
* cret: Add Forest Creek battery parameter on Cretjohnwc_yeh2021-04-122-0/+124
| | | | | | | | | | | | | | | Use the Forest Creek battery to Cret. BUG=b:185066840 BRANCH=dedede TEST=make BOARD=cret Signed-off-by: johnwc_yeh <johnwc_yeh@compal.corp-partner.google.com> Change-Id: Ib4c9c3feb7236b2d2a3d6224249003797ce1c189 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2817691 Reviewed-by: Elthan Huang <elthan_huang@compal.corp-partner.google.com> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Commit-Queue: Aseda Aboagye <aaboagye@chromium.org>
* dooly: update ALS lux equationZick Wei2021-04-121-39/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The previous equation in CL:2771482, would cause lux = 0 on some ALS board in specific ambient light , we worked with vendor and update the lux equation: Lux = LuxScalar * (DGFn * ((C * Ccoefn) + (R * Rcoefn) + (G * Gcoefn) + (B * Bcoefn)) / (Atime*Again)) Lux = MAX(0, Lux) If (G+B)/C < 0.692 n=1 If (G+B)/C >= 0.692 and < 1.012 n=2 else n=3 LuxScalar = 1.00 Coeffs n=1(Lo) n=2(Med) n=3(Hi) Ccoef 0.009 0.202 -0.661 Rcoef 0.056 - 1.1 1.334 GCoef 2.735 8.692 1.095 BCoef -1.903 -7.068 -1.821 DGF 799.797 801.347 795.574 BUG=b:184238881 BRANCH=puff TEST=verify equation works as intended. Signed-off-by: Zick Wei <zick.wei@quanta.corp-partner.google.com> Change-Id: Ic9e41579c37544496f54a4faeb1a0d0aeea8f7c3 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2812601 Reviewed-by: Gwendal Grignou <gwendal@chromium.org> Commit-Queue: Gwendal Grignou <gwendal@chromium.org>
* baklava: Starting image (quiche copy)Scott Collyer2021-04-126-0/+671
| | | | | | | | | | | | | | | | | This CL is the starting image for baklava which is a quiche varaint. The only changes made are updating the year and board name. The follow on CL contains changes relative to quiche. BUG=b:184595837 BRANCH=quiche TEST=make -j BOARD=baklava Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: I62f1b6cd710f272833a97f50dc7fe7e1ac27b85e Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2806185 Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Diana Z <dzigterman@chromium.org> Commit-Queue: Diana Z <dzigterman@chromium.org>