diff --git a/kernel/arm64/dznrm2_thunderx2t99.c b/kernel/arm64/dznrm2_thunderx2t99.c index 6077c85dd..b78878cd4 100644 --- a/kernel/arm64/dznrm2_thunderx2t99.c +++ b/kernel/arm64/dznrm2_thunderx2t99.c @@ -345,7 +345,7 @@ FLOAT CNAME(BLASLONG n, FLOAT *x, BLASLONG inc_x) #endif FLOAT ssq, scale; - if (n <= 0 || inc_x <= 0) return 0.0; + if (n <= 0 || inc_x == 0) return 0.0; #if defined(SMP) if (n <= 10000) diff --git a/kernel/arm64/scnrm2_thunderx2t99.c b/kernel/arm64/scnrm2_thunderx2t99.c index f96de441e..8f930b492 100644 --- a/kernel/arm64/scnrm2_thunderx2t99.c +++ b/kernel/arm64/scnrm2_thunderx2t99.c @@ -315,7 +315,7 @@ FLOAT CNAME(BLASLONG n, FLOAT *x, BLASLONG inc_x) FLOAT nrm2 = 0.0; double nrm2_double = 0.0; - if (n <= 0 || inc_x <= 0) return 0.0; + if (n <= 0 || inc_x == 0) return 0.0; #if defined(SMP) if (n <= 10000)