LINUX kernel porting and NIC driver additions

Source: Internet
Author: User

I use the board is Sama5d3xek, the original board core is linux-at91-3.13, upgrade use linux-at91-4.10

First go to the official website to download a linux-at91-4.10 compressed package, and then unzip in Ubuntu, into the source file directory, I use the ARM board so change makefile

The following VI Makefile

The ARCH? = $ (Subarch)

Cross_compile = $ (config_cross_compile: "%" =%)

Change to ARCH? = Arm

Cross_compile? = arm-linux-

And then save the exit

View Arch/arm/configs/sama5_defconfig

Enter command make Arch=arm sama5_defconfig

Kernel-related configuration in input make Arch=arm menuconfig (maximize the window when configuring)

The kernel compiles the Make-j4 arch=arm and generates the Zimage

If you want Uimage to execute (no load address)

loadaddr=0x20008000

Export LOADADDR

Make Arch=arm Uimage

There is a load address directly make Arch=arm Uimag

Compiling device tree

Make Arch=arm Dtbs.

Eventually get Zimage uimage and sama5d3*. DtB

Ⅱ NIC driver Add-on

What I need here is 1000M dp83867 network card driver, found that linux4.3 above version has his network card driver,

A decisive transplant, dp83867. C and ti-dp83867.h files and then kernel configuration, there was an error,

Put the 4.3 kernel phy. h in the

Static inline bool Phy_interface_is_rgmii (struct Phy_device *phydev)
{
return phydev->interface >= phy_interface_mode_rgmii &&
Phydev->interface <= Phy_interface_mode_rgmii_txid;
}; Copy to 4.10, change makefile and Kconfig files

Reconfigure the compiled kernel, OK

LINUX kernel porting and NIC driver additions

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.