From nobody Wed Dec 08 22:26:43 2021 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id F273B18CB0AE; Wed, 8 Dec 2021 22:26:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (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-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4J8Wwz56cQz4YVB; Wed, 8 Dec 2021 22:26:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (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 mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 8FF091B61D; Wed, 8 Dec 2021 22:26:43 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 1B8MQhkf005010; Wed, 8 Dec 2021 22:26:43 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 1B8MQhEP005009; Wed, 8 Dec 2021 22:26:43 GMT (envelope-from git) Date: Wed, 8 Dec 2021 22:26:43 GMT Message-Id: <202112082226.1B8MQhEP005009@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: John Baldwin Subject: git: a6765c4b449d - main - libmd: Only define SHA256_Transform_c when using the ARM64 ifunc. List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jhb X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: a6765c4b449d79c6ee24dd7c37deb2239f6281a4 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1639002403; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=De88L2uoj6fGEeOwZKnTM0v8Px/Bftkm4yyVcZMr3m4=; b=mfxEspn5qvgaln/dkSdeJjVmMDx8l+w2ZaGhUZB4n25yF87SmXogRe+eHz7UZL1NXt0l99 mhb2/vZDT+y9YhEhlw1/4LfUWcGHEriRax5vKCahHvHgZH5I2DRLdgzm4soAcf1JWo1WCu SbMqi99OmbMtb6iE07D0lExi+ajLZDDj8gWTRfDcFalwoHlENSD4GuJDZy/J0GUohyI2FD qokUE/J5QQ49+SSEhoXxOQdTZbSu2iwG/L0ZBnEHzNYVEaNYEHRQeu3hoxESIjxwRAzWmw S9Nm5kEUYqjMAtKr0I1EWe80xRkW4VUJPzx3AdIcw9nTbyCFjcbKfM/V7cejzQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1639002403; a=rsa-sha256; cv=none; b=C9IPRAdTWcx3tXp4F8Km8CubR+0QLiQ+6DbwuUOFuT5BJ9W8CX/DgzXNAK7TMcL61XIh0t XKaYldqM0+ZHAarFYuZbM6vGz6U3AxaccUB1NXoz6Pd5pNQHZRwSpaqiLQbRHJS8Cf5esU ucolyzxoVVoVPEwfoaGy2LW76S4vJVmgTfJ39JdahcyFFL93U0uskiIGrQ/RoVOOLHzWVK srv/GULhtAu+wE+1o7GRyciUq1l7Fpc28V/kF5s26R3u3PC20GcvbOMj5FZsjr6H1Yrdfk BRFe6n1H6jyUjxmpKJZ6XGVuBLaLthIguQTmWCQrmGel0FaC4gLtf0QxobBQyQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=a6765c4b449d79c6ee24dd7c37deb2239f6281a4 commit a6765c4b449d79c6ee24dd7c37deb2239f6281a4 Author: John Baldwin AuthorDate: 2021-12-08 22:25:02 +0000 Commit: John Baldwin CommitDate: 2021-12-08 22:25:02 +0000 libmd: Only define SHA256_Transform_c when using the ARM64 ifunc. GCC 9 doesn't define a SHA256_Transform symbol when the stub just wraps SHA256_Transform_c resulting in an undefined symbol for _libmd_SHA256_Transform in libmd.so. Discussed with: andrew, jrtc27 Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D31945 --- sys/crypto/sha2/sha256c.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/sys/crypto/sha2/sha256c.c b/sys/crypto/sha2/sha256c.c index 63805c97a4bb..57ae9e7a6ab3 100644 --- a/sys/crypto/sha2/sha256c.c +++ b/sys/crypto/sha2/sha256c.c @@ -138,7 +138,11 @@ static const uint32_t K[64] = { * the 512-bit input block to produce a new state. */ static void +#if defined(ARM64_SHA2) SHA256_Transform_c(uint32_t * state, const unsigned char block[64]) +#else +SHA256_Transform(uint32_t * state, const unsigned char block[64]) +#endif { uint32_t W[64]; uint32_t S[8]; @@ -213,12 +217,6 @@ DEFINE_UIFUNC(static, void, SHA256_Transform, return (SHA256_Transform_c); } -#else -static void -SHA256_Transform(uint32_t * state, const unsigned char block[64]) -{ - SHA256_Transform_c(state, block); -} #endif static unsigned char PAD[64] = {