New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 11960 for NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE – NEMO

Ignore:
Timestamp:
2019-11-25T18:19:39+01:00 (4 years ago)
Author:
acc
Message:

Branch 2019/dev_r11943_MERGE_2019. Merge in changes from 2019/dev_r11613_ENHANCE-04_namelists_as_internalfiles. (svn merge -r 11614:11954). Resolved tree conflicts and one actual conflict. Sette tested(these changes alter the ext/AGRIF reference; remember to update). See ticket #2341

Location:
NEMO/branches/2019/dev_r11943_MERGE_2019
Files:
65 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r11943_MERGE_2019

    • Property svn:externals
      •  

        old new  
        33^/utils/build/mk@HEAD         mk 
        44^/utils/tools@HEAD            tools 
        5 ^/vendors/AGRIF/dev@HEAD      ext/AGRIF 
         5^/vendors/AGRIF/dev_r11615_ENHANCE-04_namelists_as_internalfiles_agrif@HEAD      ext/AGRIF 
        66^/vendors/FCM@HEAD            ext/FCM 
        77^/vendors/IOIPSL@HEAD         ext/IOIPSL 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/ASM/asminc.F90

    r11949 r11960  
    147147      ln_temnofreeze = .FALSE. 
    148148 
    149       REWIND( numnam_ref )              ! Namelist nam_asminc in reference namelist : Assimilation increment 
    150149      READ  ( numnam_ref, nam_asminc, IOSTAT = ios, ERR = 901) 
    151150901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nam_asminc in reference namelist' ) 
    152       REWIND( numnam_cfg )              ! Namelist nam_asminc in configuration namelist : Assimilation increment 
    153151      READ  ( numnam_cfg, nam_asminc, IOSTAT = ios, ERR = 902 ) 
    154152902   IF( ios >  0 )   CALL ctl_nam ( ios , 'nam_asminc in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/BDY/bdydta.F90

    r11949 r11960  
    373373      INTEGER ::   ierror, ios     !  
    374374      ! 
     375      INTEGER ::   nbdy_rdstart, nbdy_loc 
     376      CHARACTER(LEN=50)                      ::   cerrmsg       ! error string 
    375377      CHARACTER(len=3)                       ::   cl3           !  
    376378      CHARACTER(len=100)                     ::   cn_dir        ! Root directory for location of data files 
     
    415417      ! Read namelists 
    416418      ! -------------- 
    417       REWIND(numnam_cfg) 
     419      nbdy_rdstart = 1 
    418420      DO jbdy = 1, nb_bdy 
    419421 
     
    421423         WRITE(ctmp2, '(a,i2)') 'block nambdy_dta number ', jbdy 
    422424 
    423          ! There is only one nambdy_dta block in namelist_ref -> use it for each bdy so we do a rewind  
    424          REWIND(numnam_ref) 
     425         ! There is only one nambdy_dta block in namelist_ref -> use it for each bdy so we read from the beginning 
    425426         READ  ( numnam_ref, nambdy_dta, IOSTAT = ios, ERR = 901) 
    426427901      IF( ios /= 0 )   CALL ctl_nam ( ios , 'nambdy_dta in reference namelist' ) 
     
    431432            & .OR. ( dta_bdy(jbdy)%lneed_tra   .AND.       nn_tra_dta(jbdy)    == 1 )   & 
    432433            & .OR. ( dta_bdy(jbdy)%lneed_ice   .AND.       nn_ice_dta(jbdy)    == 1 )   )   THEN 
    433             ! WARNING: we don't do a rewind here, each bdy reads its own nambdy_dta block one after another 
    434             READ  ( numnam_cfg, nambdy_dta, IOSTAT = ios, ERR = 902 ) 
     434            ! 
     435            ! Need to support possibility of reading more than one 
     436            ! nambdy_dta from the namelist_cfg internal file. 
     437            ! Do this by finding the jbdy'th occurence of nambdy_dta in the 
     438            ! character buffer as the starting point. 
     439            ! 
     440            nbdy_loc = INDEX( numnam_cfg( nbdy_rdstart: ), 'nambdy_dta' ) 
     441            IF( nbdy_loc .GT. 0 ) THEN 
     442               nbdy_rdstart = nbdy_rdstart + nbdy_loc 
     443            ELSE 
     444               WRITE(cerrmsg,'(A,I4,A)') 'Error: entry number ',jbdy,' of nambdy_dta not found' 
     445               ios = -1 
     446               CALL ctl_nam ( ios , cerrmsg ) 
     447            ENDIF 
     448            READ  ( numnam_cfg( MAX( 1, nbdy_rdstart - 2 ): ), nambdy_dta, IOSTAT = ios, ERR = 902) 
    435449902         IF( ios >  0 )   CALL ctl_nam ( ios , 'nambdy_dta in configuration namelist' ) 
    436450            IF(lwm) WRITE( numond, nambdy_dta )            
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/BDY/bdyini.F90

    r11536 r11960  
    7575      ! Read namelist parameters 
    7676      ! ------------------------ 
    77       REWIND( numnam_ref )              ! Namelist nambdy in reference namelist :Unstructured open boundaries 
    7877      READ  ( numnam_ref, nambdy, IOSTAT = ios, ERR = 901) 
    7978901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nambdy in reference namelist' ) 
     
    9392      cn_ice         (2:jp_bdy) = cn_ice         (1) 
    9493      nn_ice_dta     (2:jp_bdy) = nn_ice_dta     (1) 
    95       REWIND( numnam_cfg )              ! Namelist nambdy in configuration namelist :Unstructured open boundaries 
    9694      READ  ( numnam_cfg, nambdy, IOSTAT = ios, ERR = 902 ) 
    9795902   IF( ios >  0 )   CALL ctl_nam ( ios , 'nambdy in configuration namelist' ) 
     
    364362      ! ------------------------------------------------- 
    365363 
    366       REWIND( numnam_cfg )      
    367364      nblendta(:,:) = 0 
    368365      nbdysege = 0 
     
    10791076      INTEGER          ::   ios                 ! Local integer output status for namelist read 
    10801077      INTEGER          ::   nbdyind, nbdybeg, nbdyend 
     1078      INTEGER          ::   nbdy_count, nbdy_rdstart, nbdy_loc 
    10811079      CHARACTER(LEN=1) ::   ctypebdy   !     -        -  
     1080      CHARACTER(LEN=50)::   cerrmsg    !     -        -  
    10821081      NAMELIST/nambdy_index/ ctypebdy, nbdyind, nbdybeg, nbdyend 
    10831082      !!---------------------------------------------------------------------- 
    1084  
    1085       ! No REWIND here because may need to read more than one nambdy_index namelist. 
    1086       ! Read only namelist_cfg to avoid unseccessfull overwrite  
    1087       ! keep full control of the configuration namelist 
    1088       READ  ( numnam_cfg, nambdy_index, IOSTAT = ios, ERR = 904 ) 
     1083      ! Need to support possibility of reading more than one nambdy_index from 
     1084      ! the namelist_cfg internal file. 
     1085      ! Do this by finding the kb_bdy'th occurence of nambdy_index in the 
     1086      ! character buffer as the starting point. 
     1087      nbdy_rdstart = 1 
     1088      DO nbdy_count = 1, kb_bdy 
     1089       nbdy_loc = INDEX( numnam_cfg( nbdy_rdstart: ), 'nambdy_index' ) 
     1090       IF( nbdy_loc .GT. 0 ) THEN 
     1091          nbdy_rdstart = nbdy_rdstart + nbdy_loc 
     1092       ELSE 
     1093          WRITE(cerrmsg,'(A,I4,A)') 'Error: entry number ',kb_bdy,' of nambdy_index not found' 
     1094          ios = -1 
     1095          CALL ctl_nam ( ios , cerrmsg ) 
     1096       ENDIF 
     1097      END DO 
     1098      nbdy_rdstart = MAX( 1, nbdy_rdstart - 2 ) 
     1099      READ  ( numnam_cfg( nbdy_rdstart: ), nambdy_index, IOSTAT = ios, ERR = 904) 
    10891100904   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nambdy_index in configuration namelist' ) 
    10901101      IF(lwm) WRITE ( numond, nambdy_index ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/BDY/bdytides.F90

    r11536 r11960  
    7171      INTEGER, DIMENSION(3)                     ::   ilen0       !: length of boundary data (from OBC arrays) 
    7272      INTEGER                                   ::   ios                 ! Local integer output status for namelist read 
     73      INTEGER                                   ::   nbdy_rdstart, nbdy_loc 
     74      CHARACTER(LEN=50)                         ::   cerrmsg             !: error string 
    7375      CHARACTER(len=80)                         ::   clfile              !: full file name for tidal input file  
    7476      REAL(wp),ALLOCATABLE, DIMENSION(:,:,:)    ::   dta_read            !: work space to read in tidal harmonics data 
     
    8486      IF(lwp) WRITE(numout,*) '~~~~~~~~~~~~' 
    8587 
    86       REWIND(numnam_cfg) 
    87  
     88 
     89      nbdy_rdstart = 1 
    8890      DO ib_bdy = 1, nb_bdy 
    8991         IF( nn_dyn2d_dta(ib_bdy) >= 2 ) THEN 
     
    9496            filtide(:) = '' 
    9597 
    96             REWIND( numnam_ref ) 
    9798            READ  ( numnam_ref, nambdy_tide, IOSTAT = ios, ERR = 901) 
    9899901         IF( ios /= 0 )   CALL ctl_nam ( ios , 'nambdy_tide in reference namelist' ) 
    99             ! Don't REWIND here - may need to read more than one of these namelists.  
    100             READ  ( numnam_cfg, nambdy_tide, IOSTAT = ios, ERR = 902 ) 
     100            ! 
     101            ! Need to support possibility of reading more than one 
     102            ! nambdy_tide from the namelist_cfg internal file. 
     103            ! Do this by finding the ib_bdy'th occurence of nambdy_tide in the 
     104            ! character buffer as the starting point. 
     105            ! 
     106            nbdy_loc = INDEX( numnam_cfg( nbdy_rdstart: ), 'nambdy_tide' ) 
     107            IF( nbdy_loc .GT. 0 ) THEN 
     108               nbdy_rdstart = nbdy_rdstart + nbdy_loc 
     109            ELSE 
     110               WRITE(cerrmsg,'(A,I4,A)') 'Error: entry number ',ib_bdy,' of nambdy_tide not found' 
     111               ios = -1 
     112               CALL ctl_nam ( ios , cerrmsg ) 
     113            ENDIF 
     114            READ  ( numnam_cfg( MAX( 1, nbdy_rdstart - 2 ): ), nambdy_tide, IOSTAT = ios, ERR = 902) 
    101115902         IF( ios >  0 )   CALL ctl_nam ( ios , 'nambdy_tide in configuration namelist' ) 
    102116            IF(lwm) WRITE ( numond, nambdy_tide ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/C1D/c1d.F90

    r11536 r11960  
    5050      !!---------------------------------------------------------------------- 
    5151      ! 
    52       REWIND( numnam_ref )              ! Namelist namc1d in reference namelist : Tracer advection scheme 
    5352      READ  ( numnam_ref, namc1d, IOSTAT = ios, ERR = 901) 
    5453901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namc1d in reference namelist' ) 
    5554      ! 
    56       REWIND( numnam_cfg )              ! Namelist namtra_adv in configuration namelist : Tracer advection scheme 
    5755      READ  ( numnam_cfg, namc1d, IOSTAT = ios, ERR = 902 ) 
    5856902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namc1d in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/C1D/dtauvd.F90

    r11949 r11960  
    6060      ierr0 = 0   ;   ierr1 = 0   ;   ierr2 = 0  ;   ierr3 = 0 
    6161 
    62       REWIND( numnam_ref )              ! Namelist namc1d_uvd in reference namelist :  
    6362      READ  ( numnam_ref, namc1d_uvd, IOSTAT = ios, ERR = 901) 
    6463901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namc1d_uvd in reference namelist' ) 
    6564      ! 
    66       REWIND( numnam_cfg )              ! Namelist namc1d_uvd in configuration namelist : Parameters of the run 
    6765      READ  ( numnam_cfg, namc1d_uvd, IOSTAT = ios, ERR = 902 ) 
    6866902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namc1d_uvd in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/C1D/dyndmp.F90

    r11949 r11960  
    7979      !!---------------------------------------------------------------------- 
    8080      ! 
    81       REWIND( numnam_ref )              ! Namelist namc1d_dyndmp in reference namelist :  
    8281      READ  ( numnam_ref, namc1d_dyndmp, IOSTAT = ios, ERR = 901) 
    8382901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namc1d_dyndmp in reference namelist' ) 
    84       REWIND( numnam_cfg )              ! Namelist namc1d_dyndmp in configuration namelist : Parameters of the run 
    8583      READ  ( numnam_cfg, namc1d_dyndmp, IOSTAT = ios, ERR = 902 ) 
    8684902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namc1d_dyndmp in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/CRS/crsini.F90

    r11949 r11960  
    8282     !--------------------------------------------------------- 
    8383     ! 
    84       REWIND( numnam_ref )              ! Namelist namrun in reference namelist : Parameters of the run 
    8584      READ  ( numnam_ref, namcrs, IOSTAT = ios, ERR = 901) 
    8685901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namcrs in reference namelist' ) 
    87       REWIND( numnam_cfg )              ! Namelist namrun in configuration namelist : Parameters of the run 
    8886      READ  ( numnam_cfg, namcrs, IOSTAT = ios, ERR = 902 ) 
    8987902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namcrs in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DIA/dia25h.F90

    r11949 r11960  
    5555      !!---------------------------------------------------------------------- 
    5656      ! 
    57       REWIND ( numnam_ref )              ! Read Namelist nam_dia25h in reference namelist : 25hour mean diagnostics 
    5857      READ   ( numnam_ref, nam_dia25h, IOSTAT=ios, ERR= 901 ) 
    5958901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nam_dia25h in reference namelist' ) 
    60       REWIND( numnam_cfg )              ! Namelist nam_dia25h in configuration namelist  25hour diagnostics 
    6159      READ  ( numnam_cfg, nam_dia25h, IOSTAT = ios, ERR = 902 ) 
    6260902   IF( ios >  0 )   CALL ctl_nam ( ios , 'nam_dia25h in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DIA/diadct.F90

    r11949 r11960  
    123123      !!--------------------------------------------------------------------- 
    124124 
    125      REWIND( numnam_ref )              ! Namelist nam_diadct in reference namelist : Diagnostic: transport through sections 
    126125     READ  ( numnam_ref, nam_diadct, IOSTAT = ios, ERR = 901) 
    127126901  IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_diadct in reference namelist' ) 
    128127 
    129      REWIND( numnam_cfg )              ! Namelist nam_diadct in configuration namelist : Diagnostic: transport through sections 
    130128     READ  ( numnam_cfg, nam_diadct, IOSTAT = ios, ERR = 902 ) 
    131129902  IF( ios >  0 ) CALL ctl_nam ( ios , 'nam_diadct in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DIA/diaharm.F90

    r11949 r11960  
    7979      ENDIF 
    8080      ! 
    81       REWIND( numnam_ref )              ! Namelist nam_diaharm in reference namelist : Tidal harmonic analysis 
    8281      READ  ( numnam_ref, nam_diaharm, IOSTAT = ios, ERR = 901) 
    8382901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nam_diaharm in reference namelist' ) 
    84       REWIND( numnam_cfg )              ! Namelist nam_diaharm in configuration namelist : Tidal harmonic analysis 
    8583      READ  ( numnam_cfg, nam_diaharm, IOSTAT = ios, ERR = 902 ) 
    8684902   IF( ios >  0 )   CALL ctl_nam ( ios , 'nam_diaharm in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DIA/diahsb.F90

    r11949 r11960  
    364364         WRITE(numout,*) '~~~~~~~~~~~~ ' 
    365365      ENDIF 
    366       REWIND( numnam_ref )              ! Namelist namhsb in reference namelist 
    367366      READ  ( numnam_ref, namhsb, IOSTAT = ios, ERR = 901) 
    368367901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namhsb in reference namelist' ) 
    369       REWIND( numnam_cfg )              ! Namelist namhsb in configuration namelist 
    370368      READ  ( numnam_cfg, namhsb, IOSTAT = ios, ERR = 902 ) 
    371369902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namhsb in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DIA/diaptr.F90

    r11949 r11960  
    392392      !!---------------------------------------------------------------------- 
    393393 
    394       REWIND( numnam_ref )              ! Namelist namptr in reference namelist : Poleward transport 
    395394      READ  ( numnam_ref, namptr, IOSTAT = ios, ERR = 901) 
    396395901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namptr in reference namelist' ) 
    397396 
    398       REWIND( numnam_cfg )              ! Namelist namptr in configuration namelist : Poleward transport 
    399397      READ  ( numnam_cfg, namptr, IOSTAT = ios, ERR = 902 ) 
    400398902   IF( ios >  0 ) CALL ctl_nam ( ios , 'namptr in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DIA/diatmb.F90

    r11949 r11960  
    4141      !!---------------------------------------------------------------------- 
    4242      ! 
    43       REWIND( numnam_ref )              ! Read Namelist nam_diatmb in reference namelist : TMB diagnostics 
    4443      READ  ( numnam_ref, nam_diatmb, IOSTAT=ios, ERR= 901 ) 
    4544901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nam_diatmb in reference namelist' ) 
    4645  
    47       REWIND( numnam_cfg )              ! Namelist nam_diatmb in configuration namelist  TMB diagnostics 
    4846      READ  ( numnam_cfg, nam_diatmb, IOSTAT = ios, ERR = 902 ) 
    4947902   IF( ios >  0 ) CALL ctl_nam ( ios , 'nam_diatmb in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DIU/diu_bulk.F90

    r11949 r11960  
    5252 
    5353      ! Read the namelist 
    54       REWIND( numnam_ref ) 
    5554      READ  ( numnam_ref, namdiu, IOSTAT = ios, ERR = 901 ) 
    5655901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namdiu in reference namelist' ) 
    57       REWIND( numnam_cfg ) 
    5856      READ  ( numnam_cfg, namdiu, IOSTAT = ios, ERR = 902 ) 
    5957902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namdiu in configuration namelist' )       
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DOM/domain.F90

    r11949 r11960  
    308308      ! 
    309309      ! 
    310       REWIND( numnam_ref )              ! Namelist namrun in reference namelist : Parameters of the run 
    311310      READ  ( numnam_ref, namrun, IOSTAT = ios, ERR = 901) 
    312311901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namrun in reference namelist' ) 
    313       REWIND( numnam_cfg )              ! Namelist namrun in configuration namelist : Parameters of the run 
    314312      READ  ( numnam_cfg, namrun, IOSTAT = ios, ERR = 902 ) 
    315313902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namrun in configuration namelist' ) 
     
    406404#endif 
    407405 
    408       REWIND( numnam_ref )              ! Namelist namdom in reference namelist : space & time domain (bathymetry, mesh, timestep) 
    409406      READ  ( numnam_ref, namdom, IOSTAT = ios, ERR = 903) 
    410407903   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namdom in reference namelist' ) 
    411       REWIND( numnam_cfg )              ! Namelist namdom in configuration namelist : space & time domain (bathymetry, mesh, timestep) 
    412408      READ  ( numnam_cfg, namdom, IOSTAT = ios, ERR = 904 ) 
    413409904   IF( ios >  0 )   CALL ctl_nam ( ios , 'namdom in configuration namelist' ) 
     
    438434#if defined key_netcdf4 
    439435      !                             ! NetCDF 4 case   ("key_netcdf4" defined) 
    440       REWIND( numnam_ref )              ! Namelist namnc4 in reference namelist : NETCDF 
    441436      READ  ( numnam_ref, namnc4, IOSTAT = ios, ERR = 907) 
    442437907   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namnc4 in reference namelist' ) 
    443       REWIND( numnam_cfg )              ! Namelist namnc4 in configuration namelist : NETCDF 
    444438      READ  ( numnam_cfg, namnc4, IOSTAT = ios, ERR = 908 ) 
    445439908   IF( ios >  0 )   CALL ctl_nam ( ios , 'namnc4 in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DOM/dommsk.F90

    r11536 r11960  
    103103      !!--------------------------------------------------------------------- 
    104104      ! 
    105       REWIND( numnam_ref )              ! Namelist namlbc in reference namelist : Lateral momentum boundary condition 
    106105      READ  ( numnam_ref, namlbc, IOSTAT = ios, ERR = 901 ) 
    107106901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namlbc in reference namelist' ) 
    108       REWIND( numnam_cfg )              ! Namelist namlbc in configuration namelist : Lateral momentum boundary condition 
    109107      READ  ( numnam_cfg, namlbc, IOSTAT = ios, ERR = 902 ) 
    110108902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namlbc in configuration namelist' ) 
     
    148146 
    149147     ! Mask corrections for bdy (read in mppini2) 
    150       REWIND( numnam_ref )              ! Namelist nambdy in reference namelist :Unstructured open boundaries 
    151148      READ  ( numnam_ref, nambdy, IOSTAT = ios, ERR = 903) 
    152149903   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nambdy in reference namelist' ) 
    153       REWIND( numnam_cfg )              ! Namelist nambdy in configuration namelist :Unstructured open boundaries 
    154150      READ  ( numnam_cfg, nambdy, IOSTAT = ios, ERR = 904 ) 
    155151904   IF( ios >  0 )   CALL ctl_nam ( ios , 'nambdy in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DOM/domvvl.F90

    r11949 r11960  
    987987      !!----------------------------------------------------------------------  
    988988      ! 
    989       REWIND( numnam_ref )              ! Namelist nam_vvl in reference namelist :  
    990989      READ  ( numnam_ref, nam_vvl, IOSTAT = ios, ERR = 901) 
    991990901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nam_vvl in reference namelist' ) 
    992       REWIND( numnam_cfg )              ! Namelist nam_vvl in configuration namelist : Parameters of the run 
    993991      READ  ( numnam_cfg, nam_vvl, IOSTAT = ios, ERR = 902 ) 
    994992902   IF( ios >  0 ) CALL ctl_nam ( ios , 'nam_vvl in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DOM/dtatsd.F90

    r11536 r11960  
    6565      ierr0 = 0  ;  ierr1 = 0  ;  ierr2 = 0  ;  ierr3 = 0 
    6666      ! 
    67       REWIND( numnam_ref )              ! Namelist namtsd in reference namelist :  
    6867      READ  ( numnam_ref, namtsd, IOSTAT = ios, ERR = 901) 
    6968901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtsd in reference namelist' ) 
    70       REWIND( numnam_cfg )              ! Namelist namtsd in configuration namelist : Parameters of the run 
    7169      READ  ( numnam_cfg, namtsd, IOSTAT = ios, ERR = 902 ) 
    7270902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtsd in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DOM/iscplini.F90

    r11536 r11960  
    6262      nn_fiscpl = 0 
    6363      ln_hsb    = .FALSE. 
    64       REWIND( numnam_ref )              ! Namelist namsbc_iscpl in reference namelist : Ice sheet coupling 
    6564      READ  ( numnam_ref, namsbc_iscpl, IOSTAT = ios, ERR = 901) 
    6665901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_iscpl in reference namelist' ) 
    67       REWIND( numnam_cfg )              ! Namelist namsbc_iscpl in configuration namelist : Ice Sheet coupling 
    6866      READ  ( numnam_cfg, namsbc_iscpl, IOSTAT = ios, ERR = 902 ) 
    6967902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_iscpl in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DYN/dynadv.F90

    r11949 r11960  
    106106      ENDIF 
    107107      ! 
    108       REWIND( numnam_ref )              ! Namelist namdyn_adv in reference namelist : Momentum advection scheme 
    109108      READ  ( numnam_ref, namdyn_adv, IOSTAT = ios, ERR = 901) 
    110109901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namdyn_adv in reference namelist' ) 
    111       REWIND( numnam_cfg )              ! Namelist namdyn_adv in configuration namelist : Momentum advection scheme 
    112110      READ  ( numnam_cfg, namdyn_adv, IOSTAT = ios, ERR = 902 ) 
    113111902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namdyn_adv in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DYN/dynhpg.F90

    r11949 r11960  
    155155      !!---------------------------------------------------------------------- 
    156156      ! 
    157       REWIND( numnam_ref )              ! Namelist namdyn_hpg in reference namelist : Hydrostatic pressure gradient 
    158157      READ  ( numnam_ref, namdyn_hpg, IOSTAT = ios, ERR = 901) 
    159158901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namdyn_hpg in reference namelist' ) 
    160159      ! 
    161       REWIND( numnam_cfg )              ! Namelist namdyn_hpg in configuration namelist : Hydrostatic pressure gradient 
    162160      READ  ( numnam_cfg, namdyn_hpg, IOSTAT = ios, ERR = 902 ) 
    163161902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namdyn_hpg in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DYN/dynspg.F90

    r11949 r11960  
    203203      ENDIF 
    204204      ! 
    205       REWIND( numnam_ref )              ! Namelist namdyn_spg in reference namelist : Free surface 
    206205      READ  ( numnam_ref, namdyn_spg, IOSTAT = ios, ERR = 901) 
    207206901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namdyn_spg in reference namelist' ) 
    208207      ! 
    209       REWIND( numnam_cfg )              ! Namelist namdyn_spg in configuration namelist : Free surface 
    210208      READ  ( numnam_cfg, namdyn_spg, IOSTAT = ios, ERR = 902 ) 
    211209902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namdyn_spg in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DYN/dynvor.F90

    r11949 r11960  
    856856      ENDIF 
    857857      ! 
    858       REWIND( numnam_ref )              ! Namelist namdyn_vor in reference namelist : Vorticity scheme options 
    859858      READ  ( numnam_ref, namdyn_vor, IOSTAT = ios, ERR = 901) 
    860859901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namdyn_vor in reference namelist' ) 
    861       REWIND( numnam_cfg )              ! Namelist namdyn_vor in configuration namelist : Vorticity scheme options 
    862860      READ  ( numnam_cfg, namdyn_vor, IOSTAT = ios, ERR = 902 ) 
    863861902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namdyn_vor in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/DYN/wet_dry.F90

    r11949 r11960  
    7979      !!---------------------------------------------------------------------- 
    8080      ! 
    81       REWIND( numnam_ref )              ! Namelist namwad in reference namelist : Parameters for Wetting/Drying 
    8281      READ  ( numnam_ref, namwad, IOSTAT = ios, ERR = 905) 
    8382905   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namwad in reference namelist' )  
    84       REWIND( numnam_cfg )              ! Namelist namwad in configuration namelist : Parameters for Wetting/Drying 
    8583      READ  ( numnam_cfg, namwad, IOSTAT = ios, ERR = 906) 
    8684906   IF( ios >  0 )   CALL ctl_nam ( ios , 'namwad in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/FLO/floats.F90

    r11949 r11960  
    8989      IF(lwp) WRITE(numout,*) '~~~~~~~' 
    9090 
    91       REWIND( numnam_ref )              ! Namelist namflo in reference namelist : Floats 
    9291      READ  ( numnam_ref, namflo, IOSTAT = ios, ERR = 901) 
    9392901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namflo in reference namelist' ) 
    9493 
    95       REWIND( numnam_cfg )              ! Namelist namflo in configuration namelist : Floats 
    9694      READ  ( numnam_cfg, namflo, IOSTAT = ios, ERR = 902 ) 
    9795902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namflo in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/ICB/icbini.F90

    r11536 r11960  
    404404#endif    
    405405      !                             !==  read namelist  ==! 
    406       REWIND( numnam_ref )              ! Namelist namberg in reference namelist : Iceberg parameters 
    407406      READ  ( numnam_ref, namberg, IOSTAT = ios, ERR = 901) 
    408407901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namberg in reference namelist' ) 
    409       REWIND( numnam_cfg )              ! Namelist namberg in configuration namelist : Iceberg parameters 
    410408      READ  ( numnam_cfg, namberg, IOSTAT = ios, ERR = 902 ) 
    411409902   IF( ios >  0 ) CALL ctl_nam ( ios , 'namberg in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/IOM/in_out_manager.F90

    r11536 r11960  
    139139   INTEGER ::   numnul          =   -1      !: logical unit for /dev/null 
    140140      !                                     !  early output can be collected; do not change 
    141    INTEGER ::   numnam_ref      =   -1      !: logical unit for reference namelist 
    142    INTEGER ::   numnam_cfg      =   -1      !: logical unit for configuration specific namelist 
    143141   INTEGER ::   numond          =   -1      !: logical unit for Output Namelist Dynamics 
    144    INTEGER ::   numnam_ice_ref  =   -1      !: logical unit for ice reference namelist 
    145    INTEGER ::   numnam_ice_cfg  =   -1      !: logical unit for ice reference namelist 
    146142   INTEGER ::   numoni          =   -1      !: logical unit for Output Namelist Ice 
    147143   INTEGER ::   numevo_ice      =   -1      !: logical unit for ice variables (temp. evolution) 
    148144   INTEGER ::   numrun          =   -1      !: logical unit for run statistics 
    149145   INTEGER ::   numdct_in       =   -1      !: logical unit for transports computing 
    150    INTEGER ::   numdct_vol      =   -1      !: logical unit for voulume transports output 
    151    INTEGER ::   numdct_heat     =   -1      !: logical unit for heat    transports output 
    152    INTEGER ::   numdct_salt     =   -1      !: logical unit for salt    transports output 
     146   INTEGER ::   numdct_vol      =   -1      !: logical unit for volume transports output 
     147   INTEGER ::   numdct_heat     =   -1      !: logical unit for heat   transports output 
     148   INTEGER ::   numdct_salt     =   -1      !: logical unit for salt   transports output 
    153149   INTEGER ::   numfl           =   -1      !: logical unit for floats ascii output 
    154150   INTEGER ::   numflo          =   -1      !: logical unit for floats ascii output 
     151      ! 
     152   CHARACTER(LEN=:), ALLOCATABLE :: numnam_ref      !: character buffer for reference namelist 
     153   CHARACTER(LEN=:), ALLOCATABLE :: numnam_cfg      !: character buffer for configuration specific namelist 
     154   CHARACTER(LEN=:), ALLOCATABLE :: numnam_ice_ref  !: character buffer for ice reference namelist 
     155   CHARACTER(LEN=:), ALLOCATABLE :: numnam_ice_cfg  !: character buffer for ice configuration specific namelist 
    155156 
    156157   !!---------------------------------------------------------------------- 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/LBC/lib_mpp.F90

    r11949 r11960  
    3232   !!   ctl_opn       : Open file and check if required file is available. 
    3333   !!   ctl_nam       : Prints informations when an error occurs while reading a namelist 
     34   !!   load_nml      : Read, condense and buffer namelist file into character array for use as an internal file 
    3435   !!---------------------------------------------------------------------- 
    3536   !!---------------------------------------------------------------------- 
     
    5051   !!   mpp_ini_north : initialisation of north fold 
    5152   !!   mpp_lbc_north_icb : alternative to mpp_nfd for extra outer halo with icebergs 
     53   !!   mpp_bcast_nml : broadcast/receive namelist character buffer from reading process to all others 
    5254   !!---------------------------------------------------------------------- 
    5355   USE dom_oce        ! ocean space and time domain 
     
    5759   PRIVATE 
    5860   ! 
    59    PUBLIC   ctl_stop, ctl_warn, ctl_opn, ctl_nam 
     61   PUBLIC   ctl_stop, ctl_warn, ctl_opn, ctl_nam, load_nml 
    6062   PUBLIC   mpp_start, mppstop, mppsync, mpp_comm_free 
    6163   PUBLIC   mpp_ini_north 
     
    6668   PUBLIC   mppsend, mpprecv                          ! needed by TAM and ICB routines 
    6769   PUBLIC   mpp_report 
     70   PUBLIC   mpp_bcast_nml 
    6871   PUBLIC   tic_tac 
    6972#if ! defined key_mpp_mpi 
     
    498501#endif 
    499502   END SUBROUTINE mpp_delay_rcv 
     503 
     504   SUBROUTINE mpp_bcast_nml( cdnambuff , kleng ) 
     505      CHARACTER(LEN=:)    , ALLOCATABLE, INTENT(INOUT) :: cdnambuff 
     506      INTEGER                          , INTENT(INOUT) :: kleng 
     507      !!---------------------------------------------------------------------- 
     508      !!                  ***  routine mpp_bcast_nml  *** 
     509      !! 
     510      !! ** Purpose :   broadcast namelist character buffer 
     511      !! 
     512      !!---------------------------------------------------------------------- 
     513      !! 
     514      INTEGER ::   iflag 
     515      !!---------------------------------------------------------------------- 
     516      ! 
     517#if defined key_mpp_mpi 
     518      call MPI_BCAST(kleng, 1, MPI_INT, 0, mpi_comm_oce, iflag) 
     519      call MPI_BARRIER(mpi_comm_oce, iflag) 
     520!$AGRIF_DO_NOT_TREAT 
     521      IF ( .NOT. ALLOCATED(cdnambuff) ) ALLOCATE( CHARACTER(LEN=kleng) :: cdnambuff ) 
     522!$AGRIF_END_DO_NOT_TREAT 
     523      call MPI_BCAST(cdnambuff, kleng, MPI_CHARACTER, 0, mpi_comm_oce, iflag) 
     524      call MPI_BARRIER(mpi_comm_oce, iflag) 
     525#endif 
     526      ! 
     527   END SUBROUTINE mpp_bcast_nml 
    500528 
    501529    
     
    10661094 
    10671095   !!---------------------------------------------------------------------- 
    1068    !!   ctl_stop, ctl_warn, get_unit, ctl_opn, ctl_nam   routines 
     1096   !!   ctl_stop, ctl_warn, get_unit, ctl_opn, ctl_nam, load_nml   routines 
    10691097   !!---------------------------------------------------------------------- 
    10701098 
     
    12771305   END FUNCTION get_unit 
    12781306 
     1307   SUBROUTINE load_nml( cdnambuff , cdnamfile, kout, ldwp) 
     1308      CHARACTER(LEN=:)    , ALLOCATABLE, INTENT(INOUT) :: cdnambuff 
     1309      CHARACTER(LEN=*), INTENT(IN )                :: cdnamfile 
     1310      CHARACTER(LEN=256)                           :: chline 
     1311      INTEGER, INTENT(IN)                          :: kout 
     1312      LOGICAL, INTENT(IN)                          :: ldwp  !: .true. only for the root broadcaster 
     1313      INTEGER                                      :: itot, iun, iltc, inl, ios, itotsav 
     1314      ! 
     1315      ! Check if the namelist buffer has already been allocated. Return if it has. 
     1316      ! 
     1317      IF ( ALLOCATED( cdnambuff ) ) RETURN 
     1318      IF( ldwp ) THEN 
     1319         ! 
     1320         ! Open namelist file 
     1321         ! 
     1322         CALL ctl_opn( iun, cdnamfile, 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, kout, ldwp ) 
     1323         ! 
     1324         ! First pass: count characters excluding comments and trimable white space 
     1325         ! 
     1326         itot=0 
     1327     10  READ(iun,'(A256)',END=20,ERR=20) chline 
     1328         iltc = LEN_TRIM(chline) 
     1329         IF ( iltc.GT.0 ) THEN 
     1330          inl = INDEX(chline, '!')  
     1331          IF( inl.eq.0 ) THEN 
     1332           itot = itot + iltc + 1                                ! +1 for the newline character 
     1333          ELSEIF( inl.GT.0 .AND. LEN_TRIM( chline(1:inl-1) ).GT.0 ) THEN 
     1334           itot = itot + inl                                  !  includes +1 for the newline character 
     1335          ENDIF 
     1336         ENDIF 
     1337         GOTO 10 
     1338     20  CONTINUE 
     1339         ! 
     1340         ! Allocate text cdnambuff for condensed namelist 
     1341         ! 
     1342!$AGRIF_DO_NOT_TREAT 
     1343         ALLOCATE( CHARACTER(LEN=itot) :: cdnambuff ) 
     1344!$AGRIF_END_DO_NOT_TREAT 
     1345         itotsav = itot 
     1346         ! 
     1347         ! Second pass: read and transfer pruned characters into cdnambuff 
     1348         ! 
     1349         REWIND(iun) 
     1350         itot=1 
     1351     30  READ(iun,'(A256)',END=40,ERR=40) chline 
     1352         iltc = LEN_TRIM(chline) 
     1353         IF ( iltc.GT.0 ) THEN 
     1354          inl = INDEX(chline, '!') 
     1355          IF( inl.eq.0 ) THEN 
     1356           inl = iltc 
     1357          ELSE 
     1358           inl = inl - 1 
     1359          ENDIF 
     1360          IF( inl.GT.0 .AND. LEN_TRIM( chline(1:inl) ).GT.0 ) THEN 
     1361             cdnambuff(itot:itot+inl-1) = chline(1:inl) 
     1362             WRITE( cdnambuff(itot+inl:itot+inl), '(a)' ) NEW_LINE('A') 
     1363             itot = itot + inl + 1 
     1364          ENDIF 
     1365         ENDIF 
     1366         GOTO 30 
     1367     40  CONTINUE 
     1368         itot = itot - 1 
     1369         IF( itotsav .NE. itot ) WRITE(*,*) 'WARNING in load_nml. Allocated ',itotsav,' for read buffer; but used ',itot 
     1370         ! 
     1371         ! Close namelist file 
     1372         ! 
     1373         CLOSE(iun) 
     1374         !write(*,'(32A)') cdnambuff 
     1375      ENDIF 
     1376#if defined key_mpp_mpi 
     1377      CALL mpp_bcast_nml( cdnambuff, itot ) 
     1378#endif 
     1379  END SUBROUTINE load_nml 
     1380 
     1381 
    12791382   !!---------------------------------------------------------------------- 
    12801383END MODULE lib_mpp 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/LBC/mppini.F90

    r11640 r11960  
    176176      ! ----------------------------------- 
    177177      ! 
    178       REWIND( numnam_ref )              ! Namelist nammpp in reference namelist 
    179178      READ  ( numnam_ref, nammpp, IOSTAT = ios, ERR = 901 ) 
    180179901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nammpp in reference namelist' ) 
    181       REWIND( numnam_cfg )              ! Namelist nammpp in confguration namelist 
    182180      READ  ( numnam_cfg, nammpp, IOSTAT = ios, ERR = 902 ) 
    183181902   IF( ios >  0 )   CALL ctl_nam ( ios , 'nammpp in configuration namelist' )    
     
    197195 
    198196      ! do we need to take into account bdy_msk? 
    199       REWIND( numnam_ref )              ! Namelist nambdy in reference namelist : BDY 
    200197      READ  ( numnam_ref, nambdy, IOSTAT = ios, ERR = 903) 
    201198903   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nambdy in reference namelist (mppini)' ) 
    202       REWIND( numnam_cfg )              ! Namelist nambdy in configuration namelist : BDY 
    203199      READ  ( numnam_cfg, nambdy, IOSTAT = ios, ERR = 904 ) 
    204200904   IF( ios >  0 )   CALL ctl_nam ( ios , 'nambdy in configuration namelist (mppini)' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/LDF/ldfdyn.F90

    r11949 r11960  
    115115      !!---------------------------------------------------------------------- 
    116116      ! 
    117       REWIND( numnam_ref )              ! Namelist namdyn_ldf in reference namelist : Lateral physics 
    118117      READ  ( numnam_ref, namdyn_ldf, IOSTAT = ios, ERR = 901) 
    119118901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namdyn_ldf in reference namelist' ) 
    120119 
    121       REWIND( numnam_cfg )              ! Namelist namdyn_ldf in configuration namelist : Lateral physics 
    122120      READ  ( numnam_cfg, namdyn_ldf, IOSTAT = ios, ERR = 902 ) 
    123121902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namdyn_ldf in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/LDF/ldftra.F90

    r11949 r11960  
    152152      ! ================================= 
    153153      ! 
    154       REWIND( numnam_ref )              ! Namelist namtra_ldf in reference namelist : Lateral physics on tracers 
    155154      READ  ( numnam_ref, namtra_ldf, IOSTAT = ios, ERR = 901) 
    156155901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtra_ldf in reference namelist' ) 
    157       REWIND( numnam_cfg )              ! Namelist namtra_ldf in configuration namelist : Lateral physics on tracers 
    158156      READ  ( numnam_cfg, namtra_ldf, IOSTAT = ios, ERR = 902 ) 
    159157902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtra_ldf in configuration namelist' ) 
     
    511509      ENDIF 
    512510      ! 
    513       REWIND( numnam_ref )              ! Namelist namtra_eiv in reference namelist : eddy induced velocity param. 
    514511      READ  ( numnam_ref, namtra_eiv, IOSTAT = ios, ERR = 901) 
    515512901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtra_eiv in reference namelist' ) 
    516513      ! 
    517       REWIND( numnam_cfg )              ! Namelist namtra_eiv in configuration namelist : eddy induced velocity param. 
    518514      READ  ( numnam_cfg, namtra_eiv, IOSTAT = ios, ERR = 902 ) 
    519515902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtra_eiv in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/OBS/diaobs.F90

    r11949 r11960  
    202202 
    203203      ! Read namelist namobs : control observation diagnostics 
    204       REWIND( numnam_ref )   ! Namelist namobs in reference namelist 
    205204      READ  ( numnam_ref, namobs, IOSTAT = ios, ERR = 901) 
    206205901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namobs in reference namelist' ) 
    207       REWIND( numnam_cfg )   ! Namelist namobs in configuration namelist 
    208206      READ  ( numnam_cfg, namobs, IOSTAT = ios, ERR = 902 ) 
    209207902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namobs in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcapr.F90

    r11536 r11960  
    6969      NAMELIST/namsbc_apr/ cn_dir, sn_apr, ln_ref_apr, rn_pref, ln_apr_obc 
    7070      !!---------------------------------------------------------------------- 
    71       REWIND( numnam_ref )              ! Namelist namsbc_apr in reference namelist : File for atmospheric pressure forcing 
    7271      READ  ( numnam_ref, namsbc_apr, IOSTAT = ios, ERR = 901) 
    7372901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_apr in reference namelist' ) 
    7473 
    75       REWIND( numnam_cfg )              ! Namelist namsbc_apr in configuration namelist : File for atmospheric pressure forcing 
    7674      READ  ( numnam_cfg, namsbc_apr, IOSTAT = ios, ERR = 902 ) 
    7775902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_apr in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcblk.F90

    r11536 r11960  
    180180      ! 
    181181      !                             !** read bulk namelist   
    182       REWIND( numnam_ref )                !* Namelist namsbc_blk in reference namelist : bulk parameters 
    183182      READ  ( numnam_ref, namsbc_blk, IOSTAT = ios, ERR = 901) 
    184183901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_blk in reference namelist' ) 
    185184      ! 
    186       REWIND( numnam_cfg )                !* Namelist namsbc_blk in configuration namelist : bulk parameters 
    187185      READ  ( numnam_cfg, namsbc_blk, IOSTAT = ios, ERR = 902 ) 
    188186902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_blk in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbccpl.F90

    r11949 r11960  
    264264      ! ================================ ! 
    265265      ! 
    266       REWIND( numnam_ref )              ! Namelist namsbc_cpl in reference namelist : Variables for OASIS coupling 
    267266      READ  ( numnam_ref, namsbc_cpl, IOSTAT = ios, ERR = 901) 
    268267901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_cpl in reference namelist' ) 
    269268      ! 
    270       REWIND( numnam_cfg )              ! Namelist namsbc_cpl in configuration namelist : Variables for OASIS coupling 
    271269      READ  ( numnam_cfg, namsbc_cpl, IOSTAT = ios, ERR = 902 ) 
    272270902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_cpl in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcflx.F90

    r11536 r11960  
    9191      IF( kt == nit000 ) THEN                ! First call kt=nit000   
    9292         ! set file information 
    93          REWIND( numnam_ref )              ! Namelist namsbc_flx in reference namelist : Files for fluxes 
    9493         READ  ( numnam_ref, namsbc_flx, IOSTAT = ios, ERR = 901) 
    9594901      IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_flx in reference namelist' ) 
    9695 
    97          REWIND( numnam_cfg )              ! Namelist namsbc_flx in configuration namelist : Files for fluxes 
    9896         READ  ( numnam_cfg, namsbc_flx, IOSTAT = ios, ERR = 902 ) 
    9997902      IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_flx in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcice_cice.F90

    r11949 r11960  
    763763         sn_bot5 = FLD_N( 'botmeltn5_1m' ,    -1.    ,  'botmeltn5' ,  .true.    , .true.  ,  ' yearly'  , ''       , ''         ,  ''    ) 
    764764 
    765          REWIND( numnam_ref )              ! Namelist namsbc_cice in reference namelist :  
    766765         READ  ( numnam_ref, namsbc_cice, IOSTAT = ios, ERR = 901) 
    767766901      IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_cice in reference namelist' ) 
    768767 
    769          REWIND( numnam_cfg )              ! Namelist namsbc_cice in configuration namelist : Parameters of the run 
    770768         READ  ( numnam_cfg, namsbc_cice, IOSTAT = ios, ERR = 902 ) 
    771769902      IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_cice in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcice_if.F90

    r11949 r11960  
    7575         !                                      ! ====================== ! 
    7676         ! set file information 
    77          REWIND( numnam_ref )              ! Namelist namsbc_iif in reference namelist : Ice if file 
    7877         READ  ( numnam_ref, namsbc_iif, IOSTAT = ios, ERR = 901) 
    7978901      IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_iif in reference namelist' ) 
    8079 
    81          REWIND( numnam_cfg )              ! Namelist Namelist namsbc_iif in configuration namelist : Ice if file 
    8280         READ  ( numnam_cfg, namsbc_iif, IOSTAT = ios, ERR = 902 ) 
    8381902      IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_iif in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcisf.F90

    r11949 r11960  
    278278      !!---------------------------------------------------------------------- 
    279279 
    280       REWIND( numnam_ref )              ! Namelist namsbc_rnf in reference namelist : Runoffs  
    281280      READ  ( numnam_ref, namsbc_isf, IOSTAT = ios, ERR = 901) 
    282281901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_isf in reference namelist' ) 
    283282 
    284       REWIND( numnam_cfg )              ! Namelist namsbc_rnf in configuration namelist : Runoffs 
    285283      READ  ( numnam_cfg, namsbc_isf, IOSTAT = ios, ERR = 902 ) 
    286284902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_isf in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcmod.F90

    r11949 r11960  
    109109      ! 
    110110      !                       !**  read Surface Module namelist 
    111       REWIND( numnam_ref )          !* Namelist namsbc in reference namelist : Surface boundary 
    112111      READ  ( numnam_ref, namsbc, IOSTAT = ios, ERR = 901) 
    113112901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc in reference namelist' ) 
    114       REWIND( numnam_cfg )          !* Namelist namsbc in configuration namelist : Parameters of the run 
    115113      READ  ( numnam_cfg, namsbc, IOSTAT = ios, ERR = 902 ) 
    116114902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcrnf.F90

    r11949 r11960  
    267267      !                                   ! ============ 
    268268      ! 
    269       REWIND( numnam_ref )              ! Namelist namsbc_rnf in reference namelist : Runoffs  
    270269      READ  ( numnam_ref, namsbc_rnf, IOSTAT = ios, ERR = 901) 
    271270901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_rnf in reference namelist' ) 
    272271 
    273       REWIND( numnam_cfg )              ! Namelist namsbc_rnf in configuration namelist : Runoffs 
    274272      READ  ( numnam_cfg, namsbc_rnf, IOSTAT = ios, ERR = 902 ) 
    275273902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_rnf in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcssr.F90

    r11536 r11960  
    164164      ENDIF 
    165165      !  
    166       REWIND( numnam_ref )              ! Namelist namsbc_ssr in reference namelist :  
    167166      READ  ( numnam_ref, namsbc_ssr, IOSTAT = ios, ERR = 901) 
    168167901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_ssr in reference namelist' ) 
    169168 
    170       REWIND( numnam_cfg )              ! Namelist namsbc_ssr in configuration namelist : 
    171169      READ  ( numnam_cfg, namsbc_ssr, IOSTAT = ios, ERR = 902 ) 
    172170902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_ssr in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/sbcwave.F90

    r11949 r11960  
    397397      !!--------------------------------------------------------------------- 
    398398      ! 
    399       REWIND( numnam_ref )              ! Namelist namsbc_wave in reference namelist : File for drag coeff. from wave model 
    400399      READ  ( numnam_ref, namsbc_wave, IOSTAT = ios, ERR = 901) 
    401400901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namsbc_wave in reference namelist' ) 
    402401          
    403       REWIND( numnam_cfg )              ! Namelist namsbc_wave in configuration namelist : File for drag coeff. from wave model 
    404402      READ  ( numnam_cfg, namsbc_wave, IOSTAT = ios, ERR = 902 ) 
    405403902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namsbc_wave in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/tideini.F90

    r11536 r11960  
    5858      ! 
    5959      ! Read Namelist nam_tide 
    60       REWIND( numnam_ref )              ! Namelist nam_tide in reference namelist : Tides 
    6160      READ  ( numnam_ref, nam_tide, IOSTAT = ios, ERR = 901) 
    6261901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nam_tide in reference namelist' ) 
    6362      ! 
    64       REWIND( numnam_cfg )              ! Namelist nam_tide in configuration namelist : Tides 
    6563      READ  ( numnam_cfg, nam_tide, IOSTAT = ios, ERR = 902 ) 
    6664902   IF( ios >  0 )   CALL ctl_nam ( ios , 'nam_tide in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/STO/stopar.F90

    r11536 r11960  
    261261 
    262262      ! Read namsto namelist : stochastic parameterization 
    263       REWIND( numnam_ref )              ! Namelist namdyn_adv in reference namelist : Momentum advection scheme 
    264263      READ  ( numnam_ref, namsto, IOSTAT = ios, ERR = 901) 
    265264901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namsto in reference namelist' ) 
    266265 
    267       REWIND( numnam_cfg )              ! Namelist namdyn_adv in configuration namelist : Momentum advection scheme 
    268266      READ  ( numnam_cfg, namsto, IOSTAT = ios, ERR = 902 ) 
    269267902   IF( ios >  0 ) CALL ctl_nam ( ios , 'namsto in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/TRA/eosbn2.F90

    r11949 r11960  
    12401240      !!---------------------------------------------------------------------- 
    12411241      ! 
    1242       REWIND( numnam_ref )              ! Namelist nameos in reference namelist : equation of state 
    12431242      READ  ( numnam_ref, nameos, IOSTAT = ios, ERR = 901 ) 
    12441243901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nameos in reference namelist' ) 
    12451244      ! 
    1246       REWIND( numnam_cfg )              ! Namelist nameos in configuration namelist : equation of state 
    12471245      READ  ( numnam_cfg, nameos, IOSTAT = ios, ERR = 902 ) 
    12481246902   IF( ios >  0 )   CALL ctl_nam ( ios , 'nameos in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/TRA/traadv.F90

    r11949 r11960  
    196196      ! 
    197197      !                                !==  Namelist  ==! 
    198       REWIND( numnam_ref )                   ! Namelist namtra_adv in reference namelist : Tracer advection scheme 
    199198      READ  ( numnam_ref, namtra_adv, IOSTAT = ios, ERR = 901) 
    200199901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtra_adv in reference namelist' ) 
    201200      ! 
    202       REWIND( numnam_cfg )                   ! Namelist namtra_adv in configuration namelist : Tracer advection scheme 
    203201      READ  ( numnam_cfg, namtra_adv, IOSTAT = ios, ERR = 902 ) 
    204202902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtra_adv in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/TRA/trabbc.F90

    r11949 r11960  
    135135      !!---------------------------------------------------------------------- 
    136136      ! 
    137       REWIND( numnam_ref )              ! Namelist nambbc in reference namelist : Bottom momentum boundary condition 
    138137      READ  ( numnam_ref, nambbc, IOSTAT = ios, ERR = 901) 
    139138901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nambbc in reference namelist' ) 
    140139      ! 
    141       REWIND( numnam_cfg )              ! Namelist nambbc in configuration namelist : Bottom momentum boundary condition 
    142140      READ  ( numnam_cfg, nambbc, IOSTAT = ios, ERR = 902 ) 
    143141902   IF( ios >  0 )   CALL ctl_nam ( ios , 'nambbc in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/TRA/trabbl.F90

    r11949 r11960  
    488488      !!---------------------------------------------------------------------- 
    489489      ! 
    490       REWIND( numnam_ref )              ! Namelist nambbl in reference namelist : Bottom boundary layer scheme 
    491490      READ  ( numnam_ref, nambbl, IOSTAT = ios, ERR = 901) 
    492491901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'nambbl in reference namelist' ) 
    493492      ! 
    494       REWIND( numnam_cfg )              ! Namelist nambbl in configuration namelist : Bottom boundary layer scheme 
    495493      READ  ( numnam_cfg, nambbl, IOSTAT = ios, ERR = 902 ) 
    496494902   IF( ios >  0 )   CALL ctl_nam ( ios , 'nambbl in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/TRA/tradmp.F90

    r11949 r11960  
    180180      !!---------------------------------------------------------------------- 
    181181      ! 
    182       REWIND( numnam_ref )   ! Namelist namtra_dmp in reference namelist : T & S relaxation 
    183182      READ  ( numnam_ref, namtra_dmp, IOSTAT = ios, ERR = 901) 
    184183901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtra_dmp in reference namelist' ) 
    185184      ! 
    186       REWIND( numnam_cfg )   ! Namelist namtra_dmp in configuration namelist : T & S relaxation 
    187185      READ  ( numnam_cfg, namtra_dmp, IOSTAT = ios, ERR = 902 ) 
    188186902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtra_dmp in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/TRA/tramle.F90

    r11949 r11960  
    267267      !!---------------------------------------------------------------------- 
    268268 
    269       REWIND( numnam_ref )              ! Namelist namtra_mle in reference namelist : Tracer advection scheme 
    270269      READ  ( numnam_ref, namtra_mle, IOSTAT = ios, ERR = 901) 
    271270901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtra_mle in reference namelist' ) 
    272271 
    273       REWIND( numnam_cfg )              ! Namelist namtra_mle in configuration namelist : Tracer advection scheme 
    274272      READ  ( numnam_cfg, namtra_mle, IOSTAT = ios, ERR = 902 ) 
    275273902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtra_mle in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/TRA/traqsr.F90

    r11949 r11960  
    338338      !!---------------------------------------------------------------------- 
    339339      ! 
    340       REWIND( numnam_ref )              ! Namelist namtra_qsr in reference     namelist 
    341340      READ  ( numnam_ref, namtra_qsr, IOSTAT = ios, ERR = 901) 
    342341901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtra_qsr in reference namelist' ) 
    343342      ! 
    344       REWIND( numnam_cfg )              ! Namelist namtra_qsr in configuration namelist 
    345343      READ  ( numnam_cfg, namtra_qsr, IOSTAT = ios, ERR = 902 ) 
    346344902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtra_qsr in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/TRD/trdini.F90

    r11949 r11960  
    4747      !!---------------------------------------------------------------------- 
    4848      ! 
    49       REWIND( numnam_ref )              ! Namelist namtrd in reference namelist : trends diagnostic 
    5049      READ  ( numnam_ref, namtrd, IOSTAT = ios, ERR = 901 ) 
    5150901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtrd in reference namelist' ) 
    5251      ! 
    53       REWIND( numnam_cfg )              ! Namelist namtrd in configuration namelist : trends diagnostic 
    5452      READ  ( numnam_cfg, namtrd, IOSTAT = ios, ERR = 902 ) 
    5553902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtrd in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/TRD/trdmxl.F90

    r11949 r11960  
    733733      !!---------------------------------------------------------------------- 
    734734      ! 
    735       REWIND( numnam_ref )              ! Namelist namtrd_mxl in reference namelist : mixed layer trends diagnostic 
    736735      READ  ( numnam_ref, namtrd_mxl, IOSTAT = ios, ERR = 901 ) 
    737736901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namtrd_mxl in reference namelist' ) 
    738737 
    739       REWIND( numnam_cfg )              ! Namelist namtrd_mxl in configuration namelist : mixed layer trends diagnostic 
    740738      READ  ( numnam_cfg, namtrd_mxl, IOSTAT = ios, ERR = 902 ) 
    741739902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namtrd_mxl in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/USR/usrdef_nam.F90

    r11536 r11960  
    5959      !!---------------------------------------------------------------------- 
    6060      ! 
    61       REWIND( numnam_cfg )          ! Namelist namusr_def (exist in namelist_cfg only) 
    6261      READ  ( numnam_cfg, namusr_def, IOSTAT = ios, ERR = 902 ) 
    6362902   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namusr_def in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/ZDF/zdfdrg.F90

    r11949 r11960  
    238238      !                     !==  drag nature  ==! 
    239239      ! 
    240       REWIND( numnam_ref )                   ! Namelist namdrg in reference namelist 
    241240      READ  ( numnam_ref, namdrg, IOSTAT = ios, ERR = 901) 
    242241901   IF( ios /= 0 )   CALL ctl_nam( ios , 'namdrg in reference namelist' ) 
    243       REWIND( numnam_cfg )                   ! Namelist namdrg in configuration namelist 
    244242      READ  ( numnam_cfg, namdrg, IOSTAT = ios, ERR = 902 ) 
    245243902   IF( ios >  0 )   CALL ctl_nam( ios , 'namdrg in configuration namelist' ) 
     
    337335      !                          !==  read namlist  ==! 
    338336      ! 
    339       REWIND( numnam_ref )                   ! Namelist cl_namdrg in reference namelist 
    340337      IF(ll_top)   READ  ( numnam_ref, namdrg_top, IOSTAT = ios, ERR = 901) 
    341338      IF(ll_bot)   READ  ( numnam_ref, namdrg_bot, IOSTAT = ios, ERR = 901) 
    342339901   IF( ios /= 0 )   CALL ctl_nam( ios , TRIM(cl_namref) ) 
    343       REWIND( numnam_cfg )                   ! Namelist cd_namdrg in configuration namelist 
    344340      IF(ll_top)   READ  ( numnam_cfg, namdrg_top, IOSTAT = ios, ERR = 902 ) 
    345341      IF(ll_bot)   READ  ( numnam_cfg, namdrg_bot, IOSTAT = ios, ERR = 902 ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/ZDF/zdfgls.F90

    r11949 r11960  
    858858      !!---------------------------------------------------------- 
    859859      ! 
    860       REWIND( numnam_ref )              ! Namelist namzdf_gls in reference namelist : Vertical eddy diffivity and viscosity using gls turbulent closure scheme 
    861860      READ  ( numnam_ref, namzdf_gls, IOSTAT = ios, ERR = 901) 
    862861901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namzdf_gls in reference namelist' ) 
    863862 
    864       REWIND( numnam_cfg )              ! Namelist namzdf_gls in configuration namelist : Vertical eddy diffivity and viscosity using gls turbulent closure scheme 
    865863      READ  ( numnam_cfg, namzdf_gls, IOSTAT = ios, ERR = 902 ) 
    866864902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namzdf_gls in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/ZDF/zdfiwm.F90

    r11949 r11960  
    423423      !!---------------------------------------------------------------------- 
    424424      ! 
    425       REWIND( numnam_ref )              ! Namelist namzdf_iwm in reference namelist : Wave-driven mixing 
    426425      READ  ( numnam_ref, namzdf_iwm, IOSTAT = ios, ERR = 901) 
    427426901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namzdf_iwm in reference namelist' ) 
    428427      ! 
    429       REWIND( numnam_cfg )              ! Namelist namzdf_iwm in configuration namelist : Wave-driven mixing 
    430428      READ  ( numnam_cfg, namzdf_iwm, IOSTAT = ios, ERR = 902 ) 
    431429902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namzdf_iwm in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/ZDF/zdfosm.F90

    r11949 r11960  
    13871387     !!---------------------------------------------------------------------- 
    13881388     ! 
    1389      REWIND( numnam_ref )              ! Namelist namzdf_osm in reference namelist : Osmosis ML model 
    13901389     READ  ( numnam_ref, namzdf_osm, IOSTAT = ios, ERR = 901) 
    13911390901  IF( ios /= 0 ) CALL ctl_nam ( ios , 'namzdf_osm in reference namelist' ) 
    13921391 
    1393      REWIND( numnam_cfg )              ! Namelist namzdf_tke in configuration namelist : Turbulent Kinetic Energy 
    13941392     READ  ( numnam_cfg, namzdf_osm, IOSTAT = ios, ERR = 902 ) 
    13951393902  IF( ios >  0 ) CALL ctl_nam ( ios , 'namzdf_osm in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/ZDF/zdfphy.F90

    r11949 r11960  
    9393      ! 
    9494      !                           !==  Namelist  ==! 
    95       REWIND( numnam_ref )              ! Namelist namzdf in reference namelist : Vertical mixing parameters 
    9695      READ  ( numnam_ref, namzdf, IOSTAT = ios, ERR = 901) 
    9796901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namzdf in reference namelist' ) 
    9897      ! 
    99       REWIND( numnam_cfg )              ! Namelist namzdf in reference namelist : Vertical mixing parameters 
    10098      READ  ( numnam_cfg, namzdf, IOSTAT = ios, ERR = 902 ) 
    10199902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namzdf in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/ZDF/zdfric.F90

    r11949 r11960  
    7878      !!---------------------------------------------------------------------- 
    7979      ! 
    80       REWIND( numnam_ref )              ! Namelist namzdf_ric in reference namelist : Vertical diffusion Kz depends on Richardson number 
    8180      READ  ( numnam_ref, namzdf_ric, IOSTAT = ios, ERR = 901) 
    8281901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namzdf_ric in reference namelist' ) 
    8382 
    84       REWIND( numnam_cfg )              ! Namelist namzdf_ric in configuration namelist : Vertical diffusion Kz depends on Richardson number 
    8583      READ  ( numnam_cfg, namzdf_ric, IOSTAT = ios, ERR = 902 ) 
    8684902   IF( ios >  0 ) CALL ctl_nam ( ios , 'namzdf_ric in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/ZDF/zdftke.F90

    r11949 r11960  
    656656      !!---------------------------------------------------------------------- 
    657657      ! 
    658       REWIND( numnam_ref )              ! Namelist namzdf_tke in reference namelist : Turbulent Kinetic Energy 
    659658      READ  ( numnam_ref, namzdf_tke, IOSTAT = ios, ERR = 901) 
    660659901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namzdf_tke in reference namelist' ) 
    661660 
    662       REWIND( numnam_cfg )              ! Namelist namzdf_tke in configuration namelist : Turbulent Kinetic Energy 
    663661      READ  ( numnam_cfg, namzdf_tke, IOSTAT = ios, ERR = 902 ) 
    664662902   IF( ios >  0 ) CALL ctl_nam ( ios , 'namzdf_tke in configuration namelist' ) 
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/nemogcm.F90

    r11949 r11960  
    309309      IF( lwm )   CALL ctl_opn(     numout,        'ocean.output', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, -1, .FALSE. ) 
    310310      ! open reference and configuration namelist files 
    311                   CALL ctl_opn( numnam_ref,        'namelist_ref',     'OLD', 'FORMATTED', 'SEQUENTIAL', -1, -1, .FALSE. ) 
    312                   CALL ctl_opn( numnam_cfg,        'namelist_cfg',     'OLD', 'FORMATTED', 'SEQUENTIAL', -1, -1, .FALSE. ) 
     311                  CALL load_nml( numnam_ref,        'namelist_ref',                                           -1, lwm ) 
     312                  CALL load_nml( numnam_cfg,        'namelist_cfg',                                           -1, lwm ) 
    313313      IF( lwm )   CALL ctl_opn(     numond, 'output.namelist.dyn', 'REPLACE', 'FORMATTED', 'SEQUENTIAL', -1, -1, .FALSE. ) 
    314314      ! open /dev/null file to be able to supress output write easily 
     
    319319      !                             !--------------------! 
    320320      ! 
    321       REWIND( numnam_ref )              ! Namelist namctl in reference namelist 
    322321      READ  ( numnam_ref, namctl, IOSTAT = ios, ERR = 901 ) 
    323322901   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namctl in reference namelist' ) 
    324       REWIND( numnam_cfg )              ! Namelist namctl in confguration namelist 
    325323      READ  ( numnam_cfg, namctl, IOSTAT = ios, ERR = 902 ) 
    326324902   IF( ios >  0 )   CALL ctl_nam ( ios , 'namctl in configuration namelist' ) 
     
    377375      !                             !------------------------------------! 
    378376      ! 
    379       REWIND( numnam_ref )              ! Namelist namcfg in reference namelist 
    380377      READ  ( numnam_ref, namcfg, IOSTAT = ios, ERR = 903 ) 
    381378903   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namcfg in reference namelist' ) 
    382       REWIND( numnam_cfg )              ! Namelist namcfg in confguration namelist 
    383379      READ  ( numnam_cfg, namcfg, IOSTAT = ios, ERR = 904 ) 
    384380904   IF( ios >  0 )   CALL ctl_nam ( ios , 'namcfg in configuration namelist' )    
     
    624620      IF( numstp          /= -1 )   CLOSE( numstp          )   ! time-step file 
    625621      IF( numrun          /= -1 )   CLOSE( numrun          )   ! run statistics file 
    626       IF( numnam_ref      /= -1 )   CLOSE( numnam_ref      )   ! oce reference namelist 
    627       IF( numnam_cfg      /= -1 )   CLOSE( numnam_cfg      )   ! oce configuration namelist 
    628622      IF( lwm.AND.numond  /= -1 )   CLOSE( numond          )   ! oce output namelist 
    629       IF( numnam_ice_ref  /= -1 )   CLOSE( numnam_ice_ref  )   ! ice reference namelist 
    630       IF( numnam_ice_cfg  /= -1 )   CLOSE( numnam_ice_cfg  )   ! ice configuration namelist 
    631623      IF( lwm.AND.numoni  /= -1 )   CLOSE( numoni          )   ! ice output namelist 
    632624      IF( numevo_ice      /= -1 )   CLOSE( numevo_ice      )   ! ice variables (temp. evolution) 
Note: See TracChangeset for help on using the changeset viewer.