diff options
Diffstat (limited to 'src/eeprom_main.c')
-rw-r--r-- | src/eeprom_main.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/eeprom_main.c b/src/eeprom_main.c index a86b567..6ffc018 100644 --- a/src/eeprom_main.c +++ b/src/eeprom_main.c @@ -300,7 +300,7 @@ static void usage(FILE *out) { fprintf(out, " --capa-adc |\n"); fprintf(out, " --capa-wifi |\n"); fprintf(out, " --capa-bluetooth |\n"); - fprintf(out, " --capa <capa> |\n"); + fprintf(out, " --capa-clear (clears all flags) |\n"); fprintf(out, " --out-format { bin | yaml (default) } |\n"); fprintf(out, " --update |\n"); fprintf(out, " --daughter-card\n"); @@ -325,7 +325,7 @@ enum { CMD_OPT_CAPA_ADC, CMD_OPT_CAPA_WIFI, CMD_OPT_CAPA_BLUETOOTH, - CMD_OPT_CAPA, + CMD_OPT_CAPA_CLEAR, CMD_OPT_OUT_FORMAT, CMD_OPT_UPDATE, CMD_OPT_DAUGHTER_CARD, @@ -351,7 +351,7 @@ static struct option long_options[] = { {"capa-adc", 0, NULL, CMD_OPT_CAPA_ADC}, {"capa-wifi", 0, NULL, CMD_OPT_CAPA_WIFI}, {"capa-bluetooth", 0, NULL, CMD_OPT_CAPA_BLUETOOTH}, - {"capa", 1, NULL, CMD_OPT_CAPA}, + {"capa-clear", 0, NULL, CMD_OPT_CAPA_CLEAR}, {"out-format", 1, NULL, CMD_OPT_OUT_FORMAT}, {"update", 0, NULL, CMD_OPT_UPDATE}, {"daughter-card", 0, NULL, CMD_OPT_DAUGHTER_CARD}, @@ -554,9 +554,8 @@ int main(int argc, char *argv[]) { DEVICE_CAPA_SET(id_eeprom.capa, CAPA_BLUETOOTH); break; - case CMD_OPT_CAPA: - log_error("capa option not implemented"); - exit(1); + case CMD_OPT_CAPA_CLEAR: + memset(id_eeprom.capa, 0, sizeof(id_eeprom.capa)); break; case CMD_OPT_OUT_FORMAT: |