Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp1781313imm; Tue, 2 Oct 2018 13:58:53 -0700 (PDT) X-Google-Smtp-Source: ACcGV620x3vgOBj4zpeXYcFJC2ZwQFVKr83Ld6mpZkDyIZaita8uq+PrxtR9AvOfFkLdV6YwjPmg X-Received: by 2002:a62:20d8:: with SMTP id m85-v6mr18122675pfj.152.1538513933197; Tue, 02 Oct 2018 13:58:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538513933; cv=none; d=google.com; s=arc-20160816; b=J0HMn//eaYGCii15+XaCNmmr5XuMJ4XBVhTAkZXjCwgbNaILdG+4ig4tfmtgCuhHTB coa1KSnDCCoFkqcwk8ROH0Tkc1m9MheV9mAKg3uGdrG6WZuCIkwVF8ZUpOvvZFiu7h8Q SgwLj4UDIEQlWFE67wfxdjpYL4b9TYVFUihHf2SklZxf/x4fujxWM8euXWv/diDXXM2n YEqLXaSk5i05ZwO8oHCd72YGW0cZO3v6/TCZ0Ivno53ZDwKlAxNJRFBEbVCVfEaKtBVy XoaqKsMil1AQuW1S7zke549Be26GYbGGNOk6JfWYCo4A6S937FohtBXRIKsNDqTHhk5p X6cA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=wYvM2qT3LF9HtBoxz775Tsh0VKWcKSTgGjZkbkU1Tsc=; b=Dx6/l3i6sOfadZi4aph3/Sn64HvX5mXIybr5XYIP3ZAvRtlLV4I8PRcwyN/5Ho2moH g0x+NXF3zIKy4cWDZ68vzLETTCA0LBr2f0Uq4VCdDnBlJ3Qm4pxl/VcYzjBDpJAPPVI5 q8zQ7GCKuUsFaLVtmiOllyDae3y24sz9tOrq5+9tvjDcRUteRl2g3uzv5fWntOUcbxGN xMFwaY5u3TkHXAppihjtUIweeJth1ASgu0QxZX2hWmDG/Om3JnnWIZhypBwf+0nSveJ1 i5L11wqO1mn4jBkKJkfvycAc3tltQXIhXoHS41L9ZIXxN/hapijxTB31HYPXpdXOlcvd BJ2Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w134-v6si7375470pfd.55.2018.10.02.13.58.37; Tue, 02 Oct 2018 13:58:53 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727754AbeJCDnn (ORCPT + 99 others); Tue, 2 Oct 2018 23:43:43 -0400 Received: from mout.kundenserver.de ([212.227.17.10]:40189 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726572AbeJCDnn (ORCPT ); Tue, 2 Oct 2018 23:43:43 -0400 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue109 [212.227.15.145]) with ESMTPA (Nemesis) id 1N336J-1fjtXd3F7N-013Jow; Tue, 02 Oct 2018 22:58:12 +0200 Received: from wuerfel.lan ([109.193.40.16]) by mrelayeu.kundenserver.de (mreue109 [212.227.15.145]) with ESMTPA (Nemesis) id 1N336J-1fjtXd3F7N-013Jow; Tue, 02 Oct 2018 22:58:12 +0200 From: Arnd Bergmann To: Trond Myklebust Cc: Arnd Bergmann , Anna Schumaker , "J. Bruce Fields" , Jeff Layton , "David S. Miller" , Stephen Hemminger , James Ettle , linux-nfs@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] SUNRPC: use cmpxchg64() in gss_seq_send64_fetch_and_inc() Date: Tue, 2 Oct 2018 22:57:46 +0200 Message-Id: <20181002205809.2300654-1-arnd@arndb.de> X-Mailer: git-send-email 2.18.0 X-Provags-ID: V03:K1:lNyES8Q4W/wdnZs89Ag72TAXAvvZEjO3c58E63gJn5ORXq5fJFl 7q2VzekIUqco2jvxaLm6+ujxajDMqFjoc55sEVj5kODYVRvSMyZYYNitej4SS+e44GnAx1w 8XoMiqcSiPIXUIA9ziMrcYcMVt5fo2cuX8Wenwy3dHgIKp3ZQCL4dRFFcCYIm5/muzWql7m jgwNYPEDutDD9yW2LWi9w== X-UI-Out-Filterresults: notjunk:1;V01:K0:mVHGP47/Cb0=:YOQWVq148YCWBGdaCEiTdX c4GEMvdhAvlpOIPciZLv7jszxefpOMMfr3TMXQgsqXV6kuKeh1VoBj/QNE2bMtHWB8Nmd4ZQz a0B0OeDuaZf2abKzNrVGiFjf4PdlPWWngGbyWkLvEWkgKdLQjJVYTN/Lv4D+OFawvNLoi8TPB MoSqG3/Q1GQL6Bft12LKivKdm7Z4+BCT5zXqGZqcUqaBVS86/l+L8r/rnjxlDe+6GD/DnqXWY PZRCBJICs+kAkxWKGvs596olN2C7XcQzArqjMNsMY4hoSzIET7hk61SL/F5gebcbJXxE4kjSg 74FoaTdlRDUjrs7xQd8NyWn0prp/RHAB1SxItplrAhIs2ACGmIH8bZnEB5gvCY2rgqRg4eqUg 9ZTdZdbcOx033f7LHZYa63EpF76xd1zF+V8Yy5vt1BSv+Iu2euKs2nCZGC0OIPh4t2R0vvKr3 e5oyYO/DQccpZ2w4uGODab4BfKPGEEYptWTxqmdaRDnKBPqrx+nSxrimXPnMIJDXH9nnATYlp qYhfCie7rL7fLFyjC67mfGTkQhFhjjJEj6cwUiezFjGCrsFi93g1L1pdRLG2VPtQQXd2jM/vP pRA2GOls9LkLOiFl5KdN/0mptdp1V3IUZBYy1s3Ltg4ajpDFw4p0atLmoweP93rE61KShPw/x v9epkf5lGe/B35wt3TeNAIfl9+y8mtZ8FNOVU0Bwwkwp6VxG7uqCIeJjiFMvVH9tu40Q= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The newly introduced gss_seq_send64_fetch_and_inc() fails to build on 32-bit architectures: net/sunrpc/auth_gss/gss_krb5_seal.c:144:14: note: in expansion of macro 'cmpxchg' seq_send = cmpxchg(&ctx->seq_send64, old, old + 1); ^~~~~~~ arch/x86/include/asm/cmpxchg.h:128:3: error: call to '__cmpxchg_wrong_size' declared with attribute error: Bad argument size for cmpxchg __cmpxchg_wrong_size(); \ As the message tells us, cmpxchg() cannot be used on 64-bit arguments, that's what cmpxchg64() does. Fixes: 571ed1fd2390 ("SUNRPC: Replace krb5_seq_lock with a lockless scheme") Signed-off-by: Arnd Bergmann --- net/sunrpc/auth_gss/gss_krb5_seal.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/sunrpc/auth_gss/gss_krb5_seal.c b/net/sunrpc/auth_gss/gss_krb5_seal.c index 92594681d619..5775b9805bdc 100644 --- a/net/sunrpc/auth_gss/gss_krb5_seal.c +++ b/net/sunrpc/auth_gss/gss_krb5_seal.c @@ -141,7 +141,7 @@ gss_seq_send64_fetch_and_inc(struct krb5_ctx *ctx) do { old = seq_send; - seq_send = cmpxchg(&ctx->seq_send64, old, old + 1); + seq_send = cmpxchg64(&ctx->seq_send64, old, old + 1); } while (old != seq_send); return seq_send; } -- 2.18.0