Wykres commitów

107 Commity (9c5c2a0803f43bd0d13515d2ff43a6a199270a68)

Autor SHA1 Wiadomość Data
Maxime Coquelin bd27213299 read_debug32: Use a pointer instead of returning the value
This rework is done in order to prepare for propagating errors returned by
libusb.

Signed-off-by: Maxime Coquelin <mcoquelin.stm32@gmail.com>
2016-03-14 15:12:44 +01:00
George Talusan 60bd03a517 be quicker about determining erased byte pattern when flashing 2016-02-27 12:51:59 -05:00
George Talusan 09a8113277 make st-flash clean up on sigint/term/segv, make gdb-server clean up on sigsegv. 2016-02-22 20:07:43 -05:00
George Talusan 426cdd0866 clamp gdb memory reads to 0x1800 2016-02-19 00:04:44 -05:00
fabien.lementec c632f855ef fix signed unsigned comparison 2016-02-01 17:02:55 +01:00
texane c131b05b69 Merge pull request #369 from meisteg/stutil_reset
st-util: Fix for connecting to running devices
2016-02-01 17:02:29 +01:00
Greg Meiste ea649eb6e7 st-util: Fix for connecting to running devices
Previously, even with the reset enabled, st-util would not connect
to a target if it was running. This change will reset the chip
when opening the connection, which allows st-util to connect
successfully.

Signed-off-by: Greg Meiste <w30289@motorola.com>
2016-02-01 09:08:59 -06:00
Greg Meiste 2d8cb6be85 Add memory map for STM32L4
Signed-off-by: Greg Meiste <w30289@motorola.com>
2016-02-01 08:51:39 -06:00
Tristan Gingold 54c8d2ca8b st-util: synchronize cache for stm32f7
This patch handles the cache on the cortex-m7 stm32f7 cpu.
When gdb inserts a soft breakpoint (which is the default for
code in RAM), it replaces an instruction with a breakpoint
instruction.  But if the caches are enabled, the replacement
may be made only in the D-cache.  To reach the I-cache, the
D-cache must be flushed and the I-cache invalidated.

This implementation is coarse: it cleans the whole D-cache
and invalidate the whole I-cache.  It is possible to
track which cache lines have to be cleaned and invalidated.
2016-01-11 15:50:28 +01:00
texane d5fd6eda08 Merge pull request #360 from gingold-adacore/stm32f7-regs
stm32f7: also send features to gdb.
2015-12-17 12:38:21 +01:00
Tristan Gingold cce54ea2c7 stm32f7: also send features to gdb.
So that 'extra' registers (msp, psp, ...) are visible to user.
2015-12-17 11:06:39 +01:00
Tristan Gingold 177ef67b10 Do not send a NUL at end of packets to gdb.
GDB doesn't need it and see the NUL as a junk character
(visible with 'set debug remote 1').
2015-12-17 11:00:45 +01:00
Georg von Zengen 06fd9c4b70 Added parameter to specify one stlink v2 of many
This adds a parameter to the function stlink_open_usb and to the binary
st-flash to specify one of multiple connected stlinks.
As the identifier the iSerial of the stlink is used.
If no serial is given the function and binary behave as before.
2015-12-07 17:44:52 +01:00
mlundinse 768fe88e6c Breakpoint handling for Cortex M7 2015-10-03 16:36:37 +02:00
texane 2da33f84cd Merge pull request #330 from brunowonka/length_fix
segmentation fault length fix
2015-08-17 22:08:05 +02:00
bruno_dalbo bddf605006 segmentation fault length fix 2015-08-17 14:54:19 -03:00
Dave Vandervies e047ef25db Correctly compute flash write size for partial pages 2015-08-17 13:33:17 -04:00
mlundinse 7fbd79eef3 Added STM32F7 Support 2015-08-13 19:15:23 +02:00
Pavel Kirienko 98a41fa9c0 GDN server: F446 support 2015-07-17 12:34:37 +03:00
Nicolas Schodet af4a00a193 Fix F2 memory map
This enables GCC to only erase needed pages.
2015-05-18 17:02:26 +02:00
Craig Lilley 0c11337f02 Updated the memory map for stm32f42xxx and stm32f43xxx devices.
* These devices have up to 256K of sram.
* External memory accessed via the FMC controller is now accessible
  in GDB.
2015-05-04 23:16:31 +01:00
lementec 9fc5f77774 apply patch from rewolff: dont go bezurk if serve returns with error 2015-03-25 16:53:14 +01:00
Denis Fokin 9b2f893053 Properly close socket on WIN32 to allow accepting further connections 2015-03-15 17:49:30 +02:00
Simon Wright 5a722e3210 Merge branch 'master' of https://github.com/texane/stlink 2015-01-23 20:43:32 +00:00
Simon Wright b2dac26923 Extra RAM for STM32F42xx. 2015-01-23 20:43:23 +00:00
Stefan Misik 067430469a Added AHB3 Peripherals definition for STM32F4 2014-12-24 22:36:44 +01:00
Victor Mayoral Vilches b548f66967 Fix memory config for STM32F4
The previous memory map didn't allow to debug the whole flash
memory. A new configuration has been added and should be
used while working with the STM32F4Discovery.
2014-09-30 11:54:56 -07:00
Rene Hopf 8f97b230fc gdb server fix, indentation 2014-08-15 10:44:24 +02:00
mux e12842b492 Send F4 memory-map and features for STM32F429
* Fix issues #250 #196
2014-07-17 00:46:18 +02:00
Michael Pratt 3c3b02e83e gdbserver: use uglylogging logging
Rather than putting debug printing in #ifdef blocks, use the same
uglylogging framework used by core stlink code.

To support this, the *LOG() macros are moved into the uglylogging.h
header file, and always use the filename as the logging tag.
2014-07-12 13:23:24 -07:00
Michael Pratt 3b443dc1c8 Reindent all source files
The indentation of various st-link source files is highly inconsistent.
Reindent all source files to 4 space indentions for consistency.

I went with 4 space indentations, as it was the most common style.
2014-07-09 22:56:36 -07:00
Olivier Croquette 788d2df772 Include signal.h to define SIGINT
Fix build error with MinGW
2014-05-19 10:40:52 +02:00
Sean Simmons 94c7ac86dc * Improved support for STM32L152RE - flash/ram sizes, now correct, flash programming works.
* Cleaned up checking of FP_CTRL register in gdb-server.c
* Added source code for stm32lx.s flashloader - just for reference.
2014-03-08 11:21:16 -05:00
Jonas Norling a4ff7ba1f4 Remove unsupported --device option to st-util
Setting the STLINK device with -d hasn't worked for some time, but
the STLINK_DEVICE environment variable works instead. Remove the
option, update documentation and help text.
2014-01-22 22:51:21 +01:00
Olivier Gay 3652f98a5d Fix all compilation warnings 2013-10-27 17:07:01 +01:00
Olivier Gay c02a84641c Restore gdb-server cleanup handlers for MinGW
There were removed in my previous commit 5851dee due
to compilation errors. It actually appears these signals
are supported in MinGW but there was an include error for
MinGW, this commit fixes it.
2013-10-27 16:17:09 +01:00
Olivier Gay 5851dee3cd Fix build issues with MinGW
Remove st-term from the list of the targets for MinGW.
st-term uses termios and would require a rewrite to have
it compile on MinGW. Also remove cleanup signal handlers
in gdb-server for MinGW to compile.
2013-10-27 15:32:43 +01:00
htk e886396e0e Support for reading target voltage 2013-09-30 01:51:26 +02:00
Maxime Vincent 57700499f1 Fixed the DEBUG switch in gdb-server.c 2013-09-01 09:23:19 +02:00
Michael Pratt 596fb35916 Add option to not reset board on connect
'-n' in st-util will cause it to skip the reset step, and thus allow you
to begin debugging at whatever point the code may currently be at.

Adding this feature required changing the stlink_open functions to
accept a reset flag that tells them whether or not to reset after
connecting.  Skipping reset does not seem to have any adverse effects on
stlink usb devices.  Unfortunately, I have to stlink v1 devices to test.
2013-08-18 14:44:58 -04:00
Jack Peel 04c142c69b Add SIGTERM signal handler to also call cleanup
When stopping st-util under Eclipse as an external tool the st-util
	receives a SIGTERM signal, and would not return the device to
	usb mass storage mode.  This change now calls cleanup in the SIGTERM handler too!!
2013-04-05 17:55:19 -07:00
Fabien Le Mentec 8df5b3be5e [ update ] bind gdb server on INADDR_ANY, as requested by thomas@popp.ws 2013-04-01 15:36:52 -05:00
Michael Pratt 2216d28452 Add SIGINT handler for stlink cleanup
SIGINT causes st-util to immediately exit, without closing the open
stlink.  This leaves devices (at least the F4 Discovery) in a state
where they are unable to reset.  st-util could still connect and control
them, but a power cycle was required before they could reset on their
own.

A signal handler is added for SIGINT, which performs cleanup and closing
of the open stlink device, allowing it to function normally on
disconnect.
2013-03-06 16:34:32 -05:00
Michael Pratt 4d1ee4d97e Move persistence flag to st_state_t
It makes sense for it to be with all other state data.  This meant
passing the entire state struct into serve.
2013-03-06 14:23:17 -05:00
Michael Pratt 9bed540624 Add persistence support to gdb-server
When started with -m, or connected with 'target extended-remote', the
GDB server will not terminate upon disconnection from GDB, instead it
will begin listening for conenctions again.

Starting with extended-remote also has the advantage of allowing 'run'
to be used to reset the target and begin again.  Unfortunately, 'start'
is not working properly, as it does not send a reset packet (R), so it
complains when it tries to access memory before it is connected to the
target.
2013-03-06 12:52:12 -05:00
Michael Pratt 3569970998 Revert "[ merge ] patch from fischermi@t-online.de, GDB server endless loop"
This reverts commit 1c2828cc91.
2013-03-06 12:03:27 -05:00
Nicolas Schodet 44445dd7b0 Fix byte count when doing unaligned memory read, fix issue #127
- when start is adjusted, count should also be adjusted,
 - then, count is rounded to the next multiple of word size.
2013-02-12 19:38:46 +01:00
Fabien Le Mentec 1c2828cc91 [ merge ] patch from fischermi@t-online.de, GDB server endless loop 2012-12-27 07:00:46 -06:00
Fabien Le Mentec 08872f834d [ merge ] Andreas Seltenreich <uwi7@rz.uni-karlsruhe.de> patches 2012-11-25 09:50:44 -06:00
Jeff Kent ff1a7aa50b workaround for asserting nRST, issue "monitor jtag_reset" from gdb 2012-09-19 12:22:28 -05:00