Hi all,
I need confirmations on the ipipe model, to interpret test results. Excuse
me, I'm new to this
kind of work, I only read introductory articles on the adeos/xenomai
architecture.

I'm testing Xenomai on an e300 Core PowerPC, and, to get lowest latencies, I
realized an RTDM
driver which handles an external timer interrupt:

-sh-2.05b# cat /proc/ipipe/Xenomai
       +----- Handling ([A]ccepted, [G]rabbed, [W]ired, [D]iscarded)
       |+---- Sticky
       ||+--- Locked
       |||+-- Exclusive
       ||||+- Virtual
[IRQ]  |||||
  75:  W..X.
 512:  W..XV
 515:  W...V

IRQ 75 is the timer interrupt. It is not handled in the Linux domain:

-sh-2.05b# cat /proc/ipipe/Linux | grep " 75"
  75:  A....

The Xenomai interrupt handler simply toggles a pin
generating a squarewave measured by an oscilloscope, so this is a jitter
test:

static int demo_interrupt(rtdm_irq_t *irq_context)
{
    int ret = RTDM_IRQ_HANDLED;
    struct gpt_drv_context *ctx;

    ctx = rtdm_irq_get_arg(irq_context, struct gpt_drv_context);

    // re-enable timer interrupt
    out_be32((ctx->gpt) + GPT_STATUS, GPT_STATUS_TEXP);

    // toggle GPIO
    if (read_pin(PIN, ctx)) {
        set_pin_low(PIN, ctx);
    } else {
        set_pin_high(PIN, ctx);
    }

    return ret;
}

The test shows a 2/3 uS jitter with no load.

Then I open an ssh connection with the target, and run a "cat /dev/zero >
file". The target
is mounted on an NFS root filesystem, so this generates a high number of
fast ethernet interrupts. Now the oscilloscope shows 15 uS jitter in the
worst case,
and a visible variance. I would assume this effect as increased max latency.

The ethernet interrupt is handled only in Linux domain by the original
vanilla handler,
but Linux should be stalled/preempted when the timer interrupt occurs. So I
assume
that latency is to be justified by the time it takes to adeos to record an
ethernet interrupt event in the i-logs when the timer interrupt is executing
or ready to
execute. Is this correct?

Assuming it is correct, what i-logs are concerned in the case of the
ethernet interrupt?
Is only the Xenomai i-log, only the Linux i-log, or both i-logs concerned? I
removed the
Interrupt Shield, but did not notice jitter differences.

Is there any way to lower max latency for the timer interrupt?

May I assume the max jitter measured is the upper bound, when there is only
this Xenomai
interrupt handler, and no other real time tasks?

May I assume that increasing the number of non real time related interrupts
in the system
would determine an increased mean latency, but not an increased max latency?

Thank you very much,
Antonio
_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to