diff --git a/src/DOUAR.f90 b/src/DOUAR.f90
index bd2bf4b2a6ce178c0e9f31c4f8ed33420c9bab41..7e6249c88b93d14f6754216e35ac220fcfbf6cb7 100644
--- a/src/DOUAR.f90
+++ b/src/DOUAR.f90
@@ -734,8 +734,9 @@ do while (istep.le.params%nstep)
          !--------------------------------------------------------------------------------------
          call show_time (total,step,inc,1,'build system$')
 
-         call build_system_wsmp (n,n_iproc,n_iproc_st,nz_loc,iproc_col,ia,ja,ldb,nrhs,avals,b, &
-                                 params,osolve,ndof,mat,vo,istep,iter,iter_nl,threadinfo,weightel)
+         call build_system_wsmp (n,n_iproc,n_iproc_st,nz_loc,iproc_col,ia,ja,  &
+                                ldb,nrhs,avals,b,params,osolve,ndof,mat,vo,    &
+                                threadinfo,weightel)
 
          ! Set reference strain rate flag to false after first nl iteration
          params%init_e2d=.false.
@@ -1222,9 +1223,9 @@ do while (istep.le.params%nstep)
 
       call show_time (total,step,inc,1,'build system$')
 
-      call build_system_wsmp (n,n_iproc,n_iproc_st,nz_loc,iproc_col,ia,ja,ldb,nrhs,avals,b, &
-                              params,osolve,ndoft,mat,vo,istep,iter,iter_nl,threadinfo, &
-                              weightel)
+      call build_system_wsmp (n,n_iproc,n_iproc_st,nz_loc,iproc_col,ia,ja,ldb, &
+                             nrhs,avals,b,params,osolve,ndoft,mat,vo,          &
+                             threadinfo,weightel)
 
       !--------------------------------------------------------------------------------------
       !--------------------------------------------------------------------------------------
diff --git a/src/build_system_wsmp.f90 b/src/build_system_wsmp.f90
index 707f12c33f4f9da14230b6c4ae526e5e1701573c..cebd03873d5d49e05530963d501950484741a1f7 100644
--- a/src/build_system_wsmp.f90
+++ b/src/build_system_wsmp.f90
@@ -16,9 +16,9 @@
 !------------------------------------------------------------------------------|
 !------------------------------------------------------------------------------|
 
-subroutine build_system_wsmp (n,n_iproc,n_iproc_st,nz_loc,iproc_col,ia,ja,     &
-                              ldb,nrhs,avals,b,params,osolve,ndof,mat,vo,      &
-                              istep,iter,iter_nl,threadinfo,weightel_glob)
+subroutine build_system_wsmp (n,n_iproc,n_iproc_st,nz_loc,iproc_col,ia,ja,ldb, &
+                             nrhs,avals,b,params,osolve,ndof,mat,vo,threadinfo,&
+                             weightel_glob)
 
 !------------------------------------------------------------------------------|
 !(((((((((((((((( Purpose of the routine  ))))))))))))))))))))))))))))))))))))))
@@ -59,9 +59,6 @@ type(octreesolve) osolve
 integer ndof 
 type (material) mat(0:params%nmat)
 type (void) vo
-integer istep
-integer iter
-integer iter_nl
 type (thread) threadinfo
 double precision weightel_glob(osolve%nleaves)
 
@@ -74,7 +71,7 @@ double precision,dimension(:,:),allocatable::lsf_el
 double precision ael(8*ndof,8*ndof),bel(8*ndof),patch1(5,5),patch2(3,3)
 double precision,dimension(:),allocatable::penalty_loc,penalty_glob,eviscosity,weightel
 double precision r0,s0,t0,rst,amin
-integer i,j,k,itodo,idof,i1,i2,iii,jjj,err,jj,i1loc,k1,k2,ii
+integer i,j,itodo,idof,i1,i2,iii,jjj,err,jj,i1loc,k1,k2,ii
 integer ileaves,icut,iloc,idof1,idof2,nelem_iproc,nelem_min,nelem_max
 integer inode(5)
 integer levelmax,level