shix: Catch CPU initialization errors

Print an error message as done for the r2d machine and exit.

Signed-off-by: Andreas Färber <afaerber@suse.de>
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
This commit is contained in:
Andreas Färber 2013-04-09 16:51:23 +02:00 committed by Aurelien Jarno
parent 396a14a3be
commit 06f3ed2698
1 changed files with 4 additions and 0 deletions

View File

@ -52,6 +52,10 @@ static void shix_init(QEMUMachineInitArgs *args)
printf("Initializing CPU\n");
env = cpu_init(cpu_model);
if (env == NULL) {
fprintf(stderr, "Unable to find CPU definition\n");
exit(1);
}
/* Allocate memory space */
printf("Allocating ROM\n");