blob: fdcdf139196aa18bbdf0d87990934eee080e3f78 [file] [log] [blame]
Alex Deymo42432912013-07-12 20:21:15 -07001// Copyright (c) 2013 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
Alex Deymo759c2752014-03-17 21:09:36 -07005#ifndef CHROMEOS_PLATFORM_UPDATE_ENGINE_HARDWARE_H_
6#define CHROMEOS_PLATFORM_UPDATE_ENGINE_HARDWARE_H_
Alex Deymo42432912013-07-12 20:21:15 -07007
8#include "update_engine/hardware_interface.h"
9
10#include "base/basictypes.h"
11
12namespace chromeos_update_engine {
13
14// Implements the real interface with the hardware.
15class Hardware : public HardwareInterface {
16 public:
Chris Masonef8d037f2014-02-19 01:53:00 +000017 Hardware();
Alex Vakulenkod0fdfb32014-02-21 15:26:26 -080018 virtual ~Hardware() override;
Alex Deymo42432912013-07-12 20:21:15 -070019
20 // HardwareInterface methods.
Alex Vakulenkod0fdfb32014-02-21 15:26:26 -080021 virtual std::string BootKernelDevice() const override;
22 virtual std::string BootDevice() const override;
23 virtual std::vector<std::string> GetKernelDevices() const override;
Don Garrett83692e42013-11-08 10:11:30 -080024 virtual bool IsKernelBootable(const std::string& kernel_device,
Alex Vakulenkod0fdfb32014-02-21 15:26:26 -080025 bool* bootable) const override;
26 virtual bool MarkKernelUnbootable(const std::string& kernel_device) override;
27 virtual bool IsOfficialBuild() const override;
28 virtual bool IsNormalBootMode() const override;
Alex Deymobccbc382014-04-03 13:38:55 -070029 virtual bool IsOOBEComplete(base::Time* out_time_of_oobe) const override;
Alex Vakulenkod0fdfb32014-02-21 15:26:26 -080030 virtual std::string GetHardwareClass() const override;
31 virtual std::string GetFirmwareVersion() const override;
32 virtual std::string GetECVersion() const override;
Alex Deymo42432912013-07-12 20:21:15 -070033
34 private:
35 DISALLOW_COPY_AND_ASSIGN(Hardware);
36};
37
38} // namespace chromeos_update_engine
39
Alex Deymo759c2752014-03-17 21:09:36 -070040#endif // CHROMEOS_PLATFORM_UPDATE_ENGINE_HARDWARE_H_