From patchwork Thu Nov 6 07:53:25 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Oleksij Rempel X-Patchwork-Id: 5239671 Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 7F2699F8B3 for ; Thu, 6 Nov 2014 07:54:27 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9A87E2011E for ; Thu, 6 Nov 2014 07:54:26 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id AB3D520117 for ; Thu, 6 Nov 2014 07:54:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751895AbaKFHyR (ORCPT ); Thu, 6 Nov 2014 02:54:17 -0500 Received: from mout.gmx.net ([212.227.15.15]:57589 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751330AbaKFHyP (ORCPT ); Thu, 6 Nov 2014 02:54:15 -0500 Received: from ultralex.lan ([79.222.212.193]) by mail.gmx.com (mrgmx003) with ESMTPSA (Nemesis) id 0MU1MP-1XdFLv1nAv-00Qlcv; Thu, 06 Nov 2014 08:54:10 +0100 From: Oleksij Rempel To: ath9k-devel@qca.qualcomm.com, sujith@msujith.org, nbd@openwrt.org, patro@cs.wisc.edu, linville@tuxdriver.com, linux-wireless@vger.kernel.org Cc: Oleksij Rempel Subject: [PATCH 08/21] ath9k: add ath_ps_ops bindings Date: Thu, 6 Nov 2014 08:53:25 +0100 Message-Id: <1415260418-14321-9-git-send-email-linux@rempel-privat.de> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1415260418-14321-1-git-send-email-linux@rempel-privat.de> References: <1415260418-14321-1-git-send-email-linux@rempel-privat.de> X-Provags-ID: V03:K0:A3Wol+4CiGfe4YeQdbrO3U/fiBd2rB6W3mV822ba5GahT37U1n1 P2LklERf05zM+BKh9rLM6QTJxHn1usawBnsnLQ0GwAp76dc1LrFipIZELAU0iX2us33LKqD us0YzNmCrljm+qMSGd5x0mOWHh/xM0zjYbzC0LnTSqrulaT/dmQnr/HeMwPimgjl1XRcZL4 VRgwjpcNqQiuFdT09voZA== X-UI-Out-Filterresults: notjunk:1; Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Oleksij Rempel --- drivers/net/wireless/ath/ath9k/init.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/drivers/net/wireless/ath/ath9k/init.c b/drivers/net/wireless/ath/ath9k/init.c index fe811b3..61232d0 100644 --- a/drivers/net/wireless/ath/ath9k/init.c +++ b/drivers/net/wireless/ath/ath9k/init.c @@ -88,6 +88,21 @@ static const struct ieee80211_tpt_blink ath9k_tpt_blink[] = { static void ath9k_deinit_softc(struct ath_softc *sc); +void ath9k_op_ps_wakeup(struct ath_common *common) +{ + ath9k_ps_wakeup((struct ath_softc *) common->priv); +} + +void ath9k_op_ps_restore(struct ath_common *common) +{ + ath9k_ps_restore((struct ath_softc *) common->priv); +} + +struct ath_ps_ops ath9k_ps_ops = { + .wakeup = ath9k_op_ps_wakeup, + .restore = ath9k_op_ps_restore, +}; + /* * Read and write, they both share the same lock. We do this to serialize * reads and writes on Atheros 802.11n PCI devices only. This is required @@ -540,6 +555,7 @@ static int ath9k_init_softc(u16 devid, struct ath_softc *sc, common->ops = &ah->reg_ops; common->bus_ops = bus_ops; + common->ps_ops = &ath9k_ps_ops; common->ah = ah; common->hw = sc->hw; common->priv = sc;