diff options
author | Dan Streetman <ddstreet@ieee.org> | 2015-05-07 19:49:17 +0200 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2015-05-11 09:06:46 +0200 |
commit | 7011a122383e36dab594406720fa1d089e0be8f9 (patch) | |
tree | cd69055e54a29a9628331d8594545e50878352f3 /drivers/crypto/nx/nx-842.h | |
parent | crypto: nx - rename nx-842.c to nx-842-pseries.c (diff) | |
download | linux-7011a122383e36dab594406720fa1d089e0be8f9.tar.xz linux-7011a122383e36dab594406720fa1d089e0be8f9.zip |
crypto: nx - add NX-842 platform frontend driver
Add NX-842 frontend that allows using either the pSeries platform or
PowerNV platform driver (to be added by later patch) for the NX-842
hardware. Update the MAINTAINERS file to include the new filenames.
Update Kconfig files to clarify titles and descriptions, and correct
dependencies.
Signed-off-by: Dan Streetman <ddstreet@ieee.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/nx/nx-842.h')
-rw-r--r-- | drivers/crypto/nx/nx-842.h | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/drivers/crypto/nx/nx-842.h b/drivers/crypto/nx/nx-842.h new file mode 100644 index 000000000000..2a5d4e197c72 --- /dev/null +++ b/drivers/crypto/nx/nx-842.h @@ -0,0 +1,32 @@ + +#ifndef __NX_842_H__ +#define __NX_842_H__ + +#include <linux/kernel.h> +#include <linux/module.h> +#include <linux/nx842.h> +#include <linux/of.h> +#include <linux/slab.h> +#include <linux/io.h> + +struct nx842_driver { + struct module *owner; + + int (*compress)(const unsigned char *in, unsigned int in_len, + unsigned char *out, unsigned int *out_len, + void *wrkmem); + int (*decompress)(const unsigned char *in, unsigned int in_len, + unsigned char *out, unsigned int *out_len, + void *wrkmem); +}; + +void nx842_register_driver(struct nx842_driver *driver); +void nx842_unregister_driver(struct nx842_driver *driver); + + +/* To allow the main nx-compress module to load platform module */ +#define NX842_PSERIES_MODULE_NAME "nx-compress-pseries" +#define NX842_PSERIES_COMPAT_NAME "ibm,compression" + + +#endif /* __NX_842_H__ */ |