Refresh Motorcomm compatibility patch for upstream 1.0.34
This commit is contained in:
1 parent
55f14524df
commit
b65e187e78
2 files changed
+2
-41
No files matched your search
@@ -11,7 +11,7 @@ license=('GPL-2.0-or-later')
|
||||
depends=('dkms')
|
||||
source=(${_pkgbase}-${pkgver}.zip::'https://www.motor-comm.com/Cn/Skippower/downloadFile.html?id=1817'
|
||||
'patch.diff')
|
||||
sha256sums=('877e6953fc6eb47232a74e47b0daf33de0e7f9e9a395d3bc10d500d3c4150af8' '6cdb77774c483b640c8f0499fd54a79e773cd3f96a426cd99eec385972d9d5bb')
|
||||
sha256sums=('877e6953fc6eb47232a74e47b0daf33de0e7f9e9a395d3bc10d500d3c4150af8' '597cbcefe2c3f426a20b089b1a24f7bfcaffe81bdfe1bd2c789c9228b3b5708e')
|
||||
|
||||
prepare() {
|
||||
cd ${srcdir}
|
||||
|
||||
@@ -2,9 +2,7 @@ diff --git a/src/dkms.conf b/src/dkms.conf
|
||||
index 78eaf8b..9d93675 100644
|
||||
--- a/src/dkms.conf
|
||||
+++ b/src/dkms.conf
|
||||
@@ -1,8 +1,5 @@
|
||||
PACKAGE_NAME="yt6801"
|
||||
PACKAGE_VERSION="1.0.31"
|
||||
@@ -3,6 +3,3 @@
|
||||
-CLEAN="make clean"
|
||||
-MAKE[0]="make"
|
||||
BUILT_MODULE_NAME[0]="yt6801"
|
||||
@@ -26,43 +24,6 @@ index 3e643f9..fea4c97 100644
|
||||
struct fxgmac_channel *channel = from_timer(channel, t, expansion.tx_hang_timer);
|
||||
#else
|
||||
struct fxgmac_channel *channel = (struct fxgmac_channel *)data;
|
||||
diff --git a/src/fuxi-gmac-phy.c b/src/fuxi-gmac-phy.c
|
||||
index 36d4fb3..8bd9533 100644
|
||||
--- a/src/fuxi-gmac-phy.c
|
||||
+++ b/src/fuxi-gmac-phy.c
|
||||
@@ -324,7 +324,9 @@ static void fxgmac_phy_link_poll(struct timer_list *t)
|
||||
static void fxgmac_phy_link_poll(unsigned long data)
|
||||
#endif
|
||||
{
|
||||
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0))
|
||||
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6,16,0))
|
||||
+ struct fxgmac_pdata *pdata = timer_container_of(pdata, t, expansion.phy_poll_tm);
|
||||
+#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0))
|
||||
struct fxgmac_pdata *pdata = from_timer(pdata, t, expansion.phy_poll_tm);
|
||||
#else
|
||||
struct fxgmac_pdata *pdata = (struct fxgmac_pdata*)data;
|
||||
@@ -352,7 +354,9 @@ static void fxgmac_phy_link_poll(unsigned long data)
|
||||
|
||||
int fxgmac_phy_timer_init(struct fxgmac_pdata *pdata)
|
||||
{
|
||||
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0))
|
||||
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6,16,0))
|
||||
+ timer_init_key(&pdata->expansion.phy_poll_tm, NULL, 0, "fuxi_phy_link_update_timer", NULL);
|
||||
+#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0))
|
||||
init_timer_key(&pdata->expansion.phy_poll_tm, NULL, 0, "fuxi_phy_link_update_timer", NULL);
|
||||
#else
|
||||
init_timer_key(&pdata->expansion.phy_poll_tm, 0, "fuxi_phy_link_update_timer", NULL);
|
||||
@@ -370,6 +374,10 @@ int fxgmac_phy_timer_init(struct fxgmac_pdata *pdata)
|
||||
|
||||
void fxgmac_phy_timer_destroy(struct fxgmac_pdata *pdata)
|
||||
{
|
||||
+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(6,15,0))
|
||||
+ timer_shutdown_sync(&pdata->expansion.phy_poll_tm);
|
||||
+#else
|
||||
del_timer_sync(&pdata->expansion.phy_poll_tm);
|
||||
+#endif
|
||||
DPRINTK("fxgmac_phy_timer removed\n");
|
||||
}
|
||||
diff --git a/src/fuxi-gmac.h b/src/fuxi-gmac.h
|
||||
index 539b507..2435f0c 100644
|
||||
--- a/src/fuxi-gmac.h
|
||||
|
||||
Reference in new issue
Block a user