[POWERPC] Allow xmon to build on legacy iSeries
Michael Ellerman
michael at ellerman.id.au
Thu Nov 30 12:04:08 EST 2006
On Thu, 2006-11-30 at 11:44 +1100, Stephen Rothwell wrote:
> xmon still does not run on iSeries, but this allows us to build a combined
> kernel that includes it.
>
> Signed-off-by: Stephen Rothwell <sfr at canb.auug.org.au>
> ---
> arch/powerpc/Kconfig.debug | 2 +-
> arch/powerpc/xmon/xmon.c | 9 +++++++++
> 2 files changed, 10 insertions(+), 1 deletions(-)
>
> --
> Cheers,
> Stephen Rothwell sfr at canb.auug.org.au
>
> diff --git a/arch/powerpc/Kconfig.debug b/arch/powerpc/Kconfig.debug
> index ff16063..5cce904 100644
> --- a/arch/powerpc/Kconfig.debug
> +++ b/arch/powerpc/Kconfig.debug
> @@ -77,7 +77,7 @@ config KGDB_CONSOLE
>
> config XMON
> bool "Include xmon kernel debugger"
> - depends on DEBUGGER && !PPC_ISERIES
> + depends on DEBUGGER
> help
> Include in-kernel hooks for the xmon kernel monitor/debugger.
> Unless you are intending to debug the kernel, say N here.
> diff --git a/arch/powerpc/xmon/xmon.c b/arch/powerpc/xmon/xmon.c
> index 1cf90c8..767b242 100644
> --- a/arch/powerpc/xmon/xmon.c
> +++ b/arch/powerpc/xmon/xmon.c
> @@ -44,6 +44,7 @@
> #ifdef CONFIG_PPC64
> #include <asm/hvcall.h>
> #include <asm/paca.h>
> +#include <asm/iseries/it_lp_reg_save.h>
> #endif
>
> #include "nonstdio.h"
> @@ -2580,6 +2581,10 @@ void dump_segments(void)
>
> void xmon_init(int enable)
> {
> +#ifdef CONFIG_PPC_ISERIES
> + if (firmware_has_feature(FW_FEATURE_ISERIES))
> + return;
> +#endif
> if (enable) {
> __debugger = xmon;
> __debugger_ipi = xmon_ipi;
> @@ -2617,6 +2622,10 @@ static struct sysrq_key_op sysrq_xmon_op =
>
> static int __init setup_xmon_sysrq(void)
> {
> +#ifdef CONFIG_PPC_ISERIES
> + if (firmware_has_feature(FW_FEATURE_ISERIES))
> + return 0;
> +#endif
> register_sysrq_key('x', &sysrq_xmon_op);
> return 0;
> }
Why the ifdefs around the firmware check? Shouldn't it compile out to
nothing for !ISERIES anyway?
cheers
--
Michael Ellerman
OzLabs, IBM Australia Development Lab
wwweb: http://michael.ellerman.id.au
phone: +61 2 6212 1183 (tie line 70 21183)
We do not inherit the earth from our ancestors,
we borrow it from our children. - S.M.A.R.T Person
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20061130/cea79f5e/attachment.pgp>
More information about the Linuxppc-dev
mailing list