[dpdk-dev] [PATCH 2/2] cryptodev: rework cryptodev PMD init to not require rte_vdev.h

De Lara Guarch, Pablo pablo.de.lara.guarch at intel.com
Wed Jul 12 15:07:26 CEST 2017



> -----Original Message-----
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of De Lara Guarch,
> Pablo
> Sent: Wednesday, July 12, 2017 1:40 PM
> To: Jan Blunck <jblunck at infradead.org>; dev at dpdk.org
> Cc: Doherty, Declan <declan.doherty at intel.com>
> Subject: Re: [dpdk-dev] [PATCH 2/2] cryptodev: rework cryptodev PMD init
> to not require rte_vdev.h
> 
> 
> 
> > -----Original Message-----
> > From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Jan Blunck
> > Sent: Wednesday, July 12, 2017 9:00 AM
> > To: dev at dpdk.org
> > Cc: Doherty, Declan <declan.doherty at intel.com>
> > Subject: [dpdk-dev] [PATCH 2/2] cryptodev: rework cryptodev PMD init
> > to not require rte_vdev.h
> >
> > This reworks the library code so that it doesn't require to include
> > rte_vdev.h. This is a preparation to move the vdev bus into a
> > standalone library.
> >
> > Signed-off-by: Jan Blunck <jblunck at infradead.org>
> 
> ...
> 
> > diff --git a/lib/librte_cryptodev/rte_cryptodev_vdev.h
> > b/lib/librte_cryptodev/rte_cryptodev_vdev.h
> > index 94ab9d33d..a877eed74 100644
> > --- a/lib/librte_cryptodev/rte_cryptodev_vdev.h
> > +++ b/lib/librte_cryptodev/rte_cryptodev_vdev.h
> > @@ -33,7 +33,6 @@
> >  #ifndef _RTE_CRYPTODEV_VDEV_H_
> >  #define _RTE_CRYPTODEV_VDEV_H_
> >
> > -#include <rte_vdev.h>
> >  #include <inttypes.h>
> >
> >  #include "rte_cryptodev.h"
> > @@ -72,15 +71,15 @@ struct rte_crypto_vdev_init_params {
> >   * @param	name			PMD type name
> >   * @param	dev_private_size	Size of crypto PMDs private data
> >   * @param	socket_id		Socket to allocate resources on.
> > - * @param	vdev			Pointer to virtual device structure.
> > + * @param	dev			Pointer to device structure.
> >   *
> >   * @return
> >   *   - Cryptodev pointer if device is successfully created.
> >   *   - NULL if device cannot be created.
> >   */
> >  struct rte_cryptodev *
> > -rte_cryptodev_vdev_pmd_init(const char *name, size_t
> dev_private_size,
> > -		int socket_id, struct rte_vdev_device *vdev);
> > +rte_cryptodev_pmd_init(const char *name, size_t dev_private_size,
> > +		int socket_id, struct rte_device *dev);
> 
> Hi Jan,
> 
> Even though now this function does not require the rte_vdev_device
> structure, I would still call it rte_cryptodev_vdev_pmd_init, as it is used for
> virtual crypto devices and not physical ones.
> 
> The rest look ok to me.

Just another note. Check-git-log.sh complains about the title:

Wrong headline format:
        cryptodev: rework cryptodev PMD init to not require rte_vdev.h
Headline too long:
        cryptodev: rework cryptodev PMD init to not require rte_vdev.h

So this needs some rework (e.g. no need to use cryptodev word again).

Thanks,
Pablo
> 
> Thanks,
> Pablo


More information about the dev mailing list