X-Git-Url: https://git.gag.com/?a=blobdiff_plain;ds=sidebyside;f=src%2Fstlink-usb.h;h=f433193c81eae6ce95c20dbaa189f8f281c81c98;hb=596fb35916ef2f1da8b817fa4b6e365e71c0fc5a;hp=c632a8c4163da3257a61014cf1b614b30e7cc884;hpb=4bb6ab6d9f9ba5330309432a76724ed49d854613;p=fw%2Fstlink diff --git a/src/stlink-usb.h b/src/stlink-usb.h index c632a8c..f433193 100644 --- a/src/stlink-usb.h +++ b/src/stlink-usb.h @@ -12,13 +12,12 @@ extern "C" { #endif -#include +#include #include "stlink-common.h" #define STLINK_SG_SIZE 31 #define STLINK_CMD_SIZE 16 -#if defined(CONFIG_USE_LIBUSB) struct stlink_libusb { libusb_context* libusb_ctx; libusb_device_handle* usb_handle; @@ -30,13 +29,8 @@ extern "C" { unsigned int sg_transfer_idx; unsigned int cmd_len; }; -#else -#error "it's all bad!" - struct stlink_libusb {}; -#endif - - stlink_t* stlink_open_usb(const int verbose); + stlink_t* stlink_open_usb(const int verbose, int reset); #ifdef __cplusplus