Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp5175840pxj; Wed, 9 Jun 2021 10:53:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzbN9pLA7AhTVo9d1ap/iZxHaO/aJ3mtjfKL+uaEhQIriAUS4cToyc3gHxtc3RYcIxwfcdC X-Received: by 2002:a05:6402:177a:: with SMTP id da26mr647233edb.40.1623261184600; Wed, 09 Jun 2021 10:53:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623261184; cv=none; d=google.com; s=arc-20160816; b=MMYZR3YJoiu4dRQSeImAogADomC8siFkKlI7bOAniAWhoBSTgIAoCYbk//T/6/YCqK /DNGYUnfvcO0MzreOPx6CqVmWhY49YU0pMhXynbFYAhAN8ary09m+5PpwJqX4n5U6Wl+ w1w6xffwFBKhygAjC8oG7wWREeWEW9zYdClaAgDIsYXsV9KTQ+zFNIzHM5Xew1zdBe4Q h4/IRlGGmzGfiBKsNvHuMY52jU4xujDBdYXwy1ERTJXoATh7KZF3j7SchE3/LpcAO0C8 l+fwDsx2DmbsLlrwiwhMYFYJ2DvjkFLlnUnnPKw99Cqp/E/6G/92rogIj3n8GHm7xiZb djNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature :dkim-filter; bh=/HOmnjissLx+lpthetr985W/qYtb76YNAtpL9Q+TgUo=; b=mjFJxAbcPtlkAEkQO3OAUClnqEOnj2zehdhfE0suMgd1nSrx/rhRqsM1qVjVQOff0p jy4NJpFdpYOtVxrqM9EVAySECOvEETiVYK//PueqV4YgNzyyNS9RztVfb0bfWqpw6/LH vVLeHrOS216smbrXCrdqaSyrstA/rJMRzoJ0aCAKyE7ZikYrjD/OM++7qF0PGQVloUo7 fo3Plw1W6nwgS6Pq5rfhW01LEczsPIZgUyo6HOx7HRIELtuRUjk+UjEzuznT9MJG7oGh SBdxRfaHtaMWilL3wrDq3nGoFRSFS1CA09LqTEa29wnbZx52Ueptp5ipBaFfKdBbDcHL D4dg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.microsoft.com header.s=default header.b=c80DgLo+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.microsoft.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id fl21si368836ejc.443.2021.06.09.10.52.40; Wed, 09 Jun 2021 10:53:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.microsoft.com header.s=default header.b=c80DgLo+; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238329AbhFIOxy (ORCPT + 99 others); Wed, 9 Jun 2021 10:53:54 -0400 Received: from linux.microsoft.com ([13.77.154.182]:54086 "EHLO linux.microsoft.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238328AbhFIOxu (ORCPT ); Wed, 9 Jun 2021 10:53:50 -0400 Received: from sequoia (162-237-133-238.lightspeed.rcsntx.sbcglobal.net [162.237.133.238]) by linux.microsoft.com (Postfix) with ESMTPSA id 36F1720B7188; Wed, 9 Jun 2021 07:51:55 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 36F1720B7188 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1623250315; bh=/HOmnjissLx+lpthetr985W/qYtb76YNAtpL9Q+TgUo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=c80DgLo+RZ7PeCM+jUdVjeYBRw/W44I+zJd6qzZdHN9r7ORuQQ6AGzFitDP+/AVLR JLqhPwpsBqvYed6u1ExXDP2dxSO+TkFg+aHZOAMCQwO11kq6EKDMweBAINbQYrfvAS Ymdij+JezbRgdwPbVaGZvQYQQ2nDt5LNqgJSnrw8= Date: Wed, 9 Jun 2021 09:51:53 -0500 From: Tyler Hicks To: Jens Wiklander Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, op-tee@lists.trustedfirmware.org, Sumit Garg , Herbert Xu , Sakkinen , Sasha Levin , Thirupathaiah Annapureddy , Vikas Gupta , "David S . Miller" Subject: Re: [PATCH 4/7] hwrng: optee-rng: use tee_shm_alloc_kernel_buf() Message-ID: <20210609145153.GH4910@sequoia> References: <20210609102324.2222332-1-jens.wiklander@linaro.org> <20210609102324.2222332-5-jens.wiklander@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210609102324.2222332-5-jens.wiklander@linaro.org> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2021-06-09 12:23:21, Jens Wiklander wrote: > Uses the new simplified tee_shm_alloc_kernel_buf() function instead of > the old deprecated tee_shm_alloc() function which required specific > TEE_SHM-flags. > > Signed-off-by: Jens Wiklander Reviewed-by: Tyler Hicks Tyler > --- > drivers/char/hw_random/optee-rng.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/drivers/char/hw_random/optee-rng.c b/drivers/char/hw_random/optee-rng.c > index 135a82590923..a948c0727b2b 100644 > --- a/drivers/char/hw_random/optee-rng.c > +++ b/drivers/char/hw_random/optee-rng.c > @@ -145,10 +145,10 @@ static int optee_rng_init(struct hwrng *rng) > struct optee_rng_private *pvt_data = to_optee_rng_private(rng); > struct tee_shm *entropy_shm_pool = NULL; > > - entropy_shm_pool = tee_shm_alloc(pvt_data->ctx, MAX_ENTROPY_REQ_SZ, > - TEE_SHM_MAPPED | TEE_SHM_DMA_BUF); > + entropy_shm_pool = tee_shm_alloc_kernel_buf(pvt_data->ctx, > + MAX_ENTROPY_REQ_SZ); > if (IS_ERR(entropy_shm_pool)) { > - dev_err(pvt_data->dev, "tee_shm_alloc failed\n"); > + dev_err(pvt_data->dev, "tee_shm_alloc_kernel_buf failed\n"); > return PTR_ERR(entropy_shm_pool); > } > > -- > 2.31.1 >