Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 53668C64EC4 for ; Thu, 9 Mar 2023 07:27:17 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230122AbjCIH1P (ORCPT ); Thu, 9 Mar 2023 02:27:15 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44524 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230113AbjCIH1K (ORCPT ); Thu, 9 Mar 2023 02:27:10 -0500 Received: from mail-pj1-x102b.google.com (mail-pj1-x102b.google.com [IPv6:2607:f8b0:4864:20::102b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 70E1ADAB97; Wed, 8 Mar 2023 23:27:08 -0800 (PST) Received: by mail-pj1-x102b.google.com with SMTP id ce8-20020a17090aff0800b0023a61cff2c6so5441073pjb.0; Wed, 08 Mar 2023 23:27:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; t=1678346828; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=CJHzsaxOituYDBkxOA8H81vwLH3ZviXpLecRvt7q+4o=; b=FhiF1bkIirhXX6zU1PYQDdyHDWrRZAVxDmgaiuyVy/G5zTxdknvqDQd2qQGbFKEF8l 5pyrCJ5zPE0vQGooY0Xfz0Ac+OVH3fpkXkoBJJVBBD88eCVhRRIUBn+ENARTNH2bI3dC KVeCPVKk9hinoPfDuurpXdTOFZoT0S+7FrIICYy3nt9h33HcSm00AsqiGZD9nKaDtGpm OR1PZnp/p6+ePj5ADaRp0oHO/7WkhS4t2mjRnypLM+jUYPwJiytZQqz4foFpWXhyIWWi ebo3udUah9AJHHRd/ZUdZ30Qs/5+Rf/tqqbIRSvJ+oMF4OOL8KwOepLd3Q372C18Pc7x WDQw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; t=1678346828; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=CJHzsaxOituYDBkxOA8H81vwLH3ZviXpLecRvt7q+4o=; b=TRDnJnWxnqCYGYyKGLJnl5x3ctFYkkL/ckz6+Yw3L3mkEDMN1wdo6/JZhDGg8DnY53 O/VTS/7c/r0rMX/A3SjIBdeXigD8RKcAbfikBL0pX8MAW3UOmj7EgGYsH4fE25gs+35w K57DEWrDFv+0Uz++htpzUDhquY8+oXDRYFc+CLlEhFMcN36zS3lXitTWmXqicX6IMuUZ dF9cmMNta6R+ceDiwhMGdJyvDfRB864mezkwa3OnVK+V79YL3aLTlTVtEeqIqdNaBeHF 3VNZ6KoNsWEIkFB6qKTTosH76j9bImGQp2JXI60mWqDzKHJOEuEZ2BM4yRfYceWvw0KL mVRA== X-Gm-Message-State: AO0yUKVdUlUCHxdet5Ekw3AJ2z+xUeLjVN/vhIPU5Nw8uyU7AcdA16La Abj/juhezk+0+X7hrNPKY/RqKIMaODM3UrKMu5c= X-Google-Smtp-Source: AK7set/FlFpnQ7TXKx5oEOQ4GI/7HbhMjyIjqIVdCgszs0y16a7MjMC58+BqhJVX8tsNVesGvOBSCiL25Q3SzrH4ek8= X-Received: by 2002:a17:90a:ea0b:b0:237:5e4c:7d78 with SMTP id w11-20020a17090aea0b00b002375e4c7d78mr7669919pjy.9.1678346827909; Wed, 08 Mar 2023 23:27:07 -0800 (PST) MIME-Version: 1.0 References: <20230309035641.3439953-1-zyytlz.wz@163.com> In-Reply-To: From: Zheng Hacker Date: Thu, 9 Mar 2023 15:26:54 +0800 Message-ID: Subject: Re: [PATCH] net: calxeda: fix race condition in xgmac_remove due to unfinshed work To: Yunsheng Lin Cc: Zheng Wang , davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, 1395428693sheep@gmail.com, alex000young@gmail.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Yunsheng Lin =E4=BA=8E2023=E5=B9=B43=E6=9C=889=E6= =97=A5=E5=91=A8=E5=9B=9B 14:27=E5=86=99=E9=81=93=EF=BC=9A > > On 2023/3/9 14:23, Yunsheng Lin wrote: > > On 2023/3/9 11:56, Zheng Wang wrote: > >> In xgmac_probe, the priv->tx_timeout_work is bound with > >> xgmac_tx_timeout_work. In xgmac_remove, if there is an > >> unfinished work, there might be a race condition that > >> priv->base was written byte after iounmap it. > >> > >> Fix it by finishing the work before cleanup. > > > > This should go to net branch, so title should be: > > > > [PATCH net] net: calxeda: fix race condition in xgmac_remove due to un= finshed work > > typo error: > unfinshed -> unfinished > Got it. Will correct it in the next version of patch. Thanks, Zheng