[roll] Roll fuchsia [kernel] Move FXT metadata record writes into ReportMetadata

This patch moves writing the magic and initialization records from the
Rewind method into the `ReportMetadata` method for the per-CPU
implementation of KTrace.

Mechanically, this means:
1. Using the fxt library methods to emit the magic and initialization
   records instead of hardcoding their values inline, and
2. Using an IPI to emit these records on the boot CPU so that they're
   always read first during a read.
3. Moving the implementation of ReportMetadata from the header to the
   CPP file, which required moving the Reserve function ahead of it to
   appease the template instantiation requirements.

Note that this does slightly change the behavior of ktrace; the magic
and initialization records are emitted every time a new ktrace session
is started, instead of just when the buffer is initially allocated or
rewind'ed.

I've tested that this works by taking a trace locally; future patches
will rework `ReportMetadata` to make it more testable so we can exercise
it in unit tests.

Original-Bug: 404539312
Original-Reviewed-on: https://fuchsia-review.googlesource.com/c/fuchsia/+/1257090
Original-Revision: 6ae2e113be0363c60140a038d9c4e209973f8966
GitOrigin-RevId: 6863197cdd926228860169d0f0dd2cd1068eea5c
Change-Id: Icd55595a5e99845ced3a7af6bddd3e2bcb4bdd48
1 file changed
tree: 27298a8a97b2789dfaea264561efd44665d3efa1
  1. ctf/
  2. git-hooks/
  3. infra/
  4. third_party/
  5. cts
  6. firmware
  7. flower
  8. jiri.lock
  9. MILESTONE
  10. minimal
  11. prebuilts
  12. README.md
  13. stem
  14. test_durations
  15. toolchain
README.md

Integration

This repository contains Fuchsia's Global Integration manifest files.

Making changes

All changes should be made to the internal version of this repository. Our infrastructure automatically updates this version when the internal one changes.

Currently all changes must be made by a Google employee. Non-Google employees wishing to make a change can ask for assistance in one of the communication channels documented at get involved.

Obtaining the source

First install Jiri.

Next run:

$ jiri init
$ jiri import minimal https://fuchsia.googlesource.com/integration
$ jiri update

Third party

Third party projects should have their own subdirectory in ./third_party.