MPCI Driver

Sebastian Huber sebastian.huber at embedded-brains.de
Thu Feb 3 10:35:35 UTC 2011


Hello,

a MPCI (Multiprocessor Communications Interface) driver must provide these
functions:

/**
 *  This type defines the Multiprocessor Communications
 *  Interface (MPCI) Table.  This table defines the user-provided
 *  MPCI which is a required part of a multiprocessor system.
 *
 *  For non-blocking local operations that become remote operations,
 *  we need a timeout.  This is a per-driver timeout: default_timeout
 */
typedef struct {
  /** This fields contains the timeout for MPCI operations in ticks. */
  uint32_t                   default_timeout;
  /** This field contains the maximum size of a packet supported by this
   *  MPCI layer.  This size places a limit on the size of a message
   *  which can be transmitted over this interface.
   **/
  size_t                     maximum_packet_size;
  /** This field points to the MPCI initialization entry point. */
  MPCI_initialization_entry  initialization;
  /** This field points to the MPCI get packet entry point. */
  MPCI_get_packet_entry      get_packet;
  /** This field points to the MPCI return packet entry point. */
  MPCI_return_packet_entry   return_packet;
  /** This field points to the MPCI send packet entry point. */
  MPCI_send_entry            send_packet;
  /** This field points to the MPCI receive packet entry point. */
  MPCI_receive_entry         receive_packet;
} MPCI_Control;

I have a question regarding the send packet entry.  Does the send packet also
include a return packet semantic?  This would imply that the usage of a packet
after a call to the send packet entry is invalid.

Locking at the code is a bit confusing.  For example in
_Message_queue_MP_Send_request_packet() we get a packet, prepare the packet and
hand it over to _MPCI_Send_request_packet().  Since no references to the packet
are stored, I assume that _MPCI_Send_request_packet() will release the packet.
 Inside _MPCI_Send_request_packet() we make a call to send packet, but no call
to return packet.  So I assume that a send packet implies a packet return.  On
the other hand we use some packet values after the send packet (lines 275 to
278 in mpci.c).  Is this correct?

Have a nice day!

-- 
Sebastian Huber, embedded brains GmbH

Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany
Phone   : +49 89 18 90 80 79-6
Fax     : +49 89 18 90 80 79-9
E-Mail  : sebastian.huber at embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.



More information about the users mailing list