UEFITool/types.h
Nikolaj Schlej aa80837bf5 UT 0.21.0
- added support for new Intel descriptor type, based on
[this](http://review.coreboot.org/gitweb?p=coreboot.git;a=commit;h=1f7fd720c81755144423f2d4062c39cc651adc0a)
coreboot commit, thanks to lordkag for issue #32
- solved a bug with incorrect volume free space item placement during
volume replace, now works as expected
- solved an issue with incorrect Aptio capsule parsing introduced in
0.20.8
2015-09-06 23:46:26 +02:00

90 lines
1.8 KiB
C++

/* types.h
Copyright (c) 2015, Nikolaj Schlej. All rights reserved.
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
http://opensource.org/licenses/bsd-license.php
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
*/
#ifndef __TYPES_H__
#define __TYPES_H__
#include "basetypes.h"
// Actions
namespace Actions
{
enum ActionTypes {
NoAction = 50,
Create,
Insert,
Replace,
Remove,
Rebuild,
Rebase
};
}
// Types
namespace Types {
enum ItemTypes {
Root = 60,
Capsule,
Image,
Region,
Padding,
Volume,
File,
Section,
FreeSpace
};
}
namespace Subtypes {
enum ImageSubtypes{
IntelImage = 70,
UefiImage
};
enum CapsuleSubtypes {
AptioSignedCapsule = 80,
AptioUnsignedCapsule,
UefiCapsule,
ToshibaCapsule
};
enum VolumeSubtypes {
UnknownVolume = 90,
Ffs2Volume,
Ffs3Volume
};
enum RegionSubtypes {
DescriptorRegion = 100,
GbeRegion,
MeRegion,
BiosRegion,
PdrRegion,
EcRegion
};
enum PaddingSubtypes {
ZeroPadding = 110,
OnePadding,
DataPadding
};
};
// *ToQString conversion routines
extern QString actionTypeToQString(const UINT8 action);
extern QString itemTypeToQString(const UINT8 type);
extern QString itemSubtypeToQString(const UINT8 type, const UINT8 subtype);
extern QString compressionTypeToQString(const UINT8 algorithm);
extern QString regionTypeToQString(const UINT8 type);
#endif