lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e4cf41af-5415-f923-25f0-07e837bd7a1a@quicinc.com>
Date: Wed, 21 Feb 2024 23:32:38 +0530
From: Sricharan Ramabadhran <quic_srichara@...cinc.com>
To: Md Sadre Alam <quic_mdalam@...cinc.com>, <thara.gopinath@...il.com>,
        <herbert@...dor.apana.org.au>, <davem@...emloft.net>,
        <agross@...nel.org>, <andersson@...nel.org>,
        <konrad.dybcio@...aro.org>, <vkoul@...nel.org>,
        <linux-crypto@...r.kernel.org>, <linux-arm-msm@...r.kernel.org>,
        <linux-kernel@...r.kernel.org>, <dmaengine@...r.kernel.org>,
        <quic_varada@...cinc.com>
Subject: Re: [PATCH 01/11] crypto: qce - Add support for crypto address read



On 12/14/2023 5:12 PM, Md Sadre Alam wrote:
> Get crypto base address from DT. This will use for
> command descriptor support for crypto register r/w
> via BAM/DMA
> 
> Signed-off-by: Md Sadre Alam <quic_mdalam@...cinc.com>
> ---
>   drivers/crypto/qce/core.c | 9 +++++++++
>   drivers/crypto/qce/core.h | 1 +
>   2 files changed, 10 insertions(+)
> 
> diff --git a/drivers/crypto/qce/core.c b/drivers/crypto/qce/core.c
> index 28b5fd823827..5af0dc40738a 100644
> --- a/drivers/crypto/qce/core.c
> +++ b/drivers/crypto/qce/core.c
> @@ -192,6 +192,7 @@ static int qce_crypto_probe(struct platform_device *pdev)
>   {
>   	struct device *dev = &pdev->dev;
>   	struct qce_device *qce;
> +	struct resource *res;
>   	int ret;
>   
>   	qce = devm_kzalloc(dev, sizeof(*qce), GFP_KERNEL);
> @@ -205,6 +206,14 @@ static int qce_crypto_probe(struct platform_device *pdev)
>   	if (IS_ERR(qce->base))
>   		return PTR_ERR(qce->base);
>   
> +	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);

  Can this be combined with devm_platform_get_and_ioremap_resource ?
> +	if (!res)
> +		return -ENOMEM;
> +	qce->base_dma = dma_map_resource(dev, res->start, resource_size(res),
> +					 DMA_BIDIRECTIONAL, 0);

  unmap in remove and error cases ?

Regards,
  Sricharan

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ