All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] selftests: breakpoints: fix compile error on breakpoint_test_arm64
@ 2017-10-23  7:42 Sumit Semwal
  2017-11-01 20:52 ` Shuah Khan
  0 siblings, 1 reply; 3+ messages in thread
From: Sumit Semwal @ 2017-10-23  7:42 UTC (permalink / raw)
  To: linux-kselftest, linux-kernel, shuah
  Cc: will.deacon, panand, paul.elder, Sumit Semwal

The current mainline breakpoints test for arm64 fails to compile with

breakpoint_test_arm64.c: In function ‘set_watchpoint’:
breakpoint_test_arm64.c:97:28: error: storage size of ‘dreg_state’ isn’t known
  struct user_hwdebug_state dreg_state;

Adding a direct include for asm/ptrace.h helps it to build, and passes
the test on mainline on hikey.

Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org>
---
 tools/testing/selftests/breakpoints/breakpoint_test_arm64.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c b/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c
index 960d02100c26..2d95e5adde72 100644
--- a/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c
+++ b/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c
@@ -19,6 +19,7 @@
 
 #define _GNU_SOURCE
 
+#include <asm/ptrace.h>
 #include <sys/types.h>
 #include <sys/wait.h>
 #include <sys/ptrace.h>
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] selftests: breakpoints: fix compile error on breakpoint_test_arm64
  2017-10-23  7:42 [PATCH] selftests: breakpoints: fix compile error on breakpoint_test_arm64 Sumit Semwal
@ 2017-11-01 20:52 ` Shuah Khan
  2017-11-03  3:48   ` Sumit Semwal
  0 siblings, 1 reply; 3+ messages in thread
From: Shuah Khan @ 2017-11-01 20:52 UTC (permalink / raw)
  To: Sumit Semwal, linux-kselftest, linux-kernel
  Cc: will.deacon, panand, paul.elder, Shuah Khan, Shuah Khan

On 10/23/2017 01:42 AM, Sumit Semwal wrote:
> The current mainline breakpoints test for arm64 fails to compile with
> 
> breakpoint_test_arm64.c: In function ‘set_watchpoint’:
> breakpoint_test_arm64.c:97:28: error: storage size of ‘dreg_state’ isn’t known
>   struct user_hwdebug_state dreg_state;
> 
> Adding a direct include for asm/ptrace.h helps it to build, and passes
> the test on mainline on hikey.
> 
> Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org>
> ---
>  tools/testing/selftests/breakpoints/breakpoint_test_arm64.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c b/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c
> index 960d02100c26..2d95e5adde72 100644
> --- a/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c
> +++ b/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c
> @@ -19,6 +19,7 @@
>  
>  #define _GNU_SOURCE
>  
> +#include <asm/ptrace.h>
>  #include <sys/types.h>
>  #include <sys/wait.h>
>  #include <sys/ptrace.h>
> 

Sumit,

Thanks for the patch. I will queue this up for 4.15-rc1.
This can be marked for stable I would assume?

thanks,
-- Shuah

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] selftests: breakpoints: fix compile error on breakpoint_test_arm64
  2017-11-01 20:52 ` Shuah Khan
@ 2017-11-03  3:48   ` Sumit Semwal
  0 siblings, 0 replies; 3+ messages in thread
From: Sumit Semwal @ 2017-11-03  3:48 UTC (permalink / raw)
  To: Shuah Khan
  Cc: open list:KERNEL SELFTEST FRAMEWORK, LKML, Will Deacon, panand,
	paul.elder, Shuah Khan

Hi Shuah,

On 2 November 2017 at 02:22, Shuah Khan <shuah@kernel.org> wrote:
> On 10/23/2017 01:42 AM, Sumit Semwal wrote:
>> The current mainline breakpoints test for arm64 fails to compile with
>>
>> breakpoint_test_arm64.c: In function ‘set_watchpoint’:
>> breakpoint_test_arm64.c:97:28: error: storage size of ‘dreg_state’ isn’t known
>>   struct user_hwdebug_state dreg_state;
>>
>> Adding a direct include for asm/ptrace.h helps it to build, and passes
>> the test on mainline on hikey.
>>
>> Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org>
>> ---
>>  tools/testing/selftests/breakpoints/breakpoint_test_arm64.c | 1 +
>>  1 file changed, 1 insertion(+)
>>
>> diff --git a/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c b/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c
>> index 960d02100c26..2d95e5adde72 100644
>> --- a/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c
>> +++ b/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c
>> @@ -19,6 +19,7 @@
>>
>>  #define _GNU_SOURCE
>>
>> +#include <asm/ptrace.h>
>>  #include <sys/types.h>
>>  #include <sys/wait.h>
>>  #include <sys/ptrace.h>
>>
>
> Sumit,
>
> Thanks for the patch. I will queue this up for 4.15-rc1.
> This can be marked for stable I would assume?
Thank you; yes, it would need to be marked for 4.10+ kernels. Once you
add it to your tree, I can send a separate request to stable.
>
> thanks,
> -- Shuah

Best,
Sumit.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-11-03  3:49 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-10-23  7:42 [PATCH] selftests: breakpoints: fix compile error on breakpoint_test_arm64 Sumit Semwal
2017-11-01 20:52 ` Shuah Khan
2017-11-03  3:48   ` Sumit Semwal

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.