#include <linux/kernel.h>
#include <linux/slab.h>
#include <linux/vmalloc.h>
#include <linux/zstd.h>
#include "backend_zstd.h"
struct zstd_ctx { … };
struct zstd_params { … };
static void *zstd_custom_alloc(void *opaque, size_t size)
{ … }
static void zstd_custom_free(void *opaque, void *address)
{ … }
static void zstd_release_params(struct zcomp_params *params)
{ … }
static int zstd_setup_params(struct zcomp_params *params)
{ … }
static void zstd_destroy(struct zcomp_ctx *ctx)
{ … }
static int zstd_create(struct zcomp_params *params, struct zcomp_ctx *ctx)
{ … }
static int zstd_compress(struct zcomp_params *params, struct zcomp_ctx *ctx,
struct zcomp_req *req)
{ … }
static int zstd_decompress(struct zcomp_params *params, struct zcomp_ctx *ctx,
struct zcomp_req *req)
{ … }
const struct zcomp_ops backend_zstd = …;