diff mbox series

[linux-next] hwrng: cctrng - fix missing fips header

Message ID 20200420091318.bj533ppmetonqygn@xzhoux.usersys.redhat.com
State New
Headers show
Series [linux-next] hwrng: cctrng - fix missing fips header | expand

Commit Message

Murphy Zhou April 20, 2020, 9:13 a.m. UTC
In linux-next tree, this is causing build error:

drivers/char/hw_random/cctrng.c: In function ‘cc_trng_compwork_handler’:
drivers/char/hw_random/cctrng.c:334:49: error: ‘fips_enabled’ undeclared (first use in this function); did you mean ‘nx_enabled’?
  if (CC_REG_FLD_GET(RNG_ISR, CRNGT_ERR, isr) && fips_enabled) {
                                                 ^~~~~~~~~~~~
                                                 nx_enabled
drivers/char/hw_random/cctrng.c:334:49: note: each undeclared identifier is reported only once for each function it appears in
drivers/char/hw_random/cctrng.c:335:3: error: implicit declaration of function ‘fips_fail_notify’; did you mean ‘sysfs_notify’?
[-Werror=implicit-function-declaration]
   fips_fail_notify();
   ^~~~~~~~~~~~~~~~
   sysfs_notify
cc1: some warnings being treated as errors

Signed-off-by: Murphy Zhou <jencce.kernel@gmail.com>
---
 drivers/char/hw_random/cctrng.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/drivers/char/hw_random/cctrng.c b/drivers/char/hw_random/cctrng.c
index bdcd56243104..e82716c12c3a 100644
--- a/drivers/char/hw_random/cctrng.c
+++ b/drivers/char/hw_random/cctrng.c
@@ -15,6 +15,7 @@ 
 #include <linux/completion.h>
 #include <linux/of.h>
 #include <linux/bitfield.h>
+#include <linux/fips.h>
 
 #include "cctrng.h"