/* auto-generated, do not modify */
#include "config.h"

#include "fu-intel-thunderbolt-struct.h"
#include "fu-byte-array.h"
#include "fu-mem-private.h"
#include "fu-string.h"

#ifdef G_LOG_DOMAIN
  #undef G_LOG_DOMAIN
#endif
#define G_LOG_DOMAIN "FuStruct"

const gchar *
fu_intel_thunderbolt_nvm_section_to_string(FuIntelThunderboltNvmSection val)
{
    if (val == FU_INTEL_THUNDERBOLT_NVM_SECTION_DIGITAL)
        return "digital";
    if (val == FU_INTEL_THUNDERBOLT_NVM_SECTION_DROM)
        return "drom";
    if (val == FU_INTEL_THUNDERBOLT_NVM_SECTION_ARC_PARAMS)
        return "arc-params";
    if (val == FU_INTEL_THUNDERBOLT_NVM_SECTION_DRAM_UCODE)
        return "dram-ucode";
    if (val == FU_INTEL_THUNDERBOLT_NVM_SECTION_LAST)
        return "last";
    return NULL;
}

const gchar *
fu_intel_thunderbolt_nvm_family_to_string(FuIntelThunderboltNvmFamily val)
{
    if (val == FU_INTEL_THUNDERBOLT_NVM_FAMILY_UNKNOWN)
        return "unknown";
    if (val == FU_INTEL_THUNDERBOLT_NVM_FAMILY_FALCON_RIDGE)
        return "falcon-ridge";
    if (val == FU_INTEL_THUNDERBOLT_NVM_FAMILY_WIN_RIDGE)
        return "win-ridge";
    if (val == FU_INTEL_THUNDERBOLT_NVM_FAMILY_ALPINE_RIDGE)
        return "alpine-ridge";
    if (val == FU_INTEL_THUNDERBOLT_NVM_FAMILY_ALPINE_RIDGE_C)
        return "alpine-ridge-c";
    if (val == FU_INTEL_THUNDERBOLT_NVM_FAMILY_TITAN_RIDGE)
        return "titan-ridge";
    if (val == FU_INTEL_THUNDERBOLT_NVM_FAMILY_BB)
        return "bb";
    if (val == FU_INTEL_THUNDERBOLT_NVM_FAMILY_MAPLE_RIDGE)
        return "maple-ridge";
    if (val == FU_INTEL_THUNDERBOLT_NVM_FAMILY_GOSHEN_RIDGE)
        return "goshen-ridge";
    return NULL;
}
FuIntelThunderboltNvmFamily
fu_intel_thunderbolt_nvm_family_from_string(const gchar *val)
{
    if (g_strcmp0(val, "unknown") == 0)
        return FU_INTEL_THUNDERBOLT_NVM_FAMILY_UNKNOWN;
    if (g_strcmp0(val, "falcon-ridge") == 0)
        return FU_INTEL_THUNDERBOLT_NVM_FAMILY_FALCON_RIDGE;
    if (g_strcmp0(val, "win-ridge") == 0)
        return FU_INTEL_THUNDERBOLT_NVM_FAMILY_WIN_RIDGE;
    if (g_strcmp0(val, "alpine-ridge") == 0)
        return FU_INTEL_THUNDERBOLT_NVM_FAMILY_ALPINE_RIDGE;
    if (g_strcmp0(val, "alpine-ridge-c") == 0)
        return FU_INTEL_THUNDERBOLT_NVM_FAMILY_ALPINE_RIDGE_C;
    if (g_strcmp0(val, "titan-ridge") == 0)
        return FU_INTEL_THUNDERBOLT_NVM_FAMILY_TITAN_RIDGE;
    if (g_strcmp0(val, "bb") == 0)
        return FU_INTEL_THUNDERBOLT_NVM_FAMILY_BB;
    if (g_strcmp0(val, "maple-ridge") == 0)
        return FU_INTEL_THUNDERBOLT_NVM_FAMILY_MAPLE_RIDGE;
    if (g_strcmp0(val, "goshen-ridge") == 0)
        return FU_INTEL_THUNDERBOLT_NVM_FAMILY_GOSHEN_RIDGE;
    return FU_INTEL_THUNDERBOLT_NVM_FAMILY_UNKNOWN;
}
