Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp837942pxk; Wed, 9 Sep 2020 22:55:32 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxd+wQi2KOgviHwbPFyWx3jXvHWad0BAcyn9Cv52h7xnwXGpgINi0MGrR7uHPqZaOfIPXB1 X-Received: by 2002:a17:906:a00d:: with SMTP id p13mr7328185ejy.535.1599717332719; Wed, 09 Sep 2020 22:55:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599717332; cv=none; d=google.com; s=arc-20160816; b=dHvrNotf2A3v2W3bXYHnMs9h3SX/8p+len+eXNfnXiL/oycN18CcFW42n0N8U4ngH4 bpDJ1SZnWBg1aV21fcYu3tO5aChM1J9XEwfuEwbhZmUVg9WqQwpMFxHTco6FbQiijJCk 0gzdUODv/WxWUmgwpUm11VOAdmS/gCLZATLacZhmYY2B6SqNoPTvVDb/DBAeduxazzzM zO2nQAg96VNPRhnoLqAeTvnfVOVmVALCbag+yuxhEKahBcl5fInn+hZ7ic/6i9/D30Jd Jm/F0zoU5ZmRA2IEZjjidKTyRQPIW4wPSQVrC7ZcJMRj35CkHqNO5X3FI0BO/Fch8pSg Zheg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=d/1oapeqMoUX4fyEWjc4oR9/HMmOIqyxIeXpBbH5I6g=; b=dDDSe+xTzumpfySbxnR3W/6CY98pZpGb648AWT2nD0wWGJg6vPRu7v41kkjyAz1n/5 c3n9X0Yc9cKyLBXUBMNFcPOYxFs92gUHZjBErZCLFPXXXUy+qQgwzG1K7hubJMOp+zWF G5iAvaKbZ/QXppKBpP2/2hDI+sxYiNHYjVgfZknctg46uXdWGxg/FOkqHlHKXY0g45zm 1nPa/xYM21cO60RvdOLc0XSDRLxbj4qsLp7JNCBTftCIQji+I+/JwqcNKmQiKQfIHqY5 vNP3uiSjTrgke95tT615NqPWce/covWJfXB9sL0TQH3UN0AO+TVrffgAo3B4gNDIdFD6 GvPA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=casper.20170209 header.b=uOu1pQyJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cw15si2890430edb.299.2020.09.09.22.55.10; Wed, 09 Sep 2020 22:55:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=casper.20170209 header.b=uOu1pQyJ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728611AbgIJFx5 (ORCPT + 99 others); Thu, 10 Sep 2020 01:53:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60006 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726676AbgIJFve (ORCPT ); Thu, 10 Sep 2020 01:51:34 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CB852C0613ED; Wed, 9 Sep 2020 22:51:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=d/1oapeqMoUX4fyEWjc4oR9/HMmOIqyxIeXpBbH5I6g=; b=uOu1pQyJkN91O28k3NNeK+gmQF hrvf0kLD+AJr/uyZi5OXbLR3iOtsmxbT10BEvJu+V0Qs0jVvBr/CTgD4ImAAG37J8q5aDlOh2nUlM pliPvINsf86YsBNuz6MyTXIdXiVBn2zoy7xSuV/yvQzhG1sAqw3lvykveX+nL+Dvb4AwDkxCOBJIH 8pD7ovGBGDAYCzRlbRN3Z3axTJ3zvbIpOkVCnTgix8b8LiQ2wxfgeWX261plaiaAGclHU/2IpzWzB 5D+4jEUmv/3Yd5X9Ta1Sg5WDA32b142gJkiCRM9zlrkJKsL2h+6Cw8E9vVXC4Uy7TSedjMPaiL6bL xv7eJNCw==; Received: from hch by casper.infradead.org with local (Exim 4.92.3 #3 (Red Hat Linux)) id 1kGFUG-00036l-Oo; Thu, 10 Sep 2020 05:51:12 +0000 Date: Thu, 10 Sep 2020 06:51:12 +0100 From: Christoph Hellwig To: Alex Shi Cc: Anshuman Khandual , David Hildenbrand , Matthew Wilcox , Vlastimil Babka , Alexander Duyck , Andrew Morton , Baolin Wang , Russell King , Yoshinori Sato , Rich Felker , "David S. Miller" , Chris Zankel , Max Filippov , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sh@vger.kernel.org, sparclinux@vger.kernel.org, linux-xtensa@linux-xtensa.org, linux-mm@kvack.org Subject: Re: [PATCH v4 3/4] mm/pageblock: work around multiple arch's cmpxchg support issue Message-ID: <20200910055112.GA11727@infradead.org> References: <1599116482-7410-1-git-send-email-alex.shi@linux.alibaba.com> <1599116482-7410-3-git-send-email-alex.shi@linux.alibaba.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1599116482-7410-3-git-send-email-alex.shi@linux.alibaba.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by casper.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Sep 03, 2020 at 03:01:22PM +0800, Alex Shi wrote: > Armv6, sh2, sparc32 and xtensa can not do cmpxchg1, so we have to use > cmpxchg4 on it. > > Here we mark above 4 arch's NO_CMPXCHG_BYTE, and would add more if we > found. > > This is the first usages of cmpxchg flase sharing change. We'd better > check more cmpxchg usages in current kernel... I think a positive symbol, e.g. HAVE_CMPXCHG_BYTE is a lot easier to understand, and also fool-proof.