Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
63 changes: 62 additions & 1 deletion getting_started/intel_debug/introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -137,4 +137,65 @@ drivers and should work when changing the ``dsp_driver`` parameter.
The selection of firmware, topology, and UCM files is based on platform
capabilities, codec names, and DMI options. While the SOF team and the
community try to cover all possible cases, errors will happen when the
wrong file is selected at any of the three layers.
wrong file is selected at any of the three layers.

4. Chromebooks and SOF
----------------------

As stated above, starting from 2019/2020 Intel Chromeboooks have been
configured with the *community* key which means they can run
audio firmware signed by anyone. The entire filesystem is locked by
default instead but there are a couple options to disable security for
development purposes. In all cases the very first step is to switch the
Chromebook to (non-secure) `Developer Mode
<https://chromium.googlesource.com/chromiumos/docs/+/HEAD/developer_mode.md>`_.
Developer Mode is in fact the only strictly required step if you only
want to install and run your own SOF firmware and are not interested in
changing anything else in ChromeOS.

If you need the flexibility to make more changes, Chromebooks can run
Linux in several, non-mutually exclusive ways. All the options listed
below will let you run any SOF firmware at will. One of the biggest
differences between them is how to install and run your own Linux
kernel.

- **ChromeOS** has direct hardware access but ChromeOS development
cannot happen on ChromeOS itself, it requires a separate workstation
similar to how most embedded development typically does. Setting up
the ``cros_sdk`` is documented in the `ChromeOS developer guide
<https://chromium.googlesource.com/chromiumos/docs/+/HEAD/developer_guide.md>`_.
The ``cros_sdk`` is a complete environment that lets you modify
anything in ChromeOS and even build an entire system image. The
``cros_sdk`` requires significant disk space and there is some
learning effort if you're not already familiar with Gentoo's build
system "Portage"; especially for the Linux kernel.

- `Crostini
<https://chromium.googlesource.com/chromiumos/docs/+/HEAD/containers_and_vms.md>`_
is a secure Linux Virtual Machine that does not have direct access to
the hardware and cannot be used for SOF (it does not require Developer
Mode). Listed here for completeness. It may be possible to use
Crostini as your pseudo-separate ``cros_sdk`` workstation but a
different, more powerful system that you never have to reboot is an
obviously much better ``cros_sdk`` option.

- **Crouton** is a non-secure chroot that does allow direct hardware
access and can be used for SOF. It lets you install a choice of
popular Linux distributions which you can use to develop on the device
itself: make regular backups! The Zephyr project has `very detailed
specific instructions
<https://docs.zephyrproject.org/2.7.0/boards/xtensa/intel_adsp_cavs25/doc/index.html>`_
on how to use Crouton for SOF. Most of these instructions are not
Zephyr-specific. With Crouton you can configure and compile a Linux
kernel as usual, however the kernel *installation* process is similar
to the ``cros_sdk`` process with a couple of small twists.

- Finally, it is possible to **dual-boot** or completely replace
ChromeOS by a regular Linux distribution on *some* Chromebooks and
forget it is a Chromebook entirely. This comes at a price however: it
is the least secure option and the more likely to make your device
permanently unusable ("brick"). That level of risk is highly dependent

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minus using a debuging tool

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point but I'm trying to keep this (most dangerous) section short and "simply scary" and debug tools would IMHO stray a bit too far from SOF. I believe there are enough references in case anyone wants to go and dive into serious Chromebook hacking.

I'm guessing you're thinking about https://chromium.googlesource.com/chromiumos/platform/ec/+/cr50_stab/docs/case_closed_debugging.md and similar? From past experience these solutions also tend to be somewhat model-dependent.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From what I understand CCD should be supported going forward, its not the fastest thing in the world but if you want to unlock your system its better than opening some of these super thin cases.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

but yes i agree, good to make is scary :)

on your particular Chromebook model. If that does not scare you then
https://chrx.org/ is a good starting point; pay special attention to
the "note on security". This is the only option that lets you manage
kernel installations as a typical Linux distribution does.