aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/ccree/cc_hw_queue_defs.h
diff options
context:
space:
mode:
authorGilad Ben-Yossef <gilad@benyossef.com>2017-05-07 16:35:57 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-05-15 07:41:59 +0200
commitdf8a6b053c915bad3d5f4aab1e8fa7c87f88b176 (patch)
tree4a5fcb7a283e4dffabb387cfa5caebda88a9e190 /drivers/staging/ccree/cc_hw_queue_defs.h
parentstaging: ccree: remove min/max macros (diff)
downloadlinux-dev-df8a6b053c915bad3d5f4aab1e8fa7c87f88b176.tar.xz
linux-dev-df8a6b053c915bad3d5f4aab1e8fa7c87f88b176.zip
staging: ccree: drop open coded init for memset
Replace open coded struct zeroing with a memset call. Signed-off-by: Gilad Ben-Yossef <gilad@benyossef.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/ccree/cc_hw_queue_defs.h')
-rw-r--r--drivers/staging/ccree/cc_hw_queue_defs.h9
1 files changed, 1 insertions, 8 deletions
diff --git a/drivers/staging/ccree/cc_hw_queue_defs.h b/drivers/staging/ccree/cc_hw_queue_defs.h
index 8c2b7f489373..f17c37db6258 100644
--- a/drivers/staging/ccree/cc_hw_queue_defs.h
+++ b/drivers/staging/ccree/cc_hw_queue_defs.h
@@ -172,14 +172,7 @@ typedef enum HwDesKeySize {
#define GET_HW_Q_DESC_WORD_IDX(descWordIdx) (CC_REG_OFFSET(CRY_KERNEL, DSCRPTR_QUEUE_WORD ## descWordIdx) )
-#define HW_DESC_INIT(pDesc) do { \
- (pDesc)->word[0] = 0; \
- (pDesc)->word[1] = 0; \
- (pDesc)->word[2] = 0; \
- (pDesc)->word[3] = 0; \
- (pDesc)->word[4] = 0; \
- (pDesc)->word[5] = 0; \
-} while (0)
+#define HW_DESC_INIT(pDesc) memset(pDesc, 0, sizeof(HwDesc_s))
/*!
* This macro indicates the end of current HW descriptors flow and release the HW engines.