+ GopBlt = NULL;\r
+ Status = TranslateBmpToGopBlt (\r
+ BmpBuffer,\r
+ FileSize,\r
+ &GopBlt,\r
+ &GopBltSize,\r
+ &Height,\r
+ &Width\r
+ );\r
+ if (EFI_ERROR(Status)) {\r
+ Print(L"CapsuleApp: BMP image (%s) is not valid.\n", BmpName);\r
+ goto Done;\r
+ }\r
+ if (GopBlt != NULL) {\r
+ FreePool (GopBlt);\r
+ }\r
+ Print(L"BMP image (%s), Width - %d, Height - %d\n", BmpName, Width, Height);\r
+\r
+ if (Height > Info->VerticalResolution) {\r
+ Status = EFI_INVALID_PARAMETER;\r
+ Print(L"CapsuleApp: BMP image (%s) height is larger than current resolution.\n", BmpName);\r
+ goto Done;\r
+ }\r
+ if (Width > Info->HorizontalResolution) {\r
+ Status = EFI_INVALID_PARAMETER;\r
+ Print(L"CapsuleApp: BMP image (%s) width is larger than current resolution.\n", BmpName);\r
+ goto Done;\r
+ }\r
+\r