From owner-freebsd-arm@freebsd.org Fri Apr 28 10:18:47 2017 Return-Path: Delivered-To: freebsd-arm@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 25267D54BA4 for ; Fri, 28 Apr 2017 10:18:47 +0000 (UTC) (envelope-from otacilio.neto@bsd.com.br) Received: from mail-qk0-x229.google.com (mail-qk0-x229.google.com [IPv6:2607:f8b0:400d:c09::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id DD3011EA4 for ; Fri, 28 Apr 2017 10:18:46 +0000 (UTC) (envelope-from otacilio.neto@bsd.com.br) Received: by mail-qk0-x229.google.com with SMTP id f76so48873456qke.2 for ; Fri, 28 Apr 2017 03:18:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsd.com.br; s=capeta; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-transfer-encoding; bh=M5vxM8hfKHtw4IysItOpOYEUIK2kekZ+BMx7NwotFyU=; b=LhIgZjVe7L0H4BF13jMg7Kdhe1pEvYa9YUB4hKhbjClCorPneFKYiig/vJRpvlcjjw gPxCGVGINWM5cvcOEiasSlmsfunZVa1h44rhlkgRzWkjxDCA01aI/XN2vJGDQ5vLrIpB Q745DckNQvIbwvE+qVsVg6foFFIscCQ3NO5mo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=M5vxM8hfKHtw4IysItOpOYEUIK2kekZ+BMx7NwotFyU=; b=cEcqpG0J2sGuZ8z/ZvwU0z10saBBKRsQuij+UUemGXQntKgkUoCkHgjtoOhPDvREXz hgb9dfbq4ti0QgkyaKTD223xMoCYirJzicNsp+Z+TFjBJCkbVx1nkmUlkslVTNYIqGTM X+BoyAfDAXd4NU/8LL3iuZXG/vTVgITjJsSt7WDe5Dxc1pLTHfKUyK14yqL6usCXU8vq 8ITktzb9JN1o1HVSlvR4ouXanN7Mg+Ae7IlsjWrXRjYUmD+XwX13cB1Pxj1hPOCLdK++ sNV0ZXcZXPGzvfJCy3UyED8jmXUtZ2VIfMc9lFpi75lXIPg7mbzNfb1UKSzHlET51nm0 xkRw== X-Gm-Message-State: AN3rC/7OOv3aGe4tSRUXmthoI5/JjLCVXtxcpajZQqB+6uXMYzotkd92 X4yKcqJj5jhyZb9k X-Received: by 10.55.102.198 with SMTP id a189mr8973098qkc.249.1493374725555; Fri, 28 Apr 2017 03:18:45 -0700 (PDT) Received: from ?IPv6:2804:54:19ef:cc00:30f9:247:939:2f09? ([2804:54:19ef:cc00:30f9:247:939:2f09]) by smtp.googlemail.com with ESMTPSA id z63sm3333320qkc.6.2017.04.28.03.18.44 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 28 Apr 2017 03:18:45 -0700 (PDT) Subject: Re: FreeBSD 12-CURRENT on OrangePi One To: freebsd-arm@freebsd.org References: <8eae97a3-6f3d-2273-31fb-67627ce4bd15@paranoici.org> From: =?UTF-8?B?T3RhY8OtbGlv?= Message-ID: <3e0ebfa5-65d1-d7a0-816b-a0c72b3fe15b@bsd.com.br> Date: Fri, 28 Apr 2017 07:18:41 -0300 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0 MIME-Version: 1.0 In-Reply-To: <8eae97a3-6f3d-2273-31fb-67627ce4bd15@paranoici.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 Apr 2017 10:18:47 -0000 Em 28/04/2017 07:03, aggaz escreveu: > Dear list, > > recently I was able to build a working FreeBSD 12-CURRENT image for > OrangePi One by using crochet. > > This particular board is partially supported. It uses SoC H3 which is > supported by FreeBSD, and there is a u-boot package available in ports. > However there is no ready-made crochet-specific configuration. > > I am going to write here what I did, hoping that someone else will find > this information useful, and hoping that crochet developers are reading > this. I do not have a github account and I can not contact them on that > particular portal. > > > 1. Freebsd and crochet sources. > I am using FreeBSD 12-CURRENT and last crochet, sources of both > downloaded on April 26 2017. > > > 2. OrangePi One config > In crochet, I created a new board, called "OrangePi-One" using the > config from "OrangePi-Plus2E" as a template. > I corrected paths and a little bug on the setup.sh file, which follows: > > ========================================================================= > % cat setup.sh > KERNCONF=ALLWINNER > UBLDR_LOADADDR=0x42000000 > SUNXI_UBOOT="u-boot-orangepi-one" > SUNXI_UBOOT_BIN="u-boot.img" > IMAGE_SIZE=$((1000 * 1000 * 1000 * 2)) > TARGET_ARCH=armv6 > > UBOOT_PATH="/usr/local/share/u-boot/${SUNXI_UBOOT}" > > allwinner_partition_image ( ) { > echo "Installing U-Boot files" > dd if=${UBOOT_PATH}/u-boot-sunxi-with-spl.bin conv=notrunc,sync > of=/dev/${DISK_MD} bs=1024 seek=8 > dd if=${UBOOT_PATH}/u-boot.img conv=notrunc,sync of=/dev/${DISK_MD} > bs=1024 seek=40 > disk_partition_mbr > disk_fat_create 32m 16 1m > disk_ufs_create > } > strategy_add $PHASE_PARTITION_LWW allwinner_partition_image > > allwinner_check_uboot ( ) { > uboot_port_test ${SUNXI_UBOOT} ${SUNXI_UBOOT_BIN} > } > strategy_add $PHASE_CHECK allwinner_check_uboot > > strategy_add $PHASE_BUILD_OTHER freebsd_ubldr_build > UBLDR_LOADADDR=${UBLDR_LOADADDR} > strategy_add $PHASE_BOOT_INSTALL freebsd_ubldr_copy_ubldr . > > # BeagleBone puts the kernel on the FreeBSD UFS partition. > strategy_add $PHASE_FREEBSD_BOARD_INSTALL board_default_installkernel . > # overlay/etc/fstab mounts the FAT partition at /boot/msdos > strategy_add $PHASE_FREEBSD_BOARD_INSTALL mkdir -p boot/msdos > # ubldr help and config files go on the UFS partition (after boot dir > exists) > strategy_add $PHASE_FREEBSD_BOARD_INSTALL freebsd_ubldr_copy boot > ========================================================================= > > basically, I am using u-boot for OrangePi One from ports (line 3, 8, 12, > 13). > Line 12 was causing problems, same as described by someone else here: > https://github.com/freebsd/crochet/issues/191 > > I added the parameters "conv=notrunc,sync" and now it works. > > > 4. DTB file > There is no dtb file for OrangePi One. > In a previous attempt, by using old freebsd/crochet sources, I tried to > use the DTB file compiled for OrangePi-Plus2E. > It was working, but it took a lot to boot (I had issues with timers > apparently), and I was not able to use ethernet connection. > Then I tried the DTB from NanoPi-Neo, which is also based on H3 Soc, and > thing seems to work fine. > So now, I basically copied the DTB file /boot/dtb/nanopi-neo.dtb to > /boot/dtb/sun8i-h3-orangepi-one.dtb > > > 5. Issuses > For some reason, I can not use the GrowFS option. At boot I get errors. > The following line is continuously printed and the sistem wont boot. > ---- > vm_fault: pager read error, pid 1 (init) > ---- > I will try to grow the partition manually. > > > For the time being, this is it. > Hope this report is useful, if some developer wish to use my board and > my time to test stuff to make the support of this board more stable, I > am available for testing. > > Regards > Aggaz I'm getting exactly this same error on RPI3 and beaglebone black (vm_fault: pager read error, pid 1 (init)). And I reported here: http://freebsd.1045724.x6.nabble.com/HEAD-on-RPI3-td6181434.html The new gotcha is your report that this is related with Growfs. Thank you by your report. Now I know that my environment is clean and I'm not crazy. []'s -Otacilio