blob: f45b5bef14806089f23dbd89b286fc9aec01a139 [file] [log] [blame]
Francis Murtagh1f7db452019-08-14 09:49:34 +01001//
Jim Flynnbbfe6032020-07-20 16:57:44 +01002// Copyright © 2017 Arm Ltd and Contributors. All rights reserved.
Francis Murtagh1f7db452019-08-14 09:49:34 +01003// SPDX-License-Identifier: MIT
4//
5
6#pragma once
7
8#include <cstdint>
9
Jim Flynnbbfe6032020-07-20 16:57:44 +010010namespace arm
Aron Virginas-Tare898db92019-08-22 12:56:34 +010011{
12
Jim Flynnbbfe6032020-07-20 16:57:44 +010013namespace pipe
Aron Virginas-Tare898db92019-08-22 12:56:34 +010014{
15
Francis Murtagh1f7db452019-08-14 09:49:34 +010016class CommandHandlerKey
17{
18public:
Jim Flynn397043f2019-10-17 17:37:10 +010019 CommandHandlerKey(uint32_t familyId, uint32_t packetId, uint32_t version)
20 : m_FamilyId(familyId), m_PacketId(packetId), m_Version(version) {};
Francis Murtagh1f7db452019-08-14 09:49:34 +010021
Jim Flynn397043f2019-10-17 17:37:10 +010022 uint32_t GetFamilyId() const;
Francis Murtagh1f7db452019-08-14 09:49:34 +010023 uint32_t GetPacketId() const;
24 uint32_t GetVersion() const;
25
26 bool operator< (const CommandHandlerKey& rhs) const;
27 bool operator> (const CommandHandlerKey& rhs) const;
28 bool operator<=(const CommandHandlerKey& rhs) const;
29 bool operator>=(const CommandHandlerKey& rhs) const;
30 bool operator==(const CommandHandlerKey& rhs) const;
31 bool operator!=(const CommandHandlerKey& rhs) const;
32
33private:
Jim Flynn397043f2019-10-17 17:37:10 +010034 uint32_t m_FamilyId;
Francis Murtagh1f7db452019-08-14 09:49:34 +010035 uint32_t m_PacketId;
36 uint32_t m_Version;
37};
Aron Virginas-Tare898db92019-08-22 12:56:34 +010038
Jim Flynnbbfe6032020-07-20 16:57:44 +010039} // namespace pipe
Aron Virginas-Tare898db92019-08-22 12:56:34 +010040
Jim Flynnbbfe6032020-07-20 16:57:44 +010041} // namespace arm