Jan Kiszka <jan.kis...@siemens.com> writes:

> On 15.11.21 08:57, Philippe Gerum wrote:
>> 
>> Jan Kiszka <jan.kis...@siemens.com> writes:
>> 
>>> On 14.11.21 11:03, Philippe Gerum via Xenomai wrote:
>>>> From: Philippe Gerum <r...@xenomai.org>
>>>>
>>>> Since release v5.10.76-dovetail3, handle_oob_syscall() should return a
>>>> propagation status just like handle_pipelined_syscall(), with the same
>>>> semantics. This is a requirement for properly handling our syscall
>>>> format and the new prctl-based one concurrently. Fix up the signature
>>>> accordingly.  This status is ignored on earlier Dovetail releases.
>>>>
>>>> In addition, CONFIG_DOVETAIL_LEGACY_SYSCALL_RANGE is checked for
>>>> enabling our current syscall format, which defaults to y at the
>>>> moment.  Force it on regardless to allow for detection when this call
>>>> format is eventually deprecated upstream.
>>>>
>>>> Signed-off-by: Philippe Gerum <r...@xenomai.org>
>>>> ---
>>>>  kernel/cobalt/dovetail/syscall.c | 5 ++---
>>>>  scripts/Kconfig.frag             | 1 +
>>>>  2 files changed, 3 insertions(+), 3 deletions(-)
>>>>
>>>> diff --git a/kernel/cobalt/dovetail/syscall.c 
>>>> b/kernel/cobalt/dovetail/syscall.c
>>>> index cec6c0244..440c069d5 100644
>>>> --- a/kernel/cobalt/dovetail/syscall.c
>>>> +++ b/kernel/cobalt/dovetail/syscall.c
>>>> @@ -19,8 +19,7 @@ int handle_pipelined_syscall(struct irq_stage *stage, 
>>>> struct pt_regs *regs)
>>>>    return handle_head_syscall(stage == &inband_stage, regs);
>>>>  }
>>>>  
>>>> -void handle_oob_syscall(struct pt_regs *regs)
>>>> +int handle_oob_syscall(struct pt_regs *regs)
>>>>  {
>>>> -  int ret = handle_head_syscall(false, regs);
>>>> -  XENO_BUG_ON(COBALT, ret == KEVENT_PROPAGATE);
>>>> +  return handle_head_syscall(false, regs);
>>>>  }
>>>
>>> This unfortunately makes the Xenomai 3.2 release incompatible with
>>> latest stable Dovetail. I would now have to hectically roll out 3.2.1
>>> and cross fingers that people will use it. Better than before, but still
>>> not smooth.
>> 
>> Did you try this patch? What went wrong?
>> 
>
> The patch passed testing and is not the issue. That is in the fact that
> we must update to callback in order to have stable syscall processing
> again because 3.2 would return random codes for it and can fail subtly.
>

Do you have a failure scenario in mind?

-- 
Philippe.

Reply via email to