1
0
Fork 0
mirror of https://git.rwth-aachen.de/acs/public/villas/node/ synced 2025-03-09 00:00:00 +01:00

cleanup code

Signed-off-by: Pascal Bauer <pascal.bauer@rwth-aachen.de>
This commit is contained in:
Pascal Bauer 2024-09-04 18:19:12 +02:00
parent 46065f3ab3
commit 6e7c9c61d9

View file

@ -29,9 +29,7 @@ std::optional<int> PlatformDevice::iommu_group() const {
std::filesystem::path symlink =
std::filesystem::path(this->m_path.u8string() + "/iommu_group");
std::filesystem::path link;
link = std::filesystem::read_symlink(symlink);
std::filesystem::path link = std::filesystem::read_symlink(symlink);
std::string delimiter = "iommu_groups/";
int pos = link.u8string().find(delimiter);
int iommu_group = std::stoi(link.u8string().substr(pos + delimiter.length()));