From nobody Thu Nov 25 19:44:17 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 5DD9118AAEEE; Thu, 25 Nov 2021 19:44:18 +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 4J0SxZ00Lcz3H2c; Thu, 25 Nov 2021 19:44:18 +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 CF69F233CC; Thu, 25 Nov 2021 19:44:17 +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 1APJiHcN008052; Thu, 25 Nov 2021 19:44:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 1APJiHrf008051; Thu, 25 Nov 2021 19:44:17 GMT (envelope-from git) Date: Thu, 25 Nov 2021 19:44:17 GMT Message-Id: <202111251944.1APJiHrf008051@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Leandro Lupori Subject: git: e141b62d2088 - main - powerpc64le: fix boot when using QEMU PowerNV 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: luporl X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: e141b62d208867fc5bdb5803d05f5496260722ac Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1637869458; 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=wvy21LgeJ4vtioCBny/g6ukTPi0JNEEScpNTNRS5lgc=; b=rrc4/BlPNotmIS+hc/M5dcHTCm8XoYGryaPuw0r7gu4+nzu/iG7/3nuMuiF29RcGNIocRs jp9UqnQzVlIEhLefGQVUFdHIP87HZnYgjxP0Ha/A1Ey+Qphr7lXub+iiF7fXwOrcHLnbzd 9iJKAeLVPIgUTEDhy6ArrPeNZkLXiwKfslKAw1Ry5y/5E+6KWv0c0ZMH2FcjT3wqjBeqnd k/NCWdcjmkOilauWGyD0y89PuBQUngF0oGkQO7NwEqnzwstTr0HJo7WuTugyyndr0+sVqg 7z4cntslSDjYDLy/c0pilf++Paevur9pJLmuk0a65oKQztpzDGpRxngaGFQIlg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1637869458; a=rsa-sha256; cv=none; b=Zui1o3/hk/e8J8csoEIzo5LEjvCqDpkl3hHEMLuLfv393qnu1IuDQfpB7r/zBYYPMfBzPs EsGfvwlQ6kHZM1nqUrhV/wyh9AVIoNsbE68JPz6nRdgIiHrgK4YZ7CzDsyqK0u80Z/CHcL KMXfTscArqTXB7jzE+bEhpwRroBngZvo1e9fG8EldP8DHkJOFQHawCQJqvjVgZn39/Z01p Y7EnaRNgGLc+sD5VCmgM6/mcL1JwiaEVa9Bat5nJZrAMYryYCeBdbceeY9OemJGZcU72Ay 7zFnr4isWgIZ2RQToS5UMQlCIJJNy69gk6hMwRhtEER7zfO5IJ06zpfBVHTnvQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by luporl: URL: https://cgit.FreeBSD.org/src/commit/?id=e141b62d208867fc5bdb5803d05f5496260722ac commit e141b62d208867fc5bdb5803d05f5496260722ac Author: Leandro Lupori AuthorDate: 2021-11-25 19:41:46 +0000 Commit: Leandro Lupori CommitDate: 2021-11-25 19:41:46 +0000 powerpc64le: fix boot when using QEMU PowerNV When using QEMU PowerNV with latest op-build release (v2.7), its kexec transfers control to FreeBSD kernel in BE mode, causing an instant exception on LE kernels. Make kboot able to detect and swap endian to fix this. Reviewed by: imp Sponsored by: Instituto de Pesquisas Eldorado (eldorado.org.br) Differential Revision: https://reviews.freebsd.org/D33104 --- sys/powerpc/aim/locore64.S | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/powerpc/aim/locore64.S b/sys/powerpc/aim/locore64.S index f0a183c4b331..3eb6e546399c 100644 --- a/sys/powerpc/aim/locore64.S +++ b/sys/powerpc/aim/locore64.S @@ -82,6 +82,9 @@ TOC_ENTRY(trapstk) */ .section ".text.kboot", "x", @progbits kbootentry: +#ifdef __LITTLE_ENDIAN__ + RETURN_TO_NATIVE_ENDIAN +#endif b __start . = kbootentry + 0x40 /* Magic address used in platform layer */ .global smp_spin_sem