From nobody Mon Sep 02 10:54:12 2024 X-Original-To: riscv@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 4Wy5Gz69qTz5PTZ0 for ; Mon, 02 Sep 2024 10:54:19 +0000 (UTC) (envelope-from dclarke@blastwave.org) Received: from mail.oetec.com (mail.oetec.com [108.160.241.186]) (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 ECDSA (P-256) client-digest SHA256) (Client CN "mail.oetec.com", Issuer "E5" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Wy5Gy6By2z4RCV for ; Mon, 2 Sep 2024 10:54:18 +0000 (UTC) (envelope-from dclarke@blastwave.org) Authentication-Results: mx1.freebsd.org; dkim=pass header.d=blastwave.org header.s=default header.b=c23xm5Ag; dmarc=pass (policy=quarantine) header.from=blastwave.org; spf=pass (mx1.freebsd.org: domain of dclarke@blastwave.org designates 108.160.241.186 as permitted sender) smtp.mailfrom=dclarke@blastwave.org Received: from [172.16.35.3] (pool-99-253-118-250.cpe.net.cable.rogers.com [99.253.118.250]) (authenticated bits=0) by mail.oetec.com (8.17.1/8.17.1) with ESMTPSA id 482AsCSP077927 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Mon, 2 Sep 2024 06:54:13 -0400 (EDT) (envelope-from dclarke@blastwave.org) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=blastwave.org; s=default; t=1725274454; bh=JIZVXkwl4RwccWEpVeuF5bEP0DxBmf6yIf9y+YTN7ws=; h=Date:To:From:Subject; b=c23xm5AgWtZ4HpW/JJmmqGCtS96J1vfwCDSQ8sXLOUCbfreQADpt1uGIXLf0H71NE qJwTEw6F/e6tuWJsW/xC0z5smDrPB6JYUt3Au5qhUKiec645Fu7z24ijKZKfbD6ceV BPOT9pM3fUyrdcDlk2CDFvoVxm4W8zyzqE25M0DsUPhVqS1UIDNmPPNsnEFz3JeDc4 fzViT+TFtbeeT1cT6q0RiaVVx+d9g+JZhkHt8I+o5TrUZlh9xv/cjiM7SwLwdByaLH RCPDMB+j2Q6JpMsEBnMIbzYxLYwq+2yWMhjdn0RA37IwzRibQHT8/3pK0X3VKuP8qv ftgjczxub3rEA== Message-ID: <8a58b38a-b7fb-494e-a730-e4c341aaa9ee@blastwave.org> Date: Mon, 2 Sep 2024 06:54:12 -0400 List-Id: FreeBSD on the RISC-V instruction set architecture List-Archive: https://lists.freebsd.org/archives/freebsd-riscv List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: freebsd-riscv@freebsd.org Sender: owner-freebsd-riscv@FreeBSD.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird To: riscv@FreeBSD.org Content-Language: en-CA From: Dennis Clarke Subject: kldxref: /boot/kernel/kernel: no ELF relocation table found Organization: GENUNIX Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-oetec-MailScanner-Information: Please contact the ISP for more information X-oetec-MailScanner-ID: 482AsCSP077927 X-oetec-MailScanner: Found to be clean X-oetec-MailScanner-From: dclarke@blastwave.org X-Spam-Status: No X-Spamd-Bar: ---- X-Spamd-Result: default: False [-4.69 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_SHORT(-1.00)[-0.996]; DMARC_POLICY_ALLOW(-0.50)[blastwave.org,quarantine]; RCVD_DKIM_ARC_DNSWL_MED(-0.50)[]; R_SPF_ALLOW(-0.20)[+mx:c]; RCVD_IN_DNSWL_MED(-0.20)[108.160.241.186:from]; R_DKIM_ALLOW(-0.20)[blastwave.org:s=default]; MIME_GOOD(-0.10)[text/plain]; XM_UA_NO_VERSION(0.01)[]; MIME_TRACE(0.00)[0:+]; ARC_NA(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; HAS_ORG_HEADER(0.00)[]; RCVD_TLS_ALL(0.00)[]; RCVD_COUNT_ONE(0.00)[1]; RCPT_COUNT_ONE(0.00)[1]; PREVIOUSLY_DELIVERED(0.00)[riscv@freebsd.org]; TO_DN_NONE(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; DKIM_TRACE(0.00)[blastwave.org:+]; MLMMJ_DEST(0.00)[riscv@FreeBSD.org]; RCVD_VIA_SMTP_AUTH(0.00)[]; MID_RHS_MATCH_FROM(0.00)[]; ASN(0.00)[asn:812, ipnet:108.160.240.0/20, country:CA]; FROM_HAS_DN(0.00)[] X-Rspamd-Queue-Id: 4Wy5Gy6By2z4RCV All: Ye ol "make installkernel" starts nicely but ends a little odd : e# make installkernel -------------------------------------------------------------- >>> Install check kernel -------------------------------------------------------------- -------------------------------------------------------------- >>> Installing kernel GENERIC on Mon Sep 2 10:10:05 UTC 2024 -------------------------------------------------------------- cd /usr/obj/usr/src/riscv.riscv64/sys/GENERIC; MACHINE_ARCH=riscv64 MACHINE=riscv CPUTYPE= CC="cc -target riscv64-unknown-freebsd15.0 --sysroot=/usr/obj/usr/src/riscv.riscv64/tmp -B/usr/obj/usr/src/riscv.riscv64/tmp/usr/bin" CXX="c++ -target riscv64-unknown-freebsd15.0 --sysroot=/usr/obj/usr/src/riscv.riscv64/tmp -B/usr/obj/usr/src/riscv.riscv64/tmp/usr/bin" CPP="cpp -target riscv64-unknown-freebsd15.0 --sysroot=/usr/obj/usr/src/riscv.riscv64/tmp -B/usr/obj/usr/src/riscv.riscv64/tmp/usr/bin" AS="as" AR="ar" ELFCTL="elfctl" LD="ld" LLVM_LINK="" NM=nm OBJCOPY="objcopy" RANLIB=ranlib STRINGS= SIZE="size" STRIPBIN="strip" PATH=/usr/obj/usr/src/riscv.riscv64/tmp/bin:/usr/obj/usr/src/riscv.riscv64/tmp/usr/sbin:/usr/obj/usr/src/riscv.riscv64/tmp/usr/bin:/usr/obj/usr/src/riscv.riscv64/tmp/legacy/usr/sbin:/usr/obj/usr/src/riscv.riscv64/tmp/legacy/usr/bin:/usr/obj/usr/src/riscv.riscv64/tmp/legacy/bin:/usr/obj/usr/src/riscv.riscv64/tmp/legacy/usr/libexec::/sbin:/bin:/usr/sbin:/usr/bin make KERNEL=kernel METALOG= install thiskernel=`sysctl -n kern.bootfile || echo /boot/kernel/kernel` ; if [ ! "`dirname "$thiskernel"`" -ef /boot/kernel ] ; then chflags -R noschg /boot/kernel ; rm -rf /boot/kernel ; rm -rf /usr/lib/debug/boot/kernel ; else if [ -d /boot/kernel.old ] ; then chflags -R noschg /boot/kernel.old ; rm -rf /boot/kernel.old ; fi ; mv /boot/kernel /boot/kernel.old ; if [ -n "/usr/lib/debug" -a -d /usr/lib/debug/boot/kernel ]; then rm -rf /usr/lib/debug/boot/kernel.old ; mv /usr/lib/debug/boot/kernel /usr/lib/debug/boot/kernel.old ; fi ; sysctl kern.bootfile=/boot/kernel.old/"`basename "$thiskernel"`" ; fi kern.bootfile: /boot/kernel/kernel -> /boot/kernel.old/kernel mkdir -p /boot/kernel install -p -m 444 -o root -g wheel kernel /boot/kernel/ mkdir -p /usr/lib/debug/boot/kernel install -p -m 444 -o root -g wheel kernel.debug /usr/lib/debug/boot/kernel/ cd /usr/src/sys/modules; MAKEOBJDIRPREFIX=/usr/obj/usr/src/riscv.riscv64/sys/GENERIC/modules KMODDIR=/boot/kernel MACHINE_CPUARCH=riscv MACHINE=riscv MACHINE_ARCH=riscv64 MODULES_EXTRA="dtb/sifive" WITHOUT_MODULES="" ARCH_FLAGS="" DEBUG_FLAGS="-g" __MPATH="" KERNBUILDDIR="/usr/obj/usr/src/riscv.riscv64/sys/GENERIC" SYSDIR="/usr/src/sys" MODULE_TIED=yes WITH_CTF="1" make install ===> accf_data (install) install -T release -o root -g wheel -m 444 accf_data.ko /boot/kernel/ install -T dbg -o root -g wheel -m 444 accf_data.ko.debug /usr/lib/debug/boot/kernel/ ===> accf_dns (install) install -T release -o root -g wheel -m 444 accf_dns.ko /boot/kernel/ install -T dbg -o root -g wheel -m 444 accf_dns.ko.debug /usr/lib/debug/boot/kernel/ . . . etc etc etc . . ===> xz (install) install -T release -o root -g wheel -m 444 xz.ko /boot/kernel/ install -T dbg -o root -g wheel -m 444 xz.ko.debug /usr/lib/debug/boot/kernel/ ===> zfs (install) install -T release -o root -g wheel -m 444 zfs.ko /boot/kernel/ install -T dbg -o root -g wheel -m 444 zfs.ko.debug /usr/lib/debug/boot/kernel/ ===> zlib (install) install -T release -o root -g wheel -m 444 zlib.ko /boot/kernel/ install -T dbg -o root -g wheel -m 444 zlib.ko.debug /usr/lib/debug/boot/kernel/ kldxref /boot/kernel kldxref: /boot/kernel/kernel: no ELF relocation table found -------------------------------------------------------------- >>> Installing kernel GENERIC completed on Mon Sep 2 10:13:55 UTC 2024 -------------------------------------------------------------- So then ... "no ELF relocation table found"? Looking at https://cgit.freebsd.org/src/tree/usr.sbin/kldxref/ef.c#n220 and then downwards to line 367 : if (rel_off == 0 && rela_off == 0) { warnx("%s: no ELF relocation table found\n", ef->ef_name); error = EFTYPE; goto out; } Which makes me wonder about the ( I hope ) harmless output from this : # kldxref -dv /boot/kernel /boot/kernel/accf_data.ko module accf_data depends on kernel.1500023 (1500023,1500023) interface accf_data.1 /boot/kernel/accf_dns.ko module accf_dns depends on kernel.1500023 (1500023,1500023) interface accf_dns.1 . . . /boot/kernel/kern_testfrwk.ko module kern_testframework interface kern_testframework.1 depends on kernel.1500023 (1500023,1500023) /boot/kernel/kernel kldxref: /boot/kernel/kernel: no ELF relocation table found kldxref: /boot/kernel/kernel: not a valid DSO or object file: Inappropriate file type or format /boot/kernel/kgssapi.ko module kgssapi depends on kernel.1500023 (1500023,1500023) depends on xdr.1 (1,1) depends on krpc.1 (1,1) interface kgssapi.1 . . . etc etc . . . Also I do see this was created : e# ls -lapb /boot/kernel/linker.hints -rw-r--r-- 1 root wheel 212416 Sep 2 10:13 /boot/kernel/linker.hints e# Looking over the output from "readelf -delV /boot/kernel.old/kernel" as well as this new kernel they both look very similar. Addresses and some other bits changed of course. So therefore the situation : ( 1 ) well understood and just a normal red herring[1] ( 2 ) ignore it ( 3 ) huh? that's weird. never saw that before. Curious what is going on there. -- -- Dennis Clarke RISC-V/SPARC/PPC/ARM/CISC UNIX and Linux spoken [1] see Requesting program interpreter: /red/herring :)