The purpose of this document is to provide a guide on how to enable Dual Ethernet with the GKI Development. Reference: How to enable dual ethernet on Android 11
For a better reference how to build Android i.MX image please look at the next chapter 3 Building the Android Platform for i.MX in the Android User's Guide
diff --git a/imx8m/evk_8mp/SharedBoardConfig.mk b/imx8m/evk_8mp/SharedBoardConfig.mk
index f68eb49e..3e95708e 100644
--- a/imx8m/evk_8mp/SharedBoardConfig.mk
+++ b/imx8m/evk_8mp/SharedBoardConfig.mk
@@ -82,7 +82,12 @@ BOARD_VENDOR_KERNEL_MODULES += \
$(KERNEL_OUT)/drivers/rtc/rtc-snvs.ko \
$(KERNEL_OUT)/drivers/pci/controller/dwc/pci-imx6.ko \
$(KERNEL_OUT)/drivers/net/phy/realtek.ko \
- $(KERNEL_OUT)/drivers/net/ethernet/freescale/fec.ko
+ $(KERNEL_OUT)/drivers/net/ethernet/freescale/fec.ko \
+ $(KERNEL_OUT)/drivers/net/phy/micrel.ko \
+ $(KERNEL_OUT)/drivers/net/pcs/pcs_xpcs.ko \
+ $(KERNEL_OUT)/drivers/net/ethernet/stmicro/stmmac/dwmac-imx.ko \
+ $(KERNEL_OUT)/drivers/net/ethernet/stmicro/stmmac/stmmac.ko \
+ $(KERNEL_OUT)/drivers/net/ethernet/stmicro/stmmac/stmmac-platform.ko
ifeq ($(POWERSAVE),true)
BOARD_VENDOR_KERNEL_MODULES += \
$(KERNEL_OUT)/drivers/soc/imx/lpa_ctrl.ko \
@@ -219,15 +224,12 @@ BOARD_VENDOR_RAMDISK_KERNEL_MODULES += \
$(KERNEL_OUT)/drivers/perf/fsl_imx8_ddr_perf.ko \
$(KERNEL_OUT)/drivers/cpufreq/cpufreq-dt.ko \
$(KERNEL_OUT)/drivers/cpufreq/imx-cpufreq-dt.ko \
- $(KERNEL_OUT)/drivers/media/i2c/ov5640.ko \
$(KERNEL_OUT)/drivers/staging/media/imx/imx8-capture.ko \
$(KERNEL_OUT)/drivers/staging/media/imx/imx8-isi-capture.ko \
$(KERNEL_OUT)/drivers/staging/media/imx/imx8-isi-hw.ko \
$(KERNEL_OUT)/drivers/staging/media/imx/imx8-isi-mem2mem.ko \
$(KERNEL_OUT)/drivers/staging/media/imx/imx8-mipi-csi2-sam.ko \
$(KERNEL_OUT)/drivers/dma/imx-sdma.ko \
- $(TARGET_OUT_INTERMEDIATES)/VVCAM_OBJ/basler-camera-driver-vvcam.ko \
- $(TARGET_OUT_INTERMEDIATES)/VVCAM_OBJ/os08a20.ko \
$(KERNEL_OUT)/drivers/staging/media/imx/imx8-media-dev.ko \
$(TARGET_OUT_INTERMEDIATES)/VVCAM_OBJ/vvcam-dwe.ko \
$(TARGET_OUT_INTERMEDIATES)/VVCAM_OBJ/vvcam-isp.ko \
To let the Android framework's EthernetTracker and EthernetNetworkFactory know which interfaces to manage, the framework level configure
must be overlay in device/nxp/imx8m/evk_8mp/overlay/frameworks/base/core/res/res/values/config.xml:
diff --git a/imx8m/evk_8mp/overlay/frameworks/base/core/res/res/values/config.xml b/imx8m/evk_8mp/overlay/frameworks/base/core/res/res/values/config.xml
index 298d50cc..63f6787e 100644
--- a/imx8m/evk_8mp/overlay/frameworks/base/core/res/res/values/config.xml
+++ b/imx8m/evk_8mp/overlay/frameworks/base/core/res/res/values/config.xml
@@ -22,7 +22,12 @@
<resources>
<!--For Android we support eth0 now -->
- <string translatable="false" name="config_ethernet_iface_regex">eth0</string>
+ <string translatable="false" name="config_ethernet_iface_regex">eth\\d</string>
+
+ <string-array translatable="false" name="config_ethernet_interfaces">
+ <item>eth0;12,13,14,15,16,18,19</item>
+ <item>eth1;12,13,14,15,16,18,19</item>
+ </string-array>
<!-- List of regexpressions describing the interface (if any) that represent tetherable
USB interfaces. If the device doesn't want to support tething over USB this should
--
# Change to the MY_ANDROID Directory
$ source build/envsetup.sh
$ lunch evk_8mp-userdebug
$ ./imx-make.sh -j4 2>&1 | tee build-log.txt
GKI Development
Follow and apply the next community post: Export new symbols of GKI development Android 14
Set the GKI repo
$ repo init -u https://android.googlesource.com/kernel/manifest -b common-android14-6.1
$ repo sync
$ git remote add device https://github.com/nxp-imx/linux-imx.git
$ git remote update
$ git fetch device --tags
$ git checkout android-14.0.0_1.2.0
$ cd ..
#Be sure that symbolic links are created correctly
$ ln -s ${MY_ANDROID}/vendor/nxp-opensource/verisilicon_sw_isp_vvcam verisilicon_sw_isp_vvcam
$ ln -s ${MY_ANDROID}/vendor/nxp-opensource/nxp-mwifiex nxp-mwifiex
$ BUILD_FOR_GKI=yes
$ BUILD_CONFIG=common/build.config.imx
$ tools/bazel run //common:imx_abi_update_symbol_list
tools/bazel run //common:kernel_aarch64_dist
$ cp out/kernel_aarch64/dist/boot.img ${MY_ANDROID}/vendor/nxp/fsl-proprietary/
gki/boot.img
$ cd ${MY_ANDROID}
$ TARGET_IMX_KERNEL=true make bootimage
# Change directory to the gki folder
$ cp out/kernel_aarch64/dist/system_dlkm_staging_archive.tar.gz ${MY_ANDROID}/vendor/nxp/fsl-proprietary/gki/system_dlkm_staging_archive.tar.gz
$ cd ${MY_ANDROID}/vendor/nxp/fsl-proprietary/gki
$ tar -xzf system_dlkm_staging_archive.tar.gz -C system_dlkm_staging
$ cd ${MY_ANDROID}
$ make system_dlkmimage
Regards,
Mario
Hi,
Can you please give information on why do we need to disable camera drivers to enable ethernet?
Regards.