microblaze: fixes includes in sigcontext.h
PATCH 1/1 microblaze: fixes includes in sigcontext.h
This patch changes this file to use linux/ptrace.h instead of included file to fix this FIXME message in this file.
--- arch/microblaze/include/uapi/asm/sigcontext.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
arch/microblaze/include/uapi/asm/sigcontext.h +1 -2
@@ -9,8 +9,7 @@ #ifndef _ASM_MICROBLAZE_SIGCONTEXT_H #define _ASM_MICROBLAZE_SIGCONTEXT_H -/* FIXME should be linux/ptrace.h */ -#include <asm/ptrace.h> +#include <linux/ptrace.h> struct sigcontext { struct pt_regs regs;
Signature · 1 line
1.9.1
Quoted 5 lines · Nicholas Krause
arch/microblaze/include/uapi/asm/sigcontext.h +0
-0
arch/microblaze/include/uapi/asm/sigcontext.h line 15
Quoted 9 lines
arch/microblaze/include/uapi/asm/sigcontext.h +1
-2@@ -9,8 +9,7 @@ #ifndef _ASM_MICROBLAZE_SIGCONTEXT_H #define _ASM_MICROBLAZE_SIGCONTEXT_H -/* FIXME should be linux/ptrace.h */ -#include <asm/ptrace.h> +#include <linux/ptrace.h> struct sigcontext { struct pt_regs regs;
Umm, does this even compile? How does sigcontext.h get the definition of struct pt_regs? Seems like it would be better to just do a forward declaration.
You may be right I don't have a compiler that supports microblaze therefore I would suggest removing this FIXME message.
Cheers Nick
Quoted 20 lines · David Rientjes
Quoted 5 lines · Nicholas Krause
arch/microblaze/include/uapi/asm/sigcontext.h +0
-0arch/microblaze/include/uapi/asm/sigcontext.h line 15
Quoted 9 lines
arch/microblaze/include/uapi/asm/sigcontext.h +1
-2@@ -9,8 +9,7 @@ #ifndef _ASM_MICROBLAZE_SIGCONTEXT_H #define _ASM_MICROBLAZE_SIGCONTEXT_H -/* FIXME should be linux/ptrace.h */ -#include <asm/ptrace.h> +#include <linux/ptrace.h> struct sigcontext { struct pt_regs regs;Umm, does this even compile? How does
sigcontext.hget the definition of structpt_regs? Seems like it would be better to just do a forward declaration.
Quoted 2 lines · Nick Krause
You may be right I don't have a compiler that supports microblaze therefore I would suggest removing this FIXME message.
The FIXME here is obviously stating that the code needs to be fixed so that it can include linux/ptrace.h rather than asm/ptrace.h since we want to include the former rather than the latter. It doesn't imply, in any way, that you can just do the conversion without some due diligence (compilation) to ensure it works; otherwise it would have been including linux/ptrace.h since the beginning.
It's bad practice to mess with per-arch header files for platforms that you cannot compile yourself.
Quoted 24 lines
Cheers Nick
Quoted 20 lines · David Rientjes
Quoted 5 lines · Nicholas Krause
arch/microblaze/include/uapi/asm/sigcontext.h +0
-0arch/microblaze/include/uapi/asm/sigcontext.h line 15
Quoted 9 lines
arch/microblaze/include/uapi/asm/sigcontext.h +1
-2@@ -9,8 +9,7 @@ #ifndef _ASM_MICROBLAZE_SIGCONTEXT_H #define _ASM_MICROBLAZE_SIGCONTEXT_H -/* FIXME should be linux/ptrace.h */ -#include <asm/ptrace.h> +#include <linux/ptrace.h> struct sigcontext { struct pt_regs regs;Umm, does this even compile? How does
sigcontext.hget the definition of structpt_regs? Seems like it would be better to just do a forward declaration.
Very well ,
I guess this bug is outside my scope.
Cheers Nick
Quoted 39 lines · David Rientjes
Quoted 2 lines · Nick Krause
You may be right I don't have a compiler that supports microblaze therefore I would suggest removing this FIXME message.
The FIXME here is obviously stating that the code needs to be fixed so that it can include
linux/ptrace.hrather thanasm/ptrace.hsince we want to include the former rather than the latter. It doesn't imply, in any way, that you can just do the conversion without some due diligence (compilation) to ensure it works; otherwise it would have been includinglinux/ptrace.hsince the beginning.It's bad practice to mess with per-arch header files for platforms that you cannot compile yourself.
Quoted 24 lines
Cheers Nick
Quoted 20 lines · David Rientjes
Quoted 5 lines · Nicholas Krause
arch/microblaze/include/uapi/asm/sigcontext.h +0
-0arch/microblaze/include/uapi/asm/sigcontext.h line 15
Quoted 9 lines
arch/microblaze/include/uapi/asm/sigcontext.h +1
-2@@ -9,8 +9,7 @@ #ifndef _ASM_MICROBLAZE_SIGCONTEXT_H #define _ASM_MICROBLAZE_SIGCONTEXT_H -/* FIXME should be linux/ptrace.h */ -#include <asm/ptrace.h> +#include <linux/ptrace.h> struct sigcontext { struct pt_regs regs;Umm, does this even compile? How does
sigcontext.hget the definition of structpt_regs? Seems like it would be better to just do a forward declaration.