flash/nor/stm32l4x: Remove redundant error messages
[openocd.git] / src / target / target_request.h
blob62d5c74b1ed62944447e82bdb5ef5dce2e5d827f
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
3 /***************************************************************************
4 * Copyright (C) 2007 by Dominic Rath *
5 * Dominic.Rath@gmx.de *
6 * *
7 * Copyright (C) 2007,2008 Øyvind Harboe *
8 * oyvind.harboe@zylin.com *
9 * *
10 * Copyright (C) 2008 by Spencer Oliver *
11 * spen@spen-soft.co.uk *
12 ***************************************************************************/
14 #ifndef OPENOCD_TARGET_TARGET_REQUEST_H
15 #define OPENOCD_TARGET_TARGET_REQUEST_H
17 struct target;
18 struct command_context;
20 typedef enum target_req_cmd {
21 TARGET_REQ_TRACEMSG,
22 TARGET_REQ_DEBUGMSG,
23 TARGET_REQ_DEBUGCHAR,
24 /* TARGET_REQ_SEMIHOSTING, */
25 } target_req_cmd_t;
27 struct debug_msg_receiver {
28 struct command_context *cmd_ctx;
29 struct debug_msg_receiver *next;
32 int target_request(struct target *target, uint32_t request);
33 int delete_debug_msg_receiver(struct command_context *cmd_ctx,
34 struct target *target);
35 int target_request_register_commands(struct command_context *cmd_ctx);
36 /**
37 * Read and clear the flag as to whether we got a message.
39 * This is used to implement the back-off algorithm on
40 * sleeping in idle mode.
42 bool target_got_message(void);
44 #endif /* OPENOCD_TARGET_TARGET_REQUEST_H */