ANDROID: trusty-log: make rate limit configurable

Expose the rate limit interval and burst values as module parameters.
Set the interval parameter to zero to disable rate limiting.

Bug: 228882651

Signed-off-by: Marco Nelissen <[email protected]>
Change-Id: Ib7b645052de4b848a55a11c72d30c3718a4a8496
diff --git a/drivers/trusty/trusty-log.c b/drivers/trusty/trusty-log.c
index 6ad912e..fdc19ca 100644
--- a/drivers/trusty/trusty-log.c
+++ b/drivers/trusty/trusty-log.c
@@ -71,6 +71,10 @@
 static struct ratelimit_state trusty_log_rate_limit =
 	RATELIMIT_STATE_INIT("trusty_log", 1 * HZ, 100);
 
+module_param_named(log_ratelimit_burst, trusty_log_rate_limit.burst, int, 0644);
+module_param_named(log_ratelimit_interval, trusty_log_rate_limit.interval, int,
+		   0644);
+
 /**
  * struct trusty_log_sfile - trusty log misc device state
  *