From patchwork Tue Apr 12 11:32:50 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Shevchenko X-Patchwork-Id: 12810681 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 68354C433EF for ; Tue, 12 Apr 2022 12:24:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345325AbiDLM0k (ORCPT ); Tue, 12 Apr 2022 08:26:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43074 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239826AbiDLM0K (ORCPT ); Tue, 12 Apr 2022 08:26:10 -0400 Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7FAAA7306F; Tue, 12 Apr 2022 04:32:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1649763176; x=1681299176; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=SKjITbPb7i0r99ypkNUGhZ8LVM6D2ZzpcpXODGPohDQ=; b=iWnMgIoq6Bw5QWZzPswk2qF7N6k6KAU4+yyBV5oiZsYteKk1VHgjF4nR qtV/kpSp/v8Am/2IrOQRZNMUIajc78x7a1GDda9tbxlCnyV9WdjXOqo9G RAHZePTnaFv3PQpSWa/vd/rdATqFZBu2dCEST35rfVubtrUAZq1DdyBpV NV79jP0Q1tXLVeE94x33XtFsM/xl06c3sm5E23yesu44EX9SBVXPKEEA1 b0ifPts5Z91vhvSEJNw2P68uK7jhaDo8Yafo8XDanBKoqj/gG+a9mDOx0 k7RQ7MVoM5babXcaRfqjCRe9RApq9gulrbiNUe+AVq/8/Wy3og4DmFsHR w==; X-IronPort-AV: E=McAfee;i="6400,9594,10314"; a="262534791" X-IronPort-AV: E=Sophos;i="5.90,253,1643702400"; d="scan'208";a="262534791" Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 12 Apr 2022 04:32:56 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.90,253,1643702400"; d="scan'208";a="655072819" Received: from black.fi.intel.com ([10.237.72.28]) by fmsmga002.fm.intel.com with ESMTP; 12 Apr 2022 04:32:54 -0700 Received: by black.fi.intel.com (Postfix, from userid 1003) id 260E212C; Tue, 12 Apr 2022 14:32:53 +0300 (EEST) From: Andy Shevchenko To: Allen Pais , linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org Cc: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= , Christoph Hellwig , Andrew Morton , Andy Shevchenko Subject: [PATCH v3 1/1] firmware: tee_bnxt: Use UUID API for exporting the UUID Date: Tue, 12 Apr 2022 14:32:50 +0300 Message-Id: <20220412113250.57997-1-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-mips@vger.kernel.org There is export_uuid() function which exports uuid_t to the u8 array. Use it instead of open coding variant. This allows to hide the uuid_t internals. Signed-off-by: Andy Shevchenko Reviewed-by: Christoph Hellwig --- v3: rebased on the latest vanilla, added Andrew since it has no move for 1y+ drivers/firmware/broadcom/tee_bnxt_fw.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/firmware/broadcom/tee_bnxt_fw.c b/drivers/firmware/broadcom/tee_bnxt_fw.c index a5bf4c3f6dc7..40e3183a3d11 100644 --- a/drivers/firmware/broadcom/tee_bnxt_fw.c +++ b/drivers/firmware/broadcom/tee_bnxt_fw.c @@ -197,7 +197,7 @@ static int tee_bnxt_fw_probe(struct device *dev) return -ENODEV; /* Open session with Bnxt load Trusted App */ - memcpy(sess_arg.uuid, bnxt_device->id.uuid.b, TEE_IOCTL_UUID_LEN); + export_uuid(sess_arg.uuid, &bnxt_device->id.uuid); sess_arg.clnt_login = TEE_IOCTL_LOGIN_PUBLIC; sess_arg.num_params = 0;