Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1566078yba; Fri, 17 May 2019 01:09:39 -0700 (PDT) X-Google-Smtp-Source: APXvYqxLtGd8mpxf5B6Yje+GbQvh6zxLr9WlX7FD1VpEehdxqwCNfX0oG52yyWV1x5yDwfoPGs1Z X-Received: by 2002:aa7:9ac4:: with SMTP id x4mr59611477pfp.43.1558080579371; Fri, 17 May 2019 01:09:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558080579; cv=none; d=google.com; s=arc-20160816; b=VDNbkWmj7MmYN2qlMuMhJGyfVHXByOwvYjbop32VAslxz9G+iDTik6R9HG4tV5HkR/ p21t1acN5P540m8U6aJ4Sm9Zd3wpEoJ10/isWrjMsjBVzgB5fhpPRffvLLvQ9QJoZQ/y joVweKP/kKxS0EVmtcZPIHBPSH1PXDUPRSrrtsWhIGTlqZnX7AMCZrhReX/TNCO9Rw9F B2+zvwcMxFvmRIWe7QcYuIcdCWDS9uFlozwWYXigTqYlNZy7G9WF7kVqOP6dpOYA6+bt 58paPXr32Rvq50x/MPhOpYl7MrIGnGFdSNHnwgbmBf7Oz36ad20PAeQaLYTUUnZfDpWJ 1usA== 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 :dkim-signature:dkim-filter; bh=/BYTJ4zxnc9ql4xZQk+WJLrlDFM4qCpFxkd8pJzLb9c=; b=FxRWDvXxSF8qK6sLd4X8Xbo6qB/SQJi5JTw7P8jMI9dOkvgsxbEPB0yBoQhmqycNif WK7glYxxGeur3LVd98xfZpq0w7zDPj7jygInFCTV4kgOK/j4lBZw721Ny1gTfPMrYfjM bTeYCnVlIj0ZydMlvzu8F5It+81EDLa8Nt4pBlb8hj/dm2CSOq4Ohb6yNY/f0e8/1Dgn 64iPmPSjr6a3/2piM6qHPrNuwE9tCD9zJZC+G2lmHACulfmxdUjY+GoAYJVwzMDR0hkn sBDQrdyWTM1V0Zw1Uj8nBreYSCKhmXr8CGz0MGyscfC6KrzOguA6i59mqaUdZVbEvmlm p3cw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=Q2VtVae6; 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 f88si7426083plf.397.2019.05.17.01.09.24; Fri, 17 May 2019 01:09:39 -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; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=Q2VtVae6; 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 S1728112AbfEQGzL (ORCPT + 99 others); Fri, 17 May 2019 02:55:11 -0400 Received: from conuserg-12.nifty.com ([210.131.2.79]:40958 "EHLO conuserg-12.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727694AbfEQGzK (ORCPT ); Fri, 17 May 2019 02:55:10 -0400 Received: from localhost.localdomain (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-12.nifty.com with ESMTP id x4H6sQI1006236; Fri, 17 May 2019 15:54:26 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-12.nifty.com x4H6sQI1006236 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1558076066; bh=/BYTJ4zxnc9ql4xZQk+WJLrlDFM4qCpFxkd8pJzLb9c=; h=From:To:Cc:Subject:Date:From; b=Q2VtVae6Ee0HybhaWXSMg69y6q1arF8Sf/3u/XHMZTCPOpMB44H54BKHkbXrOYYN4 sTyqKSVgGlNw7oPey6yYOSC6lOjkiel9mhOBKa/MRcGpXQ1EeRKhiJD9ciFZUJU5lo qG5n3KT7Slc5xaDZohnfycTLEiaOSVGvd85a6BlWsNry0dKe4AR1DBIFR3kjMMSag7 ZEesarqfo0ZgWtXj9pt5ZSerrlX1EaZCLvJ3hArzEcceGum0qQRT0+XWSGTEGlPjId aZrU4OYTFZusbiPR43kGBDWduFx1qFAPX8BlT63J0EzHwxFepnxOG46QCvqob91ugR QTZCX5d2BYNbA== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: Martin Schwidefsky , Heiko Carstens , linux-s390@vger.kernel.org Cc: Arnd Bergmann , Laura Abbott , Masahiro Yamada , linux-kernel@vger.kernel.org, Andrew Morton Subject: [PATCH] s390: mark __cpacf_check_opcode() and cpacf_query_func() as __always_inline Date: Fri, 17 May 2019 15:54:24 +0900 Message-Id: <20190517065424.24453-1-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.17.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit e60fb8bf68d4 ("s390/cpacf: mark scpacf_query() as __always_inline") was not enough to make sure to meet the 'i' (immediate) constraint for the asm operands. With CONFIG_OPTIMIZE_INLINING enabled, Laura Abbott reported error with gcc 9.1.1: In file included from arch/s390/crypto/prng.c:29: ./arch/s390/include/asm/cpacf.h: In function 'cpacf_query_func': ./arch/s390/include/asm/cpacf.h:170:2: warning: asm operand 3 probably doesn't match constraints 170 | asm volatile( | ^~~ ./arch/s390/include/asm/cpacf.h:170:2: error: impossible constraint in 'asm' Add more __always_inline to force inlining. Fixes: 9012d011660e ("compiler: allow all arches to enable CONFIG_OPTIMIZE_INLINING") Reported-by: Laura Abbott Signed-off-by: Masahiro Yamada --- arch/s390/include/asm/cpacf.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/s390/include/asm/cpacf.h b/arch/s390/include/asm/cpacf.h index f316de40e51b..19459dfb4295 100644 --- a/arch/s390/include/asm/cpacf.h +++ b/arch/s390/include/asm/cpacf.h @@ -177,7 +177,7 @@ static inline void __cpacf_query(unsigned int opcode, cpacf_mask_t *mask) : "cc"); } -static inline int __cpacf_check_opcode(unsigned int opcode) +static __always_inline int __cpacf_check_opcode(unsigned int opcode) { switch (opcode) { case CPACF_KMAC: @@ -217,7 +217,7 @@ static inline int cpacf_test_func(cpacf_mask_t *mask, unsigned int func) return (mask->bytes[func >> 3] & (0x80 >> (func & 7))) != 0; } -static inline int cpacf_query_func(unsigned int opcode, unsigned int func) +static __always_inline int cpacf_query_func(unsigned int opcode, unsigned int func) { cpacf_mask_t mask; -- 2.17.1