This is an automated email from Gerrit.

Mathias Küster (kes...@freenet.de) just uploaded a new patch set to Gerrit, 
which you can find at http://openocd.zylin.com/455

-- gerrit

commit d8dce2d0ba8d5999516e27443917cbe6ed62f2dc
Author: Mathias K <kes...@freenet.de>
Date:   Tue Feb 14 10:04:09 2012 +0100

    Add bootloader mode.
    
    This patch add the bootloader define.
    
    
    Change-Id: I280a8a35c3514910dd381de3ab8ad59c9bd74ca1
    Signed-off-by: Mathias K <kes...@freenet.de>

diff --git a/src/jtag/drivers/stlink_usb.c b/src/jtag/drivers/stlink_usb.c
index 466a98c..bf14644 100644
--- a/src/jtag/drivers/stlink_usb.c
+++ b/src/jtag/drivers/stlink_usb.c
@@ -1,5 +1,5 @@
 /***************************************************************************
- *   Copyright (C) 2011 by Mathias Kuester                                 *
+ *   Copyright (C) 2011-2012 by Mathias Kuester                            *
  *   Mathias Kuester <kes...@freenet.de>                                   *
  *                                                                         *
  *   This code is based on https://github.com/texane/stlink                *
@@ -100,6 +100,7 @@ struct stlink_usb_handle_s {
 #define STLINK_DEV_MASS_MODE                   0x01
 #define STLINK_DEV_DEBUG_MODE                  0x02
 #define STLINK_DEV_SWIM_MODE                   0x03
+#define STLINK_DEV_BOOTLOADER_MODE             0x04
 #define STLINK_DEV_UNKNOWN_MODE                        -1
 
 #define STLINK_DFU_EXIT                                0x07
@@ -540,6 +541,7 @@ static int stlink_usb_init_mode(void *handle)
                case STLINK_DEV_SWIM_MODE:
                        emode = STLINK_MODE_DEBUG_SWIM;
                        break;
+               case STLINK_DEV_BOOTLOADER_MODE:
                default:
                        emode = STLINK_MODE_UNKNOWN;
                        break;
@@ -778,7 +780,6 @@ static int stlink_usb_read_regs(void *handle)
        else
                h->txbuf[1] = STLINK_DEBUG_APIV2_READALLREGS;
 
-
        res = stlink_usb_recv(handle, h->txbuf, STLINK_CMD_SIZE, h->rxbuf, 84);
 
        if (res != ERROR_OK)

-- 

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
OpenOCD-devel mailing list
OpenOCD-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to