diff options
-rw-r--r-- | src/main.c | 7 | ||||
-rw-r--r-- | src/rcm.h | 5 |
2 files changed, 8 insertions, 4 deletions
@@ -240,8 +240,10 @@ int main(int argc, char **argv) dump_platform_info(&info); if (info.op_mode != RCM_OP_MODE_DEVEL && - info.op_mode != RCM_OP_MODE_ODM_OPEN) - error(1, ENODEV, "device is not in developer or open mode, cannot flash"); + info.op_mode != RCM_OP_MODE_ODM_OPEN && + info.op_mode != RCM_OP_MODE_PRE_PRODUCTION) + error(1, ENODEV, "device is not in developer, open, " + "or pre-production mode, cannot flash"); // download the BCT ret = download_bct(h3p, bctfile); @@ -452,6 +454,7 @@ static void dump_platform_info(nv3p_platform_info_t *info) printf("Operating Mode: 0x%x", info->op_mode); char *op_mode = NULL; switch(info->op_mode) { + case RCM_OP_MODE_PRE_PRODUCTION: op_mode = "pre-production mode"; break; case RCM_OP_MODE_DEVEL: op_mode = "developer mode"; break; case RCM_OP_MODE_ODM_OPEN: op_mode = "odm open mode"; break; default: op_mode = "unknown"; break; @@ -69,8 +69,9 @@ typedef struct { } rcm_msg_t; // security operating modes -#define RCM_OP_MODE_DEVEL 0x3 -#define RCM_OP_MODE_ODM_OPEN 0x5 +#define RCM_OP_MODE_PRE_PRODUCTION 0x1 +#define RCM_OP_MODE_DEVEL 0x3 +#define RCM_OP_MODE_ODM_OPEN 0x5 uint32_t rcm_get_msg_len(uint8_t *msg); int rcm_create_msg( |