xref: /spdk/module/bdev/malloc/bdev_malloc.h (revision 488570ebd418ba07c9e69e65106dcc964f3bb41b)
1 /*   SPDX-License-Identifier: BSD-3-Clause
2  *   Copyright (c) Intel Corporation.
3  *   All rights reserved.
4  *   Copyright (c) 2021 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
5  */
6 
7 #ifndef SPDK_BDEV_MALLOC_H
8 #define SPDK_BDEV_MALLOC_H
9 
10 #include "spdk/stdinc.h"
11 
12 #include "spdk/bdev.h"
13 
14 typedef void (*spdk_delete_malloc_complete)(void *cb_arg, int bdeverrno);
15 
16 int create_malloc_disk(struct spdk_bdev **bdev, const char *name, const struct spdk_uuid *uuid,
17 		       uint64_t num_blocks, uint32_t block_size, uint32_t optimal_io_boundary);
18 
19 void delete_malloc_disk(const char *name, spdk_delete_malloc_complete cb_fn, void *cb_arg);
20 
21 #endif /* SPDK_BDEV_MALLOC_H */
22