Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp3340157rwb; Tue, 16 Aug 2022 00:41:10 -0700 (PDT) X-Google-Smtp-Source: AA6agR4mUsYjh8jgc/fxkOo/oAQdaS12ComesL87HNUSd3MXQQXUOK0aR9OQOMzdCd6CP0T0L74J X-Received: by 2002:a17:90a:6fc5:b0:1f5:553:2d42 with SMTP id e63-20020a17090a6fc500b001f505532d42mr21879042pjk.176.1660635670151; Tue, 16 Aug 2022 00:41:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660635670; cv=none; d=google.com; s=arc-20160816; b=loa4gwMFDByYJoAdly2ItJ69EE50tY6EWFVcwJg82LUUfjgeqxqlDFg0YatsElNymt woEAykOejIxKE4ytbc2v4c9g2+EWPWbrGtTPdT6ERPNZoZ8lTRFZmccdRoGZkPr9bIL5 KYzkPFXgoGEbq/b+ZGVR/APL2nAbs2GBmetfRrqoL6DObKY99e680f+Hw7pFS2Y5FeNu ebGoPT6Lq5F5VLYYqfRl+VGC+WhBXarvVFWz5lnDy+EoH5tXs92Yt9jkNxbamlM03c/o VcfDd8kadNjhUUpDCyHin7KWr/UypTsvjgGLLL6V/PiMWdi2Mq/tlbIauQ7Ep+U4w+OY RcqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :message-id:subject:cc:to:from:date; bh=zBecofI2qf14zoEIMX0eYHF+ck3U7nfAZBmYT9Z2uNs=; b=LUkFy44rdVleTIk37D00KiXd6hXyTPr18YlyaWtDVAcjw4A0QTqJiuHPwBFlCB0VmI axTNchMdmfXThGusGgeQsDSuu0Dv+mhHxNqQO8XLVNx8iVP+DaZfXHrEx5tPsjr7CKDs HRCdgW1iG3iFQGlrf3Ltk6Hiehv2+K4uenlGbC/Jh4r8nxOZELm9u+qsWuK6ZCJXUnX1 V4HEvWhFQBWECGav8jzTkEUpZ1up4JcYv7k4lJEromKjh0tP47lx/uJM9gJ0b1QXxESR bnpNdTYYnMy2rC0K1xAmWpPHeOSo64cDhKutuVktgaiW4rjbh25KamN0QWemnC3yNewd Ub7Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 85-20020a630158000000b0042291471f0esi12508367pgb.434.2022.08.16.00.40.58; Tue, 16 Aug 2022 00:41:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229710AbiHPHfL (ORCPT + 99 others); Tue, 16 Aug 2022 03:35:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46782 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232246AbiHPHee (ORCPT ); Tue, 16 Aug 2022 03:34:34 -0400 Received: from fornost.hmeau.com (helcar.hmeau.com [216.24.177.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 448F1D476E; Mon, 15 Aug 2022 21:16:00 -0700 (PDT) Received: from gwarestrin.arnor.me.apana.org.au ([192.168.103.7]) by fornost.hmeau.com with smtp (Exim 4.94.2 #2 (Debian)) id 1oNnzO-00BTJq-2W; Tue, 16 Aug 2022 14:15:39 +1000 Received: by gwarestrin.arnor.me.apana.org.au (sSMTP sendmail emulation); Tue, 16 Aug 2022 12:15:38 +0800 Date: Tue, 16 Aug 2022 12:15:38 +0800 From: Herbert Xu To: Tejun Heo , Linus Torvalds Cc: marcan@marcan.st, will@kernel.org, peterz@infradead.org, jirislaby@kernel.org, maz@kernel.org, mark.rutland@arm.com, boqun.feng@gmail.com, catalin.marinas@arm.com, oneukum@suse.com, roman.penyaev@profitbricks.com, asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org Subject: Re: [PATCH] workqueue: Fix memory ordering race in queue_work*() Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Newsgroups: apana.lists.os.linux.kernel X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Tejun Heo wrote: > > Oh, tricky one and yeah you're absolutely right that it makes no sense to > not guarantee barrier semantics when already pending. I didn't even know > test_and_set_bit() wasn't a barrier when it failed. Thanks a lot for hunting > down and fixing this. Applied to wq/for-6.0-fixes. Please revert this as test_and_set_bit was always supposed to be a full memory barrier. This is an arch bug. Cheers, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt