1 /* SPDX-License-Identifier: (BSD-3-Clause OR GPL-2.0)
3 * Copyright 2013-2016 Freescale Semiconductor Inc.
4 * Copyright 2016-2017 NXP
10 #include <rte_compat.h>
13 * Data Path Buffer Pool API
14 * Contains initialization APIs and runtime control APIs for DPBP
20 int dpbp_open(struct fsl_mc_io *mc_io,
25 int dpbp_close(struct fsl_mc_io *mc_io,
30 * struct dpbp_cfg - Structure representing DPBP configuration
31 * @options: place holder
37 int dpbp_create(struct fsl_mc_io *mc_io,
40 const struct dpbp_cfg *cfg,
43 int dpbp_destroy(struct fsl_mc_io *mc_io,
49 int dpbp_enable(struct fsl_mc_io *mc_io,
54 int dpbp_disable(struct fsl_mc_io *mc_io,
58 int dpbp_is_enabled(struct fsl_mc_io *mc_io,
64 int dpbp_reset(struct fsl_mc_io *mc_io,
69 * struct dpbp_attr - Structure representing DPBP attributes
71 * @bpid: Hardware buffer pool ID; should be used as an argument in
72 * acquire/release operations on buffers
80 int dpbp_get_attributes(struct fsl_mc_io *mc_io,
83 struct dpbp_attr *attr);
86 * DPBP notifications options
90 * BPSCN write will attempt to allocate into a cache (coherent write)
92 #define DPBP_NOTIF_OPT_COHERENT_WRITE 0x00000001
93 int dpbp_get_api_version(struct fsl_mc_io *mc_io,
99 int dpbp_get_num_free_bufs(struct fsl_mc_io *mc_io,
102 uint32_t *num_free_bufs);
104 #endif /* __FSL_DPBP_H */