## @file MdePkg.dec\r
#\r
-# This Package provides all definitions(including MACROs, strucures and library classes)\r
+# This Package provides all definitions(including functions, MACROs, structures and library classes)\r
# and libraries instances, which are defined in MDE Specification.\r
-# It also provides the definitions(including PPIs/PROTOCOLs/GUIDs) of \r
-# EFI1.10/UEFI2.0/UEFI2.1/PI1.0 and some Industry Stancards.\r
+# It also provides the definitions(including PPIs/PROTOCOLs/GUIDs) of\r
+# EFI1.10/UEFI2.0/UEFI2.1/PI1.0 and some Industry Standards.\r
#\r
# Copyright (c) 2007 - 2008, Intel Corporation.\r
#\r
# the terms and conditions of the BSD License which accompanies this distribution.\r
# The full text of the license may be found at\r
# http://opensource.org/licenses/bsd-license.php\r
-# \r
+#\r
# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,\r
# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.\r
#\r
Include/Ebc\r
\r
[LibraryClasses.common]\r
- ## @libraryclass Provides most usb APIs to support the Hid requests defined in Usb Hid 1.1 spec \r
+ ## @libraryclass Provides most usb APIs to support the Hid requests defined in Usb Hid 1.1 spec\r
# and the standard requests defined in Usb 1.1 spec.\r
##\r
- UsbLib|Include/Library/UsbLib.h\r
+ UefiUsbLib|Include/Library/UefiUsbLib.h\r
\r
## @libraryclass Provides a service to retrieve a pointer to the EFI Runtime Services Table.\r
+ # Only available to DXE and UEFI module types.\r
UefiRuntimeServicesTableLib|Include/Library/UefiRuntimeServicesTableLib.h\r
\r
## @libraryclass Provides library functions for each of the UEFI Runtime Services.\r
+ # Only available to DXE and UEFI module types.\r
UefiRuntimeLib|Include/Library/UefiRuntimeLib.h\r
\r
## @libraryclass Provides library functions for common UEFI operations.\r
##\r
UefiLib|Include/Library/UefiLib.h\r
\r
- ## @libraryclass Module entry point library for UEFI drivers, DXE Drivers and DXE Runtime Drivers\r
+ ## @libraryclass Module entry point library for UEFI drivers, DXE Drivers, DXE SMM Driver and DXE Runtime Drivers\r
UefiDriverEntryPoint|Include/Library/UefiDriverEntryPoint.h\r
\r
- ## @libraryclass UEFI Decompress Library Functions defintion for UEFI compress algorithm\r
+ ## @libraryclass UEFI Decompress Library Functions defintion for UEFI compress algorithm.\r
UefiDecompressLib|Include/Library/UefiDecompressLib.h\r
\r
## @libraryclass Provides a service to retrieve a pointer to the EFI Boot Services Table.\r
+ # Only available to DXE and UEFI module types.\r
UefiBootServicesTableLib|Include/Library/UefiBootServicesTableLib.h\r
\r
## @libraryclass Module entry point library for UEFI Applications.\r
TimerLib|Include/Library/TimerLib.h\r
\r
## @libraryclass Provides library functions to access SMBUS devices.\r
+ # Libraries of this class must be ported to a specific SMBUS controller.\r
SmbusLib|Include/Library/SmbusLib.h\r
\r
## @libraryclass Provides the functions to submit Scsi commands defined in SCSI-2 specification for scsi device.\r
- ScsiLib|Include/Library/ScsiLib.h\r
+ UefiScsiLib|Include/Library/UefiScsiLib.h\r
\r
## @libraryclass Provides a service to publish discovered system resources.\r
ResourcePublicationLib|Include/Library/ResourcePublicationLib.h\r
## @libraryclass Provide services to access I/O Ports and MMIO registers.\r
IoLib|Include/Library/IoLib.h\r
\r
- ## @libraryclass Provides services to create and parse HOBs.\r
+ ## @libraryclass Provides services to create and parse HOBs. Only available for PEI and DXE module types.\r
HobLib|Include/Library/HobLib.h\r
\r
- ## @libraryclass Provides HII related functions.\r
- HiiLib|Include/Library/HiiLib.h\r
-\r
- ## @libraryclass Provides all FVB runtime services defined in PI specification FVB protocol to provide\r
- # low level control interfaces over block-oriented firmware devices.\r
- ##\r
- FvbServiceLib|Include/Library/FvbServiceLib.h\r
-\r
- ## @libraryclass Module entry point library for DXE SMM Driver.\r
- DxeSmmDriverEntryPoint|Include/Library/DxeSmmDriverEntryPoint.h\r
-\r
## @libraryclass Provides a service to retrieve a pointer to the DXE Services Table.\r
# Only available to DXE module types.\r
##\r
## @libraryclass Provides services to maintain instruction and data caches.\r
CacheMaintenanceLib|Include/Library/CacheMaintenanceLib.h\r
\r
- ## @libraryclass Provides copy memory, fill memory, zero memory, and GUID functions. \r
+ ## @libraryclass Provides copy memory, fill memory, zero memory, and GUID functions.\r
BaseMemoryLib|Include/Library/BaseMemoryLib.h\r
\r
## @libraryclass Provides string functions, linked list functions, math functions, synchronization functions\r
##\r
BaseLib|Include/Library/BaseLib.h\r
\r
- ## @libraryclass supports displaying graphical splash screen, locking of keyboard input and\r
- # printing character on screen.\r
- ##\r
- GraphicsLib|Include/Library/GraphicsLib.h\r
-\r
- ## @libraryclass Extract Guided Section Library class defintions that provides many handlers\r
- # for the different guided section data.\r
- ##\r
+ ## @libraryclass This library provides common functions to process the different guided section data.\r
ExtractGuidedSectionLib|Include/Library/ExtractGuidedSectionLib.h\r
\r
- ## @libraryclass Provides a set of interfaces to do IFR opcode creation and interact with a UEFI Form Browser.\r
- IfrSupportLib|Include/Library/IfrSupportLib.h\r
-\r
- ## @libraryclass Provides a set of PI library functions and macros for PEI phase.\r
- PeiPiLib|Include/Library/PeiPiLib.h\r
-\r
- ## @libraryclass Defines a set of Serial Port I/O interfaces.\r
+ ## @libraryclass Provides three common serial I/O port functions.\r
SerialPortLib|Include/Library/SerialPortLib.h\r
\r
## @libraryclass Provides a set of PI library functions and macros for DXE phase.\r
- DxePiLib|Include/Library/DxePiLib.h\r
- \r
+ DxeServicesLib|Include/Library/DxeServicesLib.h\r
+\r
+ ## @libraryclass Provides synchronization functions.\r
+ ##\r
+ SynchronizationLib|Include/Library/SynchronizationLib.h\r
+\r
[LibraryClasses.IPF]\r
## @libraryclass The SAL Library provides a service to make a SAL CALL.\r
SalLib|Include/Library/SalLib.h\r
\r
- ## @libraryclass The PAL Library provides a service to make a PAL CALL.\r
- PalCallLib|Include/Library/PalCallLib.h\r
+ ## @libraryclass Provides library services to make PAL Calls.\r
+ PalLib|Include/Library/PalLib.h\r
\r
[Guids.common]\r
#\r
gEfiEventMemoryMapChangeGuid = { 0x78BEE926, 0x692F, 0x48FD, { 0x9E, 0xDB, 0x01, 0x42, 0x2E, 0xF0, 0xD7, 0xAB }}\r
gEfiEventVirtualAddressChangeGuid = { 0x13FA7698, 0xC831, 0x49C7, { 0x87, 0xEA, 0x8F, 0x43, 0xFC, 0xC2, 0x51, 0x96 }}\r
gEfiEventExitBootServicesGuid = { 0x27ABF055, 0xB1B8, 0x4C26, { 0x80, 0x48, 0x74, 0x8F, 0x37, 0xBA, 0xA2, 0xDF }}\r
+ gEfiDebugPortVariableGuid = { 0xEBA4E8D2, 0x3858, 0x41EC, { 0xA2, 0x81, 0x26, 0x47, 0xBA, 0x96, 0x60, 0xD0 }}\r
+ gEfiDebugPortDevicePathGuid = { 0xEBA4E8D2, 0x3858, 0x41EC, { 0xA2, 0x81, 0x26, 0x47, 0xBA, 0x96, 0x60, 0xD0 }}\r
\r
#\r
# GUID defined in PI1.0\r
[PcdsFeatureFlag.common]\r
## If TRUE, the component name protocol will not be installed.\r
gEfiMdePkgTokenSpaceGuid.PcdComponentNameDisable|FALSE|BOOLEAN|0x0000000d\r
- \r
+\r
## If TRUE, the driver diagnostics protocol will not be installed.\r
gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnosticsDisable|FALSE|BOOLEAN|0x0000000e\r
- \r
+\r
## If TRUE, the component name2 protocol will not be installed.\r
gEfiMdePkgTokenSpaceGuid.PcdComponentName2Disable|FALSE|BOOLEAN|0x000000010\r
- \r
+\r
## If TRUE, the driver diagnostics2 protocol will not be installed.\r
gEfiMdePkgTokenSpaceGuid.PcdDriverDiagnostics2Disable|FALSE|BOOLEAN|0x00000011\r
- \r
+\r
## Indicates whether EFI 1.1 ISO 639-2 language supports are obsolete\r
- gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultLangDeprecate|FALSE|BOOLEAN|0x00000012 .\r
+ gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultLangDeprecate|FALSE|BOOLEAN|0x00000012\r
+\r
+ ## If TRUE, UGA Draw Protocol is still consumed.\r
+ gEfiMdePkgTokenSpaceGuid.PcdUgaConsumeSupport|TRUE|BOOLEAN|0x00000013\r
\r
[PcdsFixedAtBuild.common]\r
## Indicates the maximum length of unicode string\r
gEfiMdePkgTokenSpaceGuid.PcdMaximumUnicodeStringLength|1000000|UINT32|0x00000001\r
- \r
+\r
## Indicates the maximum length of ascii string\r
gEfiMdePkgTokenSpaceGuid.PcdMaximumAsciiStringLength|1000000|UINT32|0x00000002\r
- \r
+\r
## Indicates the maximum node number of linked list\r
gEfiMdePkgTokenSpaceGuid.PcdMaximumLinkedListLength|1000000|UINT32|0x00000003\r
- \r
+\r
## Indicates the timeout tick of holding spin lock\r
gEfiMdePkgTokenSpaceGuid.PcdSpinLockTimeout|10000000|UINT32|0x00000004\r
- \r
+\r
## The mask is used to control DebugLib behavior\r
- gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0x0f|UINT8|0x00000005\r
- \r
+ gEfiMdePkgTokenSpaceGuid.PcdDebugPropertyMask|0|UINT8|0x00000005\r
+\r
## This flag is used to control the printout of DebugLib\r
- gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel|0x80000000|UINT32|0x00000006\r
- \r
+ gEfiMdePkgTokenSpaceGuid.PcdDebugPrintErrorLevel|0|UINT32|0x00000006\r
+\r
## The mask is used to control ReportStatusCodeLib behavior\r
- gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|0x06|UINT8|0x00000007\r
- \r
+ gEfiMdePkgTokenSpaceGuid.PcdReportStatusCodePropertyMask|0|UINT8|0x00000007\r
+\r
## This value is used to fill a segment of memory\r
gEfiMdePkgTokenSpaceGuid.PcdDebugClearMemoryValue|0xAF|UINT8|0x00000008\r
\r
\r
## This value is used to set the base address of pci express hierarchy\r
gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress|0xE0000000|UINT64|0x0000000a\r
- \r
+\r
## The mask is used to control PostCodeLib behavior\r
gEfiMdePkgTokenSpaceGuid.PcdPostCodePropertyMask|0|UINT8|0x0000000b\r
- \r
+\r
## This value is used to set the FSB clock\r
gEfiMdePkgTokenSpaceGuid.PcdFSBClock|200000000|UINT32|0x0000000c\r
- \r
+\r
## The maxium allowable size of formatted unicode string\r
gEfiMdePkgTokenSpaceGuid.PcdUefiLibMaxPrintBufferSize|320|UINT32|0x101\r
- \r
+\r
## Status code value for indicating a watchdog timer is expired\r
- # EFI_COMPUTING_UNIT_HOST_PROCESSOR | EFI_CU_HP_EC_TIMER_EXPIRED\r
- gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueEfiWatchDogTimerExpired|0x00011003|UINT32|0x00000013 \r
+ gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueEfiWatchDogTimerExpired|0x00011003|UINT32|0x00000013\r
\r
## Status code value for indicating the invocation of SetVirtualAddressMap()\r
- # EFI_SOFTWARE_EFI_BOOT_SERVICE | EFI_SW_RS_PC_SET_VIRTUAL_ADDRESS_MAP\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueSetVirtualAddressMap|0x03101004|UINT32|0x00000014\r
\r
## Status code value for indicating the start of memory test\r
- # EFI_COMPUTING_UNIT_MEMORY | EFI_CU_MEMORY_PC_TEST\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueMemoryTestStarted|0x00051006|UINT32|0x00000015\r
\r
## Status code value for indicating memory error in memory test\r
- # EFI_COMPUTING_UNIT_MEMORY | EFI_CU_MEMORY_EC_UNCORRECTABLE\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueUncorrectableMemoryError|0x00051003|UINT32|0x00000016\r
\r
## Status code value for indicating the failure of console operation\r
- # EFI_PERIPHERAL_REMOTE_CONSOLE | EFI_P_EC_CONTROLLER_ERROR\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueRemoteConsoleError|0x01040006|UINT32|0x00000017\r
\r
## Status code value for indicating the failure of console reset operation\r
- # EFI_PERIPHERAL_REMOTE_CONSOLE | EFI_P_PC_RESET\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueRemoteConsoleReset|0x01040001|UINT32|0x00000018\r
\r
## Status code value for indicating the failure of console input operation\r
- # EFI_PERIPHERAL_REMOTE_CONSOLE | EFI_P_EC_INPUT_ERROR\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueRemoteConsoleInputError|0x01040007|UINT32|0x00000019\r
\r
## Status code value for indicating the failure of console output operation\r
- # EFI_PERIPHERAL_REMOTE_CONSOLE | EFI_P_EC_OUTPUT_ERROR\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueRemoteConsoleOutputError|0x01040008|UINT32|0x0000001a\r
\r
## Status code value for indicating the failure of mouse operation\r
\r
## Status code value for indicating the enable of mouse device\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueMouseEnable|0x01020004|UINT32|0x30001001\r
- \r
+\r
## Status code value for indicating the disable of mouse device\r
- gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueMouseDisable|0x01020002|UINT32|0x3001002\r
+ gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueMouseDisable|0x01020002|UINT32|0x30001002\r
\r
## Status code value for indicating the enable of keyboard device\r
- gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueKeyboardEnable|0x01010004|UINT32|0x3001003\r
+ gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueKeyboardEnable|0x01010004|UINT32|0x30001003\r
\r
## Status code value for indicating the disable of keyboard device\r
- gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueKeyboardDisable|0x01010002|UINT32|0x3001004\r
+ gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueKeyboardDisable|0x01010002|UINT32|0x30001004\r
\r
## Status code value for indicating whether keboard device is present\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueKeyboardPresenceDetect|0x01010003|UINT32|0x30001005\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueKeyboardInputError|0x01010007|UINT32|0x3000100a\r
\r
## Status code value for indicating the failure of mouse input handler\r
- gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueMouseInputError|0x01020007|UINT32|0x30001000b\r
+ gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueMouseInputError|0x01020007|UINT32|0x3000100b\r
\r
## Status code value for indicating the reset operation of mouse device\r
- gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueMouseReset|0x01020001|UINT32|0x30001000c\r
+ gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueMouseReset|0x01020001|UINT32|0x3000100c\r
\r
## Indicates the allowable maximum number in extract handler table\r
gEfiMdePkgTokenSpaceGuid.PcdMaximumGuidedExtractHandler|0x10|UINT32|0x00000025\r
\r
## Default current ISO 639-2 language: English\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultLang|"eng"|VOID*|0x0000001d\r
- \r
+\r
## Default platform supported RFC 3066 languages: (American) English & French\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultPlatformLangCodes|"en-US;fr-FR"|VOID*|0x0000001e\r
- \r
+\r
## Defualt current RFC 3066 language: (American) English\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultPlatformLang|"en-US"|VOID*|0x0000001f\r
- \r
+\r
## Default current ISO 639-2 language: English & French\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultLangCodes|"engfra"|VOID*|0x0000001c\r
- \r
+\r
## Indicates the default baud rate of UART\r
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|115200|UINT64|0x00000020\r
- \r
+\r
## Indicates the number of efficient data bit in UART transaction\r
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultDataBits|8|UINT8|0x00000021\r
- \r
+\r
## Indicates the setting of data parity in UART transaction\r
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultParity|1|UINT8|0x00000022\r
- \r
+\r
## Indicates the setting of stop bit in UART transaction\r
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultStopBits|1|UINT8|0x00000023\r
- \r
+\r
## Indicates the usable type of terminal\r
# 0-PCANSI, 1-VT100, 2-VT00+, 3-UTF8\r
- gEfiMdePkgTokenSpaceGuid.PcdDefaultTerminalType|0|UINT8|0x00000024 \r
- \r
+ gEfiMdePkgTokenSpaceGuid.PcdDefaultTerminalType|0|UINT8|0x00000024\r
+\r
## Status code value for indicating the handoff from Pei phase to Dxe phase\r
- # EFI_SOFTWARE_PEI_MODULE | EFI_SW_PEI_CORE_PC_HANDOFF_TO_NEXT\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValuePeiHandoffToDxe|0x3031001|UINT32|0x3000100d\r
\r
## Status code value for indicating one PEIM is dispatched.\r
- # value: EFI_SOFTWARE_PEI_CORE | EFI_SW_PC_INIT_BEGIN\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValuePeimDispatch|0x3020002|UINT32|0x3000100e\r
\r
## Status code value for indicating entering PeiCore\r
- # value: EFI_SOFTWARE_PEI_CORE | EFI_SW_PC_INIT\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValuePeiCoreEntry|0x3020000|UINT32|0x3000100f\r
\r
## Status code value for indicating entering DxeCore\r
- # EFI_SOFTWARE_DXE_CORE | EFI_SW_DXE_CORE_PC_ENTRY_POINT\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueDxeCoreEntry|0x3041000|UINT32|0x30001010\r
\r
## Status code value for indicating the handoff from DxeCore to Bds\r
- # EFI_SOFTWARE_DXE_CORE | EFI_SW_DXE_CORE_PC_HANDOFF_TO_NEXT\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueDxeCoreHandoffToBds|0x3041001|UINT32|0x30001011\r
\r
## Status code value for indicating the exit of boot service\r
- # EFI_SOFTWARE_EFI_BOOT_SERVICE | EFI_SW_BS_PC_EXIT_BOOT_SERVICES\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueBootServiceExit|0x3100019|UINT32|0x30001012\r
\r
## Status code value for indicating the begin of Dxe driver\r
- # EFI_SOFTWARE_DXE_CORE | EFI_SW_PC_INIT_BEGIN\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueDxeDriverBegin|0x3040002|UINT32|0x30001013\r
\r
## Status code value for indicating the end of Dxe driver\r
- # EFI_SOFTWARE_DXE_CORE | EFI_SW_PC_INIT_END\r
gEfiMdePkgTokenSpaceGuid.PcdStatusCodeValueDxeDriverEnd|0x3040003|UINT32|0x30001014\r
\r
[PcdsFixedAtBuild.IPF]\r
\r
## Default current ISO 639-2 language: English & French\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultLangCodes|"engfra"|VOID*|0x0000001c\r
- \r
+\r
## Default current ISO 639-2 language: English\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultLang|"eng"|VOID*|0x0000001d\r
- \r
+\r
## Default platform supported RFC 3066 languages: (American) English & French\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultPlatformLangCodes|"en-US;fr-FR"|VOID*|0x0000001e\r
- \r
+\r
## Defualt current RFC 3066 language: (American) English\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultPlatformLang|"en-US"|VOID*|0x0000001f\r
- \r
+\r
## Indicates the default baud rate of UART\r
gEfiMdePkgTokenSpaceGuid.PcdUartDefaultBaudRate|115200|UINT64|0x00000020\r
\r
\r
## Default current ISO 639-2 language: English\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultLang|"eng"|VOID*|0x0000001d\r
- \r
+\r
## Default platform supported RFC 3066 languages: (American) English & French\r
gEfiMdePkgTokenSpaceGuid.PcdUefiVariableDefaultPlatformLangCodes|"en-US;fr-FR"|VOID*|0x0000001e\r
\r
## Indicates the usable type of terminal\r
# 0-PCANSI, 1-VT100, 2-VT00+, 3-UTF8\r
gEfiMdePkgTokenSpaceGuid.PcdDefaultTerminalType|0|UINT8|0x00000024\r
- \r
+\r
## This value is used to set the base address of pci express hierarchy\r
gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress|0xE0000000|UINT64|0x0000000a\r
-\r
-\r
-\r