This is an automated email from Gerrit. "zapb <d...@zapb.de>" just uploaded a new patch set to Gerrit, which you can find at https://review.openocd.org/c/openocd/+/9000
-- gerrit commit 10ebb2a37505dbb7f3726bf85f3a0b2bfa17dfb3 Author: Marc Schink <d...@zapb.de> Date: Sun Jul 13 19:56:45 2025 +0000 flash/nor/stm32l4x: Rework 'option_read' output Remove the verbose command output to enable processing with Tcl. Change-Id: I97c2ffbd7bbbb3064a98f8977373f6c48272e71e Signed-off-by: Marc Schink <d...@zapb.de> diff --git a/doc/openocd.texi b/doc/openocd.texi index 22095d4b27..7b0db14776 100644 --- a/doc/openocd.texi +++ b/doc/openocd.texi @@ -8357,8 +8357,8 @@ is the register offset of the Option byte to read. For example to read the FLASH_OPTR register: @example stm32l4x option_read 0 0x20 -# Option Register (for STM32L4x): <0x40022020> = 0xffeff8aa -# Option Register (for STM32WBx): <0x58004020> = ... +# Option Register (for STM32L4x): 0xffeff8aa +# Option Register (for STM32WBx): ... # The correct flash base address will be used automatically @end example diff --git a/src/flash/nor/stm32l4x.c b/src/flash/nor/stm32l4x.c index 8001aaf006..44590c7482 100644 --- a/src/flash/nor/stm32l4x.c +++ b/src/flash/nor/stm32l4x.c @@ -2409,17 +2409,16 @@ COMMAND_HANDLER(stm32l4_handle_option_read_command) if (retval != ERROR_OK) return retval; - uint32_t reg_offset, reg_addr; + uint32_t reg_offset; uint32_t value = 0; COMMAND_PARSE_NUMBER(u32, CMD_ARGV[1], reg_offset); - reg_addr = stm32l4_get_flash_reg(bank, reg_offset); retval = stm32l4_read_flash_reg(bank, reg_offset, &value); if (retval != ERROR_OK) return retval; - command_print(CMD, "Option Register: <0x%" PRIx32 "> = 0x%" PRIx32 "", reg_addr, value); + command_print(CMD, "0x%" PRIx32, value); return retval; } --