From patchwork Mon Aug 8 13:59:02 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arend van Spriel X-Patchwork-Id: 1044642 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.4) with ESMTP id p78Dxt9T008503 for ; Mon, 8 Aug 2011 13:59:57 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753521Ab1HHN7y (ORCPT ); Mon, 8 Aug 2011 09:59:54 -0400 Received: from mms2.broadcom.com ([216.31.210.18]:1862 "EHLO mms2.broadcom.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753411Ab1HHN7j (ORCPT ); Mon, 8 Aug 2011 09:59:39 -0400 Received: from [10.9.200.133] by mms2.broadcom.com with ESMTP (Broadcom SMTP Relay (Email Firewall v6.3.2)); Mon, 08 Aug 2011 07:04:48 -0700 X-Server-Uuid: D3C04415-6FA8-4F2C-93C1-920E106A2031 Received: from mail-irva-13.broadcom.com (10.11.16.103) by IRVEXCHHUB02.corp.ad.broadcom.com (10.9.200.133) with Microsoft SMTP Server id 8.2.247.2; Mon, 8 Aug 2011 06:59:09 -0700 Received: from mail-sj1-12.sj.broadcom.com (mail-sj1-12.sj.broadcom.com [10.17.16.106]) by mail-irva-13.broadcom.com (Postfix) with ESMTP id AA4CF74D04; Mon, 8 Aug 2011 06:59:25 -0700 (PDT) Received: from arend-laptop (unknown [10.176.68.34]) by mail-sj1-12.sj.broadcom.com (Postfix) with ESMTP id 9EFE320512; Mon, 8 Aug 2011 06:59:20 -0700 (PDT) Received: from arend by arend-laptop with local (Exim 4.74) ( envelope-from ) id 1QqQMR-0004RF-NB; Mon, 08 Aug 2011 15:59:19 +0200 From: "Arend van Spriel" To: gregkh@suse.de cc: devel@linuxdriverproject.org, linux-wireless@vger.kernel.org, "Roland Vossen" , "Arend van Spriel" Subject: [PATCHv2 78/82] staging: brcm80211: removed watchdog function from softmac Date: Mon, 8 Aug 2011 15:59:02 +0200 Message-ID: <1312811946-16713-79-git-send-email-arend@broadcom.com> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1312811946-16713-1-git-send-email-arend@broadcom.com> References: <1312811946-16713-1-git-send-email-arend@broadcom.com> MIME-Version: 1.0 X-WSS-ID: 6221328A3W42727004-05-01 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Mon, 08 Aug 2011 13:59:58 +0000 (UTC) From: Roland Vossen Code cleanup. Watchdog function served no purpose since it had an empty body. Reviewed-by: Pieter-Paul Giesberts Signed-off-by: Arend van Spriel --- drivers/staging/brcm80211/brcmsmac/mac80211_if.c | 14 +------------- drivers/staging/brcm80211/brcmsmac/main.c | 11 ++--------- drivers/staging/brcm80211/brcmsmac/main.h | 2 -- drivers/staging/brcm80211/brcmsmac/pub.h | 5 ++--- 4 files changed, 5 insertions(+), 27 deletions(-) diff --git a/drivers/staging/brcm80211/brcmsmac/mac80211_if.c b/drivers/staging/brcm80211/brcmsmac/mac80211_if.c index 7f6a490..a4d46dd 100644 --- a/drivers/staging/brcm80211/brcmsmac/mac80211_if.c +++ b/drivers/staging/brcm80211/brcmsmac/mac80211_if.c @@ -61,8 +61,6 @@ static void _brcms_timer(struct brcms_timer *t); static int ieee_hw_init(struct ieee80211_hw *hw); static int ieee_hw_rate_init(struct ieee80211_hw *hw); -static int wl_linux_watchdog(void *ctx); - /* Flags we support */ #define MAC_FILTERS (FIF_PROMISC_IN_BSS | \ FIF_ALLMULTI | \ @@ -828,7 +826,7 @@ static struct brcms_info *brcms_attach(u16 vendor, u16 device, wl->irq = irq; /* register module */ - brcms_c_module_register(wl->pub, "linux", wl, wl_linux_watchdog, NULL); + brcms_c_module_register(wl->pub, "linux", wl, NULL); if (ieee_hw_init(hw)) { wiphy_err(wl->wiphy, "wl%d: %s: ieee_hw_init failed!\n", unit, @@ -1701,16 +1699,6 @@ void brcms_free_timer(struct brcms_info *wl, struct brcms_timer *t) } -/* - * runs in software irq context - * - * precondition: perimeter lock is not acquired - */ -static int wl_linux_watchdog(void *ctx) -{ - return 0; -} - struct firmware_hdr { u32 offset; u32 len; diff --git a/drivers/staging/brcm80211/brcmsmac/main.c b/drivers/staging/brcm80211/brcmsmac/main.c index d011ed6..bdc7fb4 100644 --- a/drivers/staging/brcm80211/brcmsmac/main.c +++ b/drivers/staging/brcm80211/brcmsmac/main.c @@ -5374,12 +5374,6 @@ static void brcms_c_watchdog(void *arg) cfg->tk_cm_bt--; END_FOREACH_BSS() - /* Call any registered watchdog handlers */ - for (i = 0; i < BRCMS_MAXMODULES; i++) { - if (wlc->modulecb[i].watchdog_fn) - wlc->modulecb[i].watchdog_fn(wlc->modulecb[i].hdl); - } - if (BRCMS_ISNPHY(wlc->band) && !wlc->pub->tempsense_disable && ((wlc->pub->now - wlc->tempsense_lasttime) >= BRCMS_TEMPSENSE_PERIOD)) { @@ -6325,8 +6319,8 @@ _brcms_c_ioctl(struct brcms_c_info *wlc, int cmd, void *arg, int len, * register watchdog and down handlers. */ int brcms_c_module_register(struct brcms_pub *pub, - const char *name, void *hdl, - int (*w_fn)(void *handle), int (*d_fn)(void *handle)) + const char *name, void *hdl, + int (*d_fn)(void *handle)) { struct brcms_c_info *wlc = (struct brcms_c_info *) pub->wlc; int i; @@ -6337,7 +6331,6 @@ int brcms_c_module_register(struct brcms_pub *pub, strncpy(wlc->modulecb[i].name, name, sizeof(wlc->modulecb[i].name) - 1); wlc->modulecb[i].hdl = hdl; - wlc->modulecb[i].watchdog_fn = w_fn; wlc->modulecb[i].down_fn = d_fn; return 0; } diff --git a/drivers/staging/brcm80211/brcmsmac/main.h b/drivers/staging/brcm80211/brcmsmac/main.h index 0fd061b..e2febe0 100644 --- a/drivers/staging/brcm80211/brcmsmac/main.h +++ b/drivers/staging/brcm80211/brcmsmac/main.h @@ -462,8 +462,6 @@ struct modulecb { const struct brcmu_iovar *iovars; /* handle passed when handler 'doiovar' is called */ void *hdl; - /* watchdog handler */ - int (*watchdog_fn)(void *handle); /* IOVar handler * diff --git a/drivers/staging/brcm80211/brcmsmac/pub.h b/drivers/staging/brcm80211/brcmsmac/pub.h index bfbb261..40efee6 100644 --- a/drivers/staging/brcm80211/brcmsmac/pub.h +++ b/drivers/staging/brcm80211/brcmsmac/pub.h @@ -614,9 +614,8 @@ extern void brcms_c_set_ps_ctrl(struct brcms_c_info *wlc); extern void brcms_c_mctrl(struct brcms_c_info *wlc, u32 mask, u32 val); extern int brcms_c_module_register(struct brcms_pub *pub, - const char *name, void *hdl, - int (*watchdog_fn)(void *handle), - int (*down_fn)(void *handle)); + const char *name, void *hdl, + int (*down_fn)(void *handle)); extern int brcms_c_module_unregister(struct brcms_pub *pub, const char *name, void *hdl);