In examining the sample code for the Gate implementation in Syslink 2_00_00_68, I see a difference between what has been coded and the documentation. The sample hlos code( GateMPApp.c): if (status >= 0) { GateMP_Params_init (&gateMPParams); gateMPParams.remoteProtect = GateMP_RemoteProtect_SYSTEM; gateMPParams.sharedAddr = NULL; /* Calculate the size for System Gate and shared buffer*/ sharedMemSize = GateMP_sharedMemReq (&gateMPParams) + BYTES_TO_PROCESS; /* Allocate memory for GateMP */
gateMPParams.sharedAddr = Memory_alloc (srHeap, sharedMemSize, 0, NULL); if (NULL == gateMPParams.sharedAddr) { Memory_free (srHeap, (Ptr) (buffer), BYTES_TO_PROCESS); status = -1; Osal_printf ("Memory_alloc failed." " when allocating %x bytes!.\n", sharedMemSize); } else { /* Now create the actual gate */ Osal_printf ("Creating the GateMP\n"); gateMPParams.name = "HOSTGATE"; hostGate = GateMP_create (&gateMPParams); The example given in the Sys/bios Inter-Processor Communication and I/O User's Guide (SPRUGO6C): GateMP_params_init(&gparams); gparams.localProtect = GateMP_LocalProtect_THREAD; gparams.remoteProtect = GateMP_RemoteProtect_SYSTEM; gparams.name = "myGate"; gparams.regionId = 1; gateHandle = GateMP_create(&gparams, NULL); Notice that in the documented example there is no mention of allocating memory for the gate itself, is this something new, and is it required for Syslink? The included html documentation doesn't mention this either. Lee Holeva