Commit graph

12 commits

Author SHA1 Message Date
Steven Moreland
1dba6a8129 intro misctrl
Generic binary for managing the /misc partition.

This CL only uses it to do a basic health check for the /misc
partition, but the idea is this is a single place that can manage
misc partition operations for the Android platform, rather than
having to write a new tool each time.

Bug: 317262681
Test: boot, check bugreport
Change-Id: I29a4189e2e9aee57cf66520207297d39d666f7a4
2024-02-16 22:35:22 +00:00
Kelvin Zhang
6f68964a57 Make libbootloader_message available in recovery
Test: th
Bug: 227536004
Change-Id: Ie40045963c5493d8fbc1eb15e6a54ecaf1c4728f
2022-08-31 16:28:43 +00:00
Bob Badour
29be3f6ef1 [LSC] Add LOCAL_LICENSE_KINDS to bootable/recovery
Added SPDX-license-identifier-Apache-2.0 to:
  applypatch/Android.bp
  bootloader_message/Android.bp
  edify/Android.bp
  fuse_sideload/Android.bp
  install/Android.bp
  minadbd/Android.bp
  minui/Android.bp
  otautil/Android.bp
  recovery_ui/Android.bp
  recovery_utils/Android.bp
  tests/Android.bp
  tools/image_generator/Android.bp
  tools/recovery_l10n/Android.bp
  uncrypt/Android.bp
  update_verifier/Android.bp
  updater/Android.bp
  updater/Android.mk
  updater_sample/Android.bp
  updater_sample/tests/Android.bp

Added SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-MIT
    SPDX-license-identifier-OFL
to:
  Android.bp
  Android.mk

Bug: 68860345
Bug: 151177513
Bug: 151953481

Test: m all

Exempt-From-Owner-Approval: janitorial work
Change-Id: I3da761b525452838977297f773974000d4de7bd6
2021-02-14 10:37:20 -08:00
David Anderson
f771484f4e Make libboot_control vendor available.
Bug: 138861550
Test: builds
Change-Id: Ib745b59931c6258073e47b00def84c9157df90a7
2019-08-30 10:21:00 -07:00
Tao Bao
7ae0169842 Add misc_writer.
bootloader_message.h currently divides /misc into four segments. The
space between 2K and 16K is reserved for vendor use (e.g. bootloader
persists flags). This CL adds a vendor tool "misc_writer", to allow
writing data to the vendor space in /misc, before getting a dedicated
HAL for accessing /misc partition (b/131775112).

Targets need to explicitly include the module, then invoke the
executable to write data. For example, the following command will write
3-byte data ("0xABCDEF") to offset 4 in vendor space (i.e. 2048 + 4 in
/misc).
$ /vendor/bin/misc_writer --vendor-space-offset 4 --hex-string 0xABCDEF

Bug: 132906936
Test: Run recovery_unit_test on crosshatch.
Test: Call the command via init.hardware.rc on crosshatch. Check that
      the call finishes successfully. Then check the contents written to
      /misc (`dd bs=1 skip=2048 if=/dev/block/sda2 count=32 | xxd`).
Change-Id: I79548fc63fc79b705a0320868690569c3106949f
2019-05-20 15:51:26 -07:00
Colin Cross
fb68d38fba Disable libbootloader_message for darwin
libfstab is not built for darwin, don't build libbootloader_message
either.

Bug: 131709594
Test: m PRODUCT-sdk-sdk sdk_repo
Change-Id: I6e3b04f1c3e97d5aa6ac0452bf13e714f8dae437
2019-05-06 09:49:00 -07:00
Yifan Hong
d83070ddb9 libbootloader_message: host_supported.
Also, strlcat is not available on host, so use
std::string::operator+= instead.

Test: cuttlefish
Bug: 79094284

Change-Id: I1e69daeb522ca73f43e0c4855cf099a021ed4d47
2019-05-02 15:51:56 -07:00
Tao Bao
8ca3220bfe bootloader_message: Build libbootloader_message as shared lib.
And uses the shared lib version of libbase and libfs_mgr.

Bug: 78793464
Test: `m dist`
Test: Run recovery_{unit,component}_test on marlin.
Change-Id: I750c02d0bfccd6e58fb01f641de02532ace52e00
2018-07-25 13:42:33 -07:00
Jiyong Park
fafcfccc3c Mark as recovery_available:true
Libraries that are direct or indirect dependencies of modules installed
to recovery partition (e.g. adbd) are marked as recovery_available:
true. This allows a recovery variant of the lib is created when it is
depended by other recovery or recovery_available modules.

Bug: 79146551
Test: m -j
Change-Id: I9ca07ef53fbd89e7c86c0ba269fa52bb48d6deb4
2018-05-24 14:04:32 +09:00
Chih-Hung Hsieh
5aa77ca73d Use -Werror in bootable/recovery
* Move -Werror from cppflags to cflags.

Bug: 66996870
Test: build with WITH_TIDY=1
Change-Id: I59147fe24d8b48a0403c67ba07d4d384b8e9c5a3
2017-10-02 11:45:48 -07:00
Tianjie Xu
c89d1e7e2a Turn on -Wall for recovery modules
Turn on -Wall for all modules. Also remove the obsolete file_cmp() in
apply_patch test and now() in wear_ui.

The only exception is lib_edify due to the unused functions in the
intermediate cpp files generated from the lex files. It will be handled
in a seperate CL.

Bug: 64939312
Test: mma, unit tests pass
Change-Id: Ic53f76b60b6401ab20db3d98130d674c08e3702f
2017-08-28 21:56:33 -07:00
Tom Cherry
600e806384 libbootloader_message: convert to Android.bp
Test: build
Change-Id: Ia0c2e141673e37eea29306817d2f4b2c944213b0
2017-05-17 11:43:29 -07:00