Changing compilation options for BSP building

Ralf Corsepius ralf.corsepius at rtems.org
Sat Mar 25 06:56:45 UTC 2006


On Sat, 2006-03-25 at 00:32 +0100, Jiri Gaisler wrote:
> I have created a patch agains rtems-4.6.5 that includes
> the all the remaining FPU modification for the sparc port,
> and some new drivers for leon2/3. It can be downloaded at:
> 
> ftp://gaisler.com/gaisler.com/rcc/src/rtems-4.6.5.diff
> 
> The patch also includes multi-processor (shared memory)
> support for leon3. We have run rtems on a 4-cpu leon3
> system quite successfully, all the (relevant) mp tests
> ran OK.

> Can somebody (Joel?) merge the patch into the 4.6.6 branch?

I am doubts on some parts of your patches:

1. Here, you have commented out code being shared between all BSPs and
thereby are breaking the API:

--- rtems-4.6.5/c/src/lib/libbsp/shmdr/shm_driver.h     2003-09-04 20:53:36.000000000 +0200
+++ rtems-4.6.5.12/c/src/lib/libbsp/shmdr/shm_driver.h  2006-02-03 18:31:26.000000000 +0100
@@ -144,6 +144,9 @@
 #elif defined(_AM29K)
 #define SHM_LOCK_VALUE    0
 #define SHM_UNLOCK_VALUE  1
+#elif defined(__sparc__)
+#define SHM_LOCK_VALUE    1
+#define SHM_UNLOCK_VALUE  0
 #elif defined(no_cpu)               /* for this values are irrelevant */
 #define SHM_LOCK_VALUE    1
 #define SHM_UNLOCK_VALUE  0
@@ -499,6 +502,7 @@
 void           Shm_Unlock( Shm_Locked_queue_Control * );

 /* MPCI entry points */
+/*
 rtems_mpci_entry Shm_Get_packet(
   rtems_packet_prefix **
 );
@@ -517,6 +521,7 @@
   rtems_unsigned32,
   rtems_packet_prefix *
 );
+*/

 extern rtems_mpci_table MPCI_table;

@@ -524,15 +529,15 @@

 /* multiprocessor communications interface (MPCI) table */

-rtems_mpci_table MPCI_table  = {
-  100000,                     /* default timeout value in ticks */
-  MAX_PACKET_SIZE,            /* maximum packet size */
-  Shm_Initialization,         /* initialization procedure   */
-  Shm_Get_packet,             /* get packet procedure       */
-  Shm_Return_packet,          /* return packet procedure    */
-  Shm_Send_packet,            /* packet send procedure      */
-  Shm_Receive_packet          /* packet receive procedure   */
-};
+/* rtems_mpci_table MPCI_table  = { */
+/*   100000,                     /\* default timeout value in ticks *\/ */
+/*   MAX_PACKET_SIZE,            /\* maximum packet size *\/ */
+/*   Shm_Initialization,         /\* initialization procedure   *\/ */
+/*   Shm_Get_packet,             /\* get packet procedure       *\/ */
+/*   Shm_Return_packet,          /\* return packet procedure    *\/ */
+/*   Shm_Send_packet,            /\* packet send procedure      *\/ */
+/*   Shm_Receive_packet          /\* packet receive procedure   *\/ */
+/* }; */

 #endif


2. Can you explain this patch below:

--- rtems-4.6.5/cpukit/score/cpu/sparc/rtems/score/sparc.h      2003-09-04 20:47:40.000000000 +0200
+++ rtems-4.6.5.12/cpukit/score/cpu/sparc/rtems/score/sparc.h   2005-10-24 15:34:57.000000000 +0200
@@ -66,11 +66,7 @@
  */


-#if defined(_SOFT_FLOAT)
-#define SPARC_HAS_FPU 0
-#else
 #define SPARC_HAS_FPU 1
-#endif

 #if SPARC_HAS_FPU
 #define CPU_MODEL_NAME "w/FPU"

This doesn't seem right to me.

At least these code fragment can not be merged into CVS. The other parts
of your patch only affect your BSPs and therefore shouldn't be critical 

Ralf





More information about the users mailing list