r8168: bump to 8.051.02

This commit is contained in:
sbwml 2022-11-26 08:28:15 +08:00
parent 680b72918f
commit 455b03cdb4
4 changed files with 390 additions and 192 deletions

View File

@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=r8168 PKG_NAME:=r8168
PKG_VERSION:=8.050.02 PKG_VERSION:=8.051.02
PKG_RELEASE:=1 PKG_RELEASE:=1
PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION) PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)

View File

@ -1,5 +1,5 @@
diff --git a/r8168_n.c b/r8168_n.c diff --git a/r8168_n.c b/r8168_n.c
index cd868ad..d1ad5aa 100644 index 7e9e2ea..7d89701 100644
--- a/r8168_n.c --- a/r8168_n.c
+++ b/r8168_n.c +++ b/r8168_n.c
@@ -47,6 +47,7 @@ @@ -47,6 +47,7 @@
@ -10,7 +10,7 @@ index cd868ad..d1ad5aa 100644
#include <linux/if_vlan.h> #include <linux/if_vlan.h>
#include <linux/crc32.h> #include <linux/crc32.h>
#include <linux/interrupt.h> #include <linux/interrupt.h>
@@ -24643,6 +24644,22 @@ rtl8168_set_bios_setting(struct net_device *dev) @@ -24769,6 +24770,22 @@ rtl8168_set_bios_setting(struct net_device *dev)
} }
} }
@ -33,7 +33,7 @@ index cd868ad..d1ad5aa 100644
static void static void
rtl8168_init_software_variable(struct net_device *dev) rtl8168_init_software_variable(struct net_device *dev)
{ {
@@ -25206,6 +25223,8 @@ rtl8168_init_software_variable(struct net_device *dev) @@ -25343,6 +25360,8 @@ rtl8168_init_software_variable(struct net_device *dev)
tp->NotWrMcuPatchCode = TRUE; tp->NotWrMcuPatchCode = TRUE;
} }

View File

@ -190,7 +190,7 @@ do { \
#define NETIF_F_RXFCS 0 #define NETIF_F_RXFCS 0
#endif #endif
#ifndef HAVE_FREE_NETDEV #if !defined(HAVE_FREE_NETDEV) && (LINUX_VERSION_CODE < KERNEL_VERSION(3,1,0))
#define free_netdev(x) kfree(x) #define free_netdev(x) kfree(x)
#endif #endif
@ -344,7 +344,7 @@ do { \
#define DASH_SUFFIX "" #define DASH_SUFFIX ""
#endif #endif
#define RTL8168_VERSION "8.050.03" NAPI_SUFFIX FIBER_SUFFIX REALWOW_SUFFIX DASH_SUFFIX #define RTL8168_VERSION "8.051.02" NAPI_SUFFIX FIBER_SUFFIX REALWOW_SUFFIX DASH_SUFFIX
#define MODULENAME "r8168" #define MODULENAME "r8168"
#define PFX MODULENAME ": " #define PFX MODULENAME ": "
@ -445,6 +445,11 @@ This is free software, and you are welcome to redistribute it under certain cond
#define OCP_STD_PHY_BASE 0xa400 #define OCP_STD_PHY_BASE 0xa400
//Channel Wait Count
#define R8168_CHANNEL_WAIT_COUNT (20000)
#define R8168_CHANNEL_WAIT_TIME (1) // 1us
#define R8168_CHANNEL_EXIT_DELAY_TIME (20) //20us
#define NODE_ADDRESS_SIZE 6 #define NODE_ADDRESS_SIZE 6
#define SHORT_PACKET_PADDING_BUF_SIZE 256 #define SHORT_PACKET_PADDING_BUF_SIZE 256
@ -1387,6 +1392,7 @@ enum _DescStatusBit {
enum features { enum features {
// RTL_FEATURE_WOL = (1 << 0), // RTL_FEATURE_WOL = (1 << 0),
RTL_FEATURE_MSI = (1 << 1), RTL_FEATURE_MSI = (1 << 1),
RTL_FEATURE_MSIX = (1 << 2),
}; };
enum wol_capability { enum wol_capability {
@ -1513,6 +1519,8 @@ struct rtl8168_private {
struct RxDesc *RxDescArray; /* 256-aligned Rx descriptor ring */ struct RxDesc *RxDescArray; /* 256-aligned Rx descriptor ring */
dma_addr_t TxPhyAddr; dma_addr_t TxPhyAddr;
dma_addr_t RxPhyAddr; dma_addr_t RxPhyAddr;
u32 TxDescAllocSize;
u32 RxDescAllocSize;
struct sk_buff *Rx_skbuff[MAX_NUM_RX_DESC]; /* Rx data buffers */ struct sk_buff *Rx_skbuff[MAX_NUM_RX_DESC]; /* Rx data buffers */
struct ring_info tx_skb[MAX_NUM_TX_DESC]; /* Tx data buffers */ struct ring_info tx_skb[MAX_NUM_TX_DESC]; /* Tx data buffers */
unsigned rx_buf_sz; unsigned rx_buf_sz;
@ -1525,6 +1533,7 @@ struct rtl8168_private {
u16 cp_cmd; u16 cp_cmd;
u16 intr_mask; u16 intr_mask;
u16 timer_intr_mask; u16 timer_intr_mask;
int irq;
int phy_auto_nego_reg; int phy_auto_nego_reg;
int phy_1000_ctrl_reg; int phy_1000_ctrl_reg;
u8 org_mac_addr[NODE_ADDRESS_SIZE]; u8 org_mac_addr[NODE_ADDRESS_SIZE];
@ -1810,7 +1819,7 @@ enum mcfg {
#define NIC_RAMCODE_VERSION_CFG_METHOD_28 (0x0019) #define NIC_RAMCODE_VERSION_CFG_METHOD_28 (0x0019)
#define NIC_RAMCODE_VERSION_CFG_METHOD_29 (0x0055) #define NIC_RAMCODE_VERSION_CFG_METHOD_29 (0x0055)
#define NIC_RAMCODE_VERSION_CFG_METHOD_31 (0x0003) #define NIC_RAMCODE_VERSION_CFG_METHOD_31 (0x0003)
#define NIC_RAMCODE_VERSION_CFG_METHOD_35 (0x0010) #define NIC_RAMCODE_VERSION_CFG_METHOD_35 (0x0019)
//hwoptimize //hwoptimize
#define HW_PATCH_SOC_LAN (BIT_0) #define HW_PATCH_SOC_LAN (BIT_0)

File diff suppressed because it is too large Load Diff