This is an automated email from Gerrit.

"Samuel Obuch <[email protected]>" just uploaded a new patch set to 
Gerrit, which you can find at https://review.openocd.org/c/openocd/+/9758

-- gerrit

commit 90b34b92a3156a58488d2ebfe6ac5a8717e3bbcd
Author: Samuel Obuch <[email protected]>
Date:   Wed Jun 24 17:23:49 2026 +0200

    target/espressif: add insn_set functions
    
    Adds default instruction set so that users do not have to select
    one manually when using the 'disassemble' command.
    
    Change-Id: Ic100fa82588cd567d3531502eceb88a3231df266
    Signed-off-by: Samuel Obuch <[email protected]>

diff --git a/src/target/espressif/esp32.c b/src/target/espressif/esp32.c
index 4ea1c8a335..fd6565d6b4 100644
--- a/src/target/espressif/esp32.c
+++ b/src/target/espressif/esp32.c
@@ -457,6 +457,13 @@ static const struct command_registration 
esp32_command_handlers[] = {
        COMMAND_REGISTRATION_DONE
 };
 
+static int esp32_insn_set(struct command_invocation *cmd,
+       struct target *target, const char **insn_set)
+{
+       *insn_set = "xtensa";
+       return ERROR_OK;
+}
+
 /** Holds methods for Xtensa targets. */
 struct target_type esp32_target = {
        .name = "esp32",
@@ -502,4 +509,5 @@ struct target_type esp32_target = {
 
        .commands = esp32_command_handlers,
        .profiling = esp_xtensa_profiling,
+       .insn_set = esp32_insn_set,
 };
diff --git a/src/target/espressif/esp32s2.c b/src/target/espressif/esp32s2.c
index eb3ad71f24..4a5bcb0473 100644
--- a/src/target/espressif/esp32s2.c
+++ b/src/target/espressif/esp32s2.c
@@ -494,6 +494,13 @@ static const struct command_registration 
esp32s2_command_handlers[] = {
        COMMAND_REGISTRATION_DONE
 };
 
+static int esp32s2_insn_set(struct command_invocation *cmd,
+       struct target *target, const char **insn_set)
+{
+       *insn_set = "xtensa_s2";
+       return ERROR_OK;
+}
+
 /* Holds methods for Xtensa targets. */
 struct target_type esp32s2_target = {
        .name = "esp32s2",
@@ -539,4 +546,5 @@ struct target_type esp32s2_target = {
 
        .commands = esp32s2_command_handlers,
        .profiling = esp_xtensa_profiling,
+       .insn_set = esp32s2_insn_set,
 };
diff --git a/src/target/espressif/esp32s3.c b/src/target/espressif/esp32s3.c
index 14f7a7bb64..a8e3fff68b 100644
--- a/src/target/espressif/esp32s3.c
+++ b/src/target/espressif/esp32s3.c
@@ -378,6 +378,13 @@ static const struct command_registration 
esp32s3_command_handlers[] = {
        COMMAND_REGISTRATION_DONE
 };
 
+static int esp32s3_insn_set(struct command_invocation *cmd,
+       struct target *target, const char **insn_set)
+{
+       *insn_set = "xtensa_s2";
+       return ERROR_OK;
+}
+
 /** Holds methods for Xtensa targets. */
 struct target_type esp32s3_target = {
        .name = "esp32s3",
@@ -423,4 +430,5 @@ struct target_type esp32s3_target = {
 
        .commands = esp32s3_command_handlers,
        .profiling = esp_xtensa_profiling,
+       .insn_set = esp32s3_insn_set,
 };

-- 

Reply via email to