################################################################################
#
# Wi-Fi support
#
################################################################################

FEATURE_WIFI_PACKAGE_VERSION = 1.0
FEATURE_WIFI_PACKAGE_LICENSE = MIT

define FEATURE_WIFI_LINUX_CONFIG_FIXUPS
	$(call KCONFIG_ENABLE_OPT,CONFIG_WLAN)
	$(call KCONFIG_ENABLE_OPT,CONFIG_RFKILL)
	$(call KCONFIG_SET_OPT,CONFIG_MAC80211,m)
	$(call KCONFIG_SET_OPT,CONFIG_CFG80211,m)

	$(if $(filter y,$(BR2_PACKAGE_FEATURE_WIFI_DONGLE_REALTEK)),
		$(call KCONFIG_ENABLE_OPT,CONFIG_WLAN_VENDOR_REALTEK)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW89)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8703B)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8723CS)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8723D)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8723DE)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8723DS)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8723DU)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8723X)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8821C)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8821CE)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8821CS)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8821CU)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8822B)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8822BE)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8822BS)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8822BU)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8822C)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8822CU)
		$(call KCONFIG_ENABLE_OPT,CONFIG_RTW88_8822CE)
	)
endef


$(eval $(generic-package))
