mirror of
https://github.com/shenmintao/aic8800d80.git
synced 2026-09-26 17:44:16 +00:00
feat: add Vendor ID 368B with Product ID AIC8800D81
This commit is contained in:
@@ -1000,6 +1000,8 @@ static void aicwf_sdio_bus_pwrctl(struct timer_list *t)
|
|||||||
{
|
{
|
||||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(4,14,0)
|
#if LINUX_VERSION_CODE < KERNEL_VERSION(4,14,0)
|
||||||
struct aic_sdio_dev *sdiodev = (struct aic_sdio_dev *) data;
|
struct aic_sdio_dev *sdiodev = (struct aic_sdio_dev *) data;
|
||||||
|
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0)
|
||||||
|
struct aic_sdio_dev *sdiodev = timer_container_of(sdiodev, t, timer);
|
||||||
#else
|
#else
|
||||||
struct aic_sdio_dev *sdiodev = from_timer(sdiodev, t, timer);
|
struct aic_sdio_dev *sdiodev = from_timer(sdiodev, t, timer);
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -2658,6 +2658,7 @@ static struct usb_device_id aicwf_usb_id_table[] = {
|
|||||||
{USB_DEVICE(USB_VENDOR_ID_TENDA, USB_PRODUCT_ID_TENDA_U2)},
|
{USB_DEVICE(USB_VENDOR_ID_TENDA, USB_PRODUCT_ID_TENDA_U2)},
|
||||||
{USB_DEVICE(USB_VENDOR_ID_TENDA, USB_PRODUCT_ID_TENDA_U11)},
|
{USB_DEVICE(USB_VENDOR_ID_TENDA, USB_PRODUCT_ID_TENDA_U11)},
|
||||||
{USB_DEVICE(USB_VENDOR_ID_TENDA, USB_PRODUCT_ID_TENDA_U11_PRO)},
|
{USB_DEVICE(USB_VENDOR_ID_TENDA, USB_PRODUCT_ID_TENDA_U11_PRO)},
|
||||||
|
{USB_DEVICE(USB_VENDOR_ID_AIC_V2, USB_PRODUCT_ID_AIC8800D81)},
|
||||||
{USB_DEVICE(USB_VENDOR_ID_AIC_V2, USB_PRODUCT_ID_AIC8800FC_CUS1)},
|
{USB_DEVICE(USB_VENDOR_ID_AIC_V2, USB_PRODUCT_ID_AIC8800FC_CUS1)},
|
||||||
{USB_DEVICE(USB_VENDOR_ID_AIC_V2, USB_PRODUCT_ID_AIC8800FC_CUS2)},
|
{USB_DEVICE(USB_VENDOR_ID_AIC_V2, USB_PRODUCT_ID_AIC8800FC_CUS2)},
|
||||||
{USB_DEVICE(USB_VENDOR_ID_AIC_V2, USB_PRODUCT_ID_AIC8800FC_CUS3)},
|
{USB_DEVICE(USB_VENDOR_ID_AIC_V2, USB_PRODUCT_ID_AIC8800FC_CUS3)},
|
||||||
|
|||||||
@@ -2036,6 +2036,9 @@ void aicwf_p2p_alive_timeout(struct timer_list *t)
|
|||||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 15, 0)
|
#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 15, 0)
|
||||||
rwnx_vif = (struct rwnx_vif *)data;
|
rwnx_vif = (struct rwnx_vif *)data;
|
||||||
rwnx_hw = rwnx_vif->rwnx_hw;
|
rwnx_hw = rwnx_vif->rwnx_hw;
|
||||||
|
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0)
|
||||||
|
rwnx_hw = timer_container_of(rwnx_hw, t, p2p_alive_timer);
|
||||||
|
rwnx_vif = rwnx_hw->p2p_dev_vif;
|
||||||
#else
|
#else
|
||||||
rwnx_hw = from_timer(rwnx_hw, t, p2p_alive_timer);
|
rwnx_hw = from_timer(rwnx_hw, t, p2p_alive_timer);
|
||||||
rwnx_vif = rwnx_hw->p2p_dev_vif;
|
rwnx_vif = rwnx_hw->p2p_dev_vif;
|
||||||
@@ -2230,6 +2233,8 @@ static void aicwf_pwrloss_timer(struct timer_list *t)
|
|||||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 15, 0)
|
#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 15, 0)
|
||||||
rwnx_vif = (struct rwnx_vif *)data;
|
rwnx_vif = (struct rwnx_vif *)data;
|
||||||
rwnx_hw = rwnx_vif->rwnx_hw;
|
rwnx_hw = rwnx_vif->rwnx_hw;
|
||||||
|
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0)
|
||||||
|
rwnx_hw = timer_container_of(rwnx_hw, t, pwrloss_timer);
|
||||||
#else
|
#else
|
||||||
rwnx_hw = from_timer(rwnx_hw, t, pwrloss_timer);
|
rwnx_hw = from_timer(rwnx_hw, t, pwrloss_timer);
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -1868,6 +1868,8 @@ void reord_timeout_handler (struct timer_list *t)
|
|||||||
{
|
{
|
||||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(4,14,0)
|
#if LINUX_VERSION_CODE < KERNEL_VERSION(4,14,0)
|
||||||
struct reord_ctrl *preorder_ctrl = (struct reord_ctrl *)data;
|
struct reord_ctrl *preorder_ctrl = (struct reord_ctrl *)data;
|
||||||
|
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0)
|
||||||
|
struct reord_ctrl *preorder_ctrl = timer_container_of(preorder_ctrl, t, reord_timer);
|
||||||
#else
|
#else
|
||||||
struct reord_ctrl *preorder_ctrl = from_timer(preorder_ctrl, t, reord_timer);
|
struct reord_ctrl *preorder_ctrl = from_timer(preorder_ctrl, t, reord_timer);
|
||||||
#endif
|
#endif
|
||||||
@@ -2197,6 +2199,8 @@ void defrag_timeout_cb(struct timer_list *t)
|
|||||||
struct defrag_ctrl_info *defrag_ctrl = NULL;
|
struct defrag_ctrl_info *defrag_ctrl = NULL;
|
||||||
#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 15, 0)
|
#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 15, 0)
|
||||||
defrag_ctrl = (struct defrag_ctrl_info *)data;
|
defrag_ctrl = (struct defrag_ctrl_info *)data;
|
||||||
|
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0)
|
||||||
|
defrag_ctrl = timer_container_of(defrag_ctrl, t, defrag_timer);
|
||||||
#else
|
#else
|
||||||
defrag_ctrl = from_timer(defrag_ctrl, t, defrag_timer);
|
defrag_ctrl = from_timer(defrag_ctrl, t, defrag_timer);
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -12,8 +12,12 @@
|
|||||||
struct wakeup_source *rwnx_wakeup_init(const char *name)
|
struct wakeup_source *rwnx_wakeup_init(const char *name)
|
||||||
{
|
{
|
||||||
struct wakeup_source *ws;
|
struct wakeup_source *ws;
|
||||||
|
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0)
|
||||||
|
ws = wakeup_source_register(NULL, name);
|
||||||
|
#else
|
||||||
ws = wakeup_source_create(name);
|
ws = wakeup_source_create(name);
|
||||||
wakeup_source_add(ws);
|
wakeup_source_add(ws);
|
||||||
|
#endif
|
||||||
return ws;
|
return ws;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -21,8 +25,13 @@ void rwnx_wakeup_deinit(struct wakeup_source *ws)
|
|||||||
{
|
{
|
||||||
if (ws && ws->active)
|
if (ws && ws->active)
|
||||||
__pm_relax(ws);
|
__pm_relax(ws);
|
||||||
|
|
||||||
|
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 16, 0)
|
||||||
|
wakeup_source_unregister(ws);
|
||||||
|
#else
|
||||||
wakeup_source_remove(ws);
|
wakeup_source_remove(ws);
|
||||||
wakeup_source_destroy(ws);
|
wakeup_source_destroy(ws);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
struct wakeup_source *rwnx_wakeup_register(struct device *dev, const char *name)
|
struct wakeup_source *rwnx_wakeup_register(struct device *dev, const char *name)
|
||||||
|
|||||||
Reference in New Issue
Block a user