The Library constructor is only used for library dependency.
So use a dummy function to make it clear instead of using an
actual function.
Cc: Ray Ni <ray.ni@intel.com>
Cc: Maurice Ma <maurice.ma@intel.com>
Cc: Benjamin You <benjamin.you@intel.com>
Reviewed-by: Ray Ni <ray.ni@intel.com>
Signed-off-by: Guo Dong <guo.dong@intel.com>
#include <Library/PcdLib.h>\r
#include <Library/HobLib.h>\r
\r
#include <Library/PcdLib.h>\r
#include <Library/HobLib.h>\r
\r
+\r
+/** Library Constructor\r
+\r
+ @retval RETURN_SUCCESS Success.\r
+**/\r
+EFI_STATUS\r
+EFIAPI\r
+PlatformHookSerialPortConstructor (\r
+ VOID\r
+ )\r
+{\r
+ // Nothing to do here. This constructor is added to\r
+ // enable the chain of constructor invocation for\r
+ // dependent libraries.\r
+ return RETURN_SUCCESS;\r
+}\r
+\r
/**\r
Performs platform specific initialization required for the CPU to access\r
the hardware associated with a SerialPortLib instance. This function does\r
/**\r
Performs platform specific initialization required for the CPU to access\r
the hardware associated with a SerialPortLib instance. This function does\r
MODULE_TYPE = BASE\r
VERSION_STRING = 1.0\r
LIBRARY_CLASS = PlatformHookLib\r
MODULE_TYPE = BASE\r
VERSION_STRING = 1.0\r
LIBRARY_CLASS = PlatformHookLib\r
- CONSTRUCTOR = PlatformHookSerialPortInitialize\r
+ CONSTRUCTOR = PlatformHookSerialPortConstructor\r
\r
[Sources]\r
PlatformHookLib.c\r
\r
[Sources]\r
PlatformHookLib.c\r