kokkos: templated if conditions in the fix lagnevin