From patchwork Mon May 10 22:29:20 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lorenzo Bianconi X-Patchwork-Id: 433445 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C0AEDC433ED for ; Mon, 10 May 2021 22:29:44 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 97C3A61581 for ; Mon, 10 May 2021 22:29:44 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231208AbhEJWas (ORCPT ); Mon, 10 May 2021 18:30:48 -0400 Received: from mail.kernel.org ([198.145.29.99]:42906 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231162AbhEJWar (ORCPT ); Mon, 10 May 2021 18:30:47 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 1EF88615FF; Mon, 10 May 2021 22:29:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1620685780; bh=ScPLLImRY/w4P0BUEjSkH3I2WZVwZ+eKlHonbP9JOJI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RRCTBKSEHR/6ujVbTXN2hfPysqXhXwi97n3wlD+Yq+XSOfiQCYDgivb4SkcviluXi 5Ss8OyRnoMchYjSqIqT8QghsAtYN/RQcZ8542CKjKj7XG41mUHzyYms19E6bgBcdVQ 5I5ruxwwcsOVFp0wawM0uXchyUyeVhSCTroH/FDvvK38BFXVVU5PVyLEok9YCj2wgx tlcRUx4s5xfZbwxPCdMULZWOpcynttsmhyNnCCu98Sk/SVLAbKTcXmva3VxkToK7OP PK+Qux1DTJ4b2ruaMlgCK6XINBG5BuKXOCsS4j8zLJBRXu+nHojOsswfNym77xQwVU i6ulH09vIKj2A== From: Lorenzo Bianconi To: nbd@nbd.name Cc: linux-wireless@vger.kernel.org, lorenzo.bianconi@redhat.com, sean.wang@mediatek.com Subject: [PATCH 1/5] mt76: sdio: do not run mt76_txq_schedule directly Date: Tue, 11 May 2021 00:29:20 +0200 Message-Id: <74e5e9f31ceedd04f2fba416c94d96f21cd8b458.1620685619.git.lorenzo@kernel.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: References: MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org In order to support runtime-pm for sdio, do not run mt76_txq_schedule directly, but schedule tx_worker instead Signed-off-by: Lorenzo Bianconi --- drivers/net/wireless/mediatek/mt76/sdio.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/drivers/net/wireless/mediatek/mt76/sdio.c b/drivers/net/wireless/mediatek/mt76/sdio.c index a18d2896ee1f..46cd28017b96 100644 --- a/drivers/net/wireless/mediatek/mt76/sdio.c +++ b/drivers/net/wireless/mediatek/mt76/sdio.c @@ -184,9 +184,6 @@ static int mt76s_process_tx_queue(struct mt76_dev *dev, struct mt76_queue *q) if (!q->queued) wake_up(&dev->tx_wait); - if (!mcu) - mt76_txq_schedule(&dev->phy, q->qid); - return nframes; } @@ -195,19 +192,28 @@ static void mt76s_status_worker(struct mt76_worker *w) struct mt76_sdio *sdio = container_of(w, struct mt76_sdio, status_worker); struct mt76_dev *dev = container_of(sdio, struct mt76_dev, sdio); + bool resched = false; int i, nframes; do { + int ndata_frames = 0; + nframes = mt76s_process_tx_queue(dev, dev->q_mcu[MT_MCUQ_WM]); for (i = 0; i <= MT_TXQ_PSD; i++) - nframes += mt76s_process_tx_queue(dev, - dev->phy.q_tx[i]); + ndata_frames += mt76s_process_tx_queue(dev, + dev->phy.q_tx[i]); + nframes += ndata_frames; + if (ndata_frames > 0) + resched = true; if (dev->drv->tx_status_data && !test_and_set_bit(MT76_READING_STATS, &dev->phy.state)) queue_work(dev->wq, &dev->sdio.stat_work); } while (nframes > 0); + + if (resched) + mt76_worker_schedule(&dev->sdio.txrx_worker); } static void mt76s_tx_status_data(struct work_struct *work) From patchwork Mon May 10 22:29:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lorenzo Bianconi X-Patchwork-Id: 433444 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1138DC43461 for ; Mon, 10 May 2021 22:29:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id E295B61601 for ; Mon, 10 May 2021 22:29:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231220AbhEJWau (ORCPT ); Mon, 10 May 2021 18:30:50 -0400 Received: from mail.kernel.org ([198.145.29.99]:43030 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231193AbhEJWat (ORCPT ); Mon, 10 May 2021 18:30:49 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 86B1761585; Mon, 10 May 2021 22:29:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1620685784; bh=5m/m5BwE75d62QOSZjVWOwUzfdymMUFXVA64u9PbNG0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=WveoK09gVSGAg+Ws80zxE/g8kMTlcq6/15PrP89hIfr/cuEpwmHad0K+4oyxD4zMq tIeOrmgzJLkw/puUoi88t3/KFCSKkHlsr4bp6jEH936DTW2MNhfvHRdJjxeX2ai8FQ rWXbcNx+2nnOaYsrsG2bKkIBxKfO2J6El7eyqA6+KFL2lT6KG47FdfWiadKOysd32a 7GVTvG5TQfmsKazw1/3hK9UoDhRkg4EHg2DImsxtIoZPztr6kPU4gd+K1AMwALOK+I L2oslWA/i5gWvm54wbOegJqR52yMSSZQBVasK6oA0v375Raa5ZZUtNLoYfzflGYnRZ 752Rk81M8sGEA== From: Lorenzo Bianconi To: nbd@nbd.name Cc: linux-wireless@vger.kernel.org, lorenzo.bianconi@redhat.com, sean.wang@mediatek.com Subject: [PATCH 3/5] mt76: mt7663s: rely on mt76_connac_pm_ref/mt76_connac_pm_unref in tx path Date: Tue, 11 May 2021 00:29:22 +0200 Message-Id: <06131b057e47b3bdcd933bc9caed787f2007d84c.1620685619.git.lorenzo@kernel.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: References: MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Similar to mt7663e, rely on mt76_connac_pm_ref/mt76_connac_pm_unref to check PM state and increment/decrement wake counter Signed-off-by: Lorenzo Bianconi --- drivers/net/wireless/mediatek/mt76/mt7615/mac.c | 14 ++++++++++---- .../wireless/mediatek/mt76/mt7615/sdio_txrx.c | 16 ++++++++++++---- 2 files changed, 22 insertions(+), 8 deletions(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/mac.c b/drivers/net/wireless/mediatek/mt76/mt7615/mac.c index e2dcfee6be81..12c628bb200e 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7615/mac.c +++ b/drivers/net/wireless/mediatek/mt76/mt7615/mac.c @@ -1906,12 +1906,18 @@ void mt7615_pm_wake_work(struct work_struct *work) mphy = dev->phy.mt76; if (!mt7615_mcu_set_drv_ctrl(dev)) { + struct mt76_dev *mdev = &dev->mt76; int i; - mt76_for_each_q_rx(&dev->mt76, i) - napi_schedule(&dev->mt76.napi[i]); - mt76_connac_pm_dequeue_skbs(mphy, &dev->pm); - mt76_queue_tx_cleanup(dev, dev->mt76.q_mcu[MT_MCUQ_WM], false); + if (mt76_is_sdio(mdev)) { + mt76_worker_schedule(&mdev->sdio.txrx_worker); + } else { + mt76_for_each_q_rx(mdev, i) + napi_schedule(&mdev->napi[i]); + mt76_connac_pm_dequeue_skbs(mphy, &dev->pm); + mt76_queue_tx_cleanup(dev, mdev->q_mcu[MT_MCUQ_WM], + false); + } if (test_bit(MT76_STATE_RUNNING, &mphy->state)) ieee80211_queue_delayed_work(mphy->hw, &mphy->mac_work, MT7615_WATCHDOG_TIME); diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/sdio_txrx.c b/drivers/net/wireless/mediatek/mt76/mt7615/sdio_txrx.c index 4393dd21ebbb..5eb3cc409b04 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7615/sdio_txrx.c +++ b/drivers/net/wireless/mediatek/mt76/mt7615/sdio_txrx.c @@ -283,9 +283,15 @@ void mt7663s_txrx_worker(struct mt76_worker *w) { struct mt76_sdio *sdio = container_of(w, struct mt76_sdio, txrx_worker); - struct mt76_dev *dev = container_of(sdio, struct mt76_dev, sdio); + struct mt76_dev *mdev = container_of(sdio, struct mt76_dev, sdio); + struct mt7615_dev *dev = container_of(mdev, struct mt7615_dev, mt76); int i, nframes, ret; + if (!mt76_connac_pm_ref(&dev->mphy, &dev->pm)) { + queue_work(mdev->wq, &dev->pm.wake_work); + return; + } + /* disable interrupt */ sdio_claim_host(sdio->func); sdio_writel(sdio->func, WHLPCR_INT_EN_CLR, MCR_WHLPCR, NULL); @@ -295,16 +301,16 @@ void mt7663s_txrx_worker(struct mt76_worker *w) /* tx */ for (i = 0; i <= MT_TXQ_PSD; i++) { - ret = mt7663s_tx_run_queue(dev, dev->phy.q_tx[i]); + ret = mt7663s_tx_run_queue(mdev, mdev->phy.q_tx[i]); if (ret > 0) nframes += ret; } - ret = mt7663s_tx_run_queue(dev, dev->q_mcu[MT_MCUQ_WM]); + ret = mt7663s_tx_run_queue(mdev, mdev->q_mcu[MT_MCUQ_WM]); if (ret > 0) nframes += ret; /* rx */ - ret = mt7663s_rx_handler(dev); + ret = mt7663s_rx_handler(mdev); if (ret > 0) nframes += ret; } while (nframes > 0); @@ -312,6 +318,8 @@ void mt7663s_txrx_worker(struct mt76_worker *w) /* enable interrupt */ sdio_writel(sdio->func, WHLPCR_INT_EN_SET, MCR_WHLPCR, NULL); sdio_release_host(sdio->func); + + mt76_connac_pm_unref(&dev->pm); } void mt7663s_sdio_irq(struct sdio_func *func) From patchwork Mon May 10 22:29:24 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lorenzo Bianconi X-Patchwork-Id: 433443 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-19.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, INCLUDES_CR_TRAILER, INCLUDES_PATCH, MAILING_LIST_MULTI, SPF_HELO_NONE, SPF_PASS, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D9300C433ED for ; Mon, 10 May 2021 22:29:52 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 9F89761581 for ; Mon, 10 May 2021 22:29:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231289AbhEJWa4 (ORCPT ); Mon, 10 May 2021 18:30:56 -0400 Received: from mail.kernel.org ([198.145.29.99]:43178 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231281AbhEJWay (ORCPT ); Mon, 10 May 2021 18:30:54 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 1287361581; Mon, 10 May 2021 22:29:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1620685789; bh=P76/1MMWh4HZqIQTVVGkmFQftzTWoXSf7yPpB+C4i/c=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Vp2Cw6c73poizpJZe/4ErwgmMyw0krtLwE/Ee/KHNTv3dKLBqKTpNhqrhGxr3hHOl UpoA+afgMqbPJiThTPCjShqpAy2VdmZgSfNBvXBrGKd/hLbhlgZNZ/jvl03TDKJL/m yrsgWDBYtTgS6ijEMLy+WFYsBJAE6J0z+m/OjFFwAOkBx9dWo9Jv3bTloJl3zSt889 ojiNxQ0MLhJDEsudB3uDPGCm7amBgCrI3JE0325BZfdPwh9XjTv1aFOrx8fYSbfghn N72BEvlJtcSn6c/wGe8e0354DxFWtT2KiCxtrMu8e5xCkaV/bJ0tm+cX7uG/TIp2yw CUG4BSoKrSkFw== From: Lorenzo Bianconi To: nbd@nbd.name Cc: linux-wireless@vger.kernel.org, lorenzo.bianconi@redhat.com, sean.wang@mediatek.com Subject: [PATCH 5/5] mt76: mt7615: set macwork timeout according to runtime-pm Date: Tue, 11 May 2021 00:29:24 +0200 Message-Id: <7ccfbf127354bc4552fc76959a3f57e3e3c685de.1620685619.git.lorenzo@kernel.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: References: MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org Set macwork timeout value according to runtime-pm in order to reduce power consumption Signed-off-by: Lorenzo Bianconi --- .../net/wireless/mediatek/mt76/mt7615/mac.c | 15 +++++++++++---- .../net/wireless/mediatek/mt76/mt7615/main.c | 18 +++++++++++------- .../net/wireless/mediatek/mt76/mt7615/mt7615.h | 7 ++++++- .../wireless/mediatek/mt76/mt7615/pci_mac.c | 7 ++++--- 4 files changed, 32 insertions(+), 15 deletions(-) diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/mac.c b/drivers/net/wireless/mediatek/mt76/mt7615/mac.c index 12c628bb200e..afcb71699c41 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7615/mac.c +++ b/drivers/net/wireless/mediatek/mt76/mt7615/mac.c @@ -1918,9 +1918,14 @@ void mt7615_pm_wake_work(struct work_struct *work) mt76_queue_tx_cleanup(dev, mdev->q_mcu[MT_MCUQ_WM], false); } - if (test_bit(MT76_STATE_RUNNING, &mphy->state)) + + if (test_bit(MT76_STATE_RUNNING, &mphy->state)) { + unsigned long timeout; + + timeout = mt7615_get_macwork_timeout(dev); ieee80211_queue_delayed_work(mphy->hw, &mphy->mac_work, - MT7615_WATCHDOG_TIME); + timeout); + } } ieee80211_wake_queues(mphy->hw); @@ -1955,6 +1960,7 @@ void mt7615_mac_work(struct work_struct *work) { struct mt7615_phy *phy; struct mt76_phy *mphy; + unsigned long timeout; mphy = (struct mt76_phy *)container_of(work, struct mt76_phy, mac_work.work); @@ -1973,8 +1979,9 @@ void mt7615_mac_work(struct work_struct *work) mt7615_mutex_release(phy->dev); mt76_tx_status_check(mphy->dev, NULL, false); - ieee80211_queue_delayed_work(mphy->hw, &mphy->mac_work, - MT7615_WATCHDOG_TIME); + + timeout = mt7615_get_macwork_timeout(phy->dev); + ieee80211_queue_delayed_work(mphy->hw, &mphy->mac_work, timeout); } void mt7615_tx_token_put(struct mt7615_dev *dev) diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/main.c b/drivers/net/wireless/mediatek/mt76/mt7615/main.c index faae60775b16..827f19727f3c 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7615/main.c +++ b/drivers/net/wireless/mediatek/mt76/mt7615/main.c @@ -28,6 +28,7 @@ static int mt7615_start(struct ieee80211_hw *hw) { struct mt7615_dev *dev = mt7615_hw_dev(hw); struct mt7615_phy *phy = mt7615_hw_phy(hw); + unsigned long timeout; bool running; int ret; @@ -78,8 +79,8 @@ static int mt7615_start(struct ieee80211_hw *hw) set_bit(MT76_STATE_RUNNING, &phy->mt76->state); - ieee80211_queue_delayed_work(hw, &phy->mt76->mac_work, - MT7615_WATCHDOG_TIME); + timeout = mt7615_get_macwork_timeout(dev); + ieee80211_queue_delayed_work(hw, &phy->mt76->mac_work, timeout); if (!running) mt7615_mac_reset_counters(dev); @@ -352,10 +353,12 @@ int mt7615_set_channel(struct mt7615_phy *phy) mt7615_mutex_release(dev); mt76_worker_schedule(&dev->mt76.tx_worker); - if (!mt76_testmode_enabled(phy->mt76)) + if (!mt76_testmode_enabled(phy->mt76)) { + unsigned long timeout = mt7615_get_macwork_timeout(dev); + ieee80211_queue_delayed_work(phy->mt76->hw, - &phy->mt76->mac_work, - MT7615_WATCHDOG_TIME); + &phy->mt76->mac_work, timeout); + } return ret; } @@ -1200,6 +1203,7 @@ static int mt7615_resume(struct ieee80211_hw *hw) { struct mt7615_phy *phy = mt7615_hw_phy(hw); struct mt7615_dev *dev = mt7615_hw_dev(hw); + unsigned long timeout; bool running; mt7615_mutex_acquire(dev); @@ -1223,8 +1227,8 @@ static int mt7615_resume(struct ieee80211_hw *hw) mt76_connac_mcu_set_suspend_iter, phy->mt76); - ieee80211_queue_delayed_work(hw, &phy->mt76->mac_work, - MT7615_WATCHDOG_TIME); + timeout = mt7615_get_macwork_timeout(dev); + ieee80211_queue_delayed_work(hw, &phy->mt76->mac_work, timeout); mt7615_mutex_release(dev); diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/mt7615.h b/drivers/net/wireless/mediatek/mt76/mt7615/mt7615.h index 2ba86bd96a31..1e0f6a0f8c66 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7615/mt7615.h +++ b/drivers/net/wireless/mediatek/mt76/mt7615/mt7615.h @@ -20,7 +20,6 @@ MT7615_MAX_INTERFACES) #define MT7615_PM_TIMEOUT (HZ / 12) -#define MT7615_WATCHDOG_TIME (HZ / 10) #define MT7615_HW_SCAN_TIMEOUT (HZ / 10) #define MT7615_RESET_TIMEOUT (30 * HZ) #define MT7615_RATE_RETRY 2 @@ -460,6 +459,12 @@ static inline u32 mt7615_tx_mcu_int_mask(struct mt7615_dev *dev) return MT_INT_TX_DONE(dev->mt76.q_mcu[MT_MCUQ_WM]->hw_idx); } +static inline unsigned long +mt7615_get_macwork_timeout(struct mt7615_dev *dev) +{ + return dev->pm.enable ? HZ / 3 : HZ / 10; +} + void mt7615_dma_reset(struct mt7615_dev *dev); void mt7615_scan_work(struct work_struct *work); void mt7615_roc_work(struct work_struct *work); diff --git a/drivers/net/wireless/mediatek/mt76/mt7615/pci_mac.c b/drivers/net/wireless/mediatek/mt76/mt7615/pci_mac.c index cc278d8cb888..da87c02a73eb 100644 --- a/drivers/net/wireless/mediatek/mt76/mt7615/pci_mac.c +++ b/drivers/net/wireless/mediatek/mt76/mt7615/pci_mac.c @@ -268,6 +268,7 @@ void mt7615_mac_reset_work(struct work_struct *work) struct mt7615_phy *phy2; struct mt76_phy *ext_phy; struct mt7615_dev *dev; + unsigned long timeout; dev = container_of(work, struct mt7615_dev, reset_work); ext_phy = dev->mt76.phy2; @@ -345,11 +346,11 @@ void mt7615_mac_reset_work(struct work_struct *work) mt7615_mutex_release(dev); + timeout = mt7615_get_macwork_timeout(dev); ieee80211_queue_delayed_work(mt76_hw(dev), &dev->mphy.mac_work, - MT7615_WATCHDOG_TIME); + timeout); if (phy2) ieee80211_queue_delayed_work(ext_phy->hw, - &phy2->mt76->mac_work, - MT7615_WATCHDOG_TIME); + &phy2->mt76->mac_work, timeout); }