ArmPkg/ArmScmiDxe: Dynamically allocate buffer for protocol ids

Dynamically allocate the buffer to receive the SCMI protocol list.
This makes MAX_PROTOCOLS redundant, so it is removed.
It also fixes one minor code alignment issue and removes an unused
macro PROTOCOL_MASK.

Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Girish Pathak <girish.pathak@arm.com>
Tested-by: Sudeep Holla <sudeep.holla@arm.com>
Reviewed-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
This commit is contained in:
Girish Pathak
2018-06-19 14:53:53 +01:00
committed by Ard Biesheuvel
parent 889cf68c3c
commit 3b03b5e990
3 changed files with 21 additions and 12 deletions

View File

@@ -22,11 +22,6 @@
#include "ScmiPrivate.h"
// SCMI Specification 1.0
#define MAX_PROTOCOLS 6
#define PROTOCOL_MASK 0xF
// Arbitrary timeout value 20ms.
#define RESPONSE_TIMEOUT 20000