#include <linux/init.h>
#include <linux/module.h>
#include <linux/crypto.h>
#include <linux/vmalloc.h>
#include <linux/lz4.h>
#include <crypto/internal/scompress.h>
struct lz4hc_ctx { … };
static void *lz4hc_alloc_ctx(struct crypto_scomp *tfm)
{ … }
static int lz4hc_init(struct crypto_tfm *tfm)
{ … }
static void lz4hc_free_ctx(struct crypto_scomp *tfm, void *ctx)
{ … }
static void lz4hc_exit(struct crypto_tfm *tfm)
{ … }
static int __lz4hc_compress_crypto(const u8 *src, unsigned int slen,
u8 *dst, unsigned int *dlen, void *ctx)
{ … }
static int lz4hc_scompress(struct crypto_scomp *tfm, const u8 *src,
unsigned int slen, u8 *dst, unsigned int *dlen,
void *ctx)
{ … }
static int lz4hc_compress_crypto(struct crypto_tfm *tfm, const u8 *src,
unsigned int slen, u8 *dst,
unsigned int *dlen)
{ … }
static int __lz4hc_decompress_crypto(const u8 *src, unsigned int slen,
u8 *dst, unsigned int *dlen, void *ctx)
{ … }
static int lz4hc_sdecompress(struct crypto_scomp *tfm, const u8 *src,
unsigned int slen, u8 *dst, unsigned int *dlen,
void *ctx)
{ … }
static int lz4hc_decompress_crypto(struct crypto_tfm *tfm, const u8 *src,
unsigned int slen, u8 *dst,
unsigned int *dlen)
{ … }
static struct crypto_alg alg_lz4hc = …;
static struct scomp_alg scomp = …;
static int __init lz4hc_mod_init(void)
{ … }
static void __exit lz4hc_mod_fini(void)
{ … }
subsys_initcall(lz4hc_mod_init);
module_exit(lz4hc_mod_fini);
MODULE_LICENSE(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_ALIAS_CRYPTO(…) …;