Copyright (c) 2012       FUJITSU LIMITED.  All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:

* Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.

* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer listed
in this license in the documentation and/or other materials
provided with the distribution.

* Neither the name of the copyright holders nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.

The copyright holders provide no reassurances that the source code
provided does not infringe any patent, copyright, or any other
intellectual property rights of third parties.  The copyright holders
disclaim any liability to any recipient for claims brought against
recipient by any third party for infringement of that parties
intellectual property rights.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Index: ompi/mpi/f90/scripts/mpi-f90-interfaces.h.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi-f90-interfaces.h.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi-f90-interfaces.h.sh	(working copy)
@@ -175,7 +175,7 @@
     cat <<EOF
 
 subroutine ${procedure}(errorclass, ierr)
-  integer, intent(in) :: errorclass
+  integer, intent(out) :: errorclass
   integer, intent(out) :: ierr
 end subroutine ${procedure}
 
@@ -302,7 +302,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: recvcount
   integer, intent(in) :: recvtype
   integer, intent(in) :: comm
@@ -360,7 +360,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, dimension(*), intent(in) :: recvcounts
   integer, dimension(*), intent(in) :: displs
   integer, intent(in) :: recvtype
@@ -442,7 +442,7 @@
 subroutine ${proc}(sendbuf, recvbuf, count, datatype, op, &
         comm, ierr)
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: op
@@ -501,7 +501,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: recvcount
   integer, intent(in) :: recvtype
   integer, intent(in) :: comm
@@ -560,7 +560,7 @@
   integer, dimension(*), intent(in) :: sendcounts
   integer, dimension(*), intent(in) :: sdispls
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, dimension(*), intent(in) :: recvcounts
   integer, dimension(*), intent(in) :: rdispls
   integer, intent(in) :: recvtype
@@ -620,7 +620,7 @@
   integer, dimension(*), intent(in) :: sendcounts
   integer, dimension(*), intent(in) :: sdispls
   integer, dimension(*), intent(in) :: sendtypes
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, dimension(*), intent(in) :: recvcounts
   integer, dimension(*), intent(in) :: rdispls
   integer, dimension(*), intent(in) :: recvtypes
@@ -770,7 +770,7 @@
 
 subroutine ${proc}(buffer, count, datatype, root, comm&
         , ierr)
-  ${type}, intent(in) :: buffer
+  ${type}, intent(inout) :: buffer
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: root
@@ -1147,7 +1147,7 @@
   integer, intent(in) :: comm
   integer, intent(in) :: ndims
   integer, dimension(*), intent(in) :: dims
-  integer, dimension(*), intent(in) :: periods
+  logical, dimension(*), intent(in) :: periods
   integer, intent(out) :: newrank
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -1388,7 +1388,7 @@
     cat <<EOF
 
 subroutine ${procedure}(comm, comm_keyval, ierr)
-  integer, intent(inout) :: comm
+  integer, intent(in) :: comm
   integer, intent(in) :: comm_keyval
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -1691,7 +1691,7 @@
     cat <<EOF
 
 subroutine ${procedure}(comm, comm_name, ierr)
-  integer, intent(inout) :: comm
+  integer, intent(in) :: comm
   character(len=*), intent(in) :: comm_name
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -1762,8 +1762,8 @@
     cat <<EOF
 
 subroutine ${procedure}(comm, flag, ierr)
-  integer, intent(inout) :: comm
-  logical, intent(in) :: flag
+  integer, intent(in) :: comm
+  logical, intent(out) :: flag
   integer, intent(out) :: ierr
 end subroutine ${procedure}
 
@@ -1952,7 +1952,7 @@
 subroutine ${proc}(sendbuf, recvbuf, count, datatype, op, &
         comm, ierr)
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: op
@@ -2364,7 +2364,7 @@
 
 subroutine ${proc}(fh, buf, count, datatype, request&
         , ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -2478,7 +2478,7 @@
 
 subroutine ${proc}(fh, buf, count, datatype, request&
         , ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -2534,7 +2534,7 @@
 
 subroutine ${proc}(fh, buf, count, datatype, request&
         , ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -2591,7 +2591,7 @@
 subroutine ${proc}(fh, offset, buf, count, datatype, &
         request, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
@@ -2648,7 +2648,7 @@
 
 subroutine ${proc}(fh, buf, count, datatype, request&
         , ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -2728,7 +2728,7 @@
 
 subroutine ${procedure}(fh, size, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: size
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -2756,7 +2756,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -2813,7 +2813,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -2868,7 +2868,7 @@
     cat <<EOF
 
 subroutine ${proc}(fh, buf, count, datatype, ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -2923,7 +2923,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
@@ -3205,7 +3205,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -3260,7 +3260,7 @@
     cat <<EOF
 
 subroutine ${proc}(fh, buf, count, datatype, ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -3315,7 +3315,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
@@ -3370,7 +3370,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -3423,7 +3423,7 @@
 
 subroutine ${procedure}(fh, offset, whence, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   integer, intent(in) :: whence
   integer, intent(out) :: ierr
@@ -3448,7 +3448,7 @@
 
 subroutine ${procedure}(fh, offset, whence, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   integer, intent(in) :: whence
   integer, intent(out) :: ierr
@@ -3472,7 +3472,7 @@
     cat <<EOF
 
 subroutine ${procedure}(fh, flag, ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   logical, intent(in) :: flag
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -3518,7 +3518,7 @@
     cat <<EOF
 
 subroutine ${procedure}(fh, info, ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer, intent(in) :: info
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -3542,7 +3542,7 @@
 
 subroutine ${procedure}(fh, size, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: size
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -3594,7 +3594,7 @@
     cat <<EOF
 
 subroutine ${procedure}(fh, ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer, intent(out) :: ierr
 end subroutine ${procedure}
 
@@ -3621,7 +3621,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -3678,7 +3678,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -3733,7 +3733,7 @@
     cat <<EOF
 
 subroutine ${proc}(fh, buf, count, datatype, ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -3788,7 +3788,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
@@ -3843,7 +3843,7 @@
 subroutine ${proc}(fh, offset, buf, count, datatype, &
         status, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
@@ -3901,7 +3901,7 @@
 subroutine ${proc}(fh, offset, buf, count, datatype, &
         status, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
@@ -3959,7 +3959,7 @@
 subroutine ${proc}(fh, offset, buf, count, datatype&
         , ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
@@ -4015,7 +4015,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
@@ -4070,7 +4070,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -4125,7 +4125,7 @@
     cat <<EOF
 
 subroutine ${proc}(fh, buf, count, datatype, ierr)
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -4180,7 +4180,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
@@ -4235,7 +4235,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include 'mpif-config.h'
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
@@ -4388,7 +4388,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: recvcount
   integer, intent(in) :: recvtype
   integer, intent(in) :: root
@@ -4447,7 +4447,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, dimension(*), intent(in) :: recvcounts
   integer, dimension(*), intent(in) :: displs
   integer, intent(in) :: recvtype
@@ -4505,7 +4505,7 @@
 subroutine ${proc}(origin_addr, origin_count, origin_datatype, target_rank, target_disp, &
         target_count, target_datatype, win, ierr)
   include 'mpif-config.h'
-  ${type}, intent(in) :: origin_addr
+  ${type}, intent(out) :: origin_addr
   integer, intent(in) :: origin_count
   integer, intent(in) :: origin_datatype
   integer, intent(in) :: target_rank
@@ -4864,7 +4864,7 @@
     cat <<EOF
 
 subroutine ${procedure}(request, ierr)
-  integer, intent(inout) :: request
+  integer, intent(in) :: request
   integer, intent(out) :: ierr
 end subroutine ${procedure}
 
@@ -5285,7 +5285,7 @@
     cat <<EOF
 
 subroutine ${procedure}(info, key, ierr)
-  integer, intent(out) :: info
+  integer, intent(in) :: info
   character(len=*), intent(in) :: key
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -5452,7 +5452,7 @@
     cat <<EOF
 
 subroutine ${procedure}(info, key, value, ierr)
-  integer, intent(inout) :: info
+  integer, intent(in) :: info
   character(len=*), intent(in) :: key
   character(len=*), intent(in) :: value
   integer, intent(out) :: ierr
@@ -6000,7 +6000,7 @@
   integer, intent(in) :: incount
   integer, intent(in) :: datatype
   ${type}, intent(out) :: outbuf
-  integer, intent(out) :: outsize
+  integer, intent(in) :: outsize
   integer, intent(inout) :: position
   integer, intent(in) :: comm
   integer, intent(out) :: ierr
@@ -6412,7 +6412,7 @@
 subroutine ${proc}(sendbuf, recvbuf, count, datatype, op, &
         root, comm, ierr)
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: op
@@ -6526,8 +6526,8 @@
 subroutine ${proc}(sendbuf, recvbuf, recvcounts, datatype, op, &
         comm, ierr)
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
-  integer, intent(in) :: recvcounts
+  ${type}, intent(inout) :: recvbuf
+  integer, dimension(*), intent(in) :: recvcounts
   integer, intent(in) :: datatype
   integer, intent(in) :: op
   integer, intent(in) :: comm
@@ -6773,7 +6773,7 @@
 subroutine ${proc}(sendbuf, recvbuf, count, datatype, op, &
         comm, ierr)
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: op
@@ -7944,7 +7944,7 @@
     cat <<EOF
 
 subroutine ${procedure}(type, type_keyval, ierr)
-  integer, intent(inout) :: type
+  integer, intent(in) :: type
   integer, intent(in) :: type_keyval
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -8367,7 +8367,7 @@
     cat <<EOF
 
 subroutine ${procedure}(type, type_name, ierr)
-  integer, intent(inout) :: type
+  integer, intent(in) :: type
   character(len=*), intent(in) :: type_name
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -8769,7 +8769,7 @@
   integer, intent(in) :: disp_unit
   integer, intent(in) :: info
   integer, intent(in) :: comm
-  integer, intent(in) :: win
+  integer, intent(out) :: win
   integer, intent(out) :: ierr
 end subroutine ${proc}
 
@@ -8866,7 +8866,7 @@
     cat <<EOF
 
 subroutine ${procedure}(win, win_keyval, ierr)
-  integer, intent(inout) :: win
+  integer, intent(in) :: win
   integer, intent(in) :: win_keyval
   integer, intent(out) :: ierr
 end subroutine ${procedure}
@@ -9149,7 +9149,7 @@
     cat <<EOF
 
 subroutine ${procedure}(win, win_name, ierr)
-  integer, intent(inout) :: win
+  integer, intent(in) :: win
   character(len=*), intent(in) :: win_name
   integer, intent(out) :: ierr
 end subroutine ${procedure}
Index: ompi/mpi/f90/scripts/mpi_allgather_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_allgather_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_allgather_f90.f90.sh	(working copy)
@@ -52,7 +52,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: recvcount
   integer, intent(in) :: recvtype
   integer, intent(in) :: comm
Index: ompi/mpi/f90/scripts/mpi_allgatherv_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_allgatherv_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_allgatherv_f90.f90.sh	(working copy)
@@ -52,7 +52,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, dimension(*), intent(in) :: recvcounts
   integer, dimension(*), intent(in) :: displs
   integer, intent(in) :: recvtype
Index: ompi/mpi/f90/scripts/mpi_allreduce_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_allreduce_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_allreduce_f90.f90.sh	(working copy)
@@ -50,7 +50,7 @@
         comm, ierr)
   include "mpif-config.h"
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: op
Index: ompi/mpi/f90/scripts/mpi_alltoall_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_alltoall_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_alltoall_f90.f90.sh	(working copy)
@@ -52,7 +52,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: recvcount
   integer, intent(in) :: recvtype
   integer, intent(in) :: comm
Index: ompi/mpi/f90/scripts/mpi_alltoallv_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_alltoallv_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_alltoallv_f90.f90.sh	(working copy)
@@ -53,7 +53,7 @@
   integer, dimension(*), intent(in) :: sendcounts
   integer, dimension(*), intent(in) :: sdispls
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, dimension(*), intent(in) :: recvcounts
   integer, dimension(*), intent(in) :: rdispls
   integer, intent(in) :: recvtype
Index: ompi/mpi/f90/scripts/mpi_alltoallw_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_alltoallw_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_alltoallw_f90.f90.sh	(working copy)
@@ -53,7 +53,7 @@
   integer, dimension(*), intent(in) :: sendcounts
   integer, dimension(*), intent(in) :: sdispls
   integer, dimension(*), intent(in) :: sendtypes
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, dimension(*), intent(in) :: recvcounts
   integer, dimension(*), intent(in) :: rdispls
   integer, dimension(*), intent(in) :: recvtypes
Index: ompi/mpi/f90/scripts/mpi_bcast_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_bcast_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_bcast_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(buffer, count, datatype, root, comm&
         , ierr)
   include "mpif-config.h"
-  ${type}, intent(in) :: buffer
+  ${type}, intent(inout) :: buffer
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: root
Index: ompi/mpi/f90/scripts/mpi_exscan_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_exscan_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_exscan_f90.f90.sh	(working copy)
@@ -50,7 +50,7 @@
         comm, ierr)
   include "mpif-config.h"
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: op
Index: ompi/mpi/f90/scripts/mpi_file_iread_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_iread_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_iread_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, request&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_iread_shared_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_iread_shared_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_iread_shared_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, request&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_iwrite_at_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_iwrite_at_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_iwrite_at_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, offset, buf, count, datatype, &
         request, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
Index: ompi/mpi/f90/scripts/mpi_file_iwrite_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_iwrite_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_iwrite_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, request&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_iwrite_shared_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_iwrite_shared_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_iwrite_shared_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, request&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_read_all_begin_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_read_all_begin_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_read_all_begin_f90.f90.sh	(working copy)
@@ -48,7 +48,7 @@
 
 subroutine ${proc}(fh, buf, count, datatype, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_read_all_end_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_read_all_end_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_read_all_end_f90.f90.sh	(working copy)
@@ -48,7 +48,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
Index: ompi/mpi/f90/scripts/mpi_file_read_all_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_read_all_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_read_all_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_read_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_read_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_read_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_read_ordered_begin_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_read_ordered_begin_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_read_ordered_begin_f90.f90.sh	(working copy)
@@ -48,7 +48,7 @@
 
 subroutine ${proc}(fh, buf, count, datatype, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_read_ordered_end_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_read_ordered_end_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_read_ordered_end_f90.f90.sh	(working copy)
@@ -48,7 +48,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
Index: ompi/mpi/f90/scripts/mpi_file_read_ordered_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_read_ordered_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_read_ordered_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_read_shared_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_read_shared_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_read_shared_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(out) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_write_all_begin_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_all_begin_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_all_begin_f90.f90.sh	(working copy)
@@ -48,7 +48,7 @@
 
 subroutine ${proc}(fh, buf, count, datatype, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_write_all_end_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_all_end_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_all_end_f90.f90.sh	(working copy)
@@ -48,7 +48,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
Index: ompi/mpi/f90/scripts/mpi_file_write_all_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_all_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_all_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_write_at_all_begin_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_at_all_begin_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_at_all_begin_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, offset, buf, count, datatype&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
Index: ompi/mpi/f90/scripts/mpi_file_write_at_all_end_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_at_all_end_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_at_all_end_f90.f90.sh	(working copy)
@@ -48,7 +48,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
Index: ompi/mpi/f90/scripts/mpi_file_write_at_all_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_at_all_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_at_all_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, offset, buf, count, datatype, &
         status, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
Index: ompi/mpi/f90/scripts/mpi_file_write_at_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_at_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_at_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, offset, buf, count, datatype, &
         status, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   integer(kind=MPI_OFFSET_KIND), intent(in) :: offset
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
Index: ompi/mpi/f90/scripts/mpi_file_write_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_write_ordered_begin_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_ordered_begin_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_ordered_begin_f90.f90.sh	(working copy)
@@ -48,7 +48,7 @@
 
 subroutine ${proc}(fh, buf, count, datatype, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_write_ordered_end_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_ordered_end_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_ordered_end_f90.f90.sh	(working copy)
@@ -48,7 +48,7 @@
 
 subroutine ${proc}(fh, buf, status, ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
Index: ompi/mpi/f90/scripts/mpi_file_write_ordered_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_ordered_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_ordered_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_file_write_shared_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_file_write_shared_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_file_write_shared_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(fh, buf, count, datatype, status&
         , ierr)
   include "mpif-config.h"
-  integer, intent(inout) :: fh
+  integer, intent(in) :: fh
   ${type}, intent(in) :: buf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
Index: ompi/mpi/f90/scripts/mpi_gather_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_gather_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_gather_f90.f90.sh	(working copy)
@@ -52,7 +52,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: recvcount
   integer, intent(in) :: recvtype
   integer, intent(in) :: root
Index: ompi/mpi/f90/scripts/mpi_gatherv_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_gatherv_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_gatherv_f90.f90.sh	(working copy)
@@ -52,7 +52,7 @@
   ${type}, intent(in) :: sendbuf
   integer, intent(in) :: sendcount
   integer, intent(in) :: sendtype
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, dimension(*), intent(in) :: recvcounts
   integer, dimension(*), intent(in) :: displs
   integer, intent(in) :: recvtype
Index: ompi/mpi/f90/scripts/mpi_get_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_get_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_get_f90.f90.sh	(working copy)
@@ -49,7 +49,7 @@
 subroutine ${proc}(origin_addr, origin_count, origin_datatype, target_rank, target_disp, &
         target_count, target_datatype, win, ierr)
   include "mpif-config.h"
-  ${type}, intent(in) :: origin_addr
+  ${type}, intent(out) :: origin_addr
   integer, intent(in) :: origin_count
   integer, intent(in) :: origin_datatype
   integer, intent(in) :: target_rank
Index: ompi/mpi/f90/scripts/mpi_mrecv_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_mrecv_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_mrecv_f90.f90.sh	(working copy)
@@ -52,7 +52,7 @@
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(inout) :: message
-  integer, dimension(MPI_STATUS_SIZE), intent(inout) :: status
+  integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
   call ${procedure}(buf, count, datatype, message, status, ierr)
 end subroutine ${proc}
Index: ompi/mpi/f90/scripts/mpi_pack_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_pack_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_pack_f90.f90.sh	(working copy)
@@ -53,7 +53,7 @@
   integer, intent(in) :: incount
   integer, intent(in) :: datatype
   ${type}, intent(out) :: outbuf
-  integer, intent(out) :: outsize
+  integer, intent(in) :: outsize
   integer, intent(inout) :: position
   integer, intent(in) :: comm
   integer, intent(out) :: ierr
Index: ompi/mpi/f90/scripts/mpi_recv_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_recv_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_recv_f90.f90.sh	(working copy)
@@ -55,7 +55,7 @@
   integer, intent(in) :: source
   integer, intent(in) :: tag
   integer, intent(in) :: comm
-  integer, dimension(MPI_STATUS_SIZE), intent(inout) :: status
+  integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
   call ${procedure}(buf, count, datatype, source, tag, &
         comm, status, ierr)
Index: ompi/mpi/f90/scripts/mpi_reduce_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_reduce_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_reduce_f90.f90.sh	(working copy)
@@ -50,7 +50,7 @@
         root, comm, ierr)
   include "mpif-config.h"
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: op
Index: ompi/mpi/f90/scripts/mpi_reduce_scatter_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_reduce_scatter_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_reduce_scatter_f90.f90.sh	(working copy)
@@ -50,8 +50,8 @@
         comm, ierr)
   include "mpif-config.h"
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
-  integer, intent(in) :: recvcounts
+  ${type}, intent(inout) :: recvbuf
+  integer, dimension(*), intent(in) :: recvcounts
   integer, intent(in) :: datatype
   integer, intent(in) :: op
   integer, intent(in) :: comm
Index: ompi/mpi/f90/scripts/mpi_scan_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_scan_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_scan_f90.f90.sh	(working copy)
@@ -50,7 +50,7 @@
         comm, ierr)
   include "mpif-config.h"
   ${type}, intent(in) :: sendbuf
-  ${type}, intent(out) :: recvbuf
+  ${type}, intent(inout) :: recvbuf
   integer, intent(in) :: count
   integer, intent(in) :: datatype
   integer, intent(in) :: op
Index: ompi/mpi/f90/scripts/mpi_sendrecv_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_sendrecv_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_sendrecv_f90.f90.sh	(working copy)
@@ -60,7 +60,7 @@
   integer, intent(in) :: source
   integer, intent(in) :: recvtag
   integer, intent(in) :: comm
-  integer, dimension(MPI_STATUS_SIZE), intent(inout) :: status
+  integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
   call ${procedure}(sendbuf, sendcount, sendtype, dest, sendtag, &
         recvbuf, recvcount, recvtype, source, recvtag, comm, status, ierr)
Index: ompi/mpi/f90/scripts/mpi_sendrecv_replace_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_sendrecv_replace_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_sendrecv_replace_f90.f90.sh	(working copy)
@@ -57,7 +57,7 @@
   integer, intent(in) :: source
   integer, intent(in) :: recvtag
   integer, intent(in) :: comm
-  integer, dimension(MPI_STATUS_SIZE), intent(inout) :: status
+  integer, dimension(MPI_STATUS_SIZE), intent(out) :: status
   integer, intent(out) :: ierr
   call ${procedure}(buf, count, datatype, dest, sendtag, &
         source, recvtag, comm, status, ierr)
Index: ompi/mpi/f90/scripts/mpi_win_create_f90.f90.sh
===================================================================
--- ompi/mpi/f90/scripts/mpi_win_create_f90.f90.sh	(revision 25985)
+++ ompi/mpi/f90/scripts/mpi_win_create_f90.f90.sh	(working copy)
@@ -54,7 +54,7 @@
   integer, intent(in) :: disp_unit
   integer, intent(in) :: info
   integer, intent(in) :: comm
-  integer, intent(in) :: win
+  integer, intent(out) :: win
   integer, intent(out) :: ierr
   call ${procedure}(base, size, disp_unit, info, comm, &
         win, ierr)
