Index: trunk/LMDZ.MARS/libf/phymars/phyetat0_mod.F90
===================================================================
--- trunk/LMDZ.MARS/libf/phymars/phyetat0_mod.F90	(revision 3902)
+++ trunk/LMDZ.MARS/libf/phymars/phyetat0_mod.F90	(revision 3903)
@@ -19,4 +19,5 @@
 use surfdat_h,           only: phisfi, albedodat, z0, z0_default, zmea, zstd, &
                                zsig, zgam, zthe, hmons, summit, base, watercaptag
+use surfini_mod,         only: icelocationmode
 use iostart,             only: nid_start, open_startphy, close_startphy, &
                                get_field, get_var, inquire_field,        &
@@ -820,15 +821,17 @@
      write(*,*) "phyetat0: Failed loading <watercaptag> : ", &
                           "<watercaptag> is set as defined by icelocationmode in surfini.F"
-     watercaptag(:)=.false.
+     icelocationmode = 4
    else
      do ig=1,ngrid
-       if(watercaptag_tmp(ig).lt.0.5) then
-          watercaptag(ig)=.false.
+       if(watercaptag_tmp(ig) < 0.5) then
+          watercaptag(ig) = .false.
        else
-          watercaptag(ig)=.true.
+          watercaptag(ig) = .true.
        endif
      enddo
    endif
-endif !startphy_file
+else
+    watercaptag(:) = .false.
+endif ! of if (startphy_file)
 
 if (paleoclimate) then
Index: trunk/LMDZ.MARS/libf/phymars/surfini_mod.F90
===================================================================
--- trunk/LMDZ.MARS/libf/phymars/surfini_mod.F90	(revision 3902)
+++ trunk/LMDZ.MARS/libf/phymars/surfini_mod.F90	(revision 3903)
@@ -2,4 +2,15 @@
 
 implicit none
+
+! There are 4 different modes for ice distribution:
+! icelocationmode = 1 ---> based on data from surface.nc
+! icelocationmode = 2 ---> directly predefined for GCM resolutions 32x24 or 64x48
+! icelocationmode = 3 ---> based on logical relations for latitude and longitude
+! icelocationmode = 4 ---> predefined 64x48 but usable with every
+! resolution, and easily adaptable for dynamico
+! For visualisation : > /u/tnalmd/bin/watercaps gcm_txt_output_file
+integer :: icelocationmode = 5
+
+!$OMP THREADPRIVATE(icelocationmode)
 
 !=======================================================================
@@ -45,16 +56,4 @@
       ! longwatercaptag is watercaptag. Trick for some compilers
       LOGICAL, DIMENSION(100000) :: longwatercaptag
-
-! There are 4 different modes for ice distribution:
-! icelocationmode = 1 ---> based on data from surface.nc
-! icelocationmode = 2 ---> directly predefined for GCM resolutions 32x24 or 64x48
-! icelocationmode = 3 ---> based on logical relations for latitude and longitude
-! icelocationmode = 4 ---> predefined 64x48 but usable with every
-! resolution, and easily adaptable for dynamico
-! For visualisation : > /u/tnalmd/bin/watercaps gcm_txt_output_file
-      INTEGER,SAVE :: icelocationmode = 5
-
-!$OMP THREADPRIVATE(icelocationmode)
-
 
       !in case icelocationmode == 1
@@ -449,12 +448,4 @@
          write(*,*)'icelocationmode = 5'
          write(*,*)'Surfini: ice caps defined using startfi.nc data'
-         do ig=1,ngrid
-           if(any(watercaptag_glo)) then
-           else
-              call locate_watercaptag(klon_glo,lati_glo,long_glo,watercaptag_glo)
-           endif
-         enddo
-
-!         write(*,*)'watercaptag_glo(:), ',watercaptag_glo(:)
 
             case default
