ko/lib/Cropping
1. File¶
Table 1-1: Introduction to files with suffix .so
Name | Size(KB) | Use | Whether it is necessary |
---|---|---|---|
lib/ld-uClibc-1.0.31.so | 20.9 | Standard library used by toolchain | YES |
lib/libncurses.so.6.0 | 183.3 | Standard library used by toolchain | YES |
lib/libstdc++.so.6.0.20 | 619.5 | Standard library used by toolchain | If APP does not use C++, it is not necessary |
lib/libthread_db-1.0.31.so | 17.1 | Standard library used by toolchain | NO |
lib/libgcc_s.so.1 | 93.6 | Standard library used by toolchain | YES |
lib/libuClibc-1.0.31.so | 349.9 | Standard library used by toolchain | YES |
lib/libatomic.so.1.1.0 | 13.3 | Standard library used by toolchain | YES |
lib/libAEC_LINUX.so | 65.8 | Audio algorithm library: echo cancellation | NO |
lib/libAED_LINUX.so | 112.1 | Audio algorithm library: babycry, high decibel detection | NO |
lib/libAPC_LINUX.so | 90.7 | Audio algorithm library: EQ, NR, HPF, AGC | If the audio function is not used, it is not necessary |
lib/libBF_LINUX.so | 70.9 | Audio algorithm library: beamforming. | NO |
lib/libMD_LINUX.so | 442.4 | Run detection algorithm | NO |
lib/libOD_LINUX.so | 430.4 | Occlusion detection algorithm | NO |
lib/libSRC_LINUX.so | 30.0 | Audio algorithm library: re-sampling | NO |
lib/libSSL_LINUX.so | 30.2 | Audio algorithm library: sound source positioning. | NO |
lib/libVG_LINUX.so | 69.7 | Virtual fence detection algorithm | NO |
lib/libcam_fs_wrapper.so | 5.4 | The middle layer of sys module and linux API | YES |
lib/libcam_os_wrapper.so | 33.8 | The middle layer of sys module and linux API | YES |
lib/libcus3a.so | 17.4 | AF/AE/AWB interface | YES |
lib/libg711.so | 5.4 | Audio encoding library | NO |
lib/libg726.so | 9.2 | Audio encoding library | NO |
lib/libispalgo.so | 225.2 | Provide ISP advanced functions, such as AF/AE/AWB | YES |
lib/libmi_ai.so | 251.2 | Audio input related library | If the audio function is not used, it is not necessary |
lib/libmi_ao.so | 82.9 | Audio output related library | If the audio function is not used, it is not necessary |
lib/libmi_common.so | 41.7 | MI essential basic library | YES |
lib/libmi_divp.so | 5.3 | Interface of multimedia module and DIVP function | YES |
lib/libmi_iqserver.so | 66.4 | Communicate with iqtool, provide the function of network debugging iq, and connect with ISP module | NO |
lib/libmi_iqserver_pretzel.so | 42.0 | Communicate with iqtool, 335 and 337 are not supported | NO |
lib/libmi_isp.so | 42.4 | ISP function interface package library | YES |
lib/libmi_isp_pretzel.so | 38.0 | ISP function interface package library, 335 and 337 are not supported | NO |
lib/libmi_ive.so | 454.6 | Provide the use of hardware operators | If the IVE operator and the SIGMASTAR MD/OD/VG algorithm are not used, it is not necessary |
lib/libmi_ldc.so | 9.4 | Lens distortion correction function interface, 335 and 337 are not supported | NO |
lib/libmi_rgn.so | 9.4 | OSD function interface | YES |
lib/libmi_sed.so | 13.3 | smart encoder | NO |
lib/libmi_sensor.so | 9.3 | Interface of multimedia module and SENSOR function | YES |
lib/libmi_shadow.so | 13.4 | Provide VDF docking interface | It is necessary when use SIGMASTAR MD/OD/VG algorithm |
lib/libmi_sys.so | 17.4 | MI essential basic library, responsible for building the basic MI framework and providing buf management | YES |
lib/libmi_vdf.so | 85.6 | Provide video algorithm functions, including movement monitoring, occlusion detection, virtual fence, etc. | It is necessary when use SIGMASTAR MD/OD/VG algorithm |
lib/libmi_venc.so | 25.4 | Interface of multimedia module and VENC function, providing video decoding function | YES |
lib/libmi_vif.so | 9.3 | Interface of multimedia module and VIF function | YES |
lib/libmi_vpe.so | 13.4 | Interface of multimedia module and VPE function | YES |
4166KB |
表1-2: Introduction to files with suffix .ko
Name | Size(KB) | Use | Whether it is necessary |
---|---|---|---|
/config/modules/4.9.84/SC4238_MIPI.ko | 19.9 | SC4238 sensor driver | NO |
/config/modules/4.9.84/imx291_MIPI.ko | 10.3 | imx291 sensor driver | NO |
/config/modules/4.9.84/imx307_MIPI.ko | 19.6 | imx307 sensor driver | NO |
/config/modules/4.9.84/mhal.ko | 1228.8 | bottom layer implementation of multimedia layer | YES |
/config/modules/4.9.84/mi_ai.ko | 170.1 | Implementation of audio acquisition module | If the audio function is not used, it is not necessary |
/config/modules/4.9.84/mi_ao.ko | 91.9 | Implementation of audio output module | If the audio function is not used, it is not necessary |
/config/modules/4.9.84/mi_common.ko | 9.7 | Implementation of MI essential basic library | YES |
/config/modules/4.9.84/mi_divp.ko | 52.8 | Implementation of multimedia and DIVP module | YES |
/config/modules/4.9.84/mi_ldc.ko | 7.6 | Implementation of lens distortion correction,335 and 337 are not supported | NO |
/config/modules/4.9.84/mi_rgn.ko | 92.1 | Implementation of OSD module | YES |
/config/modules/4.9.84/mi_sensor.ko | 29.6 | Implementation of multimedia and sensor module | YES |
/config/modules/4.9.84/mi_shadow.ko | 46.8 | Implementation of VDF docking interface | It is necessary when use SIGMASTAR MD/OD/VG algorithm |
/config/modules/4.9.84/mi_sys.ko It needs to add specified parameters in the path where config_tool and mmap.ini are located | 414.4 | Implementation of MI essential basic library, responsible for building the basic MI framework and providing buf management | YES |
/config/modules/4.9.84/mi_venc.ko It needs to add specified parameters in the path where the chagall.bin firmware is located | 165.0 | 多媒体 VENC模块的实现 | YES |
/config/modules/4.9.84/mi_vif.ko | 40.7 | Implementation of multimedia and VIF module | YES |
/config/modules/4.9.84/mi_vpe.ko | 143.9 | Implementation of multimedia and VPE module | YES |
/config/modules/4.9.84/mmc_block.ko | 28.9 | SD card related driver, mmc basic driver | NO |
/config/modules/4.9.84/mmc_core.ko | 95.2 | SD card related driver, mmc basic driver | NO |
/config/modules/4.9.84/ms_notify.ko | 4.1 | netlink, only needs to be loaded when running mixer | NO |
/config/modules/4.9.84/msdos.ko | 9.8 | MSDOS file system | NO |
/config/modules/4.9.84/nfs.ko | 123.0 | NFS | NO |
/config/modules/4.9.84/nfsv2.ko | 16.9 | NFS | NO |
/config/modules/4.9.84/nls_utf8.ko | 3.6 | utf8 font driver | NO |
/config/modules/4.9.84/ntfs.ko | 87.0 | NTFS file system driver | NO |
/config/modules/4.9.84/sc4236_MIPI.ko | 12.7 | SC4236 sensor driver | NO |
/config/modules/4.9.84/scsi_mod.ko | 118.2 | USB and SD card drivers | NO |
/config/modules/4.9.84/sd_mod.ko | 30.5 | SD card related driver, scsi interface disk support | NO |
/config/modules/4.9.84/sunrpc.ko | 173.6 | It is used in the RPC protocol for remote command execution and is used by NFS | NO |
/config/modules/4.9.84/usb-common.ko | 5.5 | USB basic driver | NO |
/config/modules/4.9.84/usb-storage.ko | 68.4 | USB driver (rely on usb basic driver) | NO |
/config/modules/4.9.84/usbcore.ko | 144.3 | USB host basic driver | NO |
/config/modules/4.9.84/cifs.ko | 202.6 | CIFS file system driver | NO |
/config/modules/4.9.84/ehci-hcd.ko | 40.5 | USB2.0 host controller drive | NO |
/config/modules/4.9.84/fat.ko | 53.0 | fat ile system | NO |
/config/modules/4.9.84/grace.ko | 5.4 | NFS | NO |
/config/modules/4.9.84/lockd.ko | 49.1 | Mount NFS required driver | NO |
/config/modules/4.9.84/kdrv_sdmmc.ko | 30.7 | SD card driver | NO |
/config/modules/4.9.84/vfat.ko | 11.5 | vfat file system (USB or SD card) | NO |
Table 1-3: Introduction to remaining files
Tools and config files | Size | Use | Whether it is necessary |
---|---|---|---|
config_tool and mmap.ini | When insmod mi_sys.ko, the driver calls config_tool to analyze mmap.ini hardware allocation buffer. The default directory is /config, you need to add default_config_path='/new/path' at the end of insmod mi_sys.ko when replacing | YES | |
isp_api.xml | Connect iqtool to generate software interface project. When changing the path, the application should call MI_S32 MI_IQSERVER_SetDataPath(char* path) of mi_iqserver.h before iqserver_open | NO | |
iqfile0.bin -> imx307_iqfile.bin | When the ISP starts, it will read the iq file named iqfilex.bin (x: isp channel) in /config/iqfile. The basic effect of the image is that the soft link points to the actual iq file. If you want to change the location of the file, you need to execute echo isproot /new/path> /dev/ispmid before running | YES | |
chagall.bin | HW encoder fireware. Default located in /config/fw_path/chagall.bin , add fw_path=/new/path/chagall.bin at the end of insmod mi_venc.ko when changing the lacation. | YES |
-
Initial RAM filesystem and RAM disk //for ramdisk; delete it if you do not need.
-
General:
-
Kprobes // Add hook function (breakpoint) in kernel
-
Kernel performance events and counters // perf 等,用于kernel hacking
-
-
Network
-
The IPv6 protocol
-
Wireless
-
Other parts depend on user needs
-
-
Device
-
Serial ATA and Parallel ATA drivers
-
MMC/SD/SDIO card support
-
Staging drivers
-
USB host
-
Ehci //2.0
-
Uhci //3.0
-
-
USB device
-
UVC
-
Webcam
-
-
File systems
-
NFS //used for debug;
-
CIFS //used for debug
-
JFFS2 // W/R
-
UBIFS // W/R
-
FAT/NTFS //windos fs
-
-
-
Kernel hacking
-
Tracers //ftrace ect.
-
KGDB: kernel debugger //gdb
-
Debug Lockups and Hangs //debug mutex and so on.
-
Debug Lockups and Hangs
-
DEBUG_INFO //debug info, it is not convenient to debug after deleting
-
KALLSYMS // kernel symbol ect., it is not convenient to debug after deleting
-
-
Device Drivers
-
Multimedia support // usb cam related setting
-
Input device support
-
Mouse interface
-
Keyboards
-
Mice
-
Touchscreens
-
-
-
SStar SoC platform drivers // According to the needs of users
-
SStar SATA HOST //sata
-
SStar SD/MMC Card Interface Support
-
-
Other: It is recommended to use the user's config to check
2. Compilation And Config of BUSYBOX¶
2.1. Compile With Default Config¶
-
prepare
wget https://busybox.net/downloads/busybox-1.31.1.tar.bz2
tar -xvf wget busybox-1.31.1.tar.bz2 cd busybox-1.31.1
-
make
make defconfig (Compile in shared library mode by default, CONFIG_STATIC -> N) make -j4 CROSS_COMPILE=arm-none-linux-gnueabi-
2.2. BUSYBOX Cropping¶
Classified according to busybox main options.
Table 2-1: setting
Config | Size(Bytes | Function |
---|---|---|
CONFIG_DESKTOP | 8k | Open some non-essential configurations to be compatible with the desktop system |
CONFIG_INCLUDE_SUSv2 | --- | Open UNIX 98 support |
CONFIG_SHOW_USAGE | 7k | applets help |
CONFIG_FEATURE_UTMP | Used to record the currently logged in user, the who function will be used | |
CONFIG_FEATURE_PIDFILE | Generated by the pid file | |
CONFIG_FEATURE_SUID | Open root authority management | |
CONFIG_STACK_OPTIMIZATION_386 | i386 arch stack-boundary=2 | |
CONFIG_FLOAT_DURATION | Make applets support floating point, such as sleep N.NNN | |
CONFIG_FEATURE_NON_POSIX_CP | Non-POSIX标准cp命令 |
Applets
Sequence according to the display order of Applets:
The following are the configurations supported by the busybox tool, you can choose whether to enable it according to your needs:
-
Archival Utilities
Config of compression format and tool
-
Coreutils
Config of system basic tool
-
Console Utilities
-
Debian Utilities
-
klibc-utils
Including minips(ps), nuke(rm -rf) , resume and run-init
-
Editors
Including sed, awk, vi, ect.
-
Finding Utilities
Configure find, grep and xargs functions
-
Init Utilities
Including reboot, poweroff, halt, etc.
-
Login/Password Management Utilities
-
Linux Ext2 FS Progs
-
Linux Module Utilities
Including insmod/rmmod/modprobe, etc.
-
Linux System Utilities
-
Miscellaneous Utilities
-
Networking Utilities
Configure Ipv4/ipv6 and tftp, telnetd and other tools support
-
Print Utilities
Including lpd/lpr/lpq
-
Mail Utilities
-
Process Utilities
Including free, kill, top, watch, ect.
-
Runit Utilities
-
Shells
Including ash and hush
-
System Logging Utilities