From 115f165b6e3bb74f45e13a65c5f4f82f28664a2c Mon Sep 17 00:00:00 2001 From: Nikos Mavrogiannopoulos Date: Wed, 7 Jul 2010 10:40:37 +0200 Subject: Added a modified libtomcrypt with DSA and RSA algorithms. --- libtommath/tommath.h | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'libtommath/tommath.h') diff --git a/libtommath/tommath.h b/libtommath/tommath.h index b229945..a637605 100644 --- a/libtommath/tommath.h +++ b/libtommath/tommath.h @@ -83,10 +83,12 @@ extern "C" { #endif /* define heap macros */ -#define XMALLOC(x) kmalloc(x, GFP_KERNEL) -#define XFREE kfree -#define XREALLOC(x,y) krealloc(x,y, GFP_KERNEL) -#define XCALLOC(x,y) kzalloc(x*y, GPF_KERNEL) +#ifndef XMALLOC +# define XMALLOC(x) kmalloc(x, GFP_KERNEL) +# define XFREE kfree +# define XREALLOC(x,y) krealloc(x,y, GFP_KERNEL) +# define XCALLOC(x,y) kzalloc(x*y, GPF_KERNEL) +#endif /* otherwise the bits per digit is calculated automatically from the size of a mp_digit */ #ifndef DIGIT_BIT -- cgit