|
@@ -22,6 +22,7 @@
|
|
#include "fm10k.h"
|
|
#include "fm10k.h"
|
|
#include <linux/vmalloc.h>
|
|
#include <linux/vmalloc.h>
|
|
#include <net/udp_tunnel.h>
|
|
#include <net/udp_tunnel.h>
|
|
|
|
+#include <linux/if_macvlan.h>
|
|
|
|
|
|
/**
|
|
/**
|
|
* fm10k_setup_tx_resources - allocate Tx resources (Descriptors)
|
|
* fm10k_setup_tx_resources - allocate Tx resources (Descriptors)
|
|
@@ -1449,6 +1450,13 @@ static void *fm10k_dfwd_add_station(struct net_device *dev,
|
|
int size = 0, i;
|
|
int size = 0, i;
|
|
u16 glort;
|
|
u16 glort;
|
|
|
|
|
|
|
|
+ /* The hardware supported by fm10k only filters on the destination MAC
|
|
|
|
+ * address. In order to avoid issues we only support offloading modes
|
|
|
|
+ * where the hardware can actually provide the functionality.
|
|
|
|
+ */
|
|
|
|
+ if (!macvlan_supports_dest_filter(sdev))
|
|
|
|
+ return ERR_PTR(-EMEDIUMTYPE);
|
|
|
|
+
|
|
/* allocate l2 accel structure if it is not available */
|
|
/* allocate l2 accel structure if it is not available */
|
|
if (!l2_accel) {
|
|
if (!l2_accel) {
|
|
/* verify there is enough free GLORTs to support l2_accel */
|
|
/* verify there is enough free GLORTs to support l2_accel */
|