diff options
| author | James Morris <james.l.morris@oracle.com> | 2017-12-11 17:01:08 +1100 |
|---|---|---|
| committer | James Morris <james.l.morris@oracle.com> | 2017-12-11 17:01:08 +1100 |
| commit | d21bd6898336a7892914d308d5e0868f0b863571 (patch) | |
| tree | f5f756c25348b5a6c1ce9ddbaa7d1ecd1bef40b0 /lib/mpi | |
| parent | 34d8751fd4ffa34e85ee7e85d34168b3f3f62b42 (diff) | |
| parent | 50c4c4e268a2d7a3e58ebb698ac74da0de40ae36 (diff) | |
Sync to v4.15-rc3 for security subsystem developers to work against.
Diffstat (limited to 'lib/mpi')
| -rw-r--r-- | lib/mpi/Makefile | 1 | ||||
| -rw-r--r-- | lib/mpi/mpi-pow.c | 2 |
2 files changed, 3 insertions, 0 deletions
diff --git a/lib/mpi/Makefile b/lib/mpi/Makefile index 019a68c90144..d5874a7f5ff9 100644 --- a/lib/mpi/Makefile +++ b/lib/mpi/Makefile @@ -1,3 +1,4 @@ +# SPDX-License-Identifier: GPL-2.0 # # MPI multiprecision maths library (from gpg) # diff --git a/lib/mpi/mpi-pow.c b/lib/mpi/mpi-pow.c index e24388a863a7..468fb7cd1221 100644 --- a/lib/mpi/mpi-pow.c +++ b/lib/mpi/mpi-pow.c @@ -26,6 +26,7 @@ * however I decided to publish this code under the plain GPL. */ +#include <linux/sched.h> #include <linux/string.h> #include "mpi-internal.h" #include "longlong.h" @@ -256,6 +257,7 @@ int mpi_powm(MPI res, MPI base, MPI exp, MPI mod) } e <<= 1; c--; + cond_resched(); } i--; |
