2022-11-23 15:18:04 +09:00
|
|
|
# SPDX-License-Identifier: GPL-2.0
|
2021-06-21 20:54:56 +09:00
|
|
|
# Copyright (C) 2021 The Android Open Source Project
|
2022-11-23 15:18:04 +09:00
|
|
|
|
2023-06-17 09:05:00 +09:00
|
|
|
load("@bazel_skylib//rules:write_file.bzl", "write_file")
|
2022-11-24 21:00:01 +09:00
|
|
|
load("//build/bazel_common_rules/dist:dist.bzl", "copy_to_dist_dir")
|
2023-06-22 23:08:27 +09:00
|
|
|
load("//build/kernel/kleaf:common_kernels.bzl", "define_common_kernels")
|
2023-09-25 10:02:14 +09:00
|
|
|
load("//build/kernel/kleaf:constants.bzl", "X86_64_OUTS")
|
2023-06-22 23:08:27 +09:00
|
|
|
load(
|
|
|
|
"//build/kernel/kleaf:kernel.bzl",
|
2023-08-09 05:50:56 +09:00
|
|
|
"checkpatch",
|
2023-06-22 23:08:27 +09:00
|
|
|
"ddk_headers",
|
|
|
|
"kernel_abi",
|
|
|
|
"kernel_build",
|
|
|
|
"kernel_images",
|
|
|
|
"kernel_modules_install",
|
|
|
|
"merged_kernel_uapi_headers",
|
|
|
|
)
|
2023-08-07 21:42:40 +09:00
|
|
|
load(":modules.bzl", "get_gki_modules_list")
|
2022-11-24 21:00:01 +09:00
|
|
|
|
2021-11-03 08:26:49 +09:00
|
|
|
package(
|
|
|
|
default_visibility = [
|
|
|
|
"//visibility:public",
|
|
|
|
],
|
|
|
|
)
|
2021-06-21 20:54:56 +09:00
|
|
|
|
2023-05-05 07:04:29 +09:00
|
|
|
_GKI_AARCH64_MAKE_GOALS = [
|
|
|
|
"Image",
|
|
|
|
"Image.lz4",
|
|
|
|
"Image.gz",
|
|
|
|
"modules",
|
|
|
|
]
|
|
|
|
|
|
|
|
_GKI_RISCV64_MAKE_GOALS = [
|
|
|
|
"Image",
|
|
|
|
"Image.lz4",
|
|
|
|
"Image.gz",
|
|
|
|
"modules",
|
|
|
|
]
|
|
|
|
|
|
|
|
_GKI_X86_64_MAKE_GOALS = [
|
|
|
|
"bzImage",
|
|
|
|
"modules",
|
|
|
|
]
|
|
|
|
|
2023-08-09 05:50:56 +09:00
|
|
|
checkpatch(
|
|
|
|
name = "checkpatch",
|
|
|
|
checkpatch_pl = "scripts/checkpatch.pl",
|
|
|
|
)
|
|
|
|
|
2023-08-07 21:42:40 +09:00
|
|
|
# Deprecated - Use arch specific files from below.
|
2023-08-10 22:39:15 +09:00
|
|
|
alias(
|
2023-06-17 09:05:00 +09:00
|
|
|
name = "gki_system_dlkm_modules",
|
2023-08-10 22:39:15 +09:00
|
|
|
actual = "gki_system_dlkm_modules_arm64",
|
|
|
|
deprecation = """
|
|
|
|
Common list for all architectures is deprecated.
|
|
|
|
Instead use the file corresponding to the architecture used:
|
|
|
|
i.e. `gki_system_dlkm_modules_{arch}`
|
|
|
|
""",
|
|
|
|
)
|
|
|
|
|
|
|
|
alias(
|
|
|
|
name = "android/gki_system_dlkm_modules",
|
|
|
|
actual = "android/gki_system_dlkm_modules_arm64",
|
|
|
|
deprecation = """
|
|
|
|
Common list for all architectures is deprecated.
|
|
|
|
Instead use the file corresponding to the architecture used:
|
|
|
|
i.e. `gki_system_dlkm_modules_{arch}`
|
|
|
|
""",
|
2023-08-07 21:42:40 +09:00
|
|
|
)
|
|
|
|
|
|
|
|
write_file(
|
|
|
|
name = "gki_system_dlkm_modules_arm64",
|
|
|
|
out = "android/gki_system_dlkm_modules_arm64",
|
|
|
|
content = get_gki_modules_list("arm64") + [
|
|
|
|
# Ensure new line at the end.
|
|
|
|
"",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
write_file(
|
|
|
|
name = "gki_system_dlkm_modules_x86_64",
|
|
|
|
out = "android/gki_system_dlkm_modules_x86_64",
|
|
|
|
content = get_gki_modules_list("x86_64") + [
|
|
|
|
# Ensure new line at the end.
|
|
|
|
"",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
write_file(
|
|
|
|
name = "gki_system_dlkm_modules_risc64",
|
|
|
|
out = "android/gki_system_dlkm_modules_riscv64",
|
|
|
|
content = get_gki_modules_list("riscv64") + [
|
2023-06-17 09:05:00 +09:00
|
|
|
# Ensure new line at the end.
|
|
|
|
"",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2023-03-29 19:18:01 +09:00
|
|
|
filegroup(
|
|
|
|
name = "aarch64_additional_kmi_symbol_lists",
|
|
|
|
srcs = [
|
|
|
|
# keep sorted
|
2023-09-13 19:43:57 +09:00
|
|
|
"android/abi_gki_aarch64_asus",
|
2023-03-29 19:18:01 +09:00
|
|
|
"android/abi_gki_aarch64_db845c",
|
2023-04-19 15:03:19 +09:00
|
|
|
"android/abi_gki_aarch64_exynos",
|
2023-07-14 14:40:47 +09:00
|
|
|
"android/abi_gki_aarch64_exynosauto",
|
2023-03-29 19:18:01 +09:00
|
|
|
"android/abi_gki_aarch64_galaxy",
|
2024-01-06 14:20:56 +09:00
|
|
|
"android/abi_gki_aarch64_honda",
|
2023-05-17 16:13:45 +09:00
|
|
|
"android/abi_gki_aarch64_honor",
|
2023-04-11 23:03:40 +09:00
|
|
|
"android/abi_gki_aarch64_imx",
|
2023-09-05 12:27:10 +09:00
|
|
|
"android/abi_gki_aarch64_meizu",
|
2023-04-07 16:48:38 +09:00
|
|
|
"android/abi_gki_aarch64_mtk",
|
2024-01-22 12:23:20 +09:00
|
|
|
"android/abi_gki_aarch64_nothing",
|
2023-03-29 19:18:01 +09:00
|
|
|
"android/abi_gki_aarch64_oplus",
|
|
|
|
"android/abi_gki_aarch64_pixel",
|
|
|
|
"android/abi_gki_aarch64_qcom",
|
ANDROID: GKI: Add initial abi for rockchip
INFO: ABI DIFFERENCES HAVE BEEN DETECTED!
INFO: 65 function symbol(s) added
'unsigned int _bcd2bin(unsigned char)'
'unsigned char _bin2bcd(unsigned int)'
'int ce_aes_expandkey(struct crypto_aes_ctx*, const u8*, unsigned int)'
'void clk_fractional_divider_general_approximation(struct clk_hw*, unsigned long, unsigned long*, unsigned long*, unsigned long*)'
'int clk_get_phase(struct clk*)'
'void clk_hw_unregister_composite(struct clk_hw*)'
'int clk_set_phase(struct clk*, int)'
'int compat_only_sysfs_link_entry_to_kobj(struct kobject*, struct kobject*, const char*, const char*)'
'bool cpu_have_feature(unsigned int)'
'struct crypto_akcipher* crypto_alloc_akcipher(const char*, u32, u32)'
'int dev_pm_opp_get_supplies(struct dev_pm_opp*, struct dev_pm_opp_supply*)'
'void device_set_node(struct device*, struct fwnode_handle*)'
'struct devfreq_event_dev* devm_devfreq_event_add_edev(struct device*, struct devfreq_event_desc*)'
'char** devm_kasprintf_strarray(struct device*, const char*, size_t)'
'void* devm_pci_remap_cfg_resource(struct device*, struct resource*)'
'bool disable_hardirq(unsigned int)'
'int drm_gem_handle_delete(struct drm_file*, u32)'
'u16 dw_pcie_find_ext_capability(struct dw_pcie*, u8)'
'int dw_pcie_link_up(struct dw_pcie*)'
'int extcon_sync(struct extcon_dev*, unsigned int)'
'void gpiochip_relres_irq(struct gpio_chip*, unsigned int)'
'int gpiochip_reqres_irq(struct gpio_chip*, unsigned int)'
'ssize_t hdmi_avi_infoframe_pack_only(const struct hdmi_avi_infoframe*, void*, size_t)'
'struct iio_channel* iio_channel_get_all(struct device*)'
'void iio_channel_release_all(struct iio_channel*)'
'int iio_update_buffers(struct iio_dev*, struct iio_buffer*, struct iio_buffer*)'
'void input_set_poll_interval(struct input_dev*, unsigned int)'
'int input_setup_polling(struct input_dev*, void(*)(struct input_dev*))'
'void iommu_detach_group(struct iommu_domain*, struct iommu_group*)'
'int irq_gc_set_wake(struct irq_data*, unsigned int)'
'void led_set_brightness_nosleep(struct led_classdev*, unsigned int)'
'int media_entity_setup_link(struct media_link*, u32)'
'int mii_link_ok(struct mii_if_info*)'
'int mmc_sw_reset(struct mmc_card*)'
'struct pinctrl_dev* of_pinctrl_get(struct device_node*)'
'enum usb_dr_mode of_usb_get_dr_mode_by_phy(struct device_node*, int)'
'int phy_mipi_dphy_config_validate(struct phy_configure_opts_mipi_dphy*)'
'struct pinctrl_gpio_range* pinctrl_find_gpio_range_from_pin(struct pinctrl_dev*, unsigned int)'
'int pinmux_generic_add_function(struct pinctrl_dev*, const char*, const char* const*, unsigned int, void*)'
'int pm_clk_add_clk(struct device*, struct clk*)'
'int power_supply_get_property_from_supplier(struct power_supply*, enum power_supply_property, union power_supply_propval*)'
'int pwm_adjust_config(struct pwm_device*)'
'int regulator_suspend_enable(struct regulator_dev*, suspend_state_t)'
'struct iova* reserve_iova(struct iova_domain*, unsigned long, unsigned long)'
'void sha1_init(__u32*)'
'void sha1_transform(__u32*, const char*, __u32*)'
'struct skcipher_instance* skcipher_alloc_instance_simple(struct crypto_template*, struct rtattr**)'
'int skcipher_register_instance(struct crypto_template*, struct skcipher_instance*)'
'int skcipher_walk_aead_decrypt(struct skcipher_walk*, struct aead_request*, bool)'
'int skcipher_walk_aead_encrypt(struct skcipher_walk*, struct aead_request*, bool)'
'int skcipher_walk_done(struct skcipher_walk*, int)'
'int skcipher_walk_virt(struct skcipher_walk*, struct skcipher_request*, bool)'
'int snd_pcm_create_iec958_consumer_hw_params(struct snd_pcm_hw_params*, u8*, size_t)'
'int snd_pcm_stop_xrun(struct snd_pcm_substream*)'
'int snd_soc_jack_add_zones(struct snd_soc_jack*, int, struct snd_soc_jack_zone*)'
'int snd_soc_jack_get_type(struct snd_soc_jack*, int)'
'unsigned int swiotlb_max_segment()'
'void tcpm_tcpc_reset(struct tcpm_port*)'
'int usb_add_phy(struct usb_phy*, enum usb_phy_type)'
'void usb_deregister_dev(struct usb_interface*, struct usb_class_driver*)'
'struct usb_interface* usb_find_interface(struct usb_driver*, int)'
'void usb_poison_anchored_urbs(struct usb_anchor*)'
'int usb_register_dev(struct usb_interface*, struct usb_class_driver*)'
'enum usb_role usb_role_switch_get_role(struct usb_role_switch*)'
'unsigned int usb_wakeup_enabled_descendants(struct usb_device*)'
2 variable symbol(s) added
'unsigned long avenrun[3]'
'struct class* power_supply_class'
Bug: 300024866
Change-Id: I0e1aeb3470bc01a8097319dfca593c6d0c0c7d7f
Signed-off-by: Kever Yang <kever.yang@rock-chips.com>
2023-09-13 12:58:02 +09:00
|
|
|
"android/abi_gki_aarch64_rockchip",
|
2023-10-06 17:47:19 +09:00
|
|
|
"android/abi_gki_aarch64_sony",
|
2023-08-22 01:13:20 +09:00
|
|
|
"android/abi_gki_aarch64_tuxera",
|
2023-05-16 18:14:56 +09:00
|
|
|
"android/abi_gki_aarch64_unisoc",
|
2023-03-29 19:18:01 +09:00
|
|
|
"android/abi_gki_aarch64_virtual_device",
|
2023-04-19 11:16:07 +09:00
|
|
|
"android/abi_gki_aarch64_vivo",
|
ANDROID: GKI: add symbol list file for xiaomi
add abi_gki_aarch64_xiaomi
INFO: 59 function symbol(s) added
'void __blk_mq_end_request(struct request*, blk_status_t)'
'struct scsi_device* __scsi_add_device(struct Scsi_Host*, uint, uint, u64, void*)'
'int __traceiter_android_vh_binder_transaction_init(void*, struct binder_transaction*)'
'int __traceiter_android_vh_binder_wait_for_work(void*, bool, struct binder_thread*, struct binder_proc*)'
'void balance_dirty_pages_ratelimited(struct address_space*)'
'struct backing_dev_info* bdi_alloc(int)'
'void bdi_put(struct backing_dev_info*)'
'int bdi_register(struct backing_dev_info*, const char*, ...)'
'void blk_mq_freeze_queue(struct request_queue*)'
'struct request_queue* blk_mq_init_queue(struct blk_mq_tag_set*)'
'void blk_mq_tagset_busy_iter(struct blk_mq_tag_set*, busy_tag_iter_fn*, void*)'
'void blk_mq_unfreeze_queue(struct request_queue*)'
'void blk_queue_update_dma_alignment(struct request_queue*, int)'
'void blk_queue_update_dma_pad(struct request_queue*, unsigned int)'
'bool blk_update_request(struct request*, blk_status_t, unsigned int)'
'void bsg_job_done(struct bsg_job*, int, unsigned int)'
'void bsg_remove_queue(struct request_queue*)'
'struct request_queue* bsg_setup_queue(struct device*, const char*, bsg_job_fn*, bsg_timeout_fn*, int)'
'void deactivate_locked_super(struct super_block*)'
'void dev_pm_opp_remove(struct device*, unsigned long)'
'const char* drm_get_connector_type_name(unsigned int)'
'void generic_shutdown_super(struct super_block*)'
'int gpio_request_array(const struct gpio*, size_t)'
'void lockref_get(struct lockref*)'
'void logfc(struct fc_log*, const char*, char, const char*, ...)'
'int lookup_bdev(const char*, dev_t*)'
'void* mempool_alloc_pages(gfp_t, void*)'
'void mempool_free_pages(void*, void*)'
'int mempool_resize(mempool_t*, int)'
'struct nvmem_device* nvmem_register(const struct nvmem_config*)'
'void nvmem_unregister(struct nvmem_device*)'
'struct page* read_cache_page(struct address_space*, unsigned long, filler_t*, struct file*)'
'int scsi_add_host_with_dma(struct Scsi_Host*, struct device*, struct device*)'
'int scsi_change_queue_depth(struct scsi_device*, int)'
'struct scsi_device* scsi_device_lookup(struct Scsi_Host*, uint, uint, u64)'
'int scsi_dma_map(struct scsi_cmnd*)'
'void scsi_dma_unmap(struct scsi_cmnd*)'
'struct Scsi_Host* scsi_host_alloc(struct scsi_host_template*, int)'
'struct Scsi_Host* scsi_host_lookup(unsigned short)'
'void scsi_host_put(struct Scsi_Host*)'
'int scsi_is_host_device(const struct device*)'
'void scsi_print_command(struct scsi_cmnd*)'
'void scsi_remove_host(struct Scsi_Host*)'
'void scsi_report_bus_reset(struct Scsi_Host*, int)'
'void scsi_scan_host(struct Scsi_Host*)'
'struct super_block* sget_fc(struct fs_context*, int(*)(struct super_block*, struct fs_context*), int(*)(struct super_block*, struct fs_context*))'
'int ufshcd_alloc_host(struct device*, struct ufs_hba**)'
'int ufshcd_config_pwr_mode(struct ufs_hba*, struct ufs_pa_layer_attr*)'
'void ufshcd_dealloc_host(struct ufs_hba*)'
'int ufshcd_hba_enable(struct ufs_hba*)'
'int ufshcd_make_hba_operational(struct ufs_hba*)'
'void ufshcd_update_evt_hist(struct ufs_hba*, u32, u32)'
'int utf16s_to_utf8s(const wchar_t*, int, enum utf16_endian, u8*, int)'
'void wait_for_device_probe()'
'int wakeup_sources_read_lock()'
'void wakeup_sources_read_unlock(int)'
'struct wakeup_source* wakeup_sources_walk_next(struct wakeup_source*)'
'struct wakeup_source* wakeup_sources_walk_start()'
'int blk_mq_alloc_sq_tag_set(struct blk_mq_tag_set*, const struct blk_mq_ops*, unsigned int, unsigned int)'
3 variable symbol(s) added
'struct tracepoint __tracepoint_android_vh_binder_transaction_init'
'struct tracepoint __tracepoint_android_vh_binder_wait_for_work'
'u64 jiffies_64'
Bug: 276850920
Change-Id: Ibc65a0bfb3332072be7bea17e0aea48277043510
Signed-off-by: fengqi <fengqi@xiaomi.com>
2023-04-06 16:53:09 +09:00
|
|
|
"android/abi_gki_aarch64_xiaomi",
|
2023-03-29 19:18:01 +09:00
|
|
|
],
|
|
|
|
visibility = ["//visibility:public"],
|
|
|
|
)
|
2023-02-16 23:03:19 +09:00
|
|
|
|
2022-04-28 08:20:12 +09:00
|
|
|
define_common_kernels(target_configs = {
|
|
|
|
"kernel_aarch64": {
|
2023-03-17 06:25:22 +09:00
|
|
|
"kmi_symbol_list_strict_mode": True,
|
2023-08-07 21:42:40 +09:00
|
|
|
"module_implicit_outs": get_gki_modules_list("arm64"),
|
2023-02-16 23:03:19 +09:00
|
|
|
"kmi_symbol_list": "android/abi_gki_aarch64",
|
2023-07-21 08:50:01 +09:00
|
|
|
"kmi_symbol_list_add_only": True,
|
2023-03-29 19:18:01 +09:00
|
|
|
"additional_kmi_symbol_lists": [":aarch64_additional_kmi_symbol_lists"],
|
2023-03-22 07:49:31 +09:00
|
|
|
"protected_exports_list": "android/abi_gki_protected_exports_aarch64",
|
|
|
|
"protected_modules_list": "android/gki_aarch64_protected_modules",
|
2023-05-05 07:04:29 +09:00
|
|
|
"make_goals": _GKI_AARCH64_MAKE_GOALS,
|
2022-04-28 08:20:12 +09:00
|
|
|
},
|
2022-10-01 04:27:02 +09:00
|
|
|
"kernel_aarch64_16k": {
|
2023-01-19 10:46:38 +09:00
|
|
|
"kmi_symbol_list_strict_mode": False,
|
2023-08-07 21:42:40 +09:00
|
|
|
"module_implicit_outs": get_gki_modules_list("arm64"),
|
2023-05-05 07:04:29 +09:00
|
|
|
"make_goals": _GKI_AARCH64_MAKE_GOALS,
|
2022-10-01 04:27:02 +09:00
|
|
|
},
|
2022-04-28 08:20:12 +09:00
|
|
|
"kernel_aarch64_debug": {
|
2023-01-19 10:46:38 +09:00
|
|
|
"kmi_symbol_list_strict_mode": False,
|
2023-08-07 21:42:40 +09:00
|
|
|
"module_implicit_outs": get_gki_modules_list("arm64"),
|
2023-02-16 23:03:19 +09:00
|
|
|
"kmi_symbol_list": "android/abi_gki_aarch64",
|
2023-07-21 08:50:01 +09:00
|
|
|
"kmi_symbol_list_add_only": True,
|
2023-03-29 19:18:01 +09:00
|
|
|
"additional_kmi_symbol_lists": [":aarch64_additional_kmi_symbol_lists"],
|
2023-03-22 07:49:31 +09:00
|
|
|
"protected_exports_list": "android/abi_gki_protected_exports_aarch64",
|
|
|
|
"protected_modules_list": "android/gki_aarch64_protected_modules",
|
2023-05-05 07:04:29 +09:00
|
|
|
"make_goals": _GKI_AARCH64_MAKE_GOALS,
|
2022-04-28 08:20:12 +09:00
|
|
|
},
|
2022-11-22 09:11:21 +09:00
|
|
|
"kernel_riscv64": {
|
2023-01-19 10:46:38 +09:00
|
|
|
"kmi_symbol_list_strict_mode": False,
|
2023-08-07 21:42:40 +09:00
|
|
|
"module_implicit_outs": get_gki_modules_list("riscv64"),
|
2023-05-05 07:04:29 +09:00
|
|
|
"make_goals": _GKI_RISCV64_MAKE_GOALS,
|
2022-11-22 09:11:21 +09:00
|
|
|
},
|
2022-10-26 10:01:29 +09:00
|
|
|
"kernel_x86_64": {
|
|
|
|
"kmi_symbol_list_strict_mode": False,
|
2023-08-07 21:42:40 +09:00
|
|
|
"module_implicit_outs": get_gki_modules_list("x86_64"),
|
2023-03-22 07:49:31 +09:00
|
|
|
"protected_exports_list": "android/abi_gki_protected_exports_x86_64",
|
|
|
|
"protected_modules_list": "android/gki_x86_64_protected_modules",
|
2023-05-05 07:04:29 +09:00
|
|
|
"make_goals": _GKI_X86_64_MAKE_GOALS,
|
2022-10-26 10:01:29 +09:00
|
|
|
},
|
|
|
|
"kernel_x86_64_debug": {
|
|
|
|
"kmi_symbol_list_strict_mode": False,
|
2023-08-07 21:42:40 +09:00
|
|
|
"module_implicit_outs": get_gki_modules_list("x86_64"),
|
2023-03-22 07:49:31 +09:00
|
|
|
"protected_exports_list": "android/abi_gki_protected_exports_x86_64",
|
|
|
|
"protected_modules_list": "android/gki_x86_64_protected_modules",
|
2023-05-05 07:04:29 +09:00
|
|
|
"make_goals": _GKI_X86_64_MAKE_GOALS,
|
2022-10-26 10:01:29 +09:00
|
|
|
},
|
2022-04-28 08:20:12 +09:00
|
|
|
})
|
2022-04-26 13:17:00 +09:00
|
|
|
|
2023-09-25 10:02:14 +09:00
|
|
|
# Microdroid is not a real device. The kernel image is built with special
|
|
|
|
# configs to reduce the size. Hence, not using mixed build.
|
|
|
|
kernel_build(
|
|
|
|
name = "kernel_aarch64_microdroid",
|
|
|
|
srcs = ["//common:kernel_aarch64_sources"],
|
|
|
|
outs = [
|
|
|
|
"Image",
|
|
|
|
"System.map",
|
|
|
|
"modules.builtin",
|
|
|
|
"modules.builtin.modinfo",
|
|
|
|
"vmlinux",
|
|
|
|
"vmlinux.symvers",
|
|
|
|
],
|
|
|
|
build_config = "build.config.microdroid.aarch64",
|
|
|
|
make_goals = [
|
|
|
|
"Image",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
copy_to_dist_dir(
|
|
|
|
name = "kernel_aarch64_microdroid_dist",
|
|
|
|
data = [
|
|
|
|
":kernel_aarch64_microdroid",
|
|
|
|
],
|
|
|
|
dist_dir = "out/kernel_aarch64_microdroid/dist",
|
|
|
|
flat = True,
|
|
|
|
log = "info",
|
|
|
|
)
|
|
|
|
|
2024-01-11 19:49:01 +09:00
|
|
|
kernel_build(
|
|
|
|
name = "kernel_aarch64_microdroid_16k",
|
|
|
|
srcs = ["//common:kernel_aarch64_sources"],
|
|
|
|
outs = [
|
|
|
|
"Image",
|
|
|
|
"System.map",
|
|
|
|
"modules.builtin",
|
|
|
|
"modules.builtin.modinfo",
|
|
|
|
"vmlinux",
|
|
|
|
"vmlinux.symvers",
|
|
|
|
],
|
|
|
|
build_config = "build.config.microdroid.aarch64",
|
|
|
|
make_goals = [
|
|
|
|
"Image",
|
|
|
|
],
|
|
|
|
page_size = "16k",
|
|
|
|
)
|
|
|
|
|
|
|
|
copy_to_dist_dir(
|
|
|
|
name = "kernel_aarch64_microdroid_16k_dist",
|
|
|
|
data = [
|
|
|
|
":kernel_aarch64_microdroid_16k",
|
|
|
|
],
|
|
|
|
dist_dir = "out/kernel_aarch64_microdroid_16k/dist",
|
|
|
|
flat = True,
|
|
|
|
log = "info",
|
|
|
|
)
|
|
|
|
|
2023-09-25 10:02:14 +09:00
|
|
|
# Microdroid is not a real device. The kernel image is built with special
|
|
|
|
# configs to reduce the size. Hence, not using mixed build.
|
|
|
|
kernel_build(
|
|
|
|
name = "kernel_x86_64_microdroid",
|
|
|
|
srcs = ["//common:kernel_x86_64_sources"],
|
|
|
|
outs = X86_64_OUTS,
|
|
|
|
arch = "x86_64",
|
|
|
|
build_config = "build.config.microdroid.x86_64",
|
|
|
|
make_goals = [
|
|
|
|
"bzImage",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
copy_to_dist_dir(
|
|
|
|
name = "kernel_x86_64_microdroid_dist",
|
|
|
|
data = [
|
|
|
|
":kernel_x86_64_microdroid",
|
|
|
|
],
|
|
|
|
dist_dir = "out/kernel_x86_64_microdroid/dist",
|
|
|
|
flat = True,
|
|
|
|
log = "info",
|
|
|
|
)
|
|
|
|
|
|
|
|
kernel_build(
|
|
|
|
name = "kernel_aarch64_crashdump",
|
|
|
|
srcs = ["//common:kernel_aarch64_sources"],
|
|
|
|
outs = [
|
|
|
|
"Image",
|
|
|
|
],
|
|
|
|
build_config = "build.config.crashdump.aarch64",
|
|
|
|
make_goals = [
|
|
|
|
"Image",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
copy_to_dist_dir(
|
|
|
|
name = "kernel_aarch64_crashdump_dist",
|
|
|
|
data = [
|
|
|
|
":kernel_aarch64_crashdump",
|
|
|
|
],
|
|
|
|
dist_dir = "out/kernel_aarch64_crashdump/dist",
|
|
|
|
flat = True,
|
|
|
|
log = "info",
|
|
|
|
)
|
|
|
|
|
|
|
|
kernel_build(
|
|
|
|
name = "kernel_x86_64_crashdump",
|
|
|
|
srcs = ["//common:kernel_x86_64_sources"],
|
|
|
|
outs = X86_64_OUTS,
|
|
|
|
arch = "x86_64",
|
|
|
|
build_config = "build.config.crashdump.x86_64",
|
|
|
|
make_goals = [
|
|
|
|
"bzImage",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
|
|
|
copy_to_dist_dir(
|
|
|
|
name = "kernel_x86_64_crashdump_dist",
|
|
|
|
data = [
|
|
|
|
":kernel_x86_64_crashdump",
|
|
|
|
],
|
|
|
|
dist_dir = "out/kernel_x86_64_crashdump/dist",
|
|
|
|
flat = True,
|
|
|
|
log = "info",
|
|
|
|
)
|
|
|
|
|
2023-06-23 19:03:10 +09:00
|
|
|
_DB845C_MODULE_OUTS = [
|
|
|
|
# keep sorted
|
|
|
|
"crypto/michael_mic.ko",
|
|
|
|
"drivers/base/regmap/regmap-sdw.ko",
|
|
|
|
"drivers/base/regmap/regmap-slimbus.ko",
|
|
|
|
"drivers/bus/mhi/host/mhi.ko",
|
|
|
|
"drivers/clk/qcom/clk-qcom.ko",
|
|
|
|
"drivers/clk/qcom/clk-rpmh.ko",
|
|
|
|
"drivers/clk/qcom/clk-spmi-pmic-div.ko",
|
|
|
|
"drivers/clk/qcom/dispcc-sdm845.ko",
|
|
|
|
"drivers/clk/qcom/dispcc-sm8250.ko",
|
|
|
|
"drivers/clk/qcom/gcc-sdm845.ko",
|
|
|
|
"drivers/clk/qcom/gcc-sm8250.ko",
|
|
|
|
"drivers/clk/qcom/gcc-sm8450.ko",
|
|
|
|
"drivers/clk/qcom/gpucc-sdm845.ko",
|
|
|
|
"drivers/clk/qcom/gpucc-sm8250.ko",
|
|
|
|
"drivers/clk/qcom/lpass-gfm-sm8250.ko",
|
|
|
|
"drivers/clk/qcom/videocc-sdm845.ko",
|
|
|
|
"drivers/clk/qcom/videocc-sm8250.ko",
|
|
|
|
"drivers/cpufreq/qcom-cpufreq-hw.ko",
|
|
|
|
"drivers/dma-buf/heaps/system_heap.ko",
|
|
|
|
"drivers/dma/qcom/bam_dma.ko",
|
|
|
|
"drivers/dma/qcom/gpi.ko",
|
|
|
|
"drivers/extcon/extcon-usb-gpio.ko",
|
|
|
|
"drivers/firmware/qcom-scm.ko",
|
|
|
|
"drivers/gpio/gpio-wcd934x.ko",
|
|
|
|
"drivers/gpu/drm/bridge/display-connector.ko",
|
|
|
|
"drivers/gpu/drm/bridge/lontium-lt9611.ko",
|
|
|
|
"drivers/gpu/drm/bridge/lontium-lt9611uxc.ko",
|
|
|
|
"drivers/gpu/drm/display/drm_display_helper.ko",
|
|
|
|
"drivers/gpu/drm/display/drm_dp_aux_bus.ko",
|
|
|
|
"drivers/gpu/drm/msm/msm.ko",
|
|
|
|
"drivers/gpu/drm/scheduler/gpu-sched.ko",
|
|
|
|
"drivers/hwspinlock/qcom_hwspinlock.ko",
|
|
|
|
"drivers/i2c/busses/i2c-designware-core.ko",
|
|
|
|
"drivers/i2c/busses/i2c-designware-platform.ko",
|
|
|
|
"drivers/i2c/busses/i2c-qcom-geni.ko",
|
|
|
|
"drivers/i2c/busses/i2c-qup.ko",
|
|
|
|
"drivers/i2c/busses/i2c-rk3x.ko",
|
|
|
|
"drivers/i2c/i2c-dev.ko",
|
|
|
|
"drivers/i2c/i2c-mux.ko",
|
|
|
|
"drivers/i2c/muxes/i2c-mux-pca954x.ko",
|
|
|
|
"drivers/iio/adc/qcom-spmi-adc5.ko",
|
|
|
|
"drivers/iio/adc/qcom-vadc-common.ko",
|
|
|
|
"drivers/input/misc/pm8941-pwrkey.ko",
|
|
|
|
"drivers/interconnect/qcom/icc-bcm-voter.ko",
|
|
|
|
"drivers/interconnect/qcom/icc-osm-l3.ko",
|
|
|
|
"drivers/interconnect/qcom/icc-rpmh.ko",
|
|
|
|
"drivers/interconnect/qcom/qnoc-sdm845.ko",
|
|
|
|
"drivers/interconnect/qcom/qnoc-sm8250.ko",
|
|
|
|
"drivers/interconnect/qcom/qnoc-sm8450.ko",
|
|
|
|
"drivers/iommu/arm/arm-smmu/arm_smmu.ko",
|
|
|
|
"drivers/irqchip/qcom-pdc.ko",
|
|
|
|
"drivers/leds/rgb/leds-qcom-lpg.ko",
|
|
|
|
"drivers/mailbox/qcom-apcs-ipc-mailbox.ko",
|
|
|
|
"drivers/mailbox/qcom-ipcc.ko",
|
|
|
|
"drivers/media/platform/qcom/venus/venus-core.ko",
|
|
|
|
"drivers/media/platform/qcom/venus/venus-dec.ko",
|
|
|
|
"drivers/media/platform/qcom/venus/venus-enc.ko",
|
|
|
|
"drivers/mfd/qcom-spmi-pmic.ko",
|
|
|
|
"drivers/mfd/wcd934x.ko",
|
|
|
|
"drivers/misc/fastrpc.ko",
|
|
|
|
"drivers/mmc/host/cqhci.ko",
|
|
|
|
"drivers/mmc/host/sdhci-msm.ko",
|
|
|
|
"drivers/net/can/spi/mcp251xfd/mcp251xfd.ko",
|
|
|
|
"drivers/net/wireless/ath/ath.ko",
|
|
|
|
"drivers/net/wireless/ath/ath10k/ath10k_core.ko",
|
|
|
|
"drivers/net/wireless/ath/ath10k/ath10k_pci.ko",
|
|
|
|
"drivers/net/wireless/ath/ath10k/ath10k_snoc.ko",
|
|
|
|
"drivers/net/wireless/ath/ath11k/ath11k.ko",
|
|
|
|
"drivers/net/wireless/ath/ath11k/ath11k_ahb.ko",
|
|
|
|
"drivers/net/wireless/ath/ath11k/ath11k_pci.ko",
|
|
|
|
"drivers/nvmem/nvmem_qfprom.ko",
|
|
|
|
"drivers/phy/qualcomm/phy-qcom-qmp-combo.ko",
|
|
|
|
"drivers/phy/qualcomm/phy-qcom-qmp-pcie.ko",
|
|
|
|
"drivers/phy/qualcomm/phy-qcom-qmp-pcie-msm8996.ko",
|
|
|
|
"drivers/phy/qualcomm/phy-qcom-qmp-ufs.ko",
|
|
|
|
"drivers/phy/qualcomm/phy-qcom-qmp-usb.ko",
|
|
|
|
"drivers/phy/qualcomm/phy-qcom-qusb2.ko",
|
|
|
|
"drivers/phy/qualcomm/phy-qcom-snps-femto-v2.ko",
|
|
|
|
"drivers/phy/qualcomm/phy-qcom-usb-hs.ko",
|
|
|
|
"drivers/pinctrl/qcom/pinctrl-lpass-lpi.ko",
|
|
|
|
"drivers/pinctrl/qcom/pinctrl-msm.ko",
|
|
|
|
"drivers/pinctrl/qcom/pinctrl-sdm845.ko",
|
|
|
|
"drivers/pinctrl/qcom/pinctrl-sm8250.ko",
|
|
|
|
"drivers/pinctrl/qcom/pinctrl-sm8250-lpass-lpi.ko",
|
|
|
|
"drivers/pinctrl/qcom/pinctrl-sm8450.ko",
|
|
|
|
"drivers/pinctrl/qcom/pinctrl-spmi-gpio.ko",
|
|
|
|
"drivers/pinctrl/qcom/pinctrl-spmi-mpp.ko",
|
|
|
|
"drivers/power/reset/qcom-pon.ko",
|
|
|
|
"drivers/power/reset/reboot-mode.ko",
|
|
|
|
"drivers/power/reset/syscon-reboot-mode.ko",
|
|
|
|
"drivers/regulator/gpio-regulator.ko",
|
|
|
|
"drivers/regulator/qcom-rpmh-regulator.ko",
|
|
|
|
"drivers/regulator/qcom_spmi-regulator.ko",
|
|
|
|
"drivers/regulator/qcom_usb_vbus-regulator.ko",
|
|
|
|
"drivers/remoteproc/qcom_common.ko",
|
|
|
|
"drivers/remoteproc/qcom_pil_info.ko",
|
|
|
|
"drivers/remoteproc/qcom_q6v5.ko",
|
|
|
|
"drivers/remoteproc/qcom_q6v5_adsp.ko",
|
|
|
|
"drivers/remoteproc/qcom_q6v5_mss.ko",
|
|
|
|
"drivers/remoteproc/qcom_q6v5_pas.ko",
|
|
|
|
"drivers/remoteproc/qcom_q6v5_wcss.ko",
|
|
|
|
"drivers/remoteproc/qcom_sysmon.ko",
|
|
|
|
"drivers/reset/reset-qcom-aoss.ko",
|
|
|
|
"drivers/reset/reset-qcom-pdc.ko",
|
|
|
|
"drivers/rpmsg/qcom_glink.ko",
|
|
|
|
"drivers/rpmsg/qcom_glink_rpm.ko",
|
|
|
|
"drivers/rpmsg/qcom_glink_smem.ko",
|
|
|
|
"drivers/rpmsg/qcom_smd.ko",
|
|
|
|
"drivers/rpmsg/rpmsg_ns.ko",
|
|
|
|
"drivers/rtc/rtc-pm8xxx.ko",
|
|
|
|
"drivers/slimbus/slim-qcom-ngd-ctrl.ko",
|
|
|
|
"drivers/slimbus/slimbus.ko",
|
|
|
|
"drivers/soc/qcom/apr.ko",
|
|
|
|
"drivers/soc/qcom/cmd-db.ko",
|
|
|
|
"drivers/soc/qcom/cpr.ko",
|
|
|
|
"drivers/soc/qcom/llcc-qcom.ko",
|
|
|
|
"drivers/soc/qcom/mdt_loader.ko",
|
|
|
|
"drivers/soc/qcom/pdr_interface.ko",
|
|
|
|
"drivers/soc/qcom/qcom_aoss.ko",
|
|
|
|
"drivers/soc/qcom/qcom_rpmh.ko",
|
|
|
|
"drivers/soc/qcom/qmi_helpers.ko",
|
|
|
|
"drivers/soc/qcom/rmtfs_mem.ko",
|
|
|
|
"drivers/soc/qcom/rpmhpd.ko",
|
|
|
|
"drivers/soc/qcom/smem.ko",
|
|
|
|
"drivers/soc/qcom/smp2p.ko",
|
|
|
|
"drivers/soc/qcom/smsm.ko",
|
|
|
|
"drivers/soc/qcom/socinfo.ko",
|
|
|
|
"drivers/soc/qcom/spm.ko",
|
|
|
|
"drivers/soundwire/soundwire-bus.ko",
|
|
|
|
"drivers/soundwire/soundwire-qcom.ko",
|
|
|
|
"drivers/spi/spi-geni-qcom.ko",
|
|
|
|
"drivers/spi/spi-pl022.ko",
|
|
|
|
"drivers/spi/spi-qcom-qspi.ko",
|
|
|
|
"drivers/spi/spi-qup.ko",
|
|
|
|
"drivers/spmi/spmi-pmic-arb.ko",
|
|
|
|
"drivers/thermal/qcom/lmh.ko",
|
|
|
|
"drivers/thermal/qcom/qcom-spmi-adc-tm5.ko",
|
|
|
|
"drivers/thermal/qcom/qcom-spmi-temp-alarm.ko",
|
|
|
|
"drivers/thermal/qcom/qcom_tsens.ko",
|
|
|
|
"drivers/tty/serial/msm_serial.ko",
|
|
|
|
"drivers/ufs/host/ufs_qcom.ko",
|
|
|
|
"drivers/usb/common/ulpi.ko",
|
|
|
|
"drivers/usb/host/ohci-hcd.ko",
|
|
|
|
"drivers/usb/host/ohci-pci.ko",
|
|
|
|
"drivers/usb/host/ohci-platform.ko",
|
|
|
|
"drivers/usb/typec/qcom-pmic-typec.ko",
|
|
|
|
"net/mac80211/mac80211.ko",
|
|
|
|
"net/qrtr/qrtr.ko",
|
|
|
|
"net/qrtr/qrtr-mhi.ko",
|
|
|
|
"net/qrtr/qrtr-smd.ko",
|
|
|
|
"net/qrtr/qrtr-tun.ko",
|
|
|
|
"net/wireless/cfg80211.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-dmic.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-hdmi-codec.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-lpass-macro-common.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-lpass-va-macro.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-lpass-wsa-macro.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-max98927.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-rl6231.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-rt5663.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-wcd-mbhc.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-wcd9335.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-wcd934x.ko",
|
|
|
|
"sound/soc/codecs/snd-soc-wsa881x.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6adm.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6afe.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6afe-clocks.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6afe-dai.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6apm-dai.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6apm-lpass-dais.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6asm.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6asm-dai.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6core.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6prm.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6prm-clocks.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/q6routing.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/snd-q6apm.ko",
|
|
|
|
"sound/soc/qcom/qdsp6/snd-q6dsp-common.ko",
|
|
|
|
"sound/soc/qcom/snd-soc-qcom-common.ko",
|
|
|
|
"sound/soc/qcom/snd-soc-qcom-sdw.ko",
|
|
|
|
"sound/soc/qcom/snd-soc-sdm845.ko",
|
|
|
|
"sound/soc/qcom/snd-soc-sm8250.ko",
|
|
|
|
]
|
|
|
|
|
|
|
|
_DB845C_WATCHDOG_MODULE_OUTS = [
|
|
|
|
"drivers/watchdog/pm8916_wdt.ko",
|
|
|
|
"drivers/watchdog/qcom-wdt.ko",
|
|
|
|
]
|
|
|
|
|
2023-06-22 23:08:27 +09:00
|
|
|
kernel_build(
|
2023-06-23 19:03:10 +09:00
|
|
|
name = "db845c_no_kgdb",
|
2022-09-03 04:21:44 +09:00
|
|
|
outs = [
|
2022-04-26 13:17:00 +09:00
|
|
|
"arch/arm64/boot/dts/qcom/qrb5165-rb5.dtb",
|
|
|
|
"arch/arm64/boot/dts/qcom/sdm845-db845c.dtb",
|
2022-02-02 09:18:49 +09:00
|
|
|
"arch/arm64/boot/dts/qcom/sm8450-qrd.dtb",
|
2022-04-26 13:17:00 +09:00
|
|
|
],
|
2023-06-22 23:08:27 +09:00
|
|
|
# Enable mixed build.
|
|
|
|
base_kernel = ":kernel_aarch64",
|
|
|
|
build_config = "build.config.db845c",
|
|
|
|
collect_unstripped_modules = True,
|
|
|
|
kmi_symbol_list = "android/abi_gki_aarch64_db845c",
|
2023-05-12 21:04:53 +09:00
|
|
|
make_goals = [
|
|
|
|
"modules",
|
|
|
|
"qcom/sdm845-db845c.dtb",
|
|
|
|
"qcom/qrb5165-rb5.dtb",
|
|
|
|
"qcom/sm8450-qrd.dtb",
|
|
|
|
],
|
2023-06-23 19:03:10 +09:00
|
|
|
module_outs = _DB845C_MODULE_OUTS + _DB845C_WATCHDOG_MODULE_OUTS,
|
|
|
|
strip_modules = True,
|
|
|
|
)
|
|
|
|
|
|
|
|
kernel_build(
|
|
|
|
name = "db845c_with_kgdb",
|
|
|
|
outs = [
|
|
|
|
"arch/arm64/boot/dts/qcom/qrb5165-rb5.dtb",
|
|
|
|
"arch/arm64/boot/dts/qcom/sdm845-db845c.dtb",
|
|
|
|
"arch/arm64/boot/dts/qcom/sm8450-qrd.dtb",
|
2022-04-26 13:17:00 +09:00
|
|
|
],
|
2023-06-23 19:03:10 +09:00
|
|
|
# Enable mixed build.
|
|
|
|
base_kernel = ":kernel_aarch64",
|
|
|
|
build_config = "build.config.db845c",
|
|
|
|
make_goals = [
|
|
|
|
"modules",
|
|
|
|
"qcom/sdm845-db845c.dtb",
|
|
|
|
"qcom/qrb5165-rb5.dtb",
|
|
|
|
"qcom/sm8450-qrd.dtb",
|
|
|
|
],
|
|
|
|
module_outs = _DB845C_MODULE_OUTS,
|
2023-06-22 23:08:27 +09:00
|
|
|
strip_modules = True,
|
|
|
|
)
|
|
|
|
|
2023-06-23 19:03:10 +09:00
|
|
|
alias(
|
|
|
|
name = "db845c",
|
|
|
|
actual = select({
|
|
|
|
"//build/kernel/kleaf:kgdb_is_true": "db845c_with_kgdb",
|
|
|
|
"//conditions:default": "db845c_no_kgdb",
|
|
|
|
}),
|
|
|
|
)
|
|
|
|
|
2023-06-22 23:08:27 +09:00
|
|
|
kernel_abi(
|
|
|
|
name = "db845c_abi",
|
|
|
|
kernel_build = ":db845c",
|
|
|
|
kmi_symbol_list_add_only = True,
|
|
|
|
)
|
|
|
|
|
|
|
|
kernel_modules_install(
|
|
|
|
name = "db845c_modules_install",
|
|
|
|
kernel_build = ":db845c",
|
|
|
|
)
|
|
|
|
|
|
|
|
merged_kernel_uapi_headers(
|
|
|
|
name = "db845c_merged_kernel_uapi_headers",
|
|
|
|
kernel_build = ":db845c",
|
|
|
|
)
|
|
|
|
|
|
|
|
kernel_images(
|
|
|
|
name = "db845c_images",
|
|
|
|
build_initramfs = True,
|
|
|
|
kernel_build = ":db845c",
|
|
|
|
kernel_modules_install = ":db845c_modules_install",
|
|
|
|
)
|
|
|
|
|
|
|
|
copy_to_dist_dir(
|
|
|
|
name = "db845c_dist",
|
|
|
|
data = [
|
|
|
|
":db845c",
|
|
|
|
":db845c_images",
|
|
|
|
":db845c_modules_install",
|
|
|
|
":db845c_merged_kernel_uapi_headers",
|
|
|
|
# Mixed build: Additional GKI artifacts.
|
|
|
|
":kernel_aarch64",
|
|
|
|
":kernel_aarch64_modules",
|
|
|
|
":kernel_aarch64_additional_artifacts",
|
|
|
|
],
|
|
|
|
dist_dir = "out/db845/dist",
|
|
|
|
flat = True,
|
|
|
|
log = "info",
|
2022-04-26 13:17:00 +09:00
|
|
|
)
|
2022-10-12 15:07:33 +09:00
|
|
|
|
2023-04-11 19:52:32 +09:00
|
|
|
_ROCKPI4_MODULE_OUTS = [
|
|
|
|
# keep sorted
|
|
|
|
"drivers/block/virtio_blk.ko",
|
|
|
|
"drivers/char/hw_random/virtio-rng.ko",
|
|
|
|
"drivers/clk/clk-rk808.ko",
|
|
|
|
"drivers/cpufreq/cpufreq-dt.ko",
|
|
|
|
"drivers/dma/pl330.ko",
|
|
|
|
"drivers/gpu/drm/bridge/analogix/analogix_dp.ko",
|
|
|
|
"drivers/gpu/drm/bridge/synopsys/dw-hdmi.ko",
|
|
|
|
"drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.ko",
|
|
|
|
"drivers/gpu/drm/display/drm_display_helper.ko",
|
|
|
|
"drivers/gpu/drm/drm_dma_helper.ko",
|
|
|
|
"drivers/gpu/drm/rockchip/rockchipdrm.ko",
|
|
|
|
"drivers/i2c/busses/i2c-rk3x.ko",
|
|
|
|
"drivers/iio/adc/rockchip_saradc.ko",
|
|
|
|
"drivers/iio/buffer/industrialio-triggered-buffer.ko",
|
|
|
|
"drivers/iio/buffer/kfifo_buf.ko",
|
|
|
|
"drivers/mfd/rk808.ko",
|
|
|
|
"drivers/mmc/core/pwrseq_simple.ko",
|
|
|
|
"drivers/mmc/host/cqhci.ko",
|
|
|
|
"drivers/mmc/host/dw_mmc.ko",
|
|
|
|
"drivers/mmc/host/dw_mmc-pltfm.ko",
|
|
|
|
"drivers/mmc/host/dw_mmc-rockchip.ko",
|
|
|
|
"drivers/mmc/host/sdhci-of-arasan.ko",
|
|
|
|
"drivers/net/ethernet/stmicro/stmmac/dwmac-rk.ko",
|
|
|
|
"drivers/net/ethernet/stmicro/stmmac/stmmac.ko",
|
|
|
|
"drivers/net/ethernet/stmicro/stmmac/stmmac-platform.ko",
|
|
|
|
"drivers/net/net_failover.ko",
|
|
|
|
"drivers/net/pcs/pcs_xpcs.ko",
|
|
|
|
"drivers/net/virtio_net.ko",
|
|
|
|
"drivers/pci/controller/pcie-rockchip-host.ko",
|
|
|
|
"drivers/phy/rockchip/phy-rockchip-emmc.ko",
|
|
|
|
"drivers/phy/rockchip/phy-rockchip-inno-usb2.ko",
|
|
|
|
"drivers/phy/rockchip/phy-rockchip-pcie.ko",
|
|
|
|
"drivers/phy/rockchip/phy-rockchip-typec.ko",
|
|
|
|
"drivers/pwm/pwm-rockchip.ko",
|
|
|
|
"drivers/regulator/fan53555.ko",
|
|
|
|
"drivers/regulator/pwm-regulator.ko",
|
|
|
|
"drivers/regulator/rk808-regulator.ko",
|
|
|
|
"drivers/rtc/rtc-rk808.ko",
|
|
|
|
"drivers/soc/rockchip/io-domain.ko",
|
|
|
|
"drivers/thermal/rockchip_thermal.ko",
|
|
|
|
"drivers/usb/host/ohci-hcd.ko",
|
|
|
|
"drivers/usb/host/ohci-platform.ko",
|
|
|
|
"drivers/virtio/virtio_pci.ko",
|
|
|
|
"drivers/virtio/virtio_pci_legacy_dev.ko",
|
|
|
|
"drivers/virtio/virtio_pci_modern_dev.ko",
|
|
|
|
"net/core/failover.ko",
|
|
|
|
]
|
|
|
|
|
|
|
|
_ROCKPI4_WATCHDOG_MODULE_OUTS = [
|
|
|
|
# keep sorted
|
|
|
|
"drivers/watchdog/dw_wdt.ko",
|
|
|
|
]
|
|
|
|
|
2022-11-16 16:01:00 +09:00
|
|
|
# TODO(b/258259749): Convert rockpi4 to mixed build
|
|
|
|
kernel_build(
|
2023-04-11 19:52:32 +09:00
|
|
|
name = "rockpi4_no_kgdb",
|
2022-11-16 16:01:00 +09:00
|
|
|
outs = [
|
|
|
|
"Image",
|
|
|
|
"System.map",
|
|
|
|
"modules.builtin",
|
|
|
|
"modules.builtin.modinfo",
|
|
|
|
"rk3399-rock-pi-4b.dtb",
|
|
|
|
"vmlinux",
|
|
|
|
"vmlinux.symvers",
|
|
|
|
],
|
|
|
|
build_config = "build.config.rockpi4",
|
|
|
|
dtstree = "//common-modules/virtual-device:rockpi4_dts",
|
2023-05-12 21:04:53 +09:00
|
|
|
make_goals = [
|
|
|
|
"Image",
|
|
|
|
"modules",
|
|
|
|
"rk3399-rock-pi-4b.dtb",
|
|
|
|
],
|
2023-08-07 21:42:40 +09:00
|
|
|
module_outs = get_gki_modules_list("arm64") + _ROCKPI4_MODULE_OUTS + _ROCKPI4_WATCHDOG_MODULE_OUTS,
|
2023-06-22 23:08:27 +09:00
|
|
|
visibility = ["//visibility:private"],
|
2023-04-11 19:52:32 +09:00
|
|
|
)
|
|
|
|
|
|
|
|
# TODO(b/258259749): Convert rockpi4 to mixed build
|
|
|
|
kernel_build(
|
|
|
|
name = "rockpi4_with_kgdb",
|
|
|
|
outs = [
|
|
|
|
"Image",
|
|
|
|
"System.map",
|
|
|
|
"modules.builtin",
|
|
|
|
"modules.builtin.modinfo",
|
|
|
|
"rk3399-rock-pi-4b.dtb",
|
|
|
|
"vmlinux",
|
|
|
|
"vmlinux.symvers",
|
|
|
|
],
|
|
|
|
build_config = "build.config.rockpi4",
|
|
|
|
dtstree = "//common-modules/virtual-device:rockpi4_dts",
|
|
|
|
make_goals = [
|
|
|
|
"Image",
|
|
|
|
"modules",
|
|
|
|
"rk3399-rock-pi-4b.dtb",
|
2022-11-16 16:01:00 +09:00
|
|
|
],
|
2023-08-07 21:42:40 +09:00
|
|
|
module_outs = get_gki_modules_list("arm64") + _ROCKPI4_MODULE_OUTS,
|
2023-06-22 23:08:27 +09:00
|
|
|
visibility = ["//visibility:private"],
|
2023-04-11 19:52:32 +09:00
|
|
|
)
|
|
|
|
|
|
|
|
alias(
|
|
|
|
name = "rockpi4",
|
|
|
|
actual = select({
|
|
|
|
"//build/kernel/kleaf:kgdb_is_true": "rockpi4_with_kgdb",
|
|
|
|
"//conditions:default": "rockpi4_no_kgdb",
|
|
|
|
}),
|
2022-11-16 16:01:00 +09:00
|
|
|
)
|
|
|
|
|
|
|
|
kernel_modules_install(
|
|
|
|
name = "rockpi4_modules_install",
|
2023-06-22 23:08:27 +09:00
|
|
|
kernel_build = ":rockpi4",
|
2022-11-16 16:01:00 +09:00
|
|
|
)
|
|
|
|
|
|
|
|
kernel_images(
|
|
|
|
name = "rockpi4_images",
|
|
|
|
build_initramfs = True,
|
2023-06-22 23:08:27 +09:00
|
|
|
kernel_build = ":rockpi4",
|
|
|
|
kernel_modules_install = ":rockpi4_modules_install",
|
2022-11-16 16:01:00 +09:00
|
|
|
)
|
|
|
|
|
|
|
|
copy_to_dist_dir(
|
|
|
|
name = "rockpi4_dist",
|
|
|
|
data = [
|
|
|
|
":rockpi4",
|
|
|
|
":rockpi4_images",
|
|
|
|
":rockpi4_modules_install",
|
|
|
|
],
|
|
|
|
dist_dir = "out/rockpi4/dist",
|
|
|
|
flat = True,
|
|
|
|
)
|
|
|
|
|
2021-03-23 18:54:38 +09:00
|
|
|
kernel_build(
|
|
|
|
name = "fips140",
|
|
|
|
outs = [],
|
|
|
|
base_kernel = ":kernel_aarch64",
|
|
|
|
build_config = "build.config.gki.aarch64.fips140",
|
|
|
|
module_outs = ["crypto/fips140.ko"],
|
|
|
|
)
|
|
|
|
|
|
|
|
copy_to_dist_dir(
|
|
|
|
name = "fips140_dist",
|
|
|
|
data = [
|
|
|
|
":fips140",
|
|
|
|
],
|
|
|
|
dist_dir = "out/fips140/dist",
|
|
|
|
flat = True,
|
|
|
|
)
|
|
|
|
|
2022-11-12 09:37:02 +09:00
|
|
|
# allmodconfig build tests.
|
|
|
|
# These are build tests only, so:
|
|
|
|
# - outs are intentionally set to empty to not copy anything to DIST_DIR
|
|
|
|
# - --allow-undeclared-modules must be used so modules are not declared or copied.
|
|
|
|
# - No dist target because these are build tests. We don't care about the artifacts.
|
|
|
|
|
2022-11-24 21:00:01 +09:00
|
|
|
# tools/bazel build --allow_undeclared_modules //common:kernel_aarch64_allmodconfig
|
2022-11-12 09:37:02 +09:00
|
|
|
kernel_build(
|
2022-11-24 21:00:01 +09:00
|
|
|
name = "kernel_aarch64_allmodconfig",
|
2022-11-12 09:37:02 +09:00
|
|
|
# Hack to actually check the build.
|
|
|
|
# Otherwise, Bazel thinks that there are no output files, and skip building.
|
|
|
|
outs = [".config"],
|
|
|
|
build_config = "build.config.allmodconfig.aarch64",
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
2022-11-24 21:00:01 +09:00
|
|
|
# tools/bazel build --allow_undeclared_modules //common:kernel_x86_64_allmodconfig
|
2022-11-12 09:37:02 +09:00
|
|
|
kernel_build(
|
2022-11-24 21:00:01 +09:00
|
|
|
name = "kernel_x86_64_allmodconfig",
|
2022-11-12 09:37:02 +09:00
|
|
|
# Hack to actually check the build.
|
|
|
|
# Otherwise, Bazel thinks that there are no output files, and skip building.
|
|
|
|
outs = [".config"],
|
2023-06-28 03:19:15 +09:00
|
|
|
arch = "x86_64",
|
2022-11-12 09:37:02 +09:00
|
|
|
build_config = "build.config.allmodconfig.x86_64",
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
2022-11-24 21:00:01 +09:00
|
|
|
# tools/bazel build --allow_undeclared_modules //common:kernel_arm_allmodconfig
|
2022-11-12 09:37:02 +09:00
|
|
|
kernel_build(
|
2022-11-24 21:00:01 +09:00
|
|
|
name = "kernel_arm_allmodconfig",
|
2022-11-12 09:37:02 +09:00
|
|
|
# Hack to actually check the build.
|
|
|
|
# Otherwise, Bazel thinks that there are no output files, and skip building.
|
|
|
|
outs = [".config"],
|
2023-06-28 03:19:15 +09:00
|
|
|
arch = "arm",
|
2022-11-12 09:37:02 +09:00
|
|
|
build_config = "build.config.allmodconfig.arm",
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
2022-10-12 15:07:33 +09:00
|
|
|
# DDK Headers
|
2022-10-29 08:55:44 +09:00
|
|
|
# All headers. These are the public targets for DDK modules to use.
|
|
|
|
alias(
|
2022-10-12 15:07:33 +09:00
|
|
|
name = "all_headers",
|
2022-10-29 08:55:44 +09:00
|
|
|
actual = "all_headers_aarch64",
|
|
|
|
visibility = ["//visibility:public"],
|
|
|
|
)
|
|
|
|
|
|
|
|
ddk_headers(
|
|
|
|
name = "all_headers_aarch64",
|
|
|
|
hdrs = [":all_headers_allowlist_aarch64"] + select({
|
|
|
|
"//build/kernel/kleaf:allow_ddk_unsafe_headers_set": [":all_headers_unsafe"],
|
|
|
|
"//conditions:default": [],
|
|
|
|
}),
|
|
|
|
visibility = ["//visibility:public"],
|
|
|
|
)
|
|
|
|
|
2022-11-23 07:32:14 +09:00
|
|
|
ddk_headers(
|
|
|
|
name = "all_headers_arm",
|
|
|
|
hdrs = [":all_headers_allowlist_arm"] + select({
|
|
|
|
"//build/kernel/kleaf:allow_ddk_unsafe_headers_set": [":all_headers_unsafe"],
|
|
|
|
"//conditions:default": [],
|
|
|
|
}),
|
|
|
|
visibility = ["//visibility:public"],
|
|
|
|
)
|
|
|
|
|
2022-12-09 06:20:51 +09:00
|
|
|
ddk_headers(
|
|
|
|
name = "all_headers_riscv64",
|
|
|
|
hdrs = [":all_headers_allowlist_riscv64"] + select({
|
|
|
|
"//build/kernel/kleaf:allow_ddk_unsafe_headers_set": [":all_headers_unsafe"],
|
|
|
|
"//conditions:default": [],
|
|
|
|
}),
|
|
|
|
visibility = ["//visibility:public"],
|
|
|
|
)
|
|
|
|
|
2022-10-29 08:55:44 +09:00
|
|
|
ddk_headers(
|
|
|
|
name = "all_headers_x86_64",
|
|
|
|
hdrs = [":all_headers_allowlist_x86_64"] + select({
|
2022-10-12 15:07:33 +09:00
|
|
|
"//build/kernel/kleaf:allow_ddk_unsafe_headers_set": [":all_headers_unsafe"],
|
|
|
|
"//conditions:default": [],
|
|
|
|
}),
|
|
|
|
visibility = ["//visibility:public"],
|
|
|
|
)
|
|
|
|
|
2022-10-29 08:55:44 +09:00
|
|
|
# Implementation details for DDK headers. The targets below cannot be directly
|
|
|
|
# depended on by DDK modules.
|
|
|
|
|
2022-10-12 15:07:33 +09:00
|
|
|
# DDK headers allowlist. This is the list of all headers and include
|
|
|
|
# directories that are safe to use in DDK modules.
|
|
|
|
ddk_headers(
|
2022-10-29 08:55:44 +09:00
|
|
|
name = "all_headers_allowlist_aarch64",
|
|
|
|
hdrs = [
|
|
|
|
":all_headers_allowlist_aarch64_globs",
|
|
|
|
":all_headers_allowlist_common_globs",
|
|
|
|
],
|
2022-10-12 15:07:33 +09:00
|
|
|
# The list of include directories where source files can #include headers
|
|
|
|
# from. In other words, these are the `-I` option to the C compiler.
|
2022-11-04 08:12:31 +09:00
|
|
|
# These are prepended to LINUXINCLUDE.
|
|
|
|
linux_includes = [
|
2022-10-22 12:19:28 +09:00
|
|
|
"arch/arm64/include",
|
|
|
|
"arch/arm64/include/uapi",
|
2022-10-29 08:55:44 +09:00
|
|
|
"include",
|
|
|
|
"include/uapi",
|
|
|
|
],
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
2022-11-23 07:32:14 +09:00
|
|
|
ddk_headers(
|
|
|
|
name = "all_headers_allowlist_arm",
|
|
|
|
hdrs = [
|
|
|
|
":all_headers_allowlist_arm_globs",
|
|
|
|
":all_headers_allowlist_common_globs",
|
|
|
|
],
|
|
|
|
# The list of include directories where source files can #include headers
|
|
|
|
# from. In other words, these are the `-I` option to the C compiler.
|
|
|
|
# These are prepended to LINUXINCLUDE.
|
|
|
|
linux_includes = [
|
|
|
|
"arch/arm/include",
|
|
|
|
"arch/arm/include/uapi",
|
|
|
|
"include",
|
|
|
|
"include/uapi",
|
|
|
|
],
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
2022-12-09 06:20:51 +09:00
|
|
|
ddk_headers(
|
|
|
|
name = "all_headers_allowlist_riscv64",
|
|
|
|
hdrs = [
|
|
|
|
":all_headers_allowlist_common_globs",
|
|
|
|
":all_headers_allowlist_riscv64_globs",
|
|
|
|
],
|
|
|
|
# The list of include directories where source files can #include headers
|
|
|
|
# from. In other words, these are the `-I` option to the C compiler.
|
|
|
|
# These are prepended to LINUXINCLUDE.
|
|
|
|
linux_includes = [
|
|
|
|
"arch/riscv/include",
|
|
|
|
"arch/riscv/include/uapi",
|
|
|
|
"include",
|
|
|
|
"include/uapi",
|
|
|
|
],
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
2022-10-29 08:55:44 +09:00
|
|
|
ddk_headers(
|
|
|
|
name = "all_headers_allowlist_x86_64",
|
|
|
|
hdrs = [
|
|
|
|
":all_headers_allowlist_common_globs",
|
|
|
|
":all_headers_allowlist_x86_64_globs",
|
|
|
|
],
|
|
|
|
# The list of include directories where source files can #include headers
|
|
|
|
# from. In other words, these are the `-I` option to the C compiler.
|
2022-11-04 08:12:31 +09:00
|
|
|
# These are prepended to LINUXINCLUDE.
|
|
|
|
linux_includes = [
|
2022-10-22 15:07:21 +09:00
|
|
|
"arch/x86/include",
|
|
|
|
"arch/x86/include/uapi",
|
2022-10-22 12:19:28 +09:00
|
|
|
"include",
|
|
|
|
"include/uapi",
|
|
|
|
],
|
2022-10-12 15:07:33 +09:00
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
|
|
|
# List of DDK headers allowlist that are glob()-ed to avoid changes of BUILD
|
|
|
|
# file when the list of files changes. All headers in these directories
|
|
|
|
# are safe to use.
|
2022-10-29 08:55:44 +09:00
|
|
|
# These are separate filegroup targets so the all_headers_allowlist_* are
|
|
|
|
# more friendly to batch BUILD file update tools like buildozer.
|
|
|
|
|
2022-12-09 06:20:51 +09:00
|
|
|
# globs() for arm64 only
|
|
|
|
filegroup(
|
|
|
|
name = "all_headers_allowlist_aarch64_globs",
|
|
|
|
srcs = glob(["arch/arm64/include/**/*.h"]),
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
2022-11-23 07:32:14 +09:00
|
|
|
# globs() for arm only
|
|
|
|
filegroup(
|
|
|
|
name = "all_headers_allowlist_arm_globs",
|
|
|
|
srcs = glob(["arch/arm/include/**/*.h"]),
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
2022-12-09 06:20:51 +09:00
|
|
|
# globs() for riscv64 only
|
2022-10-29 08:55:44 +09:00
|
|
|
filegroup(
|
2022-12-09 06:20:51 +09:00
|
|
|
name = "all_headers_allowlist_riscv64_globs",
|
|
|
|
srcs = glob(["arch/riscv/include/**/*.h"]),
|
2022-10-29 08:55:44 +09:00
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
|
|
|
# globs() for x86 only
|
|
|
|
filegroup(
|
|
|
|
name = "all_headers_allowlist_x86_64_globs",
|
|
|
|
srcs = glob(["arch/x86/include/**/*.h"]),
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
|
|
|
# globs() for all architectures
|
2022-10-12 15:07:33 +09:00
|
|
|
filegroup(
|
2022-10-29 08:55:44 +09:00
|
|
|
name = "all_headers_allowlist_common_globs",
|
|
|
|
srcs = glob(["include/**/*.h"]),
|
2022-10-12 15:07:33 +09:00
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|
|
|
|
|
|
|
|
# DDK headers unsafe list. This is the list of all headers and include
|
|
|
|
# directories that may be used during migration from kernel_module's, but
|
|
|
|
# should be avoided in general.
|
|
|
|
# Use with caution; items may:
|
|
|
|
# - be removed without notice
|
|
|
|
# - be moved into all_headers
|
|
|
|
ddk_headers(
|
|
|
|
name = "all_headers_unsafe",
|
2022-10-22 15:07:21 +09:00
|
|
|
hdrs = [
|
|
|
|
"drivers/gpu/drm/virtio/virtgpu_trace.h",
|
|
|
|
],
|
2022-10-12 15:07:33 +09:00
|
|
|
# The list of include directories where source files can #include headers
|
|
|
|
# from. In other words, these are the `-I` option to the C compiler.
|
2022-11-04 08:12:31 +09:00
|
|
|
# Unsafe include directories are appended to ccflags-y.
|
2022-10-12 15:07:33 +09:00
|
|
|
includes = [],
|
|
|
|
visibility = ["//visibility:private"],
|
|
|
|
)
|