Gabriele Moabiti wrote:
> Gilles Chanteperdrix wrote:
>> Gabriele Moabiti wrote:
>>> (...) I consider now ManageCustomExceptions a function that do
>>> nothing. (...) INT 0 (divide error) or 16 (fpu exception) The
>>> system hangs.
>> It will not work. It is because you have to handle the exception. 
>> Otherwise, when returning to user-space, your programs tries the
>> faulty exception again, triggers the handler, which does nothing,
>> and loops indefinitely...
>> 
> 
> so the int 1 and 3 are instead signed as traps with the old CS:EIP
> points past instruction causing exception...
> 
> Sorry for the question (I have always done it directly in asm
> reprogramming customizing the IDT), do I have to change the eip of
> the pt_regs structure passed to the function?

Errr no. You probably know better than me the details of exception
handling (I trust Linux and/or Xenomai exception handling for my
everyday usage), however, if your code contains an instruction which
uses FPU, you should enable FPU and let the program retry that
instruction, otherwise, if you skip this instruction, you will never
know its result.

-- 
                                            Gilles.

_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to