Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Notes

  • PCIe testing using SSD:
  1. Enable Kernel configuration:

         PCIe PCIe was enabled by default in the RZ/G2 BSP. But you need to modify the kernel menuconfig to add support for NVME M.2 SDD.

Example          Example to modify kernel in yocto is:

$ bitbake -c menuconfig virtual/kernel

...

Once menuconfig appears, enable device driver for nvme support and save the changes.

Then build the kernel with new configuration.

$ bitbake linux-renesas -fc compile
$ bitbake linux-renesas -fc install
$ bitbake linux-renesas -fc deploy

Once        Once the built is done, update your kernel and device tree with newly built.

    2. Connect the SSD adapter board to RZ/G2H PCIe slot and check PCIe:

$ root@hihope-rzg2h:~# lspci
00:00.0 PCI bridge: Renesas Technology Corp. Device 0025
01:00.0 Non-Volatile memory controller: Samsung Electronics Co Ltd NVMe SSD Controller SM981/PM981/PM983
$ root@hihope-rzg2h:~# lsblk
NAME         MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
mmcblk0      179:0    0  29.7G  0 disk
`-mmcblk0p1  179:1    0  29.7G  0 part
mmcblk0boot0 179:8    0  31.5M  1 disk
mmcblk0boot1 179:16   0  31.5M  1 disk
mmcblk1      179:24   0  14.9G  0 disk
|-mmcblk1p1  179:25   0   512M  0 part
`-mmcblk1p2  179:26   0   1.8G  0 part /
nvme0n1      259:0    0 238.5G  0 disk   # recognized the NVME SSD

    3. Create a partition on the nvme to use

$ root@hihope-rzg2h:~# fdisk /dev/nvme0n1
Choose "n" to create a new partition
Choose "P" then "1" to create a new primary partition
Use defaults for the sector numbers
Then "w" to write the data to the disk

    After partition, "lsblk" command shows this:

$ root@hihope-rzg2h:~# lsblk
NAME         MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
mmcblk0      179:0    0  29.7G  0 disk
`-mmcblk0p1  179:1    0  29.7G  0 part
mmcblk0boot0 179:8    0  31.5M  1 disk
mmcblk0boot1 179:16   0  31.5M  1 disk
mmcblk1      179:24   0  14.9G  0 disk
|-mmcblk1p1  179:25   0   512M  0 part
`-mmcblk1p2  179:26   0   1.8G  0 part /
nvme0n1      259:0    0 238.5G  0 disk
`-nvme0n1p1  259:1    0 238.5G  0 part   # new partition

    4. Create the filesystem:

$ root@hihope-rzg2h:~# mkfs -t ext4 /dev/nvme0n1p1

   5. Create mount point:

$ root@hihope-rzg2h:~# mkdir /mnt/nvme
root@hihope-rzg2h:~# mount /dev/nvme0n1p1 /mnt/nvme
[  970.462102] EXT4-fs (nvme0n1p1): recovery complete
[  970.468717] EXT4-fs (nvme0n1p1): mounted filesystem with ordered data mode. Opts: (null)

   6. Create file to write/read:

$ root@hihope-rzg2h:~# touch /mnt/nvme/testfile

   7. Example Example for PCIe performance measured on PCIe Slot port of RZ/G2H, and with a Samsung NVMe SSD PM981a:

...