Hi,
We are working on agx xavier industrial on our custom board with R35.6.1 and would like to port a non-removed ufs device(KIOXIA THGJFGT1T45BAB8).
Please see the changes below.
diff --git a/sources/hardware/nvidia/platform/t19x/galen/kernel-dts/tegra194-p2888-0001-p2822-0000.dts b/sources/hardware/nvidia/platform/t19x/galen/kernel-dts/tegra194-p2888-0001-p2822-0000.dts
index 0f8e25d0d..fa5ab59f9 100644
--- a/sources/hardware/nvidia/platform/t19x/galen/kernel-dts/tegra194-p2888-0001-p2822-0000.dts
+++ b/sources/hardware/nvidia/platform/t19x/galen/kernel-dts/tegra194-p2888-0001-p2822-0000.dts
@@ -82,6 +82,13 @@
interrupts = <TEGRA194_MAIN_GPIO(Q, 1) IRQ_TYPE_LEVEL_HIGH>, <TEGR
A194_MAIN_GPIO(P, 6) IRQ_TYPE_LEVEL_HIGH>;
};
};
+
+ ufshci@2450000 {
+ status = "okay";
+ /delete-property/ nvidia,cd-gpios;
+ };
};
We have already detected the UFS device as /dev/sda. However, the read/write speeds are much slower than those specified in the documentation (900~1000MB/s).
p@p-desktop:~$ sudo mount /dev/sda /mnt/ufs_test
p@p-desktop:~$ sudo dd if=/dev/zero of=/mnt/ufs_test/testfile.img bs=1G count=1 conv=fdatasync status=progress
1073741824 bytes (1.1 GB, 1.0 GiB) copied, 4 s, 277 MB/s
1+0 records in
1+0 records out
1073741824 bytes (1.1 GB, 1.0 GiB) copied, 25.8974 s, 41.5 MB/s
p@p-desktop:~$ sudo /sbin/sysctl -w vm.drop_caches=3
vm.drop_caches = 3
p@p-desktop:~$ sudo dd if=/mnt/ufs_test/testfile.img of=/dev/null bs=1G count=1 status=progress
1073741824 bytes (1.1 GB, 1.0 GiB) copied, 2 s, 558 MB/s
1+0 records in
1+0 records out
1073741824 bytes (1.1 GB, 1.0 GiB) copied, 1.93587 s, 555 MB/s
Is there anything I missed?
Please see the the ufs dmesg below.
p@p-desktop:~$ sudo dmesg | grep ufs
[ 7.285931] ufs_tegra 2450000.ufshci: freq-table-hz property not specified
[ 7.295209] ufs_tegra 2450000.ufshci: ufshcd_populate_vreg: Unable to find vdd-hba-supply regulator, assuming enabled
[ 7.522892] scsi host0: ufshcd
[ 7.545745] ufs_tegra 2450000.ufshci: ufshcd_print_pwr_info:[RX, TX]: gear=[1, 1], lane[1, 1], pwr[SLOWAUTO_MODE, SLOWAUTO_MODE], rate = 0
[ 7.546165] ufs_tegra 2450000.ufshci: dme-link-startup Successful
[ 7.591417] ufs_tegra 2450000.ufshci: Total device capacity is 255944818688
[ 7.591607] ufs_tegra 2450000.ufshci: Physical erase block size is 4194304
[ 7.591798] ufs_tegra 2450000.ufshci: Allocation size is 4194304
[ 7.591991] ufs_tegra 2450000.ufshci: Max lun size is 61022
[ 7.597473] ufs_tegra 2450000.ufshci: default ref_clk_freq = 0
[ 7.608743] ufs_tegra 2450000.ufshci: HS Mode RX_Gear:gear_3 TX_Gear:gear_3 RATE_B series
[ 7.620205] ufs_tegra 2450000.ufshci: ufs scrambling feature enabled
[ 7.626777] ufs_tegra 2450000.ufshci: ufshcd_print_pwr_info:[RX, TX]: gear=[3, 3], lane[1, 1], pwr[FAST MODE, FAST MODE], rate = 2
Thx
Yen







