summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDamien George <damien@micropython.org>2024-06-11 16:31:49 +1000
committerDamien George <damien@micropython.org>2024-06-11 21:43:45 +1000
commitd7d77d91becd0716ac1672c92652d9dd72ec613f (patch)
tree9f1e7be5716d3e5d96d642371e68fae0c78aac77
parent9bfb4cec6e832c38eb04ad680a2b5e377830d3af (diff)
qemu-arm: Clean up header file includes.
Signed-off-by: Damien George <damien@micropython.org>
-rw-r--r--ports/qemu-arm/main.c5
-rw-r--r--ports/qemu-arm/mphalport.h1
-rw-r--r--ports/qemu-arm/test_main.c4
-rw-r--r--ports/qemu-arm/uart.h6
4 files changed, 6 insertions, 10 deletions
diff --git a/ports/qemu-arm/main.c b/ports/qemu-arm/main.c
index 212fd6021..025c1f17d 100644
--- a/ports/qemu-arm/main.c
+++ b/ports/qemu-arm/main.c
@@ -24,18 +24,13 @@
* THE SOFTWARE.
*/
-#include <stdint.h>
#include <stdlib.h>
#include <stdio.h>
-#include <string.h>
-#include <malloc.h>
-#include "py/obj.h"
#include "py/compile.h"
#include "py/runtime.h"
#include "py/stackctrl.h"
#include "py/gc.h"
-#include "py/repl.h"
#include "py/mperrno.h"
void do_str(const char *src, mp_parse_input_kind_t input_kind) {
diff --git a/ports/qemu-arm/mphalport.h b/ports/qemu-arm/mphalport.h
index d854cd82d..8a40505ba 100644
--- a/ports/qemu-arm/mphalport.h
+++ b/ports/qemu-arm/mphalport.h
@@ -24,7 +24,6 @@
* THE SOFTWARE.
*/
-#include <stddef.h>
#include "uart.h"
#define mp_hal_stdin_rx_chr() (0)
diff --git a/ports/qemu-arm/test_main.c b/ports/qemu-arm/test_main.c
index 13d18bb0f..96984f7cd 100644
--- a/ports/qemu-arm/test_main.c
+++ b/ports/qemu-arm/test_main.c
@@ -24,12 +24,8 @@
* THE SOFTWARE.
*/
-#include <stdint.h>
#include <stdlib.h>
#include <stdio.h>
-#include <string.h>
-#include <malloc.h>
-#include <setjmp.h>
#include "py/compile.h"
#include "py/runtime.h"
diff --git a/ports/qemu-arm/uart.h b/ports/qemu-arm/uart.h
index b2b9e523c..33eae05bd 100644
--- a/ports/qemu-arm/uart.h
+++ b/ports/qemu-arm/uart.h
@@ -23,6 +23,12 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
+#ifndef MICROPY_INCLUDED_QEMU_ARM_UART_H
+#define MICROPY_INCLUDED_QEMU_ARM_UART_H
+
+#include <stddef.h>
void uart_init(void);
void uart_tx_strn(const char *buf, size_t len);
+
+#endif // MICROPY_INCLUDED_QEMU_ARM_UART_H