|
|
|
|
@ -17,7 +17,10 @@
|
|
|
|
|
#ifdef __KERNEL__
|
|
|
|
|
#include <linux/if_arp.h>
|
|
|
|
|
#include <net/ip.h>
|
|
|
|
|
#include <linux/version.h>
|
|
|
|
|
#if (LINUX_VERSION_CODE <= KERNEL_VERSION(5, 14, 0))
|
|
|
|
|
#include <net/ipx.h>
|
|
|
|
|
#endif
|
|
|
|
|
#include <linux/atalk.h>
|
|
|
|
|
#include <linux/udp.h>
|
|
|
|
|
#include <linux/if_pppox.h>
|
|
|
|
|
@ -169,6 +172,7 @@ static __inline__ void __nat25_generate_ipv4_network_addr(unsigned char *network
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#if (LINUX_VERSION_CODE <= KERNEL_VERSION(5, 14, 0))
|
|
|
|
|
static __inline__ void __nat25_generate_ipx_network_addr_with_node(unsigned char *networkAddr,
|
|
|
|
|
unsigned int *ipxNetAddr, unsigned char *ipxNodeAddr)
|
|
|
|
|
{
|
|
|
|
|
@ -200,6 +204,7 @@ static __inline__ void __nat25_generate_apple_network_addr(unsigned char *networ
|
|
|
|
|
memcpy(networkAddr + 1, (unsigned char *)network, 2);
|
|
|
|
|
networkAddr[3] = *node;
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
static __inline__ void __nat25_generate_pppoe_network_addr(unsigned char *networkAddr,
|
|
|
|
|
@ -889,6 +894,7 @@ int nat25_db_handle(_adapter *priv, struct sk_buff *skb, int method)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#if (LINUX_VERSION_CODE <= KERNEL_VERSION(5, 14, 0))
|
|
|
|
|
/*---------------------------------------------------*/
|
|
|
|
|
/* Handle IPX and Apple Talk frame */
|
|
|
|
|
/*---------------------------------------------------*/
|
|
|
|
|
@ -1109,6 +1115,7 @@ int nat25_db_handle(_adapter *priv, struct sk_buff *skb, int method)
|
|
|
|
|
|
|
|
|
|
return -1;
|
|
|
|
|
}
|
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
/*---------------------------------------------------*/
|
|
|
|
|
/* Handle PPPoE frame */
|
|
|
|
|
|