From patchwork Wed Oct 9 16:15:11 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Solomon Peachy X-Patchwork-Id: 3010061 Return-Path: X-Original-To: patchwork-linux-wireless@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id AF7FABF924 for ; Wed, 9 Oct 2013 16:15:25 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 93D6920173 for ; Wed, 9 Oct 2013 16:15:24 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id CD66C2016D for ; Wed, 9 Oct 2013 16:15:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755467Ab3JIQPR (ORCPT ); Wed, 9 Oct 2013 12:15:17 -0400 Received: from 162-17-110-37-static.hfc.comcastbusiness.net ([162.17.110.37]:47151 "EHLO stuffed.shaftnet.org" rhost-flags-OK-FAIL-OK-OK) by vger.kernel.org with ESMTP id S1754467Ab3JIQPQ (ORCPT ); Wed, 9 Oct 2013 12:15:16 -0400 Received: from stuffed.shaftnet.org (localhost [127.0.0.1]) by stuffed.shaftnet.org (8.14.7/8.14.7) with ESMTP id r99GFDwt021068 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 9 Oct 2013 12:15:13 -0400 Received: (from pizza@localhost) by stuffed.shaftnet.org (8.14.7/8.14.7/Submit) id r99GFDGe021067; Wed, 9 Oct 2013 12:15:13 -0400 From: Solomon Peachy To: linux-wireless@vger.kernel.org Cc: Solomon Peachy , stable@vger.kernel.org, David Mosberger Subject: [PATCH] wireless: cw1200: acquire hwbus lock around cw1200_irq_handler() call. Date: Wed, 9 Oct 2013 12:15:11 -0400 Message-Id: <1381335311-20842-1-git-send-email-pizza@shaftnet.org> X-Mailer: git-send-email 1.8.1.4 X-Virus-Scanned: clamav-milter 0.97.8 at stuffed.shaftnet.org X-Virus-Status: Clean X-Spam-Status: No, score=-7.1 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 Sender: linux-wireless-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-wireless@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This fixes "lost interrupt" problems that occurred on SPI-based systems. cw1200_irq_handler() expects the hwbus to be locked, but on the SPI-path, that lock wasn't taken (unlike in the SDIO-path, where the generic SDIO-code takes care of acquiring the lock). Cc: stable@vger.kernel.org Signed-off-by: David Mosberger Signed-off-by: Solomon Peachy --- Please consider this for 3.12-rc if it's not too late! drivers/net/wireless/cw1200/cw1200_spi.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/wireless/cw1200/cw1200_spi.c b/drivers/net/wireless/cw1200/cw1200_spi.c index 899cad3..755a0c8 100644 --- a/drivers/net/wireless/cw1200/cw1200_spi.c +++ b/drivers/net/wireless/cw1200/cw1200_spi.c @@ -237,7 +237,9 @@ static irqreturn_t cw1200_spi_irq_handler(int irq, void *dev_id) struct hwbus_priv *self = dev_id; if (self->core) { + cw1200_spi_lock(self); cw1200_irq_handler(self->core); + cw1200_spi_unlock(self); return IRQ_HANDLED; } else { return IRQ_NONE;