Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c36bdd11 authored by Tim Murray's avatar Tim Murray Committed by Isaac J. Manjarres
Browse files

firmware_class: make firmware caching configurable



Because firmware caching generates uevent messages that are sent over a
netlink socket, it can prevent suspend on many platforms.  It's also not
always useful, so make it a configurable option.

bug 32180327

Change-Id: I1250512b27edb56caa78d536e5ccf1fb669476ad
Signed-off-by: default avatarTim Murray <timmurray@google.com>
Git-repo: https://source.codeaurora.org/quic/la/kernel/msm-4.4


Git-commit: e3198d51be98ec5606e2a2c5112a8a974d354fbc
Signed-off-by: default avatarChintan Pandya <cpandya@codeaurora.org>
[isaacm@codeaurora.org: Resolved trivial merge conflicts]
Signed-off-by: default avatarIsaac J. Manjarres <isaacm@codeaurora.org>
parent e15f923a
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -164,6 +164,11 @@ config FW_LOADER_USER_HELPER_FALLBACK

	  If you are unsure about this, say N here.

config FW_CACHE
       bool "Enable firmware caching during suspend"
       depends on PM_SLEEP
       default n

config WANT_DEV_COREDUMP
	bool
	help
+3 −3
Original line number Diff line number Diff line
@@ -1449,7 +1449,7 @@ request_firmware_nowait(
}
EXPORT_SYMBOL(request_firmware_nowait);

#ifdef CONFIG_PM_SLEEP
#ifdef CONFIG_FW_CACHE
static ASYNC_DOMAIN_EXCLUSIVE(fw_cache_domain);

/**
@@ -1799,7 +1799,7 @@ static void __init fw_cache_init(void)
	INIT_LIST_HEAD(&fw_cache.head);
	fw_cache.state = FW_LOADER_NO_CACHE;

#ifdef CONFIG_PM_SLEEP
#ifdef CONFIG_FW_CACHE
	spin_lock_init(&fw_cache.name_lock);
	INIT_LIST_HEAD(&fw_cache.fw_names);

@@ -1842,7 +1842,7 @@ static int __init firmware_class_init(void)

static void __exit firmware_class_exit(void)
{
#ifdef CONFIG_PM_SLEEP
#ifdef CONFIG_FW_CACHE
	unregister_syscore_ops(&fw_syscore_ops);
	unregister_pm_notifier(&fw_cache.pm_notify);
#endif