From owner-freebsd-arm@freebsd.org Wed Feb 13 21:41:10 2019 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E7D4914D8D4F for ; Wed, 13 Feb 2019 21:41:09 +0000 (UTC) (envelope-from kraileth@elderlinux.org) Received: from webmail2.omc.net (webmail2.omc.net [212.77.224.213]) by mx1.freebsd.org (Postfix) with ESMTP id 9793E75B2A for ; Wed, 13 Feb 2019 21:41:08 +0000 (UTC) (envelope-from kraileth@elderlinux.org) Received: by webmail2.omc.net (Postfix, from userid 1501) id 65D94C4380E; Wed, 13 Feb 2019 22:40:58 +0100 (CET) Received: from dyndsl-091-248-077-166.ewe-ip-backbone.de (dyndsl-091-248-077-166.ewe-ip-backbone.de [91.248.77.166]) by webmail.omc.net (Horde Framework) with HTTP; Wed, 13 Feb 2019 22:40:58 +0100 Message-ID: <20190213224058.52402wm0s4ube0ve@webmail.omc.net> Date: Wed, 13 Feb 2019 22:40:58 +0100 From: kraileth@elderlinux.org To: freebsd-arm@freebsd.org Subject: ThunderX support broken since r336520 MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: 7bit User-Agent: Internet Messaging Program (IMP) H3 (4.3.9) X-Rspamd-Queue-Id: 9793E75B2A X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of kraileth@elderlinux.org designates 212.77.224.213 as permitted sender) smtp.mailfrom=kraileth@elderlinux.org X-Spamd-Result: default: False [-2.78 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.86)[-0.862,0]; IP_SCORE(-0.00)[country: DE(-0.01)]; R_SPF_ALLOW(-0.20)[+ip4:212.77.224.0/19]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[elderlinux.org]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-0.97)[-0.968,0]; RCVD_COUNT_THREE(0.00)[3]; MX_GOOD(-0.01)[mx10.omc.net,mx11.omcnet.de]; NEURAL_HAM_SHORT(-0.64)[-0.637,0]; FROM_NO_DN(0.00)[]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; RCVD_IN_DNSWL_LOW(-0.10)[213.224.77.212.list.dnswl.org : 127.0.5.1]; R_DKIM_NA(0.00)[]; ASN(0.00)[asn:15388, ipnet:212.77.224.0/19, country:DE]; MIME_TRACE(0.00)[0:+]; RECEIVED_SPAMHAUS_PBL(0.00)[166.77.248.91.zen.spamhaus.org : 127.0.0.11] X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Feb 2019 21:41:10 -0000 Hi, Recently I got my hands on a Cavium ThunderX server for some tests before it is deployed for production. I wanted to install FreeBSD on it so I grabbed a 12.0 image and was surprised that it didn't work at all. The beastie menu is displayed, the kernel loaded - and then it just stops. As pointed out by Marcel Flores in December (https://lists.freebsd.org/pipermail/freebsd-arm/2018-December/019130.html), 11.2 does boot to the installer however. Upgrading the system to 11-STABLE worked fine, too. Building 12-STABLE or -CURRENT resulted in a kernel that wouldn't boot. I decided to find the point where ThunderX support broke in head. It's roughly 40,000 commits from the first 12-CURRENT to today. After a few nights of checking out various old revisions of HEAD and building kernels over and over again, I found out that in r336520 Emmanuel Vadot added vt_efifb to the GENERIC kernel config on arm64. According to his commit message this was tested on PINE64 hardware - but unfortunately it obviously does not work on ThunderX. To unbreak HEAD I see basically 3 options: 1) Make the EFI FB work properly on ThunderX. This would certainly be the best solution but I have no idea whatsoever how to do it. 2) Revert. Probably not a good idea since having vt_efifb included makes sense on devices where it works. Also reverting a commit from half a year ago doesn't feel right. 3) Add a THUNDERX config that builds a working kernel and live with the fact that GENERIC does not support ThunderX for the moment. I went with the following simple config for all my further tests: /usr/src/sys/arm64/conf/THUNDERX: --------------------------------- include GENERIC ident THUNDERX nodevice vt_efifb This makes -CURRENT work again. It does _not_ make 12 (-RELEASE and -STABLE) work! There's another issue with these that was fixed in HEAD after 12 was branched off. I chased the problem down, too, but: Another issue, another mail. ThunderX is a pretty interesting platform and any help in making FreeBSD run on it again is very much appreciated. Any thoughts on this? Regards, Michael