Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(135)

Side by Side Diff: firmware/include/load_firmware_fw.h

Issue 2844044: added reboot return codes to load kernel and firmware (Closed) Base URL: ssh://gitrw.chromium.org/vboot_reference.git
Patch Set: After remerge 2 Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | firmware/include/load_kernel_fw.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* Copyright (c) 2010 The Chromium OS Authors. All rights reserved. 1 /* Copyright (c) 2010 The Chromium OS Authors. All rights reserved.
2 * Use of this source code is governed by a BSD-style license that can be 2 * Use of this source code is governed by a BSD-style license that can be
3 * found in the LICENSE file. 3 * found in the LICENSE file.
4 * 4 *
5 * High-level firmware API for loading and verifying rewritable firmware. 5 * High-level firmware API for loading and verifying rewritable firmware.
6 * (Firmware Portion) 6 * (Firmware Portion)
7 */ 7 */
8 8
9 #ifndef VBOOT_REFERENCE_LOAD_FIRMWARE_FW_H_ 9 #ifndef VBOOT_REFERENCE_LOAD_FIRMWARE_FW_H_
10 #define VBOOT_REFERENCE_LOAD_FIRMWARE_FW_H_ 10 #define VBOOT_REFERENCE_LOAD_FIRMWARE_FW_H_
11 11
12 #include "sysincludes.h" 12 #include "sysincludes.h"
13 13
14 /* Recommended size of kernel_sign_key_blob in bytes, for 14 /* Recommended size of kernel_sign_key_blob in bytes, for
15 * implementations which must preallocate a transfer buffer between 15 * implementations which must preallocate a transfer buffer between
16 * boot phases */ 16 * boot phases */
17 #define LOAD_FIRMWARE_KEY_BLOB_REC_SIZE 2104 17 #define LOAD_FIRMWARE_KEY_BLOB_REC_SIZE 2104
18 18
19 /* Return codes for LoadFirmware() */ 19 /* Return codes for LoadFirmware() */
20 #define LOAD_FIRMWARE_SUCCESS 0 /* Success */ 20 #define LOAD_FIRMWARE_SUCCESS 0 /* Success */
21 #define LOAD_FIRMWARE_RECOVERY 1 /* Reboot to recovery mode */ 21 #define LOAD_FIRMWARE_RECOVERY 1 /* Reboot to recovery mode */
22 #define LOAD_FIRMWARE_REBOOT 2 /* Reboot to same mode as current boot */
22 23
23 /* Boot flags for LoadFirmware().boot_flags */ 24 /* Boot flags for LoadFirmware().boot_flags */
24 #define BOOT_FLAG_DEVELOPER UINT64_C(0x01) /* Developer switch is on */ 25 #define BOOT_FLAG_DEVELOPER UINT64_C(0x01) /* Developer switch is on */
25 26
26 typedef struct LoadFirmwareParams { 27 typedef struct LoadFirmwareParams {
27 /* Inputs to LoadFirmware() */ 28 /* Inputs to LoadFirmware() */
28 void *firmware_root_key_blob; /* Key used to sign firmware header */ 29 void *firmware_root_key_blob; /* Key used to sign firmware header */
29 void *verification_block_0; /* Key block + preamble for firmware 0 */ 30 void *verification_block_0; /* Key block + preamble for firmware 0 */
30 void *verification_block_1; /* Key block + preamble for firmware 1 */ 31 void *verification_block_1; /* Key block + preamble for firmware 1 */
31 uint64_t verification_size_0; /* Verification block 0 size in bytes */ 32 uint64_t verification_size_0; /* Verification block 0 size in bytes */
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 /* Update the data hash for the current firmware image, extending it 82 /* Update the data hash for the current firmware image, extending it
82 * by [size] bytes stored in [*data]. This function must only be 83 * by [size] bytes stored in [*data]. This function must only be
83 * called inside GetFirmwareBody(). */ 84 * called inside GetFirmwareBody(). */
84 void UpdateFirmwareBodyHash(LoadFirmwareParams* params, 85 void UpdateFirmwareBodyHash(LoadFirmwareParams* params,
85 uint8_t* data, uint64_t size); 86 uint8_t* data, uint64_t size);
86 87
87 88
88 89
89 90
90 #endif /* VBOOT_REFERENCE_LOAD_FIRMWARE_FW_H_ */ 91 #endif /* VBOOT_REFERENCE_LOAD_FIRMWARE_FW_H_ */
OLDNEW
« no previous file with comments | « no previous file | firmware/include/load_kernel_fw.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698