target/mips: Add semihosting stub

Since the SEMIHOSTING feature is optional, we need
a stub to link when it is disabled.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20240717105723.58965-4-philmd@linaro.org>
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Message-Id: <20240718094523.1198645-11-alex.bennee@linaro.org>
This commit is contained in:
Philippe Mathieu-Daudé 2024-07-18 10:45:18 +01:00 committed by Alex Bennée
parent bf9ab9d131
commit fca2ffcb0b
2 changed files with 19 additions and 2 deletions

View File

@ -1,10 +1,12 @@
mips_system_ss.add(files(
'cp0_helper.c',
'mips-semi.c',
'special_helper.c',
'tlb_helper.c',
))
mips_system_ss.add(when: ['CONFIG_SEMIHOSTING'],
if_true: files('mips-semi.c'),
if_false: files('semihosting-stub.c')
)
mips_system_ss.add(when: 'TARGET_MIPS64', if_true: files(
'lcsr_helper.c',
))

View File

@ -0,0 +1,15 @@
/*
* MIPS semihosting stub
*
* SPDX-FileContributor: Philippe Mathieu-Daudé <philmd@linaro.org>
* SPDX-FileCopyrightText: 2024 Linaro Ltd.
* SPDX-License-Identifier: GPL-2.0-or-later
*/
#include "qemu/osdep.h"
#include "internal.h"
void mips_semihosting(CPUMIPSState *env)
{
g_assert_not_reached();
}