OK3568 4.19.206 Buildroot PCIe to SATA Function Modification Method

Document classification: □ Top secret □ Secret □ Internal information ■ Open

Revision History

Date

Version

Revision History

04/08/2022

V1.0

Initial Version

Method to Modify PCIe to SATA Function

Hardware Requirements

FIT-PCIE-SATA V1.0 adapter board (converts PCIe 2.0 interface to dual SATA 2.0 ports)

Image

Software Configuration

Modify Device Tree

OK3568-linux-source/kernel/arch/arm64/boot/dts/rockchip/OK3568-C-common.dtsi

Note: Red text indicates fields to be modified or manually added

Turn off pcie 2.0 function and add SATA function description

&pcie2x1 {

reset-gpios = <&gpio0 RK_PB6 GPIO_ACTIVE_HIGH>;

vpcie3v3-supply = <&vcc3v3_sys>;

status = "<font style="color:#FF0000;">disabled</font>";

};

&sata2 {

status = “okay”;

assigned-clock-rates = <24000000>;

};

Modify the default configuration file**

/OK3568-linux-source/kernel/arch/arm64/configs/OK3568-C-linux_defconfig

Add the followings:

CONFIG_ATA=y

CONFIG_SATA_AHCI=y

CONFIG_SATA_AHCI_PLATFORM=y

CONFIG_PHY_ROCKCHIP_NANENG_COMBO_PHY=y

Execute the./build. sh kernel in the/OK3568-linux-source directory.

Separately flash /OK3568-linux-source/kernel/boot.img

Test

Write data:

Image

Read data:

Image