Linux cryptographic layer development
 help / color / mirror / Atom feed
From: Antoine Tenart <antoine.tenart@bootlin.com>
To: Pascal van Leeuwen <pascalvanl@gmail.com>
Cc: linux-crypto@vger.kernel.org, antoine.tenart@bootlin.com,
	herbert@gondor.apana.org.au, davem@davemloft.net,
	Pascal van Leeuwen <pvanleeuwen@verimatrix.com>
Subject: Re: [PATCHv3 3/4] crypto: inside-secure - add support for PCI based FPGA development board
Date: Mon, 5 Aug 2019 10:36:02 +0200	[thread overview]
Message-ID: <20190805083602.GG14470@kwain> (raw)
In-Reply-To: <1564586959-9963-4-git-send-email-pvanleeuwen@verimatrix.com>

Hello Pascal,

The patch looks mostly good, just a few comments below.

On Wed, Jul 31, 2019 at 05:29:18PM +0200, Pascal van Leeuwen wrote:
> @@ -381,10 +383,11 @@ static int safexcel_hw_init(struct safexcel_crypto_priv *priv)
>  		       EIP197_HIA_DxE_CFG_MAX_DATA_SIZE(8);
>  		val |= EIP197_HIA_DxE_CFG_DATA_CACHE_CTRL(WR_CACHE_3BITS);
>  		val |= EIP197_HIA_DSE_CFG_ALWAYS_BUFFERABLE;
> -		/* FIXME: instability issues can occur for EIP97 but disabling it impact
> -		 * performances.
> +		/*
> +		 * FIXME: instability issues can occur for EIP97 but disabling
> +		 * it impacts performance.
>  		 */

No need to change the comment style here.

> @@ -514,7 +517,8 @@ void safexcel_dequeue(struct safexcel_crypto_priv *priv, int ring)
>  	struct safexcel_context *ctx;
>  	int ret, nreq = 0, cdesc = 0, rdesc = 0, commands, results;
> 
> -	/* If a request wasn't properly dequeued because of a lack of resources,
> +	/*
> +	 * If a request wasn't properly dequeued because of a lack of resources,
>  	 * proceeded it first,
>  	 */

Ditto.

> @@ -543,7 +547,8 @@ void safexcel_dequeue(struct safexcel_crypto_priv *priv, int ring)
> 
> -		/* In case the send() helper did not issue any command to push
> +		/*
> +		 * In case the send() helper did not issue any command to push

Ditto.

> -	/* Not enough resources to handle all the requests. Bail out and save
> +	/*
> +	 * Not enough resources to handle all the requests. Bail out and save

Ditto.

> @@ -731,7 +738,8 @@ static inline void safexcel_handle_result_descriptor(struct safexcel_crypto_priv
>  		       EIP197_xDR_PROC_xD_COUNT(tot_descs * priv->config.rd_offset),
>  		       EIP197_HIA_RDR(priv, ring) + EIP197_HIA_xDR_PROC_COUNT);
> 
> -	/* If the number of requests overflowed the counter, try to proceed more
> +	/*
> +	 * If the number of requests overflowed the counter, try to proceed more

Ditto.

> +#if IS_ENABLED(CONFIG_OF)
> +/*
> + * for Device Tree platform driver
> + */

Single line comment should be:

/* comment */

> +#if IS_ENABLED(CONFIG_PCI)
> +/*
> + * PCIE devices - i.e. Inside Secure development boards
> + */

Here as well.

> +static int crypto_is_pci_probe(struct pci_dev *pdev,
> +			       const struct pci_device_id *ent)

The whole driver uses the "safexcel_" prefix for functions. You should
use it here as well for consistency.

> +void crypto_is_pci_remove(struct pci_dev *pdev)

Here as well.

> +static const struct pci_device_id crypto_is_pci_ids[] = {

Here as well.

> +static struct pci_driver crypto_is_pci_driver = {

Here as well.

> +static int __init crypto_is_init(void)

Here as well.

> +static void __exit crypto_is_exit(void)

Here as well.

Thanks,
Antoine

-- 
Antoine Ténart, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

  reply	other threads:[~2019-08-05  8:36 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-31 15:29 [PATCHv3 0/4] crypto: inside-secure - broaden driver scope Pascal van Leeuwen
2019-07-31 15:29 ` [PATCHv3 1/4] crypto: inside-secure - make driver selectable for non-Marvell hardware Pascal van Leeuwen
2019-08-05  8:04   ` Antoine Tenart
2019-07-31 15:29 ` [PATCHv3 2/4] crypto: inside-secure - Remove redundant algo to engine mapping code Pascal van Leeuwen
2019-08-05  7:51   ` Antoine Tenart
2019-07-31 15:29 ` [PATCHv3 3/4] crypto: inside-secure - add support for PCI based FPGA development board Pascal van Leeuwen
2019-08-05  8:36   ` Antoine Tenart [this message]
2019-08-05  8:47     ` Pascal Van Leeuwen
2019-08-05  9:09       ` Antoine Tenart
2019-08-05  9:49         ` Pascal Van Leeuwen
2019-07-31 15:29 ` [PATCHv3 4/4] crypto: inside-secure - add support for using the EIP197 without vendor firmware Pascal van Leeuwen
2019-08-05  9:07   ` Antoine Tenart
2019-08-05  9:48     ` Pascal Van Leeuwen
2019-08-05  9:54       ` Antoine Tenart
2019-08-05 10:12         ` Pascal Van Leeuwen
2019-08-05 12:43           ` Antoine Tenart
2019-08-05 13:02             ` Pascal Van Leeuwen
2019-08-05 13:12               ` Antoine Tenart

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190805083602.GG14470@kwain \
    --to=antoine.tenart@bootlin.com \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=pascalvanl@gmail.com \
    --cc=pvanleeuwen@verimatrix.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox