From nobody Wed Aug 02 19:56:42 2023 X-Original-To: freebsd-arm@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 4RGN7w6dMLzZjw4 for ; Wed, 2 Aug 2023 19:58:20 +0000 (UTC) (envelope-from marklmi@yahoo.com) Received: from sonic317-20.consmr.mail.gq1.yahoo.com (sonic317-20.consmr.mail.gq1.yahoo.com [98.137.66.146]) (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) by mx1.freebsd.org (Postfix) with ESMTPS id 4RGN6P5NlSz3Byy for ; Wed, 2 Aug 2023 19:57:01 +0000 (UTC) (envelope-from marklmi@yahoo.com) Authentication-Results: mx1.freebsd.org; none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1691006218; bh=w+B5jJcvRIqykxajCt/60beNzfwIYV+hNzYzN1oe8GE=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From:Subject:Reply-To; b=uRrmalhuuCvMjlIks9pr/ydn5VeksYloLwXcrRIDPSZ200dWOisILC4msA9fQhCDE55DsSO4q4c/LneedL66fEkHjm8HwVR+8kedtuqkxtoQjfVbWqTkH8GFZIfbes8KT/ELr1dEDWoS+oiKoH8gy1CF2U1IRqog9ODhOKPJhqp72VPO3YlDrgoxKrikkas/kJqep+N+7EwOQCdk5D+RqHs7X0HeTcYQqQIrihSmVcgr0wElL01mI6zlD4i3rwe0KFi4Q+VVdhqivHUoDQnrTFRcQDDys/0/xldb/gjr8t/tfcvSWMt+mTHUspQ5GB6BPLjH+1zPJOp3JT/XQ51VtA== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1691006218; bh=WRmhcgsctJa0GPaNPjtWiyCGYi4s1i0AL7jY4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UwvdRSiYZEjLWquaMAG3X6OMfD029CXsaB9PjDbews c929LmgRpUY_0uxPTQTKQKVlpbLxy6B0JDYAxaSUjmTkbJ43YxSz8TOVma0L0adT_j4dNsmN8c3v KiFsZNWPTyM059KAm3FDVYUPuTYimjNqRD7AftCnNAekZVgs3kYOURsIwH65X1Qma2dPCwSBhCCK 1o60cGMkAs9pR3shy1J6GlWnsr.rH3MqYaEuj5aJhNnaJh3kmCcRjLRKFuf7Wo8AMIuRoprBFiUm yVXPtEy.pTJf4fCynpff1bewhv0Xu7WbwrgNGTHnih6vH7z6pAmcYw1cyDveosmhQQrTzB9b013w g_sJf6gXt_y21JUyh8nsJl7M.wQeFqVXNeLFwuOfHG5ILYH8NFSK5_v9JOepPl4o58T.dc7Pg.Rn pxTzLkgG8QXXgH2sDtCGNKYunf0B7pKd.rKKCVkNlLPCqW40phSMw_c7PHwjxvjiNEG67FH_RIAM yUqw_zGCBEHa75ddh_PWjdVDWcJYqo6CgLejggJmKEvC7BoYUZDwJz2e3SUydqnBmJslqvalwQQ- - X-Sonic-MF: X-Sonic-ID: edde3f38-98c4-4707-81dc-6d9df92b8e6f Received: from sonic.gate.mail.ne1.yahoo.com by sonic317.consmr.mail.gq1.yahoo.com with HTTP; Wed, 2 Aug 2023 19:56:58 +0000 Received: by hermes--production-gq1-7d844d8954-qb9gk (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID bbcd901997ee516ccc08a927d0ce0448; Wed, 02 Aug 2023 19:56:53 +0000 (UTC) Content-Type: text/plain; charset=us-ascii List-Id: Porting FreeBSD to ARM processors List-Archive: https://lists.freebsd.org/archives/freebsd-arm List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-arm@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3731.700.6\)) Subject: Re: sys/modules/Makefile and MACHINE_ARCH vs arm64 (in use) vs aarch64 (not in use) VS. man arch; also COMPAT_FREEBSD32_ENABLED use From: Mark Millard In-Reply-To: Date: Wed, 2 Aug 2023 12:56:42 -0700 Cc: Current FreeBSD , FreeBSD ARM List Content-Transfer-Encoding: quoted-printable Message-Id: <2B0FE8B1-5E53-4E70-9792-15A8E423CA33@yahoo.com> References: To: Warner Losh X-Mailer: Apple Mail (2.3731.700.6) X-Rspamd-Queue-Id: 4RGN6P5NlSz3Byy X-Spamd-Bar: ---- X-Rspamd-Pre-Result: action=no action; module=replies; Message is reply to one we originated X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:36647, ipnet:98.137.64.0/20, country:US] On Aug 2, 2023, at 11:16, Warner Losh wrote: > Those all look wrong to me. >=20 > Warner=20 >=20 > On Wed, Aug 2, 2023, 11:27 AM Mark Millard wrote: > man arch reports: >=20 > MACHINE MACHINE_CPUARCH MACHINE_ARCH > arm64 aarch64 aarch64 > . . . > arm arm armv6, armv7 >=20 > So I'd not expect arm64 in MACHINE_ARCH . But > sys/modules/Makefile has (from a grep for MACHINE_ARCH): >=20 > .if ${MACHINE_ARCH} =3D=3D "amd64" || ${MACHINE_ARCH} =3D=3D "arm64" > .if ${MACHINE_ARCH} =3D=3D "amd64" || ${MACHINE_ARCH} =3D=3D "arm64" = || ${MACHINE_ARCH:Mpowerpc64*} >=20 >=20 > Another issue may be that COMPAT_FREEBSD32_ENABLED is only > put to use in the Makefile for MACHINE_CPUARCH being i386 > or amd64 : >=20 > .if ${MACHINE_CPUARCH} =3D=3D "i386" || ${MACHINE_CPUARCH} =3D=3D = "amd64" > _agp=3D agp > .if ${MACHINE_CPUARCH} =3D=3D "i386" || = !empty(COMPAT_FREEBSD32_ENABLED) > . . . I'll note that, for example, i386 vs. armv7 do not match for some struct md_ioctl field offsets and the overall size. Mike Karels is looking at getting struct md_ioctl32 correctly matching each of of the contexts: i386, (32-bit) powerpc, and armv7. I do not know if there are other COMPAT_FREEBSD32 adjustments needed for differences in memory layout across the 3 (i386, powerpc, armv7). md_ioctl I learned about via kyua test runs and looking at the background for some things it reported for armv7. I've not found a clear indication of what is expected to work for chroot/lib32 vs. what is not expected to work. It seems one must look in the code and see if one finds conditional material based, in part, on COMPAT_FREEBSD32. It might also be that COMPAT_FREEBSD32 for i386 vs. armv7 vs. powerpc might not be intending identical coverage for all I know. So seeing COMPAT_FREEBSD32 might not be enough to know the intent. =3D=3D=3D Mark Millard marklmi at yahoo.com