Help required with RTEMS Capture Engine.

Chris Johns chrisj at rtems.org
Wed Jul 20 22:32:27 UTC 2016


On 19/07/2016 18:30, vivek kukreja wrote:
> Hello all,
>
> I'm Vivek Kukreja and i'm working on Capture Engine for GSoC this year. I'm running rtems 4.12 and I came across an error on running the capture.exe example to trace user extensions.
> The 'ctrace' command is giving an error RTEMS_UNSATISFIED.
> I think this error is due to a faulty if condition in cpukit/libmisc/capture.c
>
> I think the following exit condition is inconsistent:
> if ( (capture_flags_global & RTEMS_CAPTURE_ON) != 0 )
>
> And it should be:
> if ( (capture_flags_global & RTEMS_CAPTURE_ON) == 0 )
>
> I've been asked to open a ticket for this bug but i wanted to confirm beforehand if anyone else faced this issue, since the capture engine code was commited 16months back.
>

There is something wrong with this code and I am not sure what it is. 
Joel is going to have to sort this out.

For example, this comment says this function returns a number of record 
slots back to the capture engine which implies to me this can be called 
with the capture engine is running:

https://git.rtems.org/rtems/tree/cpukit/libmisc/capture/capture.c#n1244

and yet the type of code you point out:

https://git.rtems.org/rtems/tree/cpukit/libmisc/capture/capture.c#n1269

says you cannot do this operation while the capture is on. One of these 
things is wrong and I do not know which.

I suspect the test is wrong but I am not sure if it is ok to change or 
if the test is actually valid.

Joel?

Chris



More information about the devel mailing list