Linux preempt-rt

Check our new training course

Real-Time Linux with PREEMPT_RT

Check our new training course
with Creative Commons CC-BY-SA
lecture and lab materials

Bootlin logo

Elixir Cross Referencer

# Copyright (c) 2017 Intel Corporation
# Copyright (c) 2016 Cadence Design Systems, Inc.
# SPDX-License-Identifier: Apache-2.0

# Abstraction of 'run' goal with xt-run
ifneq (${QEMU_PTY},)
# By default xt-sim uses pty, do nothing

run: zephyr
	@echo "**** Running simulation for Xtensa core \"${CONFIG_SOC}\" ****"
	$(if ${QEMU_PIPE},,@echo "To exit from XT-RUN enter: 'CTRL+c'")
	@echo '[XT-RUN] CPU: ${CONFIG_SOC}'
	# Run the emulator in the background and leave a PID file for
	# sanitycheck
ifneq ($(QEMU_PIPE),)
	# Use the existing interface that we set up for QEMU:
	# 1) A pair of pipe for console input and output, named
	#    $(QEMU_PIPE).in and $(QEMU_PIPE).out. The extensions are implicit
	#    in QEMU's -seral pipe:.... argument.
	# 2) A PID file so that sanitycheck can kill the emulator
		< ${QEMU_PIPE}.in > ${QEMU_PIPE}.out & echo $$! >
	# Wait until the emulator terminates (for any reason)
	$(Q) cat | xargs $(srctree)/scripts/waitpid

.PHONY: run