[[["易于理解","easyToUnderstand","thumb-up"],["解决了我的问题","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["没有我需要的信息","missingTheInformationINeed","thumb-down"],["太复杂/步骤太多","tooComplicatedTooManySteps","thumb-down"],["内容需要更新","outOfDate","thumb-down"],["翻译问题","translationIssue","thumb-down"],["示例/代码问题","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["最后更新时间 (UTC):2025-03-26。"],[],[],null,["# Android kernel frequently asked questions\n\nThis document contains frequently asked questions about the Android kernel,\nknown also as the Generic Kernel Image (GKI) kernel. If you are unfamiliar with\nGKI and GKI kernel terminology, refer to the\n[Kernel overview](/docs/core/architecture/kernel).\n\nCan Kernel Module Interface (KMI) symbol lists be changed in a stable kernel?\n-----------------------------------------------------------------------------\n\nChanges that don't affect the existing KMI can be added to kernels that are\nfrozen. These changes include new exported functions and symbol list entries.\nFor details, see [Manage symbol lists](/docs/core/architecture/kernel/stable-kmi#managing-symbol-lists).\n\nCan I change structures used by vendor modules in a stable kernel?\n------------------------------------------------------------------\n\nStructures that are part of a KMI interface can't be changed in kernels with a\nfrozen KMI. Prior to KMI freeze, these structures can be changed.\n\nCan I change the kernel as long as I don't break binary or source compatibility?\n--------------------------------------------------------------------------------\n\nChanges that don't affect the KMI can be made as described in [Android-specific\npatches](/docs/core/architecture/kernel/kernel-code#android-specific-patches).\n\nHow does GKI handle kernel configuration?\n-----------------------------------------\n\nFor information on kernel configuration, refer to the\n[Changes to gki_defconfig](/docs/core/architecture/kernel/kernel-code#changes-to-gki-defconfig).\n\nHow do I handle upstream bug fixes for overwrites to existing GKI modules?\n--------------------------------------------------------------------------\n\nIf you create a vendor module based on a driver in\n[Android Common Kernel (ACK)](/docs/core/architecture/kernel/android-common),\nit's up to you to ensure that bug fixes from upstream and ACK are propagated\nto your module. Generally, it's in your best interest to use the GKI kernel and\nGKI modules without modification so these updates are provided consistently\nby Google.\n\nAre there GKI specific tests?\n-----------------------------\n\nThere are [Vendor Test Suite (VTS)](/docs/compatibility/vts) tests that verify\nthat a certified GKI build is installed and also to enforce per-release GKI\nrequirements. For example, there are Android 12 VTS tests for boot header v3\nand to verify the existence of required partitions in a device running a 5.10\nkernel.\n\nHow do I create the project defconfig fragment file for device builds?\n----------------------------------------------------------------------\n\nMany GKI-compliant devices use a config fragment to describe the configuration\noptions needed, in addition to `gki_defconfig`, to build the vendor modules.\nExamples that are part of the ACK codebase include Cuttlefish and DB845c.\nThere's no way to avoid some manual examination of configuration options\nto optimize the fragment, but `scripts/diffconfig` from the kernel sources\nis useful for comparing the results of `gki_defconfig` and\n`gki_defconfig+device.fragment`.\n\nIs there a workaround for modprobe treating - and _ as equivalent?\n------------------------------------------------------------------\n\nThe\n[modprobe man page](https://man7.org/linux/man-pages/man8/modprobe.8.html)\ncontains this description: \"`modprobe` intelligently adds\nor removes a module from the Linux kernel: note that for convenience, there is\nno difference between _ and - in module names (automatic underscore conversion\nis performed).\" The GKI team adheres to the standard upstream convention, so\nvendor tools or module naming conventions must take this adherence into account.\n\nHow do I enable debugfs for internal use?\n-----------------------------------------\n\nFor details on enabling debugfs, see [intrusive downstream debug\nfeatures](/docs/core/architecture/kernel/debugging-with-gki#intrusive-downstream-debug-features).\n\nHow can I resolve mismatched ABIs between the GKI kernel with a specific module configuration enabled?\n------------------------------------------------------------------------------------------------------\n\nMismatched ABIs between the GKI kernel and module configuration represents an\nimplicit module config dependency, where enabling a module causes a binary\nconfig to be built into the resulting kernel image. Reach out to the Android\nkernel team\n([kernel-team@android.com](mailto:kernel-team@android.com)) to determine a path\nforward. After the list of symbols is determined, create a bug in the\n[Issue Tracker](https://issuetracker.google.com/components/1124381) and upload\na change to the symbol list."]]