Index: /issm/trunk-jpl/test/MITgcm/code/cpl_issm.F
===================================================================
--- /issm/trunk-jpl/test/MITgcm/code/cpl_issm.F	(revision 22635)
+++ /issm/trunk-jpl/test/MITgcm/code/cpl_issm.F	(revision 22636)
@@ -45,32 +45,34 @@
 #ifdef ALLOW_CPL_ISSM
 #include "EESUPPORT.h"
-      COMMON /CPL_MPI_ID/
-     &     mpiMyWid, toissmcomm
+      COMMON /CPL_MPI_ID/ mpiMyWid, toissmcomm
       INTEGER mpiMyWid, toissmcomm, mpiRC
-      integer mpistatus(MPI_STATUS_SIZE)
-      real*8 CouplingTime, IceModelTime
-      integer i, j, bi, bj, buffsize
-      Real*8  xfer_array(Nx,Ny)
-      _RL     local(1:sNx,1:sNy,nSx,nSy)
+      INTEGER mpistatus(MPI_STATUS_SIZE)
+      INTEGER i, j, bi, bj, buffsize
+      _R8 CouplingTime, IceModelTime
+      _R8 xfer_array(Nx,Ny)
+      _R8 local(1:sNx,1:sNy,nSx,nSy)
 
       IF( myTime .EQ. startTime ) THEN
 
-C     Send deltatimestep
-         _BEGIN_MASTER( myThid )
-         call MPI_Recv(CouplingTime,1,MPI_DOUBLE,0,10001000,toissmcomm,
-     &        mpistatus,mpiRC)
-         print*, 'Ocean received CouplingTime: ', CouplingTime
-         call MPI_Recv(IceModelTime,1,MPI_DOUBLE,0,10001001,toissmcomm,
-     &        mpistatus,mpiRC)
-         print*, 'Ocean received IceModelTime: ', IceModelTime
-         call MPI_Send(myTime,1,MPI_DOUBLE,0,10001002,toissmcomm,
-     &        mpistatus)
-         call MPI_Send(Nx,1,MPI_INT,0,10001003,toissmcomm,
-     &        mpistatus)
-         call MPI_Send(Ny,1,MPI_INT,0,10001004,toissmcomm,
-     &        mpistatus)
-         _END_MASTER( myThid )
+C     Send/receive scalar values
+         IF( myProcId .EQ. 0 ) THEN
+            _BEGIN_MASTER( myThid )         
+            call MPI_Recv(CouplingTime,1,MPI_DOUBLE,0,10001000,
+     &           toissmcomm,mpistatus,mpiRC)
+            print*, 'Ocean received CouplingTime: ', CouplingTime
+            call MPI_Recv(IceModelTime,1,MPI_DOUBLE,0,10001001,
+     &           toissmcomm,mpistatus,mpiRC)
+            print*, 'Ocean received IceModelTime: ', IceModelTime
+            call MPI_Send(myTime,1,MPI_DOUBLE,0,10001002,
+     &           toissmcomm,mpistatus)
+            call MPI_Send(Nx,1,MPI_INT,0,10001003,
+     &           toissmcomm,mpistatus)
+            call MPI_Send(Ny,1,MPI_INT,0,10001004,
+     &           toissmcomm,mpistatus)
+            _END_MASTER( myThid )
+         endif
 
 C     Send longitude East of center of cell
+         print*,'this is xC',xC
          DO bj=1,nSy
             DO bi=1,nSx
@@ -82,12 +84,20 @@
             ENDDO
          ENDDO
-CDM         CALL GATHER_2D_R8( xfer_array, local, myThid )
-         _BEGIN_MASTER( myThid )
-         buffsize = Nx*Ny
-         CALL MPI_SEND(xfer_array,buffsize,MPI_DOUBLE_PRECISION,
-     &        0,10001005,toissmcomm,mpistatus)
-         _END_MASTER( myThid )
-         
+         print*,'this is local xC',local
+         CALL BAR2( myThid ) 
+         CALL GATHER_2D_R8( xfer_array, local, Nx, Ny,
+     &        .FALSE., .FALSE., myThid )
+         print*,'this is global XC',xfer_array
+         IF( myProcId .EQ. 0 ) THEN
+            _BEGIN_MASTER( myThid )
+            buffsize = Nx*Ny
+            CALL MPI_SEND(xfer_array,buffsize,MPI_DOUBLE_PRECISION,
+     &           0,10001005,toissmcomm,mpistatus)
+            _END_MASTER( myThid )
+         ENDIF
+         CALL BAR2( myThid )
+
 C     Send latitude North of center of cell
+         print*,'this is yC',yC
          DO bj=1,nSy
             DO bi=1,nSx
@@ -99,14 +109,20 @@
             ENDDO
          ENDDO
-CDM         CALL GATHER_2D_R8( xfer_array, local, myThid )
-         _BEGIN_MASTER( myThid )
-         buffsize = Nx*Ny
-         CALL MPI_SEND(xfer_array,buffsize,MPI_DOUBLE_PRECISION,
-     &        0,10001006,toissmcomm,mpistatus)
-         _END_MASTER( myThid )
+         print*,'this is local yC',local
+         CALL BAR2( myThid ) 
+         CALL GATHER_2D_R8( xfer_array, local, Nx, Ny,
+     &                      .FALSE., .FALSE., myThid )
+         print*,'this is global YC',xfer_array
+         IF( myProcId .EQ. 0 ) THEN
+            _BEGIN_MASTER( myThid )
+            buffsize = Nx*Ny
+            CALL MPI_SEND(xfer_array,buffsize,MPI_DOUBLE_PRECISION,
+     &           0,10001006,toissmcomm,mpistatus)
+            _END_MASTER( myThid )
+         ENDIF
+         CALL BAR2( myThid )
+         print*,'Done Sending XC/YC arrays.'
 
       ENDIF
-
-      print*,'Done Sending XC/YC arrays.'
 
 #endif /* ALLOW_CPL_MPMICE */
Index: /issm/trunk-jpl/test/MITgcm/code/eeboot_minimal.F
===================================================================
--- /issm/trunk-jpl/test/MITgcm/code/eeboot_minimal.F	(revision 22635)
+++ /issm/trunk-jpl/test/MITgcm/code/eeboot_minimal.F	(revision 22636)
@@ -66,10 +66,9 @@
 #endif
 #ifdef ALLOW_CPL_ISSM
-      COMMON /CPL_MPI_ID/
-     &     mpiMyWid, toissmcomm
-      INTEGER mpiMyWid, toissmcomm
-      integer my_local_rank,my_local_size, numprocsworld
-      integer dummy1(1),dummy2(1)
-      integer status(MPI_STATUS_SIZE)
+      COMMON /CPL_MPI_ID/ mpiMyWid, toissmcomm
+      INTEGER             mpiMyWid, toissmcomm
+      INTEGER my_local_rank,my_local_size, numprocsworld
+      INTEGER dummy1(1),dummy2(1)
+      INTEGER status(MPI_STATUS_SIZE)
 #endif /* ALLOW_CPL_ISSM */
 #if defined(ALLOW_NEST_PARENT) || defined(ALLOW_NEST_CHILD)
