smc_netlink.h 660 B

12345678910111213141516171819202122232425262728293031323334
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. /*
  3. * Shared Memory Communications over RDMA (SMC-R) and RoCE
  4. *
  5. * SMC Generic netlink operations
  6. *
  7. * Copyright IBM Corp. 2020
  8. *
  9. * Author(s): Guvenc Gulce <[email protected]>
  10. */
  11. #ifndef _SMC_NETLINK_H
  12. #define _SMC_NETLINK_H
  13. #include <net/netlink.h>
  14. #include <net/genetlink.h>
  15. extern struct genl_family smc_gen_nl_family;
  16. extern const struct nla_policy smc_gen_ueid_policy[];
  17. struct smc_nl_dmp_ctx {
  18. int pos[3];
  19. };
  20. static inline struct smc_nl_dmp_ctx *smc_nl_dmp_ctx(struct netlink_callback *c)
  21. {
  22. return (struct smc_nl_dmp_ctx *)c->ctx;
  23. }
  24. int smc_nl_init(void) __init;
  25. void smc_nl_exit(void);
  26. #endif