forked from Imagelibrary/rtems
2011-09-09 Sebastian Huber <sebastian.huber@embedded-brains.de>
* score/include/rtems/score/basedefs.h: Typo. * score/src/mpci.c, rtems/src/eventmp.c, rtems/src/msgmp.c, rtems/src/partmp.c, rtems/src/regionmp.c, rtems/src/semmp.c, rtems/src/signalmp.c, rtems/src/taskmp.c: Use RTEMS_STATIC_ASSERT() to ensure that the packet size is small enough.
This commit is contained in:
@@ -1,3 +1,11 @@
|
|||||||
|
2011-09-09 Sebastian Huber <sebastian.huber@embedded-brains.de>
|
||||||
|
|
||||||
|
* score/include/rtems/score/basedefs.h: Typo.
|
||||||
|
* score/src/mpci.c, rtems/src/eventmp.c, rtems/src/msgmp.c,
|
||||||
|
rtems/src/partmp.c, rtems/src/regionmp.c, rtems/src/semmp.c,
|
||||||
|
rtems/src/signalmp.c, rtems/src/taskmp.c: Use RTEMS_STATIC_ASSERT() to
|
||||||
|
ensure that the packet size is small enough.
|
||||||
|
|
||||||
2011-09-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
|
2011-09-02 Sebastian Huber <sebastian.huber@embedded-brains.de>
|
||||||
|
|
||||||
* libmisc/monitor/mon-monitor.c: Removed "exit" and "quit" commands to
|
* libmisc/monitor/mon-monitor.c: Removed "exit" and "quit" commands to
|
||||||
|
|||||||
@@ -26,6 +26,11 @@
|
|||||||
#include <rtems/score/thread.h>
|
#include <rtems/score/thread.h>
|
||||||
#include <rtems/rtems/support.h>
|
#include <rtems/rtems/support.h>
|
||||||
|
|
||||||
|
RTEMS_STATIC_ASSERT(
|
||||||
|
sizeof(Event_MP_Packet) <= MP_PACKET_MINIMUM_PACKET_SIZE,
|
||||||
|
Event_MP_Packet
|
||||||
|
);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* _Event_MP_Send_process_packet
|
* _Event_MP_Send_process_packet
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -27,6 +27,14 @@
|
|||||||
#include <rtems/score/watchdog.h>
|
#include <rtems/score/watchdog.h>
|
||||||
#include <rtems/rtems/support.h>
|
#include <rtems/rtems/support.h>
|
||||||
|
|
||||||
|
#define MESSAGE_QUEUE_MP_PACKET_SIZE \
|
||||||
|
offsetof(Message_queue_MP_Packet, Buffer.buffer)
|
||||||
|
|
||||||
|
RTEMS_STATIC_ASSERT(
|
||||||
|
MESSAGE_QUEUE_MP_PACKET_SIZE <= MP_PACKET_MINIMUM_PACKET_SIZE,
|
||||||
|
Message_queue_MP_Packet
|
||||||
|
);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* _Message_queue_MP_Send_process_packet
|
* _Message_queue_MP_Send_process_packet
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -26,6 +26,11 @@
|
|||||||
#include <rtems/score/thread.h>
|
#include <rtems/score/thread.h>
|
||||||
#include <rtems/rtems/support.h>
|
#include <rtems/rtems/support.h>
|
||||||
|
|
||||||
|
RTEMS_STATIC_ASSERT(
|
||||||
|
sizeof(Partition_MP_Packet) <= MP_PACKET_MINIMUM_PACKET_SIZE,
|
||||||
|
Partition_MP_Packet
|
||||||
|
);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* _Partition_MP_Send_process_packet
|
* _Partition_MP_Send_process_packet
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -26,6 +26,11 @@
|
|||||||
#include <rtems/score/thread.h>
|
#include <rtems/score/thread.h>
|
||||||
#include <rtems/rtems/support.h>
|
#include <rtems/rtems/support.h>
|
||||||
|
|
||||||
|
RTEMS_STATIC_ASSERT(
|
||||||
|
sizeof(Region_MP_Packet) <= MP_PACKET_MINIMUM_PACKET_SIZE,
|
||||||
|
Region_MP_Packet
|
||||||
|
);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* _Region_MP_Send_process_packet
|
* _Region_MP_Send_process_packet
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -27,6 +27,11 @@
|
|||||||
#include <rtems/score/watchdog.h>
|
#include <rtems/score/watchdog.h>
|
||||||
#include <rtems/rtems/support.h>
|
#include <rtems/rtems/support.h>
|
||||||
|
|
||||||
|
RTEMS_STATIC_ASSERT(
|
||||||
|
sizeof(Semaphore_MP_Packet) <= MP_PACKET_MINIMUM_PACKET_SIZE,
|
||||||
|
Semaphore_MP_Packet
|
||||||
|
);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* _Semaphore_MP_Send_process_packet
|
* _Semaphore_MP_Send_process_packet
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -28,6 +28,11 @@
|
|||||||
#include <rtems/score/watchdog.h>
|
#include <rtems/score/watchdog.h>
|
||||||
#include <rtems/rtems/support.h>
|
#include <rtems/rtems/support.h>
|
||||||
|
|
||||||
|
RTEMS_STATIC_ASSERT(
|
||||||
|
sizeof(Signal_MP_Packet) <= MP_PACKET_MINIMUM_PACKET_SIZE,
|
||||||
|
Signal_MP_Packet
|
||||||
|
);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* _Signal_MP_Send_process_packet
|
* _Signal_MP_Send_process_packet
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -27,6 +27,11 @@
|
|||||||
#include <rtems/score/watchdog.h>
|
#include <rtems/score/watchdog.h>
|
||||||
#include <rtems/rtems/support.h>
|
#include <rtems/rtems/support.h>
|
||||||
|
|
||||||
|
RTEMS_STATIC_ASSERT(
|
||||||
|
sizeof(RTEMS_tasks_MP_Packet) <= MP_PACKET_MINIMUM_PACKET_SIZE,
|
||||||
|
RTEMS_tasks_MP_Packet
|
||||||
|
);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* _RTEMS_tasks_MP_Send_process_packet
|
* _RTEMS_tasks_MP_Send_process_packet
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -166,7 +166,7 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define RTEMS_STATIC_ASSERT(cond, msg) \
|
#define RTEMS_STATIC_ASSERT(cond, msg) \
|
||||||
typedef int rtems_static_assert ## msg [(cond) ? 1 : -1]
|
typedef int rtems_static_assert_ ## msg [(cond) ? 1 : -1]
|
||||||
|
|
||||||
#ifndef ASM
|
#ifndef ASM
|
||||||
#ifdef RTEMS_DEPRECATED_TYPES
|
#ifdef RTEMS_DEPRECATED_TYPES
|
||||||
|
|||||||
@@ -34,6 +34,11 @@
|
|||||||
#include <rtems/score/coresem.h>
|
#include <rtems/score/coresem.h>
|
||||||
#include <rtems/config.h>
|
#include <rtems/config.h>
|
||||||
|
|
||||||
|
RTEMS_STATIC_ASSERT(
|
||||||
|
sizeof(MPCI_Internal_packet) <= MP_PACKET_MINIMUM_PACKET_SIZE,
|
||||||
|
MPCI_Internal_packet
|
||||||
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This is the core semaphore which the MPCI Receive Server blocks on.
|
* This is the core semaphore which the MPCI Receive Server blocks on.
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user