compat: Added headers and macros to support RHEL7.0
[compat-rdma/compat.git] / include / linux / ethtool.h
index cff23a8..98f0e60 100644 (file)
 #define ETH_MODULE_SFF_8436            0x4
 #define ETH_MODULE_SFF_8436_LEN                256
 #endif
+
+#ifndef SPEED_20000
+#define SPEED_20000 20000
+#define SUPPORTED_20000baseMLD2_Full    (1 << 21)
+#define SUPPORTED_20000baseKR2_Full     (1 << 22)
+#define ADVERTISED_20000baseMLD2_Full   (1 << 21)
+#define ADVERTISED_20000baseKR2_Full    (1 << 22)
+#endif
+
+#ifndef SPEED_40000
+#define SPEED_40000 40000
+#endif
+
+#ifndef SPEED_56000
+#define SPEED_56000 56000
+#define SUPPORTED_56000baseKR4_Full    (1 << 27)
+#define SUPPORTED_56000baseCR4_Full    (1 << 28)
+#define SUPPORTED_56000baseSR4_Full    (1 << 29)
+#define SUPPORTED_56000baseLR4_Full    (1 << 30)
+#define ADVERTISED_56000baseKR4_Full   (1 << 27)
+#define ADVERTISED_56000baseCR4_Full   (1 << 28)
+#define ADVERTISED_56000baseSR4_Full   (1 << 29)
+#define ADVERTISED_56000baseLR4_Full   (1 << 30)
+#endif
+
+#define SPEED_25000 25000
+#define SPEED_50000 50000
+#define SPEED_100000 100000
+/*TODO Ethtool new SPEED API */
+#define SUPPORTED_100000baseCR4_Full 0
+#define ADVERTISED_100000baseCR4_Full 0
+#define SUPPORTED_100000baseSR4_Full 0
+#define ADVERTISED_100000baseSR4_Full 0
+#define SUPPORTED_100000baseKR4_Full 0
+#define ADVERTISED_100000baseKR4_Full 0
+#define SUPPORTED_1000000baseLR4_Full 0
+#define ADVERTISED_1000000baseLR4_Full 0
+#define SUPPORTED_100baseTX_Full 0
+#define ADVERTISED_100baseTX_Full 0
+#define SUPPORTED_25000baseCR_Full 0
+#define ADVERTISED_25000baseCR_Full 0
+#define SUPPORTED_25000baseKR_Full 0
+#define ADVERTISED_25000baseKR_Full 0
+#define SUPPORTED_25000baseSR_Full 0
+#define ADVERTISED_25000baseSR_Full 0
+#define SUPPORTED_50000baseCR2_Full 0
+#define ADVERTISED_50000baseCR2_Full 0
+#define SUPPORTED_50000baseKR2_Full 0
+#define ADVERTISED_50000baseKR2_Full 0
+
+#ifndef SPEED_UNKNOWN
+#define SPEED_UNKNOWN          -1
+#endif
+
+#ifndef DUPLEX_UNKNOWN
+#define DUPLEX_UNKNOWN         -1
+#endif
+
+#ifndef SUPPORTED_40000baseKR4_Full
+/* Add missing defines for supported and advertised speed features */
+#define SUPPORTED_40000baseKR4_Full     (1 << 23)
+#define SUPPORTED_40000baseCR4_Full     (1 << 24)
+#define SUPPORTED_40000baseSR4_Full     (1 << 25)
+#define SUPPORTED_40000baseLR4_Full     (1 << 26)
+#define ADVERTISED_40000baseKR4_Full    (1 << 23)
+#define ADVERTISED_40000baseCR4_Full    (1 << 24)
+#define ADVERTISED_40000baseSR4_Full    (1 << 25)
+#define ADVERTISED_40000baseLR4_Full    (1 << 26)
+#endif
 #endif