From 9c692d5ae7ea84d221d7504b7ebef07ea8f3ff27 Mon Sep 17 00:00:00 2001 From: Bogdan Purcareata Date: Fri, 2 Mar 2018 04:23:58 -0600 Subject: staging: fsl-mc: Move DPBP out of staging Move the source files out of staging into their final locations: - dpbp.c goes to drivers/bus/fsl-mc/, next to the core infrastructure - dpbp-cmd.h gets merged into drivers/bus/fsl-mc/fsl-mc-private.h, next to the other internally used APIs - dpbp.h gets merged into include/linux/fsl/mc.h, exposing the public API Update references in the dpaa2-eth staging driver. DPBP stands for Data Path Buffer Pool - you can read more about the object in Documentation/networking/dpaa2/overview.rst Signed-off-by: Bogdan Purcareata Reviewed-by: Laurentiu Tudor Signed-off-by: Greg Kroah-Hartman --- include/linux/fsl/mc.h | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) (limited to 'include/linux/fsl') diff --git a/include/linux/fsl/mc.h b/include/linux/fsl/mc.h index 765ba41f5987..66118e1fb5b9 100644 --- a/include/linux/fsl/mc.h +++ b/include/linux/fsl/mc.h @@ -451,4 +451,46 @@ static inline bool is_fsl_mc_bus_dprtc(const struct fsl_mc_device *mc_dev) return mc_dev->dev.type == &fsl_mc_bus_dprtc_type; } +/* + * Data Path Buffer Pool (DPBP) API + * Contains initialization APIs and runtime control APIs for DPBP + */ + +int dpbp_open(struct fsl_mc_io *mc_io, + u32 cmd_flags, + int dpbp_id, + u16 *token); + +int dpbp_close(struct fsl_mc_io *mc_io, + u32 cmd_flags, + u16 token); + +int dpbp_enable(struct fsl_mc_io *mc_io, + u32 cmd_flags, + u16 token); + +int dpbp_disable(struct fsl_mc_io *mc_io, + u32 cmd_flags, + u16 token); + +int dpbp_reset(struct fsl_mc_io *mc_io, + u32 cmd_flags, + u16 token); + +/** + * struct dpbp_attr - Structure representing DPBP attributes + * @id: DPBP object ID + * @bpid: Hardware buffer pool ID; should be used as an argument in + * acquire/release operations on buffers + */ +struct dpbp_attr { + int id; + u16 bpid; +}; + +int dpbp_get_attributes(struct fsl_mc_io *mc_io, + u32 cmd_flags, + u16 token, + struct dpbp_attr *attr); + #endif /* _FSL_MC_H_ */ -- cgit v1.2.3