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

Side by Side Diff: active_main_firmware.h

Issue 3530001: first cut: establishes base helper classes and main (Closed) Base URL: http://git.chromium.org/git/cros_boot_mode.git
Patch Set: truncation is bad, m'kay. . . Created 10 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « README ('k') | active_main_firmware.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4 //
5 // Defines the ActiveMainFirmware class which extracts the firmware volume used
6 // for boot.
7 #ifndef CROS_BOOT_MODE_ACTIVE_MAIN_FIRMWARE_H_
8 #define CROS_BOOT_MODE_ACTIVE_MAIN_FIRMWARE_H_
9
10 #include <sys/types.h>
11
12 #include "platform_reader.h"
13
14 namespace cros_boot_mode {
15
16 class ActiveMainFirmware : public PlatformReader {
17 public:
18 ActiveMainFirmware();
19 virtual ~ActiveMainFirmware();
20
21 enum {
22 kRecovery = 0,
23 kReadWriteA,
24 kReadWriteB,
25 };
26 static const char *kActiveMainFirmwareText[];
27 static const size_t kActiveMainFirmwareCount;
28
29 virtual const char *c_str() const;
30 virtual int Process(const char *contents, size_t length);
31 virtual const char *default_platform_file_path() const {
32 return "/sys/devices/platform/chromeos_acpi/BINF.1";
33 }
34 virtual const char *name() const {
35 return "active_main_firmware";
36 }
37 virtual size_t max_size() const {
38 return sizeof("-1");
39 }
40 };
41
42 } // namespace cros_boot_mode
43 #endif // CROS_BOOT_MODE_ACTIVE_MAIN_FIRMWARE_H_
OLDNEW
« no previous file with comments | « README ('k') | active_main_firmware.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698