From ef43ed7161921e24325ddd22be2783b594ce7591 Mon Sep 17 00:00:00 2001 From: Alexandre Abadie Date: Thu, 11 Feb 2021 15:00:04 +0100 Subject: [PATCH] boards/hifive1: define supported programmers --- boards/hifive1/Makefile.include | 1 + boards/hifive1b/Makefile.include | 3 +-- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/boards/hifive1/Makefile.include b/boards/hifive1/Makefile.include index 41ff60da34..5385a18171 100644 --- a/boards/hifive1/Makefile.include +++ b/boards/hifive1/Makefile.include @@ -4,6 +4,7 @@ PORT_DARWIN ?= $(firstword $(sort $(wildcard /dev/tty.usbmodem*))) # this board uses openocd with a custom reset command PROGRAMMER ?= openocd +PROGRAMMERS_SUPPORTED += openocd OPENOCD_CMD_RESET_RUN =-c _reset # use our own openocd script to flash since HiFive1 has reset problems. diff --git a/boards/hifive1b/Makefile.include b/boards/hifive1b/Makefile.include index 815fef936c..88ec119270 100644 --- a/boards/hifive1b/Makefile.include +++ b/boards/hifive1b/Makefile.include @@ -1,5 +1,6 @@ # Set default programmer as jlink PROGRAMMER ?= jlink +PROGRAMMERS_SUPPORTED += jlink openocd ifeq (openocd,$(PROGRAMMER)) OPENOCD_DEBUG_ADAPTER = jlink @@ -10,8 +11,6 @@ else ifeq (jlink,$(PROGRAMMER)) JLINK_DEVICE = FE310 JLINK_IF = JTAG FLASH_ADDR = 0x20010000 -else - $(error Programmer '$(PROGRAMMER)' not supported for board '$(BOARD)') endif TESTRUNNER_RESET_DELAY = 1