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

small code review

Signed-off-by: Niklas Eiling <niklas.eiling@eonerc.rwth-aachen.de>
This commit is contained in:
Niklas Eiling 2023-01-06 11:14:34 +01:00
parent 14f924b6c5
commit 5ab6007909
2 changed files with 4 additions and 6 deletions

View file

@ -36,16 +36,14 @@ public:
virtual ~Card();
bool mapMemoryBlock(const std::shared_ptr<MemoryBlock> block);
bool unmapMemoryBlock(const MemoryBlock &block);
std::shared_ptr<kernel::vfio::Container> vfioContainer;
std::shared_ptr<ip::Core> lookupIp(const std::string &name) const;
std::shared_ptr<ip::Core> lookupIp(const Vlnv &vlnv) const;
std::shared_ptr<ip::Core> lookupIp(const ip::IpIdentifier &id) const;
bool mapMemoryBlock(const std::shared_ptr<MemoryBlock> block);
bool unmapMemoryBlock(const MemoryBlock &block);
std::shared_ptr<kernel::vfio::Container> vfioContainer;
protected:
// Keep a map of already mapped memory blocks
std::map<MemoryManager::AddressSpaceId, std::shared_ptr<MemoryBlock>> memoryBlocksMapped;

View file

@ -63,7 +63,7 @@ void fpga::ConnectString::parseString(std::string& connectString)
return;
}
std::regex regex("([0-9]+)([<\\->]+)([0-9]+|stdin|stdout)");
static const std::regex regex("([0-9]+)([<\\->]+)([0-9]+|stdin|stdout)");
std::smatch match;
if (!std::regex_match(connectString, match, regex) || match.size() != 4) {