[IA64] do not sync RBS when changing PT_AR_BSP or PT_CFM
Syncing is no longer needed, because user RBS is already up-to-date. Actually, if a debugger modified the contents of the original RBS prior to changing PT_AR_BSP, the modifications would get overwritten. Signed-off-by: Petr Tesarik <ptesarik@suse.cz> Signed-off-by: Tony Luck <tony.luck@intel.com>
This commit is contained in:
parent
972559a052
commit
08b23d74e0
@ -1011,14 +1011,9 @@ access_uarea (struct task_struct *child, unsigned long addr,
|
|||||||
* the kernel was entered.
|
* the kernel was entered.
|
||||||
*
|
*
|
||||||
* Furthermore, when changing the contents of
|
* Furthermore, when changing the contents of
|
||||||
* PT_AR_BSP (or PT_CFM) we MUST copy any
|
* PT_AR_BSP (or PT_CFM) while the task is
|
||||||
* users-level stacked registers that are
|
* blocked in a system call, convert the state
|
||||||
* stored on the kernel stack back to
|
* so that the non-system-call exit
|
||||||
* user-space because otherwise, we might end
|
|
||||||
* up clobbering kernel stacked registers.
|
|
||||||
* Also, if this happens while the task is
|
|
||||||
* blocked in a system call, which convert the
|
|
||||||
* state such that the non-system-call exit
|
|
||||||
* path is used. This ensures that the proper
|
* path is used. This ensures that the proper
|
||||||
* state will be picked up when resuming
|
* state will be picked up when resuming
|
||||||
* execution. However, it *also* means that
|
* execution. However, it *also* means that
|
||||||
@ -1035,10 +1030,6 @@ access_uarea (struct task_struct *child, unsigned long addr,
|
|||||||
urbs_end = ia64_get_user_rbs_end(child, pt, &cfm);
|
urbs_end = ia64_get_user_rbs_end(child, pt, &cfm);
|
||||||
if (write_access) {
|
if (write_access) {
|
||||||
if (*data != urbs_end) {
|
if (*data != urbs_end) {
|
||||||
if (ia64_sync_user_rbs(child, sw,
|
|
||||||
pt->ar_bspstore,
|
|
||||||
urbs_end) < 0)
|
|
||||||
return -1;
|
|
||||||
if (in_syscall(pt))
|
if (in_syscall(pt))
|
||||||
convert_to_non_syscall(child,
|
convert_to_non_syscall(child,
|
||||||
pt,
|
pt,
|
||||||
@ -1058,10 +1049,6 @@ access_uarea (struct task_struct *child, unsigned long addr,
|
|||||||
urbs_end = ia64_get_user_rbs_end(child, pt, &cfm);
|
urbs_end = ia64_get_user_rbs_end(child, pt, &cfm);
|
||||||
if (write_access) {
|
if (write_access) {
|
||||||
if (((cfm ^ *data) & PFM_MASK) != 0) {
|
if (((cfm ^ *data) & PFM_MASK) != 0) {
|
||||||
if (ia64_sync_user_rbs(child, sw,
|
|
||||||
pt->ar_bspstore,
|
|
||||||
urbs_end) < 0)
|
|
||||||
return -1;
|
|
||||||
if (in_syscall(pt))
|
if (in_syscall(pt))
|
||||||
convert_to_non_syscall(child,
|
convert_to_non_syscall(child,
|
||||||
pt,
|
pt,
|
||||||
|
Loading…
Reference in New Issue
Block a user