All of lore.kernel.org
 help / color / mirror / Atom feed
* Dovetail 5.10.y sync
@ 2023-03-16 18:43 Jan Kiszka
       [not found] ` <0d2fbd52-288c-1af5-b462-ec6a4ec1ba0b@bela.io>
  0 siblings, 1 reply; 4+ messages in thread
From: Jan Kiszka @ 2023-03-16 18:43 UTC (permalink / raw)
  To: Philippe Gerum, Xenomai

Hi Philippe,

currently aligning v5.10.y-dovetail to ...-rebase, and I'm left now with 
this merge delta:

diff --git a/arch/arm64/kernel/entry.S b/arch/arm64/kernel/entry.S
index 8dd10391ca37..02e0b86e4da7 100644
--- a/arch/arm64/kernel/entry.S
+++ b/arch/arm64/kernel/entry.S
@@ -799,7 +799,8 @@ SYM_CODE_START_LOCAL(ret_to_user)
 	bl	trace_hardirqs_off
 #endif
 	ldr	x19, [tsk, #TSK_TI_FLAGS]
-	and	x2, x19, #_TIF_WORK_MASK
+	mov	x2, #_TIF_WORK_MASK
+	and	x2, x19, x2
 	cbnz	x2, work_pending
 finish_ret_to_user:
 	user_enter_irqoff

Any reason for this change, implemented in [1]?

Jan

[1] https://source.denx.de/Xenomai/linux-dovetail/-/commit/7f1078a34e#2803808927dc5f1a93c4d4a6e56f1e7671d53c01_754_780

-- 
Siemens AG, Technology
Competence Center Embedded Linux

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

* Re: Dovetail 5.10.y sync
       [not found] ` <0d2fbd52-288c-1af5-b462-ec6a4ec1ba0b@bela.io>
@ 2023-03-16 19:11   ` Jan Kiszka
  2023-03-16 20:54     ` Florian Bezdeka
  2023-03-17  6:51   ` Philippe Gerum
  1 sibling, 1 reply; 4+ messages in thread
From: Jan Kiszka @ 2023-03-16 19:11 UTC (permalink / raw)
  To: Giulio Moro, Philippe Gerum, Xenomai

On 16.03.23 19:57, Giulio Moro wrote:
> I am totally not involved with the change at hand, but it looks like it
> is related to this:
> 
>  #define TIF_SIGPENDING        0    /* signal pending */
>  #define TIF_NEED_RESCHED    1    /* rescheduling necessary */
>  #define TIF_NOTIFY_RESUME    2    /* callback before returning to user */
>  #define TIF_FOREIGN_FPSTATE    3    /* CPU's FP state is not current's */
>  #define TIF_UPROBE        4    /* uprobe breakpoint or singlestep */
>  #define TIF_FSCHECK        5    /* Check FS is USER_DS on return */
>  #define TIF_MTE_ASYNC_FAULT    6    /* MTE Asynchronous Tag Check Fault */
>  #define TIF_NOTIFY_SIGNAL    7    /* signal notifications exist */
>  #define TIF_SYSCALL_TRACE    8    /* syscall trace active */
>  #define TIF_SYSCALL_AUDIT    9    /* syscall auditing */
>  #define TIF_SYSCALL_TRACEPOINT    10    /* syscall tracepoint for
> ftrace */
>  #define TIF_SECCOMP        11    /* syscall secure computing */
>  #define TIF_SYSCALL_EMU        12    /* syscall emulation active */
> +#define TIF_RETUSER        13    /* INBAND_TASK_RETUSER is pending */
> 
> ...
> 
>  #define _TIF_WORK_MASK        (_TIF_NEED_RESCHED | _TIF_SIGPENDING | \
>                   _TIF_NOTIFY_RESUME | _TIF_FOREIGN_FPSTATE | \
>                   _TIF_UPROBE | _TIF_FSCHECK | _TIF_MTE_ASYNC_FAULT | \
> -                 _TIF_NOTIFY_SIGNAL)
> +                 _TIF_NOTIFY_SIGNAL | _TIF_RETUSER)
> 
> as _TIF_RETUSER is (1 << 13), then _TIF_WORK_MASK no longer fits into 8
> bits and can no longer be used as a flexible second operand to AND.
> Instead, it needs its dedicated MOV instruction.
> 

Ah, that makes sense. Thanks for clarifying!

Jan

-- 
Siemens AG, Technology
Competence Center Embedded Linux


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

* Re: Dovetail 5.10.y sync
  2023-03-16 19:11   ` Jan Kiszka
@ 2023-03-16 20:54     ` Florian Bezdeka
  0 siblings, 0 replies; 4+ messages in thread
From: Florian Bezdeka @ 2023-03-16 20:54 UTC (permalink / raw)
  To: Jan Kiszka, Giulio Moro, Philippe Gerum, Xenomai

On Thu, 2023-03-16 at 20:11 +0100, Jan Kiszka wrote:
> On 16.03.23 19:57, Giulio Moro wrote:
> > I am totally not involved with the change at hand, but it looks like it
> > is related to this:
> > 
> >  #define TIF_SIGPENDING        0    /* signal pending */
> >  #define TIF_NEED_RESCHED    1    /* rescheduling necessary */
> >  #define TIF_NOTIFY_RESUME    2    /* callback before returning to user */
> >  #define TIF_FOREIGN_FPSTATE    3    /* CPU's FP state is not current's */
> >  #define TIF_UPROBE        4    /* uprobe breakpoint or singlestep */
> >  #define TIF_FSCHECK        5    /* Check FS is USER_DS on return */
> >  #define TIF_MTE_ASYNC_FAULT    6    /* MTE Asynchronous Tag Check Fault */
> >  #define TIF_NOTIFY_SIGNAL    7    /* signal notifications exist */
> >  #define TIF_SYSCALL_TRACE    8    /* syscall trace active */
> >  #define TIF_SYSCALL_AUDIT    9    /* syscall auditing */
> >  #define TIF_SYSCALL_TRACEPOINT    10    /* syscall tracepoint for
> > ftrace */
> >  #define TIF_SECCOMP        11    /* syscall secure computing */
> >  #define TIF_SYSCALL_EMU        12    /* syscall emulation active */
> > +#define TIF_RETUSER        13    /* INBAND_TASK_RETUSER is pending */
> > 
> > ...
> > 
> >  #define _TIF_WORK_MASK        (_TIF_NEED_RESCHED | _TIF_SIGPENDING | \
> >                   _TIF_NOTIFY_RESUME | _TIF_FOREIGN_FPSTATE | \
> >                   _TIF_UPROBE | _TIF_FSCHECK | _TIF_MTE_ASYNC_FAULT | \
> > -                 _TIF_NOTIFY_SIGNAL)
> > +                 _TIF_NOTIFY_SIGNAL | _TIF_RETUSER)
> > 
> > as _TIF_RETUSER is (1 << 13), then _TIF_WORK_MASK no longer fits into 8
> > bits and can no longer be used as a flexible second operand to AND.
> > Instead, it needs its dedicated MOV instruction.
> > 
> 
> Ah, that makes sense. Thanks for clarifying!

That was the build failure we saw on arm64 a few weeks ago in the rt-
stable tree...

> 
> Jan
> 


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

* Re: Dovetail 5.10.y sync
       [not found] ` <0d2fbd52-288c-1af5-b462-ec6a4ec1ba0b@bela.io>
  2023-03-16 19:11   ` Jan Kiszka
@ 2023-03-17  6:51   ` Philippe Gerum
  1 sibling, 0 replies; 4+ messages in thread
From: Philippe Gerum @ 2023-03-17  6:51 UTC (permalink / raw)
  To: Giulio Moro; +Cc: Jan Kiszka, Xenomai


Giulio Moro <giulio@bela.io> writes:

> I am totally not involved with the change at hand, but it looks like it is related to this:
>
>  #define TIF_SIGPENDING		0	/* signal pending */
>  #define TIF_NEED_RESCHED	1	/* rescheduling necessary */
>  #define TIF_NOTIFY_RESUME	2	/* callback before returning to user */
>  #define TIF_FOREIGN_FPSTATE	3	/* CPU's FP state is not current's */
>  #define TIF_UPROBE		4	/* uprobe breakpoint or singlestep */
>  #define TIF_FSCHECK		5	/* Check FS is USER_DS on return */
>  #define TIF_MTE_ASYNC_FAULT	6	/* MTE Asynchronous Tag Check Fault */
>  #define TIF_NOTIFY_SIGNAL	7	/* signal notifications exist */
>  #define TIF_SYSCALL_TRACE	8	/* syscall trace active */
>  #define TIF_SYSCALL_AUDIT	9	/* syscall auditing */
>  #define TIF_SYSCALL_TRACEPOINT	10	/* syscall tracepoint for ftrace */
>  #define TIF_SECCOMP		11	/* syscall secure computing */
>  #define TIF_SYSCALL_EMU		12	/* syscall emulation active */
> +#define TIF_RETUSER		13	/* INBAND_TASK_RETUSER is pending */
>
> ...
>
>  #define _TIF_WORK_MASK		(_TIF_NEED_RESCHED | _TIF_SIGPENDING | \
>  				 _TIF_NOTIFY_RESUME | _TIF_FOREIGN_FPSTATE | \
>  				 _TIF_UPROBE | _TIF_FSCHECK | _TIF_MTE_ASYNC_FAULT | \
> -				 _TIF_NOTIFY_SIGNAL)
> +				 _TIF_NOTIFY_SIGNAL | _TIF_RETUSER)
>
> as _TIF_RETUSER is (1 << 13), then _TIF_WORK_MASK no longer fits into 8 bits and can no longer be used as a flexible second operand to AND. Instead, it needs its dedicated MOV instruction.
>

That was indeed the reason for the change.

-- 
Philippe.

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

end of thread, other threads:[~2023-03-17  6:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-16 18:43 Dovetail 5.10.y sync Jan Kiszka
     [not found] ` <0d2fbd52-288c-1af5-b462-ec6a4ec1ba0b@bela.io>
2023-03-16 19:11   ` Jan Kiszka
2023-03-16 20:54     ` Florian Bezdeka
2023-03-17  6:51   ` Philippe Gerum

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.