MULTIPLE CALL TO SEGMENT

Hi All,
I've a warning message : MULTIPLE CALL TO SEGMENT L15
The problem comes from 2 different ISRs that call the same function.
What I dont understand is that both callers are ISRs and therfore the called function will not be called at the same time.
I use keil 7.07 for an2131 cypress (ezusb),
here is my code :

#pragma NOAREGS

static void Check_Data_Received(unsigned char data_received)
{
...
MIDI_In_Add_Buffer(data_received, &MIDI_In_From_Con);
...
}

static void MIDI_In_Add_Buffer(unsigned char data_in, Midi_In_Struct *midi_struct)
{
...
}

#pragma AREGS

static void serial_port_0_isr (void) interrupt COM0_VECT using 1
{
BYTE data_received;
...
Check_Data_Received(data_received);
...
}

void ISR_Ep2out(void) interrupt 0
{
..
MIDI_In_Add_Buffer(OUT2BUF[index+frame+1], &MIDI_In_From_Usb);
}

The warning is as follow :

*** WARNING L15: MULTIPLE CALL TO SEGMENT
SEGMENT: ?PR?_MIDI_IN_ADD_BUFFER?ITR
CALLER1: ?PR?SERIAL_PORT_0_ISR?ITR
CALLER2: ?PR?USB_JUMP_TABLE?USBJT

Any help greatly appreciated

Parents
  • What I dont understand is that both callers are ISRs and therfore the called function will not be called at the same time.

    True only if both ISRs are same priority.

    You expect the linker to find and analyze all occurences of IP (and its multitude of expansions IP1, EIP etc) and based on that decide if there is any possibility of one ISR calling when the subroutine is processing a call from another ISR. That is asking the linker to be a bit more than it could ever be. For one, to do this the linker would need to be drivative aware.

    Erik

Reply
  • What I dont understand is that both callers are ISRs and therfore the called function will not be called at the same time.

    True only if both ISRs are same priority.

    You expect the linker to find and analyze all occurences of IP (and its multitude of expansions IP1, EIP etc) and based on that decide if there is any possibility of one ISR calling when the subroutine is processing a call from another ISR. That is asking the linker to be a bit more than it could ever be. For one, to do this the linker would need to be drivative aware.

    Erik

Children
More questions in this forum