summaryrefslogtreecommitdiff
path: root/board/baklava
Commit message (Collapse)AuthorAgeFilesLines
* board: Sort header filesJeremy Bettis2022-12-011-2/+3
| | | | | | | | | | | | | | | | | | | | Sort all includes in board with the clang-format rules used by the zephyr project. BRANCH=None BUG=b:247100970 TEST=zmake build -a TEST=./twister --clobber -v -i TEST=make -j72 buildall_only runtests TEST=zmake compare-builds -a Signed-off-by: Jeremy Bettis <jbettis@google.com> Change-Id: I6ad72b167cbb768a64c338fa633eb4bf5a401897 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/4060360 Reviewed-by: Tom Hughes <tomhughes@chromium.org> Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org> Tested-by: Jeremy Bettis <jbettis@chromium.org> Commit-Queue: Jeremy Bettis <jbettis@chromium.org>
* honeybuns: usb_mux: Split struct usb_mux in honeybuns boardsTomasz Michalec2022-09-131-6/+8
| | | | | | | | | | | | | | | | Update honeybuns boards to use new struct usb_mux_chain. BUG=b:236274003 TEST=make buildall BRANCH=None Cq-Depend: chromium:3748785 Signed-off-by: Tomasz Michalec <tm@semihalf.com> Change-Id: I0c104fb65705d8fcba7c962fdff92eb07d46a455 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3780407 Tested-by: Tomasz Michalec <tmichalec@google.com> Commit-Queue: Tomasz Michalec <tmichalec@google.com> Reviewed-by: Keith Short <keithshort@chromium.org>
* Update license boilerplate text in source code filesMike Frysinger2022-09-125-5/+5
| | | | | | | | | | | | | | | Normally we don't do this, but enough changes have accumulated that we're doing a tree-wide one-off update of the name & style. BRANCH=none BUG=chromium:1098010 TEST=`repo upload` works Change-Id: Icd3a1723c20595356af83d190b2c6a9078b3013b Signed-off-by: Mike Frysinger <vapier@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3891203 Reviewed-by: Jeremy Bettis <jbettis@chromium.org> Reviewed-by: Jack Rosenthal <jrosenth@chromium.org>
* tree-wide: const-ify argv for console commandsCaveh Jalali2022-09-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | This updates the API for console commands from "int cmd(int argc, char **argv)" to "int cmd(int argc, const char **argv)" which is more accurate and in line with common convention. BRANCH=none BUG=b:244387210 TEST="make buildall" passes TEST="zmake build -a" passes TEST="util/compare_build.sh -b all" passes TEST="./twister -v -T zephyr/test" passes Cq-Depend: chrome-internal:4960125 Cq-Depend: chrome-internal:4959932 Change-Id: I57de9f35b85b8f3c7119df36aefb2abf25d2625f Signed-off-by: Caveh Jalali <caveh@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3863941 Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Reviewed-by: Tom Hughes <tomhughes@chromium.org> Reviewed-by: Keith Short <keithshort@chromium.org>
* board/baklava/board.h: Format with clang-formatJack Rosenthal2022-07-011-6/+6
| | | | | | | | | | | BUG=b:236386294 BRANCH=none TEST=none Change-Id: I442af4730563d232a5861f99af01149fe6f46724 Signed-off-by: Jack Rosenthal <jrosenth@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3727997 Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
* board/baklava/board.c: Format with clang-formatJack Rosenthal2022-07-011-45/+37
| | | | | | | | | | | BUG=b:236386294 BRANCH=none TEST=none Change-Id: Ic939cdfa6a9034f97dea8a6921ce271305422626 Signed-off-by: Jack Rosenthal <jrosenth@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3728017 Reviewed-by: Jeremy Bettis <jbettis@chromium.org>
* honeybuns: Add board level USB_PD_CONNECT hooksScott Collyer2021-11-231-0/+25
| | | | | | | | | | | | | | | | | | | | | | | | This CL moves the board specific parts of USB_PD_CONNECT hook to board.c file as there are different GPIOs that must be changed between quiche/gingerbread. For Gingerbread, the USB Hubs are held in reset until there is a usbc attach event. quiche/baklava don't require USB hub resets to be controlled, but do have a separate GPIO indicator the MST hub. BUG=b:206059703 BRANCH=quiche TEST=verified GPIO signal levels for signals affected by this CL on quiche and gingerbread. Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: I88ef6ddfe5026fc75384507920368681d28a21f9 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3291133 Commit-Queue: Scott Collyer <scollyer@chromium.org> Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org>
* Add math_lib for 32 bit boards that use pd_timerDenis Brockus2021-09-271-0/+3
| | | | | | | | | | | | | | | | | | pd_timer was changed to use bitmask_uint64 to create the equivalent of BIT(o) for uint64_t bitmasks BUG=none BRANCH=none TEST=make buildall Signed-off-by: Denis Brockus <dbrockus@google.com> Change-Id: I7cc6a24771a9c5e1050fa1c3ff1391ef77518b80 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/3182631 Tested-by: Denis Brockus <dbrockus@chromium.org> Auto-Submit: Denis Brockus <dbrockus@chromium.org> Commit-Queue: Yuval Peress <peress@google.com> Reviewed-by: Yuval Peress <peress@google.com>
* quiche/baklava: Change UFP_PLUG_DET to be active lowScott Collyer2021-06-171-1/+1
| | | | | | | | | | | | | | | | | This CL changes the gpio signal UFP_PLUG_DET to be active low instead of active high. The initial description of this signal was incorrect. BUG=b:189860586 BRANCH=quiche TEST=ODM vendor verified that interop test against karben is now working with the display extending. Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: I966be6a4f725810d03b2748ea95217b9bffec61c Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2959396 Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Diana Z <dzigterman@chromium.org> Commit-Queue: Scott Collyer <scollyer@chromium.org>
* honeybuns: Move configs for MP release to board.hScott Collyer2021-05-261-0/+6
| | | | | | | | | | | | | | | | | This CL moves the configs that are needed to be changed for an MP release to the board.h files from baseboard.h. BUG=b:183686750 BRANCH=quiche TEST=make BOARD=quiche/gingerbread/baklava Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: I7c602ecb2f2af02638be080613bb83dee568c332 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2911737 Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Aseda Aboagye <aaboagye@chromium.org> Reviewed-by: Diana Z <dzigterman@chromium.org> Commit-Queue: Scott Collyer <scollyer@chromium.org>
* honeybuns: Board specific power button and LEDsScott Collyer2021-05-141-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This CL modifies both power button press/release polairty and power button LED control signals to be board specific instead of platform specific. Previously there were platform specific macros for BUTTON_PRESSED_LEVEL and BUTTON_RELEASED_LEVEL. But, these levels will depend on how the power button circuit is designed. This CL moves these macros to board.h. In addition, macros are added to for the GPIO signals used for green/red LED control. This allows for boards that don't support the power button LED at all. BUG=b:164157329 BRANCH=quiche TEST=Verfied power button works on both quiche and gingerbread. Previously, this was only working on quiche because gingerbread has opposite polarity for the power button signal. Also, verfied that power button/status LED turns off when dock is off. Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: Iee838ee158d23252e8b429f51a1dd1a71d8e94a0 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2868225 Commit-Queue: Scott Collyer <scollyer@chromium.org> Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Diana Z <dzigterman@chromium.org>
* baklava: Use correct VID for USB-EPScott Collyer2021-05-142-2/+4
| | | | | | | | | | | | | | | | This CL sets CONFIG_USB_VID to correct value for the OEM. In addition, updated the vendor and product strings. BUG=b:185066262 BRANCH=quiche TEST=verfied that fwupd works correctly on baklava Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: I4d61253b3a32cc117daaee5e731db9bff4b85e6e Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2848425 Reviewed-by: Diana Z <dzigterman@chromium.org> Commit-Queue: Scott Collyer <scollyer@chromium.org> Tested-by: Scott Collyer <scollyer@chromium.org>
* honeybuns: Add usbc attached gpio support for usb/mst hubsScott Collyer2021-05-023-6/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This CL adds support for new GPIO signals used by the EC to notify usb/mst hubs about type-c attach and over current protection events. The usb3 only port on quiche/baklava uses a PPC, and previously the PPC was only being used to enable/disable VBUS and did not have interrupt support. However, there can still protection events that must be handled. This CL also adds a simple usbc state machine to be able to determine attached.src state while in RO. The USB hub needs to be notified when VBUS is present (BPWRDET) otherwise it will just go into suspend state and there can be USB enumeration issues. BUG=b:185066262 BRANCH=quiche TEST=manual For OCP, I set the PPC source current limit to 1.5A and connected to a chromebook. This triggers the OCP event. For BPWRDET/UFP_PLUG_DET verified that when attached, these signals are high, when detached, are low as expected. Signed-off-by: Scott Collyer <scollyer@google.com> Change-Id: Ia147b970ea3dc298545aec4dedaa035ad2a1db30 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2818522 Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Sam Hurst <shurst@google.com> Commit-Queue: Scott Collyer <scollyer@chromium.org>
* honeybuns: Add C2 initialization with power button on/offScott Collyer2021-04-172-43/+3
| | | | | | | | | | | | | | | | | | | | | | | 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>
* honeybuns: Allow for board specific mf preferenceScott Collyer2021-04-151-0/+5
| | | | | | | | | | | | | | | | | | 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>
* 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>
* 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>