Maybe this is me being slow, but could this not be described as PcdGetPtr(id##MppSel##num)?
Yes it seems to be better approach to use "PcdGet()" macro with preprocessor concatenation.
Why is this done as a preprocessor macro? Could it be a STATIC function instead?
It is macro, because GET_PCD_PTR, GET_PIN_COUNT, GET_BASE, GET_REV_FLAG use concatenation and argument "id" has to be defined during preprocessing. This macro is invoked 4 times since we can have up to 4 different chips. Inside function, there will be no possibility to invoke above macros with different arguments. It will be necessary to create four different functions.
Should this not be OpenPlatformMarvellPkg (or suchlike)?
Ok.