From mboxrd@z Thu Jan 1 00:00:00 1970 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=-12.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable 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 E32A7C43460 for ; Mon, 3 May 2021 11:32:58 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id A94A8610E6 for ; Mon, 3 May 2021 11:32:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233460AbhECLdt (ORCPT ); Mon, 3 May 2021 07:33:49 -0400 Received: from mail-41104.protonmail.ch ([185.70.41.104]:29010 "EHLO mail-41104.protonmail.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233269AbhECLdr (ORCPT ); Mon, 3 May 2021 07:33:47 -0400 Received: from mail-02.mail-europe.com (mail-0201.mail-europe.com [51.77.79.158]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by mail-41104.protonmail.ch (Postfix) with ESMTPS id 4FYgg447ZRz4x77Z for ; Mon, 3 May 2021 11:27:12 +0000 (UTC) Authentication-Results: mail-41104.protonmail.ch; dkim=pass (1024-bit key) header.d=protonmail.com header.i=@protonmail.com header.b="BVuu59Gw" Date: Mon, 03 May 2021 11:27:07 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail; t=1620041228; bh=wUfkSjCJnewhMEv3u15zjzGQMHZ9P3CYFHvLSQMnJkw=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References:From; b=BVuu59GwtJgSSJzN+XMCWUq0CxCwFnMgPFzhT9K6UtvFh2nzgZlfbyYI48Q9YQfDM iz42itRXoq/QyubyA+9NDW59wP7wAFSF3ZKN06G2EcxRLCbt/bT5lF43+rrb5B1oSi u+Exg1D/bwZQj0kfA1ldPcOBKAdINncwNXA03hUY= To: Greg Kroah-Hartman From: Jari Ruusu Cc: "linux-kernel@vger.kernel.org" , "stable@vger.kernel.org" , Jiri Kosina , Kalle Valo Reply-To: Jari Ruusu Subject: Re: [PATCH 5.10 1/2] iwlwifi: Fix softirq/hardirq disabling in iwl_pcie_gen2_enqueue_hcmd() Message-ID: In-Reply-To: References: <20210430141910.473289618@linuxfoundation.org> <20210430141910.521897363@linuxfoundation.org> <608CFF6A.4BC054A3@users.sourceforge.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sunday, May 2, 2021 2:03 PM, Greg Kroah-Hartman wrote: > If you could provide backported patches to those kernels you think this > is needed to, I can take them directly. Otherwise running sed isn't > always the easiest thing to do on my end :) iwlwifi: Fix softirq/hardirq disabling in iwl_pcie_enqueue_hcmd() upstream commit 2800aadc18a64c96b051bcb7da8a7df7d505db3f, backport for linux-4.4.y (compile tested only) Signed-off-by: Jari Ruusu --- a/drivers/net/wireless/iwlwifi/pcie/tx.c +++ b/drivers/net/wireless/iwlwifi/pcie/tx.c @@ -1341,6 +1341,7 @@ static int iwl_pcie_enqueue_hcmd(struct iwl_trans *tr= ans, =09u32 cmd_pos; =09const u8 *cmddata[IWL_MAX_CMD_TBS_PER_TFD]; =09u16 cmdlen[IWL_MAX_CMD_TBS_PER_TFD]; +=09unsigned long flags2; =09if (WARN(!trans_pcie->wide_cmd_header && =09=09 group_id > IWL_ALWAYS_LONG_GROUP, @@ -1423,10 +1424,10 @@ static int iwl_pcie_enqueue_hcmd(struct iwl_trans *= trans, =09=09goto free_dup_buf; =09} -=09spin_lock_bh(&txq->lock); +=09spin_lock_irqsave(&txq->lock, flags2); =09if (iwl_queue_space(q) < ((cmd->flags & CMD_ASYNC) ? 2 : 1)) { -=09=09spin_unlock_bh(&txq->lock); +=09=09spin_unlock_irqrestore(&txq->lock, flags2); =09=09IWL_ERR(trans, "No space in command queue\n"); =09=09iwl_op_mode_cmd_queue_full(trans->op_mode); @@ -1588,7 +1589,7 @@ static int iwl_pcie_enqueue_hcmd(struct iwl_trans *tr= ans, =09spin_unlock_irqrestore(&trans_pcie->reg_lock, flags); out: -=09spin_unlock_bh(&txq->lock); +=09spin_unlock_irqrestore(&txq->lock, flags2); free_dup_buf: =09if (idx < 0) =09=09kfree(dup_buf); -- Jari Ruusu=C2=A0 4096R/8132F189 12D6 4C3A DCDA 0AA4 27BD=C2=A0 ACDF F073 3C= 80 8132 F189