Skip to content

Commit

Permalink
Updated API documentation and HII strings to use new marketing terms.
Browse files Browse the repository at this point in the history
Signed-off-by: Sydney Young <[email protected]>
  • Loading branch information
Sydney Young authored and StevenPontsler committed Mar 3, 2020
1 parent a3805b0 commit aeefc38
Show file tree
Hide file tree
Showing 86 changed files with 2,484 additions and 1,219 deletions.
10 changes: 5 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -640,11 +640,11 @@ if((ASCIIDOCTOR_FOUND OR A2X_FOUND) AND LNX_BUILD)

set(DOCUMENTATION_INPUT_FILES
${ROOT}/Documentation/ipmctl/ipmctl.txt
${ROOT}/Documentation/ipmctl/DIMM_Discovery/ipmctl-show-device.txt
${ROOT}/Documentation/ipmctl/DIMM_Discovery/ipmctl-show-memory-resources.txt
${ROOT}/Documentation/ipmctl/DIMM_Discovery/ipmctl-show-socket.txt
${ROOT}/Documentation/ipmctl/DIMM_Discovery/ipmctl-show-system-capabilities.txt
${ROOT}/Documentation/ipmctl/DIMM_Discovery/ipmctl-show-topology.txt
${ROOT}/Documentation/ipmctl/Discovery/ipmctl-show-device.txt
${ROOT}/Documentation/ipmctl/Discovery/ipmctl-show-memory-resources.txt
${ROOT}/Documentation/ipmctl/Discovery/ipmctl-show-socket.txt
${ROOT}/Documentation/ipmctl/Discovery/ipmctl-show-system-capabilities.txt
${ROOT}/Documentation/ipmctl/Discovery/ipmctl-show-topology.txt
${ROOT}/Documentation/ipmctl/Memory_Subsystem_Provisioning/ipmctl-change-device-passphrase.txt
${ROOT}/Documentation/ipmctl/Memory_Subsystem_Provisioning/ipmctl-change-device-security.txt
${ROOT}/Documentation/ipmctl/Memory_Subsystem_Provisioning/ipmctl-create-goal.txt
Expand Down
21 changes: 11 additions & 10 deletions DcpmPkg/cli/CommandParser.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#include <Debug.h>
#include <Types.h>
#include <Printer.h>
#include <Utility.h>

#define DISP_NAME_LEN 32 //!< Display string length (used when formatting output in alternative formats)
#define DISP_DELIMS_LEN 10 //!< Deliminter string length (used when formatting output in alternative formats)
Expand Down Expand Up @@ -63,7 +64,7 @@
#define FORCE_OPTION_DETAILS_TEXT L"Suppress confirmations" //!< 'force' option help text detail
#define RECOVER_OPTION L"-recover" //!< 'recover' option name
#define RECOVER_OPTION_FLASH_SPI L"FlashSPI" //!< 'recover' option value to FlashSpi during update
#define RECOVER_OPTION_DETAILS_TEXT L"Run update on non-functional DCPMMs only (deprecated) or run SPI Flash recovery" //!< 'recover' option value to FlashSpi during update
#define RECOVER_OPTION_DETAILS_TEXT L"Run update on non-functional" PMEM_MODULES_STR L"only (deprecated) or run SPI Flash recovery" //!< 'recover' option value to FlashSpi during update
#define UNITS_OPTION L"-units" //!< 'units' option name
#define UNITS_OPTION_B L"B" //!< 'units' option value for B
#define UNITS_OPTION_MB L"MB" //!< 'units' option value for MB
Expand Down Expand Up @@ -261,18 +262,18 @@
#define DCPMM_PERFORMANCE_TOTAL_WRITE_REQUESTS L"TotalWriteRequests"

/** Sensor Detail Messages **/
#define DIMM_HEALTH_STR_DETAIL L"Health - The current DCPMM health as reported in the SMART log"
#define MEDIA_TEMPERATURE_STR_DETAIL L"MediaTemperature-The current DCPMM media temperature in Celsius"
#define CONTROLLER_TEMPERATURE_STR_DETAIL L"ControllerTemperature - The current DCPMM controller temperature in Celsius"
#define SPARE_CAPACITY_STR_DETAIL L"PercentageRemaining - Remaining DCPMMs life as a percentage value of factory expected\
#define DIMM_HEALTH_STR_DETAIL L"Health - The current " PMEM_MODULE_STR L" health as reported in the SMART log"
#define MEDIA_TEMPERATURE_STR_DETAIL L"MediaTemperature - The current " PMEM_MODULE_STR L" media temperature in Celsius"
#define CONTROLLER_TEMPERATURE_STR_DETAIL L"ControllerTemperature - The current " PMEM_MODULE_STR " controller temperature in Celsius"
#define SPARE_CAPACITY_STR_DETAIL L"PercentageRemaining - Remaining " PMEM_MODULES_STR L" life as a percentage value of factory expected\
life spa"
#define LATCHED_DIRTY_SHUTDOWN_COUNT_STR_DETAIL L"LatchedDirtyShutdownCount - The number of shutdowns without notification over the lifetime of\
the DCPMM"
the " PMEM_MODULE_STR
#define UNLATCHED_DIRTY_SHUTDOWN_COUNT_STR_DETAIL L"UnlatchedDirtyShutdownCount - The number of shutdowns without notification over the lifetime of\
the DCPMM."
#define POWER_ON_TIME_STR_DETAIL L"PowerOnTime - The total power-on time over the lifetime of the DCPMM"
#define UPTIME_STR_DETAIL L"UpTime - The total power-on time since the last power cycle of the DCPMM"
#define POWER_CYCLES_STR_DETAIL L"PowerCycles - The number of power cycles over the lifetime of the DCPMM"
the " PMEM_MODULE_STR L"."
#define POWER_ON_TIME_STR_DETAIL L"PowerOnTime - The total power-on time over the lifetime of the " PMEM_MODULE_STR
#define UPTIME_STR_DETAIL L"UpTime - The total power-on time since the last power cycle of the " PMEM_MODULE_STR
#define POWER_CYCLES_STR_DETAIL L"PowerCycles - The number of power cycles over the lifetime of the " PMEM_MODULE_STR
#define FW_ERROR_COUNT_STR_DETAIL L"FwErrorCount - The total number of firmware error log entries"


Expand Down
2 changes: 1 addition & 1 deletion DcpmPkg/cli/Common.c
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@ GetDimmIdsFromString(

if (!DimmIdFound) {
Rc = EFI_NOT_FOUND;
PRINTER_SET_MSG(pCmd->pPrintCtx, Rc, L"DIMM not found. Invalid DimmID: " FORMAT_STR_NL, ppDimmIdTokensStr[Index]);
PRINTER_SET_MSG(pCmd->pPrintCtx, Rc, PMEM_MODULE_STR L" not found. Invalid DimmID: " FORMAT_STR_NL, ppDimmIdTokensStr[Index]);
goto FinishError;
}
}
Expand Down
34 changes: 17 additions & 17 deletions DcpmPkg/cli/Common.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ typedef struct _CMD_DISPLAY_OPTIONS {
#define CLI_ARGS_STR L"Args"
#define TAG_STR L"Tag"
#define DDR_STR L"DDR"
#define DCPMM_STR L"DCPMM"
// Find PMEM_MODULE_STR in CommandParser.h
#define TOTAL_STR L"Total"
#define MEMORY_TYPE_STR L"MemoryType"

Expand Down Expand Up @@ -76,8 +76,8 @@ typedef struct _CMD_DISPLAY_OPTIONS {
#define CLI_ERR_FAILED_TO_FIND_PROTOCOL L"Error: DCPMM_CONFIG2_PROTOCOL not found."
#define CLI_ERR_INVALID_REGION_ID L"Error: The region identifier is not valid."
#define CLI_ERR_INVALID_NAMESPACE_ID L"Error: The namespace identifier is not valid."
#define CLI_ERR_NO_DIMMS_ON_SOCKET L"Error: There are no DIMMs on the specified socket(s)."
#define CLI_ERR_NO_SPECIFIED_DIMMS_ON_SPECIFIED_SOCKET L"Error: None of the specified dimm(s) belong to the specified socket(s)."
#define CLI_ERR_NO_DIMMS_ON_SOCKET L"Error: There are no " PMEM_MODULES_STR L" on the specified socket(s)."
#define CLI_ERR_NO_SPECIFIED_DIMMS_ON_SPECIFIED_SOCKET L"Error: None of the specified " PMEM_MODULE_STR L"(s) belong to the specified socket(s)."
#define CLI_ERR_INVALID_SOCKET_ID L"Error: The socket identifier is not valid."
#define CLI_ERR_OUT_OF_MEMORY L"Error: There is not enough memory to complete the requested operation."
#define CLI_ERR_WRONG_FILE_PATH L"Error: Wrong file path."
Expand All @@ -91,7 +91,7 @@ typedef struct _CMD_DISPLAY_OPTIONS {
#define CLI_ERR_POPULATION_VIOLATION L"Error: The specified device is in population violation."
#define CLI_ERR_REGION_TO_SOCKET_MAPPING L"The specified region id might not exist on the specified Socket(s).\n"
#define CLI_ERR_PCD_CORRUPTED L"Error: Unable to complete operation due to existing PCD Configuration partition corruption. Use create -f -goal to override current PCD and create goal."
#define CLI_ERR_OPENING_PBR_PROTOCOL L"Error: Communication with the device driver failed. Failed to obtain PBR protocol."
#define CLI_ERR_OPENING_PBR_PROTOCOL L"Error: Communication with the device driver failed. Failed to obtain PBR protocol."
#define CLI_ERR_NMFM_LOWER_VIOLATION L"WARNING! The requested memory mode size for 2LM goal is below the recommended NM:FM limit of 1:%d"
#define CLI_ERR_NMFM_UPPER_VIOLATION L"WARNING! The requested memory mode size for 2LM goal is above the recommended NM:FM limit of 1:%d"

Expand Down Expand Up @@ -155,30 +155,30 @@ typedef struct _CMD_DISPLAY_OPTIONS {

#define CLI_ERR_PROPERTIES_MEMORYMODE_RESERVED_TOO_LARGE L"Syntax Error: Properties MemoryMode and Reserved cannot sum greater than 100%%%%" //%%%% because format string is processed twice

#define CLI_INFO_NO_DIMMS L"No DIMMs in the system."
#define CLI_INFO_NO_FUNCTIONAL_DIMMS L"No functional DIMMs in the system."
#define CLI_INFO_NO_DIMMS L"No " PMEM_MODULES_STR L" in the system."
#define CLI_INFO_NO_FUNCTIONAL_DIMMS L"No functional " PMEM_MODULES_STR L" in the system."
#define CLI_INFO_NO_REGIONS L"There are no Regions defined in the system."
#define CLI_INFO_NO_MANAGEABLE_DIMMS L"No manageable DIMMs in the system."
#define CLI_INFO_NO_NON_FUNCTIONAL_DIMMS L"No non-functional DIMMs in the system."
#define CLI_INFO_NO_MANAGEABLE_DIMMS L"No manageable " PMEM_MODULES_STR L" in the system."
#define CLI_INFO_NO_NON_FUNCTIONAL_DIMMS L"No non-functional " PMEM_MODULES_STR L" in the system."
#define CLI_INFO_SHOW_REGION L"Show Region"
#define CLI_INFO_NO_NAMESPACES_DEFINED L"No Namespaces defined in the system."
#define CLI_INFO_SHOW_NAMESPACE L"Show Namespace"
#define CLI_INFO_SET_NAMESPACE L"Set Namespace"
#define CLI_INFO_DELETE_NAMESPACE L"Delete Namespace"
#define CLI_INFO_DUMP_DEBUG_LOG L"Dump Debug Log"
#define CLI_INFO_LOAD_GOAL L"Load Goal"
#define CLI_INFO_LOAD_GOAL_CONFIRM_PROMPT L"Load the configuration goal from '" FORMAT_STR L"' which will delete existing data and provision the capacity of the DIMMs on the next reboot."
#define CLI_INFO_LOAD_GOAL_CONFIRM_PROMPT L"Load the configuration goal from '" FORMAT_STR L"' which will delete existing data and provision the capacity of the " PMEM_MODULES_STR L" on the next reboot."
#define CLI_INFO_SHOW_REGISTER L"Show Register"

#define CLI_ERR_MASTER_PASSPHRASE_NOT_ENABLED L"Master Passphrase not enabled on specified dimms."
#define CLI_ERR_MASTER_PASSPHRASE_NOT_ENABLED L"Master Passphrase not enabled on specified " PMEM_MODULES_STR L"."
#define CLI_ERR_MISSING_PASSPHRASE_PROPERTY L"Syntax Error: Passphrase property not provided."
#define CLI_ERR_DEFAULT_OPTION_NOT_COMBINED L"Syntax Error: Default option should be given in combination with master option."
#define CLI_ERR_DEFAULT_OPTION_PASSPHRASE_PROPERTY_USED_TOGETHER L"Syntax Error: Passphrase property and default option cannot be used together."

#define CLI_ERR_FORCE_REQUIRED L"Error: This command requires force option."
#define CLI_ERR_INVALID_BLOCKSIZE_FOR_CAPACITY L"Error: Capacity property can only be used with 512 or 4096 bytes block size."
#define CLI_ERR_INVALID_NAMESPACE_CAPACITY L"Error: Invalid value for namespace capacity."
#define CLI_ERR_SOME_VALUES_NOT_SUPPORTED L"Error: One or more of the fields specified are not supported on all the DIMMs."
#define CLI_ERR_SOME_VALUES_NOT_SUPPORTED L"Error: One or more of the fields specified are not supported on all the " PMEM_MODULES_STR L"."
#define CLI_ERR_VERSION_RETRIEVE L": Unable to retrieve version from FW image."
#define CLI_ERR_PRINTING_DIAGNOSTICS_RESULTS L"Error: Printing of diagnostics results failed."
#define CLI_INJECT_ERROR_FAILED L"Error: Inject error command failed"
Expand All @@ -190,9 +190,9 @@ typedef struct _CMD_DISPLAY_OPTIONS {

#define CLI_INFO_LOAD_FW L"Load FW"
#define CLI_INFO_LOAD_RECOVER_FW L"Load recovery FW"
#define CLI_INFO_LOAD_RECOVER_INVALID_DIMM L"The specified dimm does not exist or is not in a non-functional state."
#define CLI_INFO_LOAD_RECOVER_INVALID_DIMM L"The specified " PMEM_MODULE_STR L" does not exist or is not in a non-functional state."
#define CLI_INFO_ON L" on"
#define CLI_PROGRESS_STR L"\rOperation on DIMM 0x%04x Progress: %d%%"
#define CLI_PROGRESS_STR L"\rOperation on " PMEM_MODULE_STR L" 0x%04x Progress: %d%%"

#define CLI_LOAD_MFG_FW L"MFG Load Prod FW"
#define CLI_INJECT_MFG L"MFG Inject command"
Expand Down Expand Up @@ -225,14 +225,14 @@ typedef struct _CMD_DISPLAY_OPTIONS {

#define CLI_ERR_DISPLAY_PREFERENCES_RETRIEVE L"Unable to retrieve user display preferences."

#define CLI_DOWNGRADE_PROMPT L"Downgrade firmware on DIMM " FORMAT_STR L"?"
#define CLI_DOWNGRADE_PROMPT L"Downgrade firmware on " PMEM_MODULE_STR L" " FORMAT_STR L"?"

#define CLI_RECOVER_DIMM_PROMPT_STR L"Recover dimm:"
#define CLI_RECOVER_DIMM_PROMPT_STR L"Recover " PMEM_MODULE_STR L":"

#define CLI_FORMAT_DIMM_REBOOT_REQUIRED_STR L"A power cycle is required after a device format."
#define CLI_FORMAT_DIMM_PROMPT_STR L"This operation will take several minutes to complete and will erase all data on DIMM "
#define CLI_FORMAT_DIMM_PROMPT_STR L"This operation will take several minutes to complete and will erase all data on " PMEM_MODULE_STR L" "
#define CLI_INFO_START_FORMAT L"Format"
#define CLI_FORMAT_DIMM_STARTING_FORMAT L"Formatting DIMM(s)..."
#define CLI_FORMAT_DIMM_STARTING_FORMAT L"Formatting " PMEM_MODULE_STR L"(s)..."

#define CLI_INFO_DUMP_SUPPORT_SUCCESS L"Dump support data successfully written to " FORMAT_STR L"."
#define CLI_INFO_DUMP_CONFIG_SUCCESS L"Successfully dumped system configuration to file: " FORMAT_STR_NL
Expand Down
2 changes: 1 addition & 1 deletion DcpmPkg/cli/CreateGoalCommand.c
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ struct Command CreateGoalCommand =
{RESERVED_PROPERTY, L"", HELP_TEXT_PERCENT, FALSE, ValueRequired},
{NS_LABEL_VERSION_PROPERTY, L"", HELP_TEXT_NS_LABEL_VERSION, FALSE, ValueRequired}
},
L"Provision capacity on one or more DCPMMs into regions.", //!< help
L"Provision capacity on one or more " PMEM_MODULES_STR L" into regions.", //!< help
CreateGoal,
TRUE, //!< enable print control support
};
Expand Down
6 changes: 3 additions & 3 deletions DcpmPkg/cli/DeleteDimmCommand.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ struct Command DeleteDimmCommand =
},
{{DIMM_TARGET, L"", HELP_TEXT_DIMM_IDS, TRUE, ValueOptional}}, //!< targets
{{PASSPHRASE_PROPERTY, L"", HELP_TEXT_STRING, FALSE, ValueOptional}}, //!< properties
L"Erase persistent data on one or more DCPMMs.", //!< help
L"Erase persistent data on one or more " PMEM_MODULES_STR L".", //!< help
DeleteDimm, TRUE
};

Expand Down Expand Up @@ -295,7 +295,7 @@ DeleteDimm(
if (EFI_ERROR(ReturnCode)) {
goto Finish;
}
PRINTER_PROMPT_MSG(pPrinterCtx, ReturnCode, L"Erasing DIMM " FORMAT_STR L".", DimmStr);
PRINTER_PROMPT_MSG(pPrinterCtx, ReturnCode, L"Erasing " PMEM_MODULE_STR L" " FORMAT_STR L".", DimmStr);
ReturnCode = PromptYesNo(&Confirmation);
if (!EFI_ERROR(ReturnCode) && Confirmation) {
ReturnCode = pNvmDimmConfigProtocol->SetSecurityState(pNvmDimmConfigProtocol,&pDimmIds[Index], 1,
Expand All @@ -304,7 +304,7 @@ DeleteDimm(
goto FinishCommandStatusSet;
}
} else {
PRINTER_PROMPT_MSG(pPrinterCtx, ReturnCode, L"Skipped erasing data from DIMM " FORMAT_STR L"\n", DimmStr);
PRINTER_PROMPT_MSG(pPrinterCtx, ReturnCode, L"Skipped erasing data from " PMEM_MODULE_STR L" " FORMAT_STR L"\n", DimmStr);
continue;
}
}
Expand Down
2 changes: 1 addition & 1 deletion DcpmPkg/cli/DeleteGoalCommand.c
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ struct Command DeleteGoalCommand =
{SOCKET_TARGET, L"", HELP_TEXT_SOCKET_IDS, FALSE, ValueOptional}
},
{{L"", L"", L"", FALSE, ValueOptional}}, //!< properties
L"Delete the region configuration goal from one or more DCPMMs.", //!< help
L"Delete the region configuration goal from one or more " PMEM_MODULES_STR L".", //!< help
DeleteGoal,
TRUE, //!< enable print control support
};
Expand Down
8 changes: 4 additions & 4 deletions DcpmPkg/cli/DeletePcdCommand.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ struct Command DeletePcdCommand =
, TRUE, ValueOptional}
},
{{L"", L"", L"", FALSE, ValueOptional}}, //!< properties
L"Clear the namespace LSA partition on one or more DCPMMs.", //!< help
L"Clear the namespace LSA partition on one or more " PMEM_MODULES_STR L".", //!< help
DeletePcdCmd,
TRUE //!< enable print control support
};
Expand Down Expand Up @@ -172,7 +172,7 @@ DeletePcdCmd(
#ifdef OS_BUILD
ReturnCode = EFI_INVALID_PARAMETER;
PRINTER_SET_MSG(pPrinterCtx, ReturnCode, CLI_ERR_INCORRECT_VALUE_TARGET_PCD);
PRINTER_SET_MSG(pPrinterCtx, ReturnCode, L"LSA option not available. Refer to your OSV tools for DCPMM namespace management.");
PRINTER_SET_MSG(pPrinterCtx, ReturnCode, L"LSA option not available. Refer to your OSV tools for " PMEM_MODULE_STR L" namespace management.");
goto Finish;
#endif
ConfigIdMask |= DELETE_PCD_CONFIG_LSA_MASK;
Expand Down Expand Up @@ -238,7 +238,7 @@ DeletePcdCmd(

if (!Force) {
PRINTER_PROMPT_MSG(pPrinterCtx, ReturnCode, L"WARNING: Modifying the Platform Configuration Data can result in loss of data!\n");
PRINTER_PROMPT_MSG(pPrinterCtx, ReturnCode, L"Clear " FORMAT_STR L"partition(s) on %d DIMM(s).", pDisplayTargets, DimmIdsCount);
PRINTER_PROMPT_MSG(pPrinterCtx, ReturnCode, L"Clear " FORMAT_STR L"partition(s) on %d " PMEM_MODULE_STR L"(s).", pDisplayTargets, DimmIdsCount);
ReturnCode = PromptYesNo(&Confirmation);
if (EFI_ERROR(ReturnCode) || !Confirmation) {
ReturnCode = EFI_NOT_STARTED;
Expand Down Expand Up @@ -277,7 +277,7 @@ DeletePcdCmd(
}

if (DimmInNamespace) {
PRINTER_PROMPT_MSG(pPrinterCtx, ReturnCode, L"DIMM " FORMAT_STR L" is a member of a Namespace. Will not delete data from this DIMM.", DimmStr);
PRINTER_PROMPT_MSG(pPrinterCtx, ReturnCode, PMEM_MODULE_STR L" " FORMAT_STR L" is a member of a Namespace. Will not delete data from this " PMEM_MODULE_STR ".", DimmStr);
SetObjStatusForDimmInfoWithErase(pCommandStatus, pDimm, NVM_ERR_PCD_DELETE_DENIED, TRUE);
} else {
pCommandStatus->GeneralStatus = NVM_ERR_OPERATION_NOT_STARTED;
Expand Down
4 changes: 2 additions & 2 deletions DcpmPkg/cli/LoadCommand.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ struct Command LoadCommand =
{DIMM_TARGET, L"", HELP_TEXT_DIMM_IDS, TRUE, ValueOptional}
},
{{L"", L"", L"", FALSE, ValueOptional}}, //!< properties
L"Update the firmware on one or more DCPMMs.", //!< help
L"Update the firmware on one or more " PMEM_MODULES_STR L".", //!< help
Load //!< run function
};

Expand Down Expand Up @@ -300,7 +300,7 @@ Load(

ResetCmdStatus(pCommandStatus, NVM_ERR_OPERATION_NOT_STARTED);
if (!Examine) {
Print(L"Starting update on %d dimm(s)...\n", DimmTargetsNum);
Print(L"Starting update on %d " PMEM_MODULE_STR L"(s)...\n", DimmTargetsNum);
// Create callback that will print progress
gBS->CreateEvent((EVT_TIMER | EVT_NOTIFY_SIGNAL), PRINT_PRIORITY, PrintProgress, pCommandStatus, &ProgressEvent);
gBS->SetTimer(ProgressEvent, TimerPeriodic, PROGRESS_EVENT_TIMEOUT);
Expand Down
Loading

0 comments on commit aeefc38

Please sign in to comment.