staging: ccree: fix FIPS mgr naming convention

The FIPS manager files were using a naming convention which was
inconsistent (ssi vs. cc) and often too long.

Make the code more readable by switching to a simpler, consistent naming
convention.

Signed-off-by: Gilad Ben-Yossef <gilad@benyossef.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Gilad Ben-Yossef 2017-12-12 14:53:10 +00:00 committed by Greg Kroah-Hartman
parent e24673641e
commit 6dc4d30252
3 changed files with 9 additions and 9 deletions

View File

@ -307,7 +307,7 @@ static int init_cc_resources(struct platform_device *plat_dev)
} }
#endif #endif
rc = ssi_fips_init(new_drvdata); rc = cc_fips_init(new_drvdata);
if (rc) { if (rc) {
dev_err(dev, "CC_FIPS_INIT failed 0x%x\n", rc); dev_err(dev, "CC_FIPS_INIT failed 0x%x\n", rc);
goto post_sysfs_err; goto post_sysfs_err;
@ -393,7 +393,7 @@ post_req_mgr_err:
post_sram_mgr_err: post_sram_mgr_err:
cc_sram_mgr_fini(new_drvdata); cc_sram_mgr_fini(new_drvdata);
post_fips_init_err: post_fips_init_err:
ssi_fips_fini(new_drvdata); cc_fips_fini(new_drvdata);
post_sysfs_err: post_sysfs_err:
#ifdef ENABLE_CC_SYSFS #ifdef ENABLE_CC_SYSFS
ssi_sysfs_fini(); ssi_sysfs_fini();
@ -424,7 +424,7 @@ static void cleanup_cc_resources(struct platform_device *plat_dev)
cc_buffer_mgr_fini(drvdata); cc_buffer_mgr_fini(drvdata);
cc_req_mgr_fini(drvdata); cc_req_mgr_fini(drvdata);
cc_sram_mgr_fini(drvdata); cc_sram_mgr_fini(drvdata);
ssi_fips_fini(drvdata); cc_fips_fini(drvdata);
#ifdef ENABLE_CC_SYSFS #ifdef ENABLE_CC_SYSFS
ssi_sysfs_fini(); ssi_sysfs_fini();
#endif #endif

View File

@ -51,7 +51,7 @@ void cc_set_ree_fips_status(struct cc_drvdata *drvdata, bool status)
cc_iowrite(drvdata, CC_REG(HOST_GPR0), val); cc_iowrite(drvdata, CC_REG(HOST_GPR0), val);
} }
void ssi_fips_fini(struct cc_drvdata *drvdata) void cc_fips_fini(struct cc_drvdata *drvdata)
{ {
struct cc_fips_handle *fips_h = drvdata->fips_handle; struct cc_fips_handle *fips_h = drvdata->fips_handle;
@ -105,7 +105,7 @@ static void fips_dsr(unsigned long devarg)
} }
/* The function called once at driver entry point .*/ /* The function called once at driver entry point .*/
int ssi_fips_init(struct cc_drvdata *p_drvdata) int cc_fips_init(struct cc_drvdata *p_drvdata)
{ {
struct cc_fips_handle *fips_h; struct cc_fips_handle *fips_h;
struct device *dev = drvdata_to_dev(p_drvdata); struct device *dev = drvdata_to_dev(p_drvdata);

View File

@ -27,19 +27,19 @@ enum cc_fips_status {
CC_FIPS_SYNC_STATUS_RESERVE32B = S32_MAX CC_FIPS_SYNC_STATUS_RESERVE32B = S32_MAX
}; };
int ssi_fips_init(struct cc_drvdata *p_drvdata); int cc_fips_init(struct cc_drvdata *p_drvdata);
void ssi_fips_fini(struct cc_drvdata *drvdata); void cc_fips_fini(struct cc_drvdata *drvdata);
void fips_handler(struct cc_drvdata *drvdata); void fips_handler(struct cc_drvdata *drvdata);
void cc_set_ree_fips_status(struct cc_drvdata *drvdata, bool ok); void cc_set_ree_fips_status(struct cc_drvdata *drvdata, bool ok);
#else /* CONFIG_CRYPTO_FIPS */ #else /* CONFIG_CRYPTO_FIPS */
static inline int ssi_fips_init(struct cc_drvdata *p_drvdata) static inline int cc_fips_init(struct cc_drvdata *p_drvdata)
{ {
return 0; return 0;
} }
static inline void ssi_fips_fini(struct cc_drvdata *drvdata) {} static inline void cc_fips_fini(struct cc_drvdata *drvdata) {}
static inline void cc_set_ree_fips_status(struct cc_drvdata *drvdata, static inline void cc_set_ree_fips_status(struct cc_drvdata *drvdata,
bool ok) {} bool ok) {}
static inline void fips_handler(struct cc_drvdata *drvdata) {} static inline void fips_handler(struct cc_drvdata *drvdata) {}