|
@@ -13,6 +13,7 @@
|
|
|
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
|
|
|
|
|
|
#include <linux/err.h>
|
|
|
+#include <linux/ratelimit.h>
|
|
|
#include <linux/key-type.h>
|
|
|
#include <crypto/public_key.h>
|
|
|
#include <keys/asymmetric-type.h>
|
|
@@ -45,8 +46,8 @@ static struct key *request_asymmetric_key(struct key *keyring, uint32_t keyid)
|
|
|
}
|
|
|
|
|
|
if (IS_ERR(key)) {
|
|
|
- pr_warn("Request for unknown key '%s' err %ld\n",
|
|
|
- name, PTR_ERR(key));
|
|
|
+ pr_err_ratelimited("Request for unknown key '%s' err %ld\n",
|
|
|
+ name, PTR_ERR(key));
|
|
|
switch (PTR_ERR(key)) {
|
|
|
/* Hide some search errors */
|
|
|
case -EACCES:
|