]> git.proxmox.com Git - mirror_edk2.git/blame - MdeModulePkg/Include/Library/DisplayUpdateProgressLib.h
MdeModulePkg: Add DisplayUpdateProgressLib class
[mirror_edk2.git] / MdeModulePkg / Include / Library / DisplayUpdateProgressLib.h
CommitLineData
825d138f
MK
1/** @file\r
2 Provides services to display completion progress when processing a\r
3 firmware update that updates the firmware image in a firmware device.\r
4 A platform may provide its own instance of this library class to custoimize\r
5 how a user is informed of completion progress.\r
6\r
7 Copyright (c) 2016, Microsoft Corporation\r
8 Copyright (c) 2018, Intel Corporation. All rights reserved.<BR>\r
9\r
10 All rights reserved.\r
11 Redistribution and use in source and binary forms, with or without\r
12 modification, are permitted provided that the following conditions are met:\r
13 1. Redistributions of source code must retain the above copyright notice,\r
14 this list of conditions and the following disclaimer.\r
15 2. Redistributions in binary form must reproduce the above copyright notice,\r
16 this list of conditions and the following disclaimer in the documentation\r
17 and/or other materials provided with the distribution.\r
18\r
19 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND\r
20 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED\r
21 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.\r
22 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,\r
23 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,\r
24 BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,\r
25 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF\r
26 LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE\r
27 OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF\r
28 ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\r
29\r
30**/\r
31\r
32#ifndef __DISPLAY_PROGRESS_LIB__\r
33#define __DISPLAY_PROGRESS_LIB__\r
34\r
35#include <Protocol/GraphicsOutput.h>\r
36\r
37/**\r
38 Indicates the current completion progress of a firmware update.\r
39\r
40 @param[in] Completion A value between 0 and 100 indicating the current\r
41 completion progress of a firmware update. This\r
42 value must the the same or higher than previous\r
43 calls to this service. The first call of 0 or a\r
44 value of 0 after reaching a value of 100 resets\r
45 the progress indicator to 0.\r
46 @param[in] Color Color of the progress indicator. Only used when\r
47 Completion is 0 to set the color of the progress\r
48 indicator. If Color is NULL, then the default color\r
49 is used.\r
50\r
51 @retval EFI_SUCCESS Progress displayed successfully.\r
52 @retval EFI_INVALID_PARAMETER Completion is not in range 0..100.\r
53 @retval EFI_INVALID_PARAMETER Completion is less than Completion value from\r
54 a previous call to this service.\r
55 @retval EFI_NOT_READY The device used to indicate progress is not\r
56 available.\r
57**/\r
58EFI_STATUS\r
59EFIAPI\r
60DisplayUpdateProgress (\r
61 IN UINTN Completion,\r
62 IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL_UNION *Color OPTIONAL\r
63 );\r
64\r
65#endif\r