Thread (185 messages) 185 messages, 9 authors, 2018-10-23

Re: [PATCH 03/16] crypto/cpt/base: add hardware initialization API for CPT

From: De Lara Guarch, Pablo <hidden>
Date: 2018-06-19 13:56:54

-----Original Message-----
From: Jerin Jacob [mailto:jerin.jacob@caviumnetworks.com]
Sent: Thursday, June 14, 2018 4:14 AM
To: Anoob Joseph <redacted>
Cc: Akhil Goyal <redacted>; De Lara Guarch, Pablo
[off-list ref]; Thomas Monjalon
[off-list ref]; Nithin Dabilpuram [off-list ref];
Ankur Dwivedi [off-list ref]; Murthy NSSR
[off-list ref]; Narayana Prasad
[off-list ref]; Ragothaman Jayaraman
[off-list ref]; Srisivasubramanian Srinivasan
[off-list ref]; dev@dpdk.org
Subject: Re: [PATCH 03/16] crypto/cpt/base: add hardware initialization API for
CPT

-----Original Message-----
quoted
Date: Fri,  8 Jun 2018 22:15:12 +0530
From: Anoob Joseph <redacted>
To: Akhil Goyal <redacted>, Pablo de Lara
[off-list ref], Thomas Monjalon
[off-list ref]
Cc: Nithin Dabilpuram <redacted>, Ankur Dwivedi
[off-list ref], Jerin Jacob
[off-list ref],  Murthy NSSR
[off-list ref], Narayana Prasad
[off-list ref], Ragothaman Jayaraman
[off-list ref], Srisivasubramanian Srinivasan
[off-list ref], dev@dpdk.org
Subject: [PATCH 03/16] crypto/cpt/base: add hardware initialization
API for  CPT
X-Mailer: git-send-email 2.7.4

From: Nithin Dabilpuram <redacted>

Adds hardware device initialization specific api for Cavium CPT device.

Signed-off-by: Ankur Dwivedi <redacted>
Signed-off-by: Murthy NSSR <redacted>
Signed-off-by: Nithin Dabilpuram <redacted>
Signed-off-by: Ragothaman Jayaraman
[off-list ref]
quoted
Signed-off-by: Srisivasubramanian Srinivasan
[off-list ref]
---
 drivers/crypto/cpt/base/cpt8xxx_device.c | 200 ++++++++++++++++
drivers/crypto/cpt/base/cpt8xxx_device.h |  85 +++++++
 drivers/crypto/cpt/base/cpt_debug.h      | 231 +++++++++++++++++++
 drivers/crypto/cpt/base/cpt_device.c     | 383
+++++++++++++++++++++++++++++++
quoted
 drivers/crypto/cpt/base/cpt_device.h     | 162 +++++++++++++
 drivers/crypto/cpt/base/cpt_vf_mbox.c    | 176 ++++++++++++++
 drivers/crypto/cpt/base/cpt_vf_mbox.h    |  60 +++++
 7 files changed, 1297 insertions(+)
 create mode 100644 drivers/crypto/cpt/base/cpt8xxx_device.c
 create mode 100644 drivers/crypto/cpt/base/cpt8xxx_device.h
 create mode 100644 drivers/crypto/cpt/base/cpt_debug.h
 create mode 100644 drivers/crypto/cpt/base/cpt_device.c
 create mode 100644 drivers/crypto/cpt/base/cpt_device.h
 create mode 100644 drivers/crypto/cpt/base/cpt_vf_mbox.c
 create mode 100644 drivers/crypto/cpt/base/cpt_vf_mbox.h

+#include <assert.h>
+#include "cpt_request_mgr.h"
+#include <rte_eal_memconfig.h>
List the external to DPDK includes first, then internal to DPDK and then internal to this PMD,
separating these three blocks with a blank line.
quoted
+
+#ifdef CPT_DEBUG
Remove CPT_DEBUG. No harming in compiling these definitions either case.
It will avoid the chance of build breakage.
...
quoted
+int cptvf_deinit_device(struct cpt_vf *dev) {
+	struct cpt_vf *cptvf = (struct cpt_vf *)dev;
+
+	/* Do misc work one last time */
+	cptvf_poll_misc(cptvf);
+
+	/* TODO anything else ?? */
Remove unclear TODOs
quoted
+
+	return 0;
+}
+
+int cptvf_init_device(struct cpt_vf *cptvf,
Return type should be in the line above the function name,
as per DPDK coding style guidelines.
quoted
+		      void *pdev,
+		      void *reg_base,
+		      char *name,
+		      uint32_t flags)
+{
+	(void) flags;

RTE_SET_USED
Actually, why don't you just remove the parameter?

Thanks,
Pablo
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help