From 7a09ed68e203a813d88fb7fc6eeb1e92209561a5 Mon Sep 17 00:00:00 2001
From: Mike Frysinger <vapier@gentoo.org>
Date: Mon, 8 Aug 2016 13:06:49 +0800
Subject: [PATCH] sim: bfin: split out common mach/model defines into arch.h
The current machs.h mixes common enums with Blackfin-specific defines.
This causes us troubles with header inclusion order such that we can't
drop the old SIM_CPU typedef (which is duplicated in common code). By
splitting the two up, we can unwind this dependency chain, and drop the
old typedef. It also fixes building with older gcc versions.
[Romain: backport from gdb 7.12]
Signed-off-by: Romain Naour <romain.naour@gmail.com>
sim/bfin/ChangeLog | 9 +++++++++
sim/bfin/arch.h | 44 ++++++++++++++++++++++++++++++++++++++++++++
sim/bfin/machs.h | 20 --------------------
sim/bfin/sim-main.h | 8 ++------
4 files changed, 55 insertions(+), 26 deletions(-)
create mode 100644 sim/bfin/arch.h
diff --git a/sim/bfin/ChangeLog b/sim/bfin/ChangeLog
index 3dea7c9..a995436 100644
+2016-08-13 Mike Frysinger <vapier@gentoo.org>
+ * machs.h (MODEL_TYPE, MACH_ATTR, BFIN_INSN_*): Move ...
+ * arch.h: ... to this new header file.
+ * sim-main.h (SIM_CPU): Delete.
+ Include arch.h before sim-base.h, and move sim-base.h before
2016-01-10 Mike Frysinger <vapier@gentoo.org>
* config.in, configure: Regenerate.
diff --git a/sim/bfin/arch.h b/sim/bfin/arch.h
+/* Simulator for Analog Devices Blackfin processors.
+ Copyright (C) 2005-2016 Free Software Foundation, Inc.
+ Contributed by Analog Devices, Inc.
+ This file is part of simulators.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 3 of the License, or
+ (at your option) any later version.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.