Jump to content

Roman555

Members
  • Posts

    8
  • Joined

  • Last visited

Recent Profile Visitors

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

  1. The board limits power consuption of USB devices using SY6280 chips. It sets 1.1 amper limit for a pair of USB-A connectors. Your WD Elements 25A1 draws upto 0.75A. I agree, the board and the HDD are Ok, but the power supply maybe has a poor quality https://linux-sunxi.org/File:OrangePi_pcplus_schematic_v1.1.pdf
  2. When you run compile.sh you can observe in a table "summary of kernel patches" which patches are going to apply. User patches are in the bottom of the table. Maybe you've chosen a wrong directory to put your custom patch... Also you can set userpatch folder manually. See in https://docs.armbian.com/Developer-Guide_Build-Options/ USERPATCHES_PATH option
  3. The long explanation is here Before: # dmesg ...... [ 9.606887] thermal_sys: Failed to find 'trips' node [ 9.606902] thermal_sys: Failed to find trip points for thermal-sensor id=1 [ 9.606923] sun8i-thermal 1c24c00.thermal-sensor: Failed to register sensor 1 (-EINVAL) [ 9.606938] sun8i-thermal: probe of 1c24c00.thermal-sensor failed with error -22 ...... My patch for sun8i-r40.dtsi. Yes, it's copy-paste with changing names of a cpu thermal trip point for a gpu thermal trip point. Now it's ok # ls /sys/devices/virtual/thermal/ cooling_device0 thermal_zone0 thermal_zone1 fix_gpu_thermal_zone_sun8i-r40_bananapi-m2u.patch
  4. Thank you, Gunjan Gupta! I suppose to apply the suggested overlay method someday when/if future possible updates will broke my custom fixes. P.S. I also found a solution for a broken CPU temperature sensor. I think I have to create a new topic to not mess this one
  5. Now about my current system. The improvement was done and the system works well with a USB NVME SSD (no sudden shutdowns - power is distributed from a PS via onboard SATA conn to microUSB, not via SY6280AAC or AXP221S as usual 4xUSB-A are connected). Because both kernels were from the same branch (6.1.y) I thought dts files could be exchanged. The new dtb file was converted from new dts file. # dtc -I dts -O dtb /boot/dtb/sun8i-r40-bananapi-m2-ultra.dts -o /boot/dtb/sun8i-r40-bananapi-m2-ultra.dtb # reboot I'd like to mention that the difference between both sun8i-r40-bananapi-m2-ultra.dts was significant. I don't think it could be done by hand. I attached both - old (no-microusb) and new dts files so you will be able compare them if you want. IMO, in general, installing a new compiled custom kernel from deb files is more robust way. I hope armbian's guru-s will comment it someday and suggest an easier method sun8i-r40-bananapi-m2u.dts.zip
  6. So I ejected my current microsd and inserted an old one with an old system and the new builded debs. To install: # dpkg -i <package.deb> listed in order to install linux-image-current-sunxi_23.11.0-trunk_armhf__6.1.63.deb linux-u-boot-bananapim2ultra-current_23.11.0-trunk_armhf.deb linux-dtb-current-sunxi_23.11.0-trunk_armhf__6.1.63.deb bullseye/base-files_23.11.0-trunk-11.1+deb11u8-bullseye_armhf.deb armbian-bsp-cli-bananapim2ultra-current_23.11.0-trunk_armhf.deb armbian-bsp-cli-bananapim2ultra_23.11.0-trunk_armhf.deb armbian-firmware_23.11.0-trunk_all.deb After successful rebooting I got Armbian-unofficial 23.11.0-trunk Bullseye with Linux 6.1.63-current-sunxi And you know - nothing changed - the mUSB port still didn't work. Then I decided to check a corresponding dts file (the original file was preserved) : # cp /boot/dtb/sun8i-r40-bananapi-m2-ultra.dtb{,.orig} # dtc -I dtb -O dts /boot/dtb/sun8i-r40-bananapi-m2-ultra.dtb -o /boot/dtb/sun8i-r40-bananapi-m2-ultra.dts And what I saw in /boot/dtb/sun8i-r40-bananapi-m2-ultra.dts that microUSB port was disabled: usb@1c14000 { compatible = "allwinner,sun8i-r40-ehci\0generic-ehci"; reg = <0x1c14000 0x100>; interrupts = <0x00 0x27 0x04>; clocks = <0x05 0x2f>; resets = <0x05 0x17>; phys = <0x21 0x00>; phy-names = "usb"; status = "disabled"; phandle = <0x5e>; }; usb@1c14400 { compatible = "allwinner,sun8i-r40-ohci\0generic-ohci"; reg = <0x1c14400 0x100>; interrupts = <0x00 0x28 0x04>; clocks = <0x05 0x32 0x05 0x7f>; phys = <0x21 0x00>; phy-names = "usb"; status = "disabled"; phandle = <0x5f>; }; So "disabled" was replaced with "okay" and dts was converted back into dtb : # dtc -I dts -O dtb /boot/dtb/sun8i-r40-bananapi-m2-ultra.dts -o /boot/dtb/sun8i-r40-bananapi-m2-ultra.dtb After rebooting the microUSB started working as USB Host : root@myhostname:~# lsusb Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 002 Device 002: ID 1a40:0101 Terminus Technology Inc. Hub Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 001 Device 002: ID 0bda:9210 Realtek Semiconductor Corp. RTL9210 M.2 NVME Adapter Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Now I'm going to change only the dtb file in my current system (armbian 23.8.1) and see whether it helps or not. BTW, when I ran the old system I saw CPU temp was shown (it is not in the current system) P.S. You may ask why it's all for. Because a USB NVME SSD draws a lot of power. It causes sudden shutdowns of the board. IMO the only way to solve the problem is to power a USB NVME SSD directly from a main power source (I have a good power source (PS), I measured and controlled the voltage and current during load testing and also I tried to exchange the PS but it didn't help)
  7. I managed to make the patch and placed it into build/userpatches/kernel/archive/sunxi-6.1 After that the image and debs were built. I'll test the image soon. microusb_as_usbhost_bananapi-m2u.patch
  8. Hi everyone! To cut long story short I have to make a microUSB port work as USB Host. I found out that there is a patch that will bring the port up. Last year I managed to build a full custom image for my board using armbian documentation. I've already successfully upgraded software upto Armbian 23.8.1 Bullseye with Linux 6.1.53-current-sunxi So I'm going to build custom kernel with the patch applied to arch/arm/boot/dts/sun8i-r40.dtsi https://github.com/Vutlan/linux-sunxi/commit/e0b16f86b91b5b03c4acd041aa2d45eb688378b2#diff-fb8cf9a1a0b868557516caf54f4e966b ehci0: usb@1c14000 { compatible = "allwinner,sun8i-r40-ehci", "generic-ehci"; reg = <0x01c14000 0x100>; interrupts = <GIC_SPI 39 IRQ_TYPE_LEVEL_HIGH>; clocks = <&ccu CLK_BUS_EHCI0>; resets = <&ccu RST_BUS_EHCI0>; phys = <&usbphy 0>; phy-names = "usb"; status = "disabled"; }; ohci0: usb@1c14400 { compatible = "allwinner,sun8i-r40-ohci", "generic-ohci"; reg = <0x01c14400 0x100>; interrupts = <GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>; clocks = <&ccu CLK_BUS_OHCI0>, <&ccu CLK_USB_OHCI0>; phys = <&usbphy 0>; phy-names = "usb"; status = "disabled"; }; The main question : Am I going to move in a right direction ? What I've already done: - "git pull" in armbian/build directory. Now I'm trying to build a kernel from the edge branch (because 6.1.y kernel is in the edge branch) for BananaPi M2 Ultra. During the compilation the script is trying to add RTL8811CU and ask for someone's github credentials. When I've feed it with my credentials it is answered that "remote: Support for password authentication was removed on August 13, 2021." So it's been failed. Mayby I should remove old clonned local repository and re-clone it from github again ? Although u-boot has been built successfully. But it's an earlier branch than installed - 23.02.0-trunk. What should I build at all to make microUSB port work as USB Host ? Or maybe it's possible to make necessary changes in my current configuration, isn't it ? Any suggestions are welcome P.S. I've already removed an old armbian/build folder and clonned again. Script compile.sh works well, there's no question about github credentials.
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines