Commit f9f28469 authored by Gilad Ben-Yossef's avatar Gilad Ben-Yossef Committed by Greg Kroah-Hartman

staging: ccree: remove unused cc_base parameter

Remove a common parameter named cc_base with the pointer
to the mapped command registers which was used by the
old register access macros that are not longer in use.
Signed-off-by: default avatarGilad Ben-Yossef <gilad@benyossef.com>
Reviewed-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 155ff091
...@@ -225,7 +225,7 @@ static int ssi_aead_init(struct crypto_aead *tfm) ...@@ -225,7 +225,7 @@ static int ssi_aead_init(struct crypto_aead *tfm)
return -ENOMEM; return -ENOMEM;
} }
static void ssi_aead_complete(struct device *dev, void *ssi_req, void __iomem *cc_base) static void ssi_aead_complete(struct device *dev, void *ssi_req)
{ {
struct aead_request *areq = (struct aead_request *)ssi_req; struct aead_request *areq = (struct aead_request *)ssi_req;
struct aead_req_ctx *areq_ctx = aead_request_ctx(areq); struct aead_req_ctx *areq_ctx = aead_request_ctx(areq);
......
...@@ -67,7 +67,7 @@ struct ssi_ablkcipher_ctx { ...@@ -67,7 +67,7 @@ struct ssi_ablkcipher_ctx {
struct crypto_shash *shash_tfm; struct crypto_shash *shash_tfm;
}; };
static void ssi_ablkcipher_complete(struct device *dev, void *ssi_req, void __iomem *cc_base); static void ssi_ablkcipher_complete(struct device *dev, void *ssi_req);
static int validate_keys_sizes(struct ssi_ablkcipher_ctx *ctx_p, u32 size) static int validate_keys_sizes(struct ssi_ablkcipher_ctx *ctx_p, u32 size)
{ {
...@@ -688,8 +688,7 @@ static int ssi_blkcipher_complete(struct device *dev, ...@@ -688,8 +688,7 @@ static int ssi_blkcipher_complete(struct device *dev,
struct scatterlist *dst, struct scatterlist *dst,
struct scatterlist *src, struct scatterlist *src,
unsigned int ivsize, unsigned int ivsize,
void *areq, void *areq)
void __iomem *cc_base)
{ {
int completion_error = 0; int completion_error = 0;
struct ablkcipher_request *req = (struct ablkcipher_request *)areq; struct ablkcipher_request *req = (struct ablkcipher_request *)areq;
...@@ -832,8 +831,7 @@ static int ssi_blkcipher_process( ...@@ -832,8 +831,7 @@ static int ssi_blkcipher_process(
dst); dst);
} else { } else {
rc = ssi_blkcipher_complete(dev, ctx_p, req_ctx, dst, rc = ssi_blkcipher_complete(dev, ctx_p, req_ctx, dst,
src, ivsize, NULL, src, ivsize, NULL);
ctx_p->drvdata->cc_base);
} }
} }
...@@ -849,7 +847,7 @@ static int ssi_blkcipher_process( ...@@ -849,7 +847,7 @@ static int ssi_blkcipher_process(
return rc; return rc;
} }
static void ssi_ablkcipher_complete(struct device *dev, void *ssi_req, void __iomem *cc_base) static void ssi_ablkcipher_complete(struct device *dev, void *ssi_req)
{ {
struct ablkcipher_request *areq = (struct ablkcipher_request *)ssi_req; struct ablkcipher_request *areq = (struct ablkcipher_request *)ssi_req;
struct blkcipher_req_ctx *req_ctx = ablkcipher_request_ctx(areq); struct blkcipher_req_ctx *req_ctx = ablkcipher_request_ctx(areq);
...@@ -858,7 +856,7 @@ static void ssi_ablkcipher_complete(struct device *dev, void *ssi_req, void __io ...@@ -858,7 +856,7 @@ static void ssi_ablkcipher_complete(struct device *dev, void *ssi_req, void __io
unsigned int ivsize = crypto_ablkcipher_ivsize(tfm); unsigned int ivsize = crypto_ablkcipher_ivsize(tfm);
ssi_blkcipher_complete(dev, ctx_p, req_ctx, areq->dst, areq->src, ssi_blkcipher_complete(dev, ctx_p, req_ctx, areq->dst, areq->src,
ivsize, areq, cc_base); ivsize, areq);
} }
/* Async wrap functions */ /* Async wrap functions */
......
...@@ -199,7 +199,6 @@ int init_cc_regs(struct ssi_drvdata *drvdata, bool is_probe) ...@@ -199,7 +199,6 @@ int init_cc_regs(struct ssi_drvdata *drvdata, bool is_probe)
static int init_cc_resources(struct platform_device *plat_dev) static int init_cc_resources(struct platform_device *plat_dev)
{ {
struct resource *req_mem_cc_regs = NULL; struct resource *req_mem_cc_regs = NULL;
void __iomem *cc_base = NULL;
struct ssi_drvdata *new_drvdata; struct ssi_drvdata *new_drvdata;
struct device *dev = &plat_dev->dev; struct device *dev = &plat_dev->dev;
struct device_node *np = dev->of_node; struct device_node *np = dev->of_node;
...@@ -232,8 +231,6 @@ static int init_cc_resources(struct platform_device *plat_dev) ...@@ -232,8 +231,6 @@ static int init_cc_resources(struct platform_device *plat_dev)
dev_dbg(dev, "CC registers mapped from %pa to 0x%p\n", dev_dbg(dev, "CC registers mapped from %pa to 0x%p\n",
&req_mem_cc_regs->start, new_drvdata->cc_base); &req_mem_cc_regs->start, new_drvdata->cc_base);
cc_base = new_drvdata->cc_base;
/* Then IRQ */ /* Then IRQ */
new_drvdata->irq = platform_get_irq(plat_dev, 0); new_drvdata->irq = platform_get_irq(plat_dev, 0);
if (new_drvdata->irq < 0) { if (new_drvdata->irq < 0) {
......
...@@ -100,7 +100,7 @@ ...@@ -100,7 +100,7 @@
#define SSI_MAX_IVGEN_DMA_ADDRESSES 3 #define SSI_MAX_IVGEN_DMA_ADDRESSES 3
struct ssi_crypto_req { struct ssi_crypto_req {
void (*user_cb)(struct device *dev, void *req, void __iomem *cc_base); void (*user_cb)(struct device *dev, void *req);
void *user_arg; void *user_arg;
dma_addr_t ivgen_dma_addr[SSI_MAX_IVGEN_DMA_ADDRESSES]; dma_addr_t ivgen_dma_addr[SSI_MAX_IVGEN_DMA_ADDRESSES];
/* For the first 'ivgen_dma_addr_len' addresses of this array, /* For the first 'ivgen_dma_addr_len' addresses of this array,
......
...@@ -357,7 +357,7 @@ static void ssi_hash_unmap_result(struct device *dev, ...@@ -357,7 +357,7 @@ static void ssi_hash_unmap_result(struct device *dev,
state->digest_result_dma_addr = 0; state->digest_result_dma_addr = 0;
} }
static void ssi_hash_update_complete(struct device *dev, void *ssi_req, void __iomem *cc_base) static void ssi_hash_update_complete(struct device *dev, void *ssi_req)
{ {
struct ahash_request *req = (struct ahash_request *)ssi_req; struct ahash_request *req = (struct ahash_request *)ssi_req;
struct ahash_req_ctx *state = ahash_request_ctx(req); struct ahash_req_ctx *state = ahash_request_ctx(req);
...@@ -368,7 +368,7 @@ static void ssi_hash_update_complete(struct device *dev, void *ssi_req, void __i ...@@ -368,7 +368,7 @@ static void ssi_hash_update_complete(struct device *dev, void *ssi_req, void __i
req->base.complete(&req->base, 0); req->base.complete(&req->base, 0);
} }
static void ssi_hash_digest_complete(struct device *dev, void *ssi_req, void __iomem *cc_base) static void ssi_hash_digest_complete(struct device *dev, void *ssi_req)
{ {
struct ahash_request *req = (struct ahash_request *)ssi_req; struct ahash_request *req = (struct ahash_request *)ssi_req;
struct ahash_req_ctx *state = ahash_request_ctx(req); struct ahash_req_ctx *state = ahash_request_ctx(req);
...@@ -384,7 +384,7 @@ static void ssi_hash_digest_complete(struct device *dev, void *ssi_req, void __i ...@@ -384,7 +384,7 @@ static void ssi_hash_digest_complete(struct device *dev, void *ssi_req, void __i
req->base.complete(&req->base, 0); req->base.complete(&req->base, 0);
} }
static void ssi_hash_complete(struct device *dev, void *ssi_req, void __iomem *cc_base) static void ssi_hash_complete(struct device *dev, void *ssi_req)
{ {
struct ahash_request *req = (struct ahash_request *)ssi_req; struct ahash_request *req = (struct ahash_request *)ssi_req;
struct ahash_req_ctx *state = ahash_request_ctx(req); struct ahash_req_ctx *state = ahash_request_ctx(req);
......
...@@ -189,7 +189,7 @@ static inline void enqueue_seq( ...@@ -189,7 +189,7 @@ static inline void enqueue_seq(
* \param dev * \param dev
* \param dx_compl_h The completion event to signal * \param dx_compl_h The completion event to signal
*/ */
static void request_mgr_complete(struct device *dev, void *dx_compl_h, void __iomem *cc_base) static void request_mgr_complete(struct device *dev, void *dx_compl_h)
{ {
struct completion *this_compl = dx_compl_h; struct completion *this_compl = dx_compl_h;
...@@ -491,8 +491,7 @@ static void proc_completions(struct ssi_drvdata *drvdata) ...@@ -491,8 +491,7 @@ static void proc_completions(struct ssi_drvdata *drvdata)
#endif /* COMPLETION_DELAY */ #endif /* COMPLETION_DELAY */
if (likely(ssi_req->user_cb)) if (likely(ssi_req->user_cb))
ssi_req->user_cb(dev, ssi_req->user_arg, ssi_req->user_cb(dev, ssi_req->user_arg);
drvdata->cc_base);
request_mgr_handle->req_queue_tail = (request_mgr_handle->req_queue_tail + 1) & (MAX_REQUEST_QUEUE_SIZE - 1); request_mgr_handle->req_queue_tail = (request_mgr_handle->req_queue_tail + 1) & (MAX_REQUEST_QUEUE_SIZE - 1);
dev_dbg(dev, "Dequeue request tail=%u\n", dev_dbg(dev, "Dequeue request tail=%u\n",
request_mgr_handle->req_queue_tail); request_mgr_handle->req_queue_tail);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment