From nobody Sat Jul 1 21:19:15 2023 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 4QtlS54bKyz4lPGJ; Sat, 1 Jul 2023 21:19:17 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (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 "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4QtlS51nDXz3xpW; Sat, 1 Jul 2023 21:19:17 +0000 (UTC) (envelope-from jhb@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1688246357; h=from:from: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:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=QXuTMKvQ8dSv5/FR7CcYTXIh45ZMVPi9984Thy8OVCA=; b=CK9XaR0bg7hdvXU6pz0XvpDaKsvTMjIL6/uK48T0z5HWuh+8LbSDUL4Xs4qTxevZY1xJOA PAM75KjLruAJYHIUQeinIkJVqQ7kZUU24vu8l737suzM4MsNJkG7biZ6q7NvgrsG0JcPo2 cUpb/UnPmyNAFys8TzyuDmLuf45nuqrGG7UiTdXMNeoS5s+87YY0MErD6f270A9RDQ3l/f SlfB6uDqUvh2/l0MaDIPc+j7TnbokRoWjvXqQnIz/AJ6jF4Ej4BsZJqkCGxqomkCdqJJEv Q5m1LEQer8uspQ55AAURZJ4HlsGQvAmhVHO1bYpdjAiqJkt0imJhBALTu/qYng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1688246357; h=from:from: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:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=QXuTMKvQ8dSv5/FR7CcYTXIh45ZMVPi9984Thy8OVCA=; b=hqHCbx/h+CZUnUphZ3e41f2zR+rcxEU3sbNuq+FPAZPyxBckuNZo/WhAQY4zCe0sSNHKF5 g9ENNlHs62EH4LKeDOG5eo3u65+EEyYJQoLCek7kiPd6y4TZ6cu5kSzwHpUQBS1k01cTb7 jGZdShjasM5RQOjKdAUR379GtAEv1DQwGZkeSatHYd3GVxxY2EajSDLpCQCwIw3m0MZ3UV v2FoT17qONcKfgLVP7agEwhHHp8GmbY3FKM55ECNnQscpATPwrmbGhxguPLLavZ9y1aohq 45LCi8AkPIFuixeH0/ZGXDqzpfTAG+det8Hrrf3rL6RpNcaRLJgbgqeQlw6i6Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1688246357; a=rsa-sha256; cv=none; b=d3npU3fN7SGyHdV2gN1ehOS2rklSxIj4/ow1s7+bMhm6WfVkm3RrHz3otrKgIY4fc5Xaai g0342m7bI49Xm/6UhbNqvDO1bfxAgyKxxlMjQ17ZnWXGxlZnzS8OBs3wEWAupKPY/0n+LO MjS1TEf5Hec9S9UBBOPNTAd+twPfe5Q8Nc7t7hLMQHfJYOteY/tiIEnzcushEI+XzbsjuD VMYHVwKKU1FClH3DhBkGZ0s2iGlIR5dp8dzM8Srw+MDKfXvWOptsHA3Gp99n9GnciUeWXo rtQ/wab7+lG+wW9ojIzV4RqtGbHCNkuDNGEN9C+XCYNoYwJ2QjX8trm5Nzdv5Q== Received: from [IPV6:2601:648:8680:16b0:9018:f799:cdac:ccb1] (unknown [IPv6:2601:648:8680:16b0:9018:f799:cdac:ccb1]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: jhb) by smtp.freebsd.org (Postfix) with ESMTPSA id 4QtlS450LFz1CGn; Sat, 1 Jul 2023 21:19:16 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Message-ID: Date: Sat, 1 Jul 2023 14:19:15 -0700 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 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.12.0 Content-Language: en-US To: Jessica Clarke Cc: "src-committers@freebsd.org" , "dev-commits-src-all@freebsd.org" , "dev-commits-src-main@freebsd.org" References: <202307011923.361JNMtJ070354@gitrepo.freebsd.org> <43225A5D-CBC7-4F1E-9B28-78A5A703FB56@freebsd.org> From: John Baldwin Subject: Re: git: da3096a92d2c - main - rdrand_rng: Build with -fPIC on i386 when using GCC. In-Reply-To: <43225A5D-CBC7-4F1E-9B28-78A5A703FB56@freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-ThisMailContainsUnwantedMimeParts: N On 7/1/23 12:43 PM, Jessica Clarke wrote: > On 1 Jul 2023, at 20:23, John Baldwin wrote: >> >> The branch main has been updated by jhb: >> >> URL: https://cgit.FreeBSD.org/src/commit/?id=da3096a92d2c1c06b25613444d9b369475d50321 >> >> commit da3096a92d2c1c06b25613444d9b369475d50321 >> Author: John Baldwin >> AuthorDate: 2023-07-01 19:23:00 +0000 >> Commit: John Baldwin >> CommitDate: 2023-07-01 19:23:00 +0000 >> >> rdrand_rng: Build with -fPIC on i386 when using GCC. >> >> ld.bfd requires an R_386_PLT32 relocation for calls to ifuncs >> rather than R_386_PC32. (lld permits R_386_PC32.) > > That’s odd and doesn’t quite seem a sufficient explanation on its own? > PDEs can have IFUNCs just fine today, so why is it different for kernel > modules here? I don't know. I sort of assumed this was related to the fact that we have custom weirdness for how ifuncs work with amd64 kernel modules (though I guess that shouldn't matter for i386 since I think that's due to amd64 not using DSOs for modules?). What I do know is that ld.bfd failed to link and said it wanted -fPIC. It's also been a while since I first wrote this commit and log message and I don't recall the details of how I had come to that conclusion. Searching now I did come across this bug report for binutils which might suggest that this might actually be a difference in the assembler behavior: https://sourceware.org/bugzilla/show_bug.cgi?id=27169 -- John Baldwin