VxWorks TCB overwrite - VxWorks

This is a discussion on VxWorks TCB overwrite - VxWorks ; Hello, We are using VxWorks5.5.1 for our product and are facing a crash problem now. >From the crash-dump we can see that a function called selWakeupAll , and tries to switch to some task and it crashes. We have tried ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: VxWorks TCB overwrite

  1. VxWorks TCB overwrite

    Hello,
    We are using VxWorks5.5.1 for our product and are facing a crash
    problem now.

    >From the crash-dump we can see that a function called selWakeupAll ,

    and tries to switch to some task and it crashes.

    We have tried the following:
    1. Protected the memory above the created tasks, so that the TCB+Stack
    for the task is pushed below and any access to the protected memory
    will show the funciton in the crash dump.

    2. We have used the TaskSwitchHook function, to check for the Old and
    New task the stack pointers. If it exceeds the stack limit the
    corrosponding task is suspended.

    Could you please suggest some ways to debug such TCB overwrite kind of
    issues.

    Regards,
    Sunil


  2. Re: VxWorks TCB overwrite

    Hi Sunil,

    from my experience, I would suppose a stack overflow. Stack and TCB
    always reside close to each other. When a task uses more stackspace than
    it got reserved it may overwrite its tcb.

    Try to increase the concerned task's stack and check the task for
    recursive function calls.

    This might (hopefully) help.

    Greetings,

    Fritz


    Sunil wrote:
    > Hello,
    > We are using VxWorks5.5.1 for our product and are facing a crash
    > problem now.
    >
    >>From the crash-dump we can see that a function called selWakeupAll ,

    > and tries to switch to some task and it crashes.
    >
    > We have tried the following:
    > 1. Protected the memory above the created tasks, so that the TCB+Stack
    > for the task is pushed below and any access to the protected memory
    > will show the funciton in the crash dump.
    >
    > 2. We have used the TaskSwitchHook function, to check for the Old and
    > New task the stack pointers. If it exceeds the stack limit the
    > corrosponding task is suspended.
    >
    > Could you please suggest some ways to debug such TCB overwrite kind of
    > issues.
    >
    > Regards,
    > Sunil
    >


+ Reply to Thread