[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAK8P3a1hByh-k8mng8a22C1-tNU0yn1LNvoaCmHp4RpP_GUs4Q@mail.gmail.com>
Date: Wed, 17 Oct 2018 17:46:56 +0200
From: Arnd Bergmann <arnd@...db.de>
To: Guo Ren <ren_guo@...ky.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Daniel Lezcano <daniel.lezcano@...aro.org>,
David Miller <davem@...emloft.net>,
gregkh <gregkh@...uxfoundation.org>,
Christoph Hellwig <hch@...radead.org>,
Marc Zyngier <marc.zyngier@....com>,
Mark Rutland <mark.rutland@....com>,
Peter Zijlstra <peterz@...radead.org>,
Rob Herring <robh@...nel.org>,
Thomas Gleixner <tglx@...utronix.de>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
linux-arch <linux-arch@...r.kernel.org>,
DTML <devicetree@...r.kernel.org>,
Rob Herring <robh+dt@...nel.org>, c-sky_gcc_upstream@...ky.com
Subject: Re: [PATCH V9 15/21] csky: Debug and Ptrace GDB
On Tue, Oct 16, 2018 at 5:06 AM Guo Ren <ren_guo@...ky.com> wrote:
>
> This patch adds arch ptrace implementation, stack dump and bug.h.
>
> Signed-off-by: Guo Ren <ren_guo@...ky.com>
> Cc: Arnd Bergmann <arnd@...db.de>
Reviewed-by: Arnd Bergmann <arnd@...db.de>
> diff --git a/arch/csky/include/asm/bug.h b/arch/csky/include/asm/bug.h
> new file mode 100644
> index 0000000..bd7b323
> --- /dev/null
> +++ b/arch/csky/include/asm/bug.h
> @@ -0,0 +1,26 @@
> +/* SPDX-License-Identifier: GPL-2.0 */
> +// Copyright (C) 2018 Hangzhou C-SKY Microsystems co.,ltd.
> +
> +#ifndef __ASM_CSKY_BUG_H
> +#define __ASM_CSKY_BUG_H
> +
> +#include <linux/compiler.h>
> +#include <linux/const.h>
> +#include <linux/types.h>
> +
> +#define BUG() \
> +do { \
> + asm volatile ("bkpt\n"); \
> + unreachable(); \
> +} while (0)
Since you have a breakpoint instruction, a nice addition might
be to use that for implementing WARN_ON as well, whenever you
get around to doing that. It's certainly not required for the initial
merge.
Powered by blists - more mailing lists