-
Notifications
You must be signed in to change notification settings - Fork 17
Expand file tree
/
Copy pathdevice.hpp
More file actions
33 lines (27 loc) · 805 Bytes
/
device.hpp
File metadata and controls
33 lines (27 loc) · 805 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/* Interface for Linux/Unix devices.
*
* Author: Pascal Bauer <pascal.bauer@rwth-aachen.de>
*
* SPDX-FileCopyrightText: 2023-2024 Pascal Bauer <pascal.bauer@rwth-aachen.de>
* SPDX-License-Identifier: Apache-2.0
*/
#pragma once
#include <filesystem>
#include <optional>
#include <villas/kernel/devices/driver.hpp>
namespace villas {
namespace kernel {
namespace devices {
class Device {
public:
virtual ~Device(){};
virtual std::optional<std::unique_ptr<Driver>> driver() const = 0;
virtual std::optional<int> iommu_group() const = 0;
virtual std::string name() const = 0;
virtual std::filesystem::path override_path() const = 0;
virtual std::filesystem::path path() const = 0;
virtual void probe() const = 0;
};
} // namespace devices
} // namespace kernel
} // namespace villas