Message ID | 20230515080553.979680310@infradead.org (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 90940C77B75 for <linux-mm@archiver.kernel.org>; Mon, 15 May 2023 08:06:54 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id DA84A900003; Mon, 15 May 2023 04:06:52 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id D0B95280001; Mon, 15 May 2023 04:06:52 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 9898A900003; Mon, 15 May 2023 04:06:52 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 6FE10900002 for <linux-mm@kvack.org>; Mon, 15 May 2023 04:06:52 -0400 (EDT) Received: from smtpin18.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id 340D51A1366 for <linux-mm@kvack.org>; Mon, 15 May 2023 08:06:52 +0000 (UTC) X-FDA: 80791758264.18.6235D50 Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) by imf18.hostedemail.com (Postfix) with ESMTP id 2D1A91C0007 for <linux-mm@kvack.org>; Mon, 15 May 2023 08:06:49 +0000 (UTC) Authentication-Results: imf18.hostedemail.com; dkim=pass header.d=infradead.org header.s=desiato.20200630 header.b="mfr/Lee6"; spf=none (imf18.hostedemail.com: domain of peterz@infradead.org has no SPF policy when checking 90.155.92.199) smtp.mailfrom=peterz@infradead.org; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1684138010; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding:in-reply-to: references:references:dkim-signature; bh=gp7OCKaBYjIIkPcuPMybL+ixdp/AdwhFq0MWXNBGUCo=; b=WuYuxdDGcD0HzcH2ME8DhnRDYHMP5+6L6tnsjAQe2umnK4hHyroKXHruMVZQgqQFLIUBGl wNaVg+u4zqW4bI34nohHUEz5STgJU8gkDAhD9CuUdj5c65ypDzbN6s27cTGsjXUSh/1iyA QKHPbMjDD2Tw4ixdega/SZ88rW52zJQ= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1684138010; a=rsa-sha256; cv=none; b=LmIwFvnsDBF49g5Qsgwi6rD7ZVvprRvkJa8DyqZTFDxEpAnqMc371KkFRkQyCU4VWFat+T lUvWbn3JWG4rkrLPchrYJcIbD/KVAYLPUJLFngdgqQodsjKuIZSR48Z1PKZWrGWxR+G75F k6swpQBx3NnrH17Rpgz+2x6fdWZdst8= ARC-Authentication-Results: i=1; imf18.hostedemail.com; dkim=pass header.d=infradead.org header.s=desiato.20200630 header.b="mfr/Lee6"; spf=none (imf18.hostedemail.com: domain of peterz@infradead.org has no SPF policy when checking 90.155.92.199) smtp.mailfrom=peterz@infradead.org; dmarc=none DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Content-Type:MIME-Version:References: Subject:Cc:To:From:Date:Message-ID:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:In-Reply-To; bh=gp7OCKaBYjIIkPcuPMybL+ixdp/AdwhFq0MWXNBGUCo=; b=mfr/Lee6q6wb3hW9VLMJP6RMas nTl9Qe1+9Iu48xOQT4aXYKIo3YdHu4pVixS6ep5klWjn2Hleinv1VLcJZJw+35Dak53xO4M9X9KIK FpMiCIIAsi7/QgdKTHO+THopVLnjgnmza7zDZfiP5yT3vka2IQVSR4N/m/pdNqYPnTzsA8lIVgWqD P5m3mwC26ExmfD/meFO5f1ezwrEtuIohzrkIWoLo3mQANg3Hx3wLE8RBN4yr9HOkOwiYyEuNQ3/1W PLL/LI+1uLThBRAeCCPMwP+WHJ7vOYl/0orY1PoeN18xp4Y80oyboD7BypdwlKtzQ00oQnrhgh54F yIuqhB5w==; Received: from j130084.upc-j.chello.nl ([24.132.130.84] helo=noisy.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.96 #2 (Red Hat Linux)) id 1pyTDk-00BQMy-1T; Mon, 15 May 2023 08:06:16 +0000 Received: from hirez.programming.kicks-ass.net (hirez.programming.kicks-ass.net [192.168.1.225]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by noisy.programming.kicks-ass.net (Postfix) with ESMTPS id 0C5C8300786; Mon, 15 May 2023 10:06:10 +0200 (CEST) Received: by hirez.programming.kicks-ass.net (Postfix, from userid 0) id AB37F202674A5; Mon, 15 May 2023 10:06:10 +0200 (CEST) Message-ID: <20230515080553.979680310@infradead.org> User-Agent: quilt/0.66 Date: Mon, 15 May 2023 09:57:00 +0200 From: Peter Zijlstra <peterz@infradead.org> To: torvalds@linux-foundation.org Cc: corbet@lwn.net, will@kernel.org, peterz@infradead.org, boqun.feng@gmail.com, mark.rutland@arm.com, catalin.marinas@arm.com, dennis@kernel.org, tj@kernel.org, cl@linux.com, hca@linux.ibm.com, gor@linux.ibm.com, agordeev@linux.ibm.com, borntraeger@linux.ibm.com, svens@linux.ibm.com, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com, x86@kernel.org, hpa@zytor.com, joro@8bytes.org, suravee.suthikulpanit@amd.com, robin.murphy@arm.com, dwmw2@infradead.org, baolu.lu@linux.intel.com, Arnd Bergmann <arnd@arndb.de>, Herbert Xu <herbert@gondor.apana.org.au>, davem@davemloft.net, penberg@kernel.org, rientjes@google.com, iamjoonsoo.kim@lge.com, Andrew Morton <akpm@linux-foundation.org>, vbabka@suse.cz, roman.gushchin@linux.dev, 42.hyeyoo@gmail.com, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-s390@vger.kernel.org, iommu@lists.linux.dev, linux-arch@vger.kernel.org, linux-crypto@vger.kernel.org Subject: [PATCH v3 01/11] cyrpto/b128ops: Remove struct u128 References: <20230515075659.118447996@infradead.org> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Rspamd-Queue-Id: 2D1A91C0007 X-Rspam-User: X-Rspamd-Server: rspam06 X-Stat-Signature: 1qpanabfwa5939f5ctg6g3ott8nuyxxq X-HE-Tag: 1684138009-756905 X-HE-Meta: U2FsdGVkX1+gVGd4UfjJMea6iqm+f+aSYPLYhVd1aSIiU2UD4ORtpxzOMM9Xlh8JEWDPaPoCdB7/1e7sFTIQ+f+wTmj5N6E9llB9mNDttqbA2GC0Mu5NBOZZ5s+MCOGeLkvIjxvRVg3pK/5KLXY8W8GPzAVtuttICKJam6BYMpXe1IUdjkgupEjRBNko2TEpt07nyTyB/UWZKN4Vjy40af0kTEpSgGglo/jM9XElJgCn9B9UiTDx1XbPD39479d52iNgi4I6TyDhzEBKQPR+wx/SrsUxykixtKeZ3sUXmBbbJet8zy3CZ7jGlmVoTfep7cJv58/Og3sog05T3E2Uil6qSpSi7xELtk7uke7r5jI69SsFEjajK8GME1HiKS+NUU45D2uKwZ8tq2PG8OUuq4XvpXIwjm8vDZWq6iFmIEkBj61qaQP/CdV2BFSj/tLMho2P5n/iRNOTwpSrHJ39m7VsZHfPp2EWFOnjJF+FCsF7634Fo4VyIVFH2OwOAxjFCWaAj7riUC8ZP0Vt3WWG84Ot4XIUPwWpWrzL8sz8qyFLxARP32NC3qYNksRVhsGkV1zXvJpkV6gQn5YLSzXb/tQQ1z6nNiFATGNFcv6KcwiOowKLEzuW1zQxAxbWEvZivkQCNDf2Puq7ICHsp/nq2PiQ+SEW+osKFt7HyHP0PBX3G7GfIJhLiaycXvkO2u1vNHIOa5FB2kkhJldLTGcfSsWNiweqgqMu5BnJiOQ+1bsxxjDzshw2S65/ACAogiZu5E5+ZVW5ZFJeUnokcVh1zlg/w2Q/fxEHQ2Q1bo7X76FMxLvFdYZluarVexBq/G+miMvXHea2HqhJFYYVxFlTjmuNze8z11nS9R8TPfQJKmUeOM+PBw+ihC009Z6Gz//O+HYURM62vi/ehGQ729/8WA/Y6/zM4i2riqZ213ZxM1wT8Gbk7/4h9CNDAZxqCNlzt4PWEMsJpP572FY91gp zxmS4IyM H6NR4MTk6TzBCs0mwjho7DHkYjfw12xj6oFlAkujOV99fVuIAX+48jAdwYJe+SMamVDIMlzCfn5xy7lWevlKsfJu7FwpOTSo0praqWkqmnGZn6lg6BtMUKHw5nWoW+Ik67CbwzfGu01XrAZfcGEzcCWC+z30qlcfCdU5LwMyDgo/+5FQFx2Cn0+3vJmT9tIII9ANx2tZmRo685v4WqAbi579UFRk4vZuMMpeXTV4yhY69fxFj+M6MBBfNpG7unwtAK970VisKVnf7opWJ93axYFIRh/TnwCCb5v5ceZT/v//rNnAFYAFWvsYUUCvPX6v0RjkZL8PerhKzupMGUiuMsmFW+FMKr1zJnDVfTIBe9qEAizwmzGLTZ4Ztes6fClsocbzj5jylPksSckkdBKGx8zz/AQ== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> |
Series |
Introduce cmpxchg128() -- aka. the demise of cmpxchg_double()
|
expand
|
--- a/include/crypto/b128ops.h +++ b/include/crypto/b128ops.h @@ -50,10 +50,6 @@ #include <linux/types.h> typedef struct { - u64 a, b; -} u128; - -typedef struct { __be64 a, b; } be128; @@ -61,20 +57,16 @@ typedef struct { __le64 b, a; } le128; -static inline void u128_xor(u128 *r, const u128 *p, const u128 *q) +static inline void be128_xor(be128 *r, const be128 *p, const be128 *q) { r->a = p->a ^ q->a; r->b = p->b ^ q->b; } -static inline void be128_xor(be128 *r, const be128 *p, const be128 *q) -{ - u128_xor((u128 *)r, (u128 *)p, (u128 *)q); -} - static inline void le128_xor(le128 *r, const le128 *p, const le128 *q) { - u128_xor((u128 *)r, (u128 *)p, (u128 *)q); + r->a = p->a ^ q->a; + r->b = p->b ^ q->b; } #endif /* _CRYPTO_B128OPS_H */