Jump to content

wahaha

Members
  • Content Count

    47
  • Joined

  • Last visited

  • Days Won

    4

wahaha last won the day on April 16 2023

wahaha had the most liked content!

Community Reputation

4 Neutral

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. hi @DaveWK, I managed to resolve this with ideas about your post. you'll have to rebuild idbloader, uboot, kernel. and put them in the correct sector location. # Partition format to follow | Partition No. | Name | Sector Start | Sector End | Size | Comments | |---------------|-----------|--------------|------------|-------|--------------------------| | - | idbloader | 64 | 16383 | | first stage boot loader | | 1 | uboot | 16384 | 24575 | 4mb | second stage boot loader | | 2 | trust | 24576 | 32767 | 4mb | linux / android trust | | 3 | misc | 32768 | 40959 | 4mb | for misc inputs | | 4 | boot | 40960 | 172031 | 64mb | linux kernel boot | | 5 | userdata | 172032 | 303103 | 64mb | for kernel boot elements | | 6 | rootfs | 303104 | ~ | ~ | core linux OS | Then use dd command to extract out fedora rootfs from .raw file into an image file (similar to what you have done above) Note: when compiling uboot, you'll need to amend the hardcoded section where it looks for rootfs. see this: here Finally, use dd to write them all in. and it'll boot up perfectly!
  2. Hi @tooz, Ah okay. Because I see that within uboot `make menuconfig`, there is [*] Enable boot arguements () Boot arguements Even if I specify the location within `Boot arguements` by part-UUID to tell it which partition ramfs is located at It won't work? Thank you
  3. I am trying to load initramfs into a dedicated partition, instead of packaging it together with kernel. My understanding is that I will need to define the location within uboot (so that it can be loaded into memory together with kernel as 2 separate objects). Within the kernel i will then need to make this change: General setup ---> () Initramfs source file(s) [*] Support initial ramdisk/ramfs compressed using gzip [ ] Support initial ramdisk/ramfs compressed using bzip2 [ ] Support initial ramdisk/ramfs compressed using LZMA [ ] Support initial ramdisk/ramfs compressed using XZ [ ] Support initial ramdisk/ramfs compressed using LZO [ ] Support initial ramdisk/ramfs compressed using LZ4 My question is, within `uboot`, how do i specify that i have placed the `initramfs.cpio.gz` file into partition 5 of my SD Card?
  4. I am trying to view the uboot and boot messages on the tinkerboard 2s as it boots up, but it is failing to print out the message to computer terminal (via screen). I have connected the cables to gpio pins 6, 8, 10. (gnd, uart0_tx, uart0_rx) as per image below. from there, i plug it into the computer and used the below code to get the usb device that it is connected to sudo dmesg | grep tty Result : [21875.686247] cdc_acm 1-4:1.0: ttyACM0: USB ACM device From there, I used: sudo screen /dev/ttyACM0 115200` to launch screen with baud rate of 115200.. But there is no output on the screen. Not sure what is wrong? is Uart enabled by default?
  5. @tooz, okay, last question for this topic - is the below method correct in creating the idbloader.img? ``` tools/mkimage -n rk3399 -T rksd -d /home/rkbin/bin/rk33/rk3399_ddr_800MHz_v1.30.bin idbloader.img cat /home/rkbin/bin/rk33/rk3399_miniloader_v1.30.bin >> idbloader.img ``` This was from the rockchip site i linked at the start of the thread. If i'm wrong, how is idbloader.img created please?
  6. @tooz, can you confirm if i actually need `idbloader.img`? correct me if i'm wrong, but it seems like `idbloader.img` has been packed together with `uboot.img` when i run `make tinker_board_2_defconfig` -> which generates uboot.img and trust.img If that's the case, which partition / sector should be be `dd` into?
  7. Hey @tooz, Am I correct that the partition should be like this? # Create a new partition table and partitions sudo parted -s /dev/sdb mklabel gpt # Primary GPT and MBR partitions are implicit in GPT and need not be created separately sudo parted /dev/sdb unit s mkpart idbloader 64 7167 # loader1 (PartNum in GPT: 1) sudo parted /dev/sdb unit s mkpart uboot 16384 24575 # loader2 (PartNum in GPT: 2) sudo parted /dev/sdb unit s mkpart trust 24576 32767 # trust (PartNum in GPT: 3) sudo parted /dev/sdb unit s mkpart boot 32768 262143 # boot (PartNum in GPT: 4) sudo parted /dev/sdb set 4 boot on sudo parted /dev/sdb unit s mkpart rootfs ext4 262144 16777182 # rootfs (PartNum in GPT: 5) sudo parted /dev/sdb print followed by: sudo dd if=idbloader.img of=/dev/sdb1 status=progress sudo dd if=uboot.img of=/dev/sdb2 status=progress sudo dd if=trust.img of=/dev/sdb3 status=progress sudo dd if=boot.img of=/dev/sdb4 status=progress sudo dd if=rootfs.img of=/dev/sdb5 status=progress sync
  8. i was referring to rockchip's boot guide on how to boot into RK3399 here. They mentioned to follow this flow (i am using miniloader approach to SD Card): As such, I went to Asus github page to pull `rkbin`, `u-boot`, and `kernel` to build. I have successfully build the uboot with: ``` ./make.sh tinker_board_2 CROSS_COMPILE=aarch64-linux-gnu- ``` -> which generates uboot.img, trust.img and rk3399_loader_v1.30.128.bin. I then created the IDBLoader image with: ``` tools/mkimage -n rk3399 -T rksd -d /home/rkbin/bin/rk33/rk3399_ddr_800MHz_v1.30.bin idbloader.img cat /home/rkbin/bin/rk33/rk3399_miniloader_v1.30.bin >> idbloader.img ``` Kernel is straightforward as per the other posts: ``` make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- tinker_board_2_defconfig make ARCH=arm64 CROSS_COMPILE=aarch64-linux-gnu- rk3399-tinker_board_2.img -j16 ``` After that I created rootfs with this guide. So I have all the required images: idbloader.img, uboot.img, trust.img, boot.img, rootfs.img. However, when I put them all together based on rockchip's docs, I am still not able to boot into screen. Any ideas what is wrong? I don't think it's even getting into the boot section because there is no green light once I put power in.
  9. Hi @tooz, I've successfully ran ./make.sh tinker_board_2 CROSS_COMPILE=/path/to/rockchip-linux-prebuilts-gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu/bin/aarch64-none-linux-gnu- I noticed that in the make.sh file, it says -> board built okay, there are uboot/trust/loader images in current directory. From this below image, I understand that uboot and trust image can be written into the sd card via the sudo dd command. Curious, what do I need the loader that was created also? I also understand that boot is the kernel. But what about misc, recovery, backup? How do they get generated?
  10. Also, I am cross_compiling it on my desktop pc (so not directly on the arm64 tinkerboard).
  11. hi @tooz, I get met with the error: ./make.sh tinker_board_2 CROSS_COMPILE=/home/rockchip-linux-prebuilts-gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu/bin/aarch64-none-linux-gnu- grep: .config: No such file or directory grep: .config: No such file or directory ## make tinker_board_2_defconfig -j24 HOSTCC scripts/basic/fixdep HOSTCC scripts/kconfig/conf.o SHIPPED scripts/kconfig/zconf.tab.c SHIPPED scripts/kconfig/zconf.lex.c SHIPPED scripts/kconfig/zconf.hash.c HOSTCC scripts/kconfig/zconf.tab.o In file included from scripts/kconfig/zconf.tab.c:2470: In function 'dep_stack_insert', inlined from 'sym_check_print_recursive' at scripts/kconfig/symbol.c:1123:3, inlined from 'sym_check_deps' at scripts/kconfig/symbol.c:1300:3: scripts/kconfig/symbol.c:1099:19: warning: storing the address of local variable 'cv_stack' in 'check_top' [-Wdangling-pointer=] 1099 | check_top = stack; | ~~~~~~~~~~^~~~~~~ scripts/kconfig/symbol.c: In function 'sym_check_deps': scripts/kconfig/symbol.c:1120:26: note: 'cv_stack' declared here 1120 | struct dep_stack cv_stack; | ^~~~~~~~ scripts/kconfig/symbol.c:1090:4: note: 'check_top' declared here 1090 | } *check_top; | ^~~~~~~~~ HOSTLD scripts/kconfig/conf # # configuration written to .config # make: /home/rockchip-linux-prebuilts-gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu/bin/aarch64-none-linux-gnu-gcc: No such file or directory /bin/sh: /home/rockchip-linux-prebuilts-gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu/bin/aarch64-none-linux-gnu-gcc: not found BusyBox v1.36.1 (2024-05-21 13:38:37 UTC) multi-call binary. Usage: dirname FILENAME Strip non-directory suffix from FILENAME scripts/kconfig/conf --silentoldconfig Kconfig CHK include/config.h UPD include/config.h CFG u-boot.cfg /bin/sh: /home/rockchip-linux-prebuilts-gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu/bin/aarch64-none-linux-gnu-gcc: not found GEN include/autoconf.mk.dep /bin/sh: /home/rockchip-linux-prebuilts-gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu/bin/aarch64-none-linux-gnu-gcc: not found make[1]: *** [scripts/Makefile.autoconf:79: u-boot.cfg] Error 1 make[1]: *** Waiting for unfinished jobs.... CFG spl/u-boot.cfg make[1]: *** [scripts/Makefile.autoconf:50: include/autoconf.mk.dep] Error 1 CFG tpl/u-boot.cfg /bin/sh: /home/rockchip-linux-prebuilts-gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu/bin/aarch64-none-linux-gnu-gcc: not found /bin/sh: /home/rockchip-linux-prebuilts-gcc-arm-10.3-2021.07-x86_64-aarch64-none-linux-gnu/bin/aarch64-none-linux-gnu-gcc: not found make[1]: *** [scripts/Makefile.autoconf:83: spl/u-boot.cfg] Error 1 make[1]: *** [scripts/Makefile.autoconf:87: tpl/u-boot.cfg] Error 1 make: *** No rule to make target 'include/config/auto.conf', needed by 'include/config/uboot.release'. Stop. Am I missing something?
  12. Hi @tooz, Sorry I missed your reply..! I was revisiting this again, but i don't see where ./build.sh is. I cloned https://github.com/TinkerBoard-Linux/rockchip-linux-u-boot which is for kernel 5.10 uboot it seems. but can't seem to build the uboot. 2nd qns: the guide you posted above is purely to build the uboot right? I still have to build the kernel separately, and the OS image? Can you share how the OS image can also be flashed onto the sdcard please? Thank you,
  13. hello. for anyone who is still looking for this, its here: https://github.com/TinkerBoard-Linux. You need to go into repositories and look for the relevant items: rockchip-linux-u-boot | rockchip-linux-kernel |
  14. FYI - I am trying to install Fedora server on the tinkerboard 2s. not debian.
  15. hi dave. i came across this because i'm also interested in doing the same. (but fedeora server instead). any luck to get this to work? the asus engineers just came out with kernel 5.10 in Oct 2023.
×
×
  • Create New...