lkml.org 
[lkml]   [2018]   [Jul]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH] x86/ptrace: Add comments to x86_regset about empty slots
Date
find_regset() goes through regsets sequentially.  Empty slots
in regset arrays causes mismatch. Add comments to x86_regset
enum.

Signed-off-by: Yu-cheng Yu <yu-cheng.yu@intel.com>
---
arch/x86/kernel/ptrace.c | 5 +++++
1 file changed, 5 insertions(+)

diff --git a/arch/x86/kernel/ptrace.c b/arch/x86/kernel/ptrace.c
index e2ee403865eb..130ca4f27a17 100644
--- a/arch/x86/kernel/ptrace.c
+++ b/arch/x86/kernel/ptrace.c
@@ -42,6 +42,11 @@

#include "tls.h"

+/*
+ * find_regset() goes through regsets sequentially.
+ * Do not create empty slots in x86_64_regsets[] or
+ * x86_32_regsets[] below.
+ */
enum x86_regset {
REGSET_GENERAL,
REGSET_FP,
--
2.17.1
\
 
 \ /
  Last update: 2018-07-15 22:07    [W:0.064 / U:0.420 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site