cachepc-linux

Fork of AMDESE/linux with modifications for CachePC side-channel attack
git clone https://git.sinitax.com/sinitax/cachepc-linux
Log | Files | Refs | README | LICENSE | sfeed.txt

geneve.h (986B)


      1/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
      2/* Copyright (c) 2019 Mellanox Technologies. */
      3
      4#ifndef __MLX5_GENEVE_H__
      5#define __MLX5_GENEVE_H__
      6
      7#include <net/geneve.h>
      8#include <linux/mlx5/driver.h>
      9
     10struct mlx5_geneve;
     11
     12#ifdef CONFIG_MLX5_ESWITCH
     13
     14struct mlx5_geneve *mlx5_geneve_create(struct mlx5_core_dev *mdev);
     15void mlx5_geneve_destroy(struct mlx5_geneve *geneve);
     16
     17int mlx5_geneve_tlv_option_add(struct mlx5_geneve *geneve, struct geneve_opt *opt);
     18void mlx5_geneve_tlv_option_del(struct mlx5_geneve *geneve);
     19
     20#else /* CONFIG_MLX5_ESWITCH */
     21
     22static inline struct mlx5_geneve
     23*mlx5_geneve_create(struct mlx5_core_dev *mdev) { return NULL; }
     24static inline void
     25mlx5_geneve_destroy(struct mlx5_geneve *geneve) {}
     26static inline int
     27mlx5_geneve_tlv_option_add(struct mlx5_geneve *geneve, struct geneve_opt *opt) { return 0; }
     28static inline void
     29mlx5_geneve_tlv_option_del(struct mlx5_geneve *geneve) {}
     30
     31#endif /* CONFIG_MLX5_ESWITCH */
     32
     33#endif /* __MLX5_GENEVE_H__ */