Bug 235362 - Cannot boot Jetson TK1 on FreeBSD 13.0-CURRENT
Summary: Cannot boot Jetson TK1 on FreeBSD 13.0-CURRENT
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: arm (show other bugs)
Version: CURRENT
Hardware: arm Any
: --- Affects Only Me
Assignee: freebsd-arm (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-01-31 23:06 UTC by Gerald Aryeetey
Modified: 2019-08-16 19:28 UTC (History)
1 user (show)

See Also:


Attachments
Error log with printf statements showing lock state before initializing (204.99 KB, text/plain)
2019-01-31 23:06 UTC, Gerald Aryeetey
no flags Details
Original error without printf statements (2.66 KB, text/plain)
2019-01-31 23:07 UTC, Gerald Aryeetey
no flags Details
Changes to the configuration of JETSON-TK1 (to enable NFS) (1.06 KB, patch)
2019-01-31 23:07 UTC, Gerald Aryeetey
no flags Details | Diff
Make arguments used to build & install JETSON-TK1 kernel (263 bytes, text/plain)
2019-01-31 23:08 UTC, Gerald Aryeetey
no flags Details
Changes to sys/gnu/dts/arm/tegra124-jetson-tk1.dts to bypass the error (470 bytes, patch)
2019-01-31 23:09 UTC, Gerald Aryeetey
no flags Details | Diff
Error log after changing sys/gnu/dts/arm/tegra124-jetson-tk1.dts to bypass error (11.86 KB, text/plain)
2019-01-31 23:10 UTC, Gerald Aryeetey
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gerald Aryeetey 2019-01-31 23:06:35 UTC
Created attachment 201568 [details]
Error log with printf statements showing lock state before initializing

Kernel crashes during boot when booting a Jetson TK1 from NFS. Booting the kernel dies early on with "vm reserv" already initialized.

Further investigation seems to show that not all of the mutexes used in the array were initialized to zero correctly.

Using git bisect, it appears the commit that brought in the issue is base r340337 which brought in Linux devicetree specifications.
After isolating the changes to the Jetson TK1, it appears that the memory region may be too big? Using a smaller length (256MB smaller) appears to resolve the issue.
Comment 1 Gerald Aryeetey 2019-01-31 23:07:11 UTC
Created attachment 201569 [details]
Original error without printf statements
Comment 2 Gerald Aryeetey 2019-01-31 23:07:50 UTC
Created attachment 201570 [details]
Changes to the  configuration of JETSON-TK1 (to enable NFS)
Comment 3 Gerald Aryeetey 2019-01-31 23:08:30 UTC
Created attachment 201571 [details]
Make arguments used to build & install JETSON-TK1 kernel
Comment 4 Gerald Aryeetey 2019-01-31 23:09:26 UTC
Created attachment 201572 [details]
Changes to sys/gnu/dts/arm/tegra124-jetson-tk1.dts to bypass the error
Comment 5 Gerald Aryeetey 2019-01-31 23:10:59 UTC
Created attachment 201573 [details]
Error log after changing sys/gnu/dts/arm/tegra124-jetson-tk1.dts to bypass error
Comment 6 commit-hook freebsd_committer freebsd_triage 2019-02-06 06:04:32 UTC
A commit references this bug:

Author: mmel
Date: Wed Feb  6 06:03:44 UTC 2019
New revision: 343828
URL: https://svnweb.freebsd.org/changeset/base/343828

Log:
  Adapt FreeBSD specific DT stub for Jetson TK1 board to be consistent with
  update of devicetree to 4.19 in r340337.
  Our build system doesn't provide dependencies for included DTS files, so
  nobody noticed this issue for long time.

  PR:		235362
  MFC after:	1 week

Changes:
  head/sys/dts/arm/tegra124-jetson-tk1-fbsd.dts
Comment 7 Michal Meloun freebsd_committer freebsd_triage 2019-02-06 06:14:55 UTC
Fixed in r343828.
Thanks for reporting.
Comment 8 commit-hook freebsd_committer freebsd_triage 2019-08-16 19:28:03 UTC
A commit references this bug:

Author: ray
Date: Fri Aug 16 19:27:06 UTC 2019
New revision: 351133
URL: https://svnweb.freebsd.org/changeset/base/351133

Log:
  Check paddr for overflow.
  Fix panic on initialize of "vm reserv" per-superpage lock in case when RAM ends at upper boundary of address space.
  Observed on ARM32 board BPI-R2 (2GB RAM 0x80000000-0xffffffff).

  PR:		235362
  Reviewed by:	kib, markj, alc
  MFC after:	2 weeks
  Differential Revision:	https://reviews.freebsd.org/D21272

Changes:
  head/sys/vm/vm_reserv.c