From patchwork Mon Feb 12 10:31:21 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Moorthy B S X-Patchwork-Id: 127987 Delivered-To: patch@linaro.org Received: by 10.46.124.24 with SMTP id x24csp3077707ljc; Mon, 12 Feb 2018 02:39:51 -0800 (PST) X-Google-Smtp-Source: AH8x224clNPpHzbHfxi7FWnc27OTdG+FymWylwmN2yE3a58S3qf9W6xKi+yzkrgRQXtOo++++r2n X-Received: by 2002:a17:902:24c7:: with SMTP id l7-v6mr10354292plg.268.1518431991859; Mon, 12 Feb 2018 02:39:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518431991; cv=none; d=google.com; s=arc-20160816; b=jbuzaeFKWVJLCEcyKaJpxLX0nKDYL+nDi4cHgxWA5d0jN1ezz2lgM2cloD4Xt4obTi Vmfg2oXCFsluH5VGsMIGp1BrqyJ3JkNaBqxcUJTNFmiebC22y3LxOhyB5k308amG8D58 MLXa86kg8lQHFJDMTPoF9BwyLlJ3uW4fc7aQOvYSV7YPCxE2ePaAvbwRMzvmv7XiYvP4 bRTJP6fatxhy6sj3mAjN9OK+/s9j1LxluzBZGcjca0WDfi6JbzVgzkSCCOdl9xGOmYgs GsdCgRb+Ii5o4AMUfQLUEw++m/AUSYmovt0Rs2r8qAEihzZ3CFzqionKun38tC1d6TmQ bPiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:cc :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to:arc-authentication-results; bh=0tOMNMphyq7fk5plchED4pSVTJwwnFiX61PFvfFxf/s=; b=hlllESTR8OABUo2qr495xsrdfBeYcCru6gfOGauaeo6ioKEuJWlzjWW1hvb+kE5j5X HV6lHDsqqBY6kVKUftJZJmkzYbyDsuMY4/JLjpwO0FNikL5Y8dv5ezqRRWaVvDEa/rSM omlN8ckWcvzntCvzJTPNJY2kg4184O9oIIhr6MECyPzy9n6LxktuZ82NU0rWgbdTVEtz hCfGZgTpQPGOq0DmqNTL5vo3Nn+iUztMrXJRPWFMJXlzXsiBZZHGam9kBF3WPp+GpK2k skVKPqV78AAL0F2tVGRLUE22MqJ4Z1ardJ6ZEixxBSUncAqn9xSoEYTV7JUK98/s2xJU 759Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Ec8EHh4f; spf=pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 198.145.21.10 as permitted sender) smtp.mailfrom=edk2-devel-bounces@lists.01.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from ml01.01.org (ml01.01.org. [198.145.21.10]) by mx.google.com with ESMTPS id p6si4952649pga.700.2018.02.12.02.39.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 12 Feb 2018 02:39:51 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 198.145.21.10 as permitted sender) client-ip=198.145.21.10; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Ec8EHh4f; spf=pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 198.145.21.10 as permitted sender) smtp.mailfrom=edk2-devel-bounces@lists.01.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from [127.0.0.1] (localhost [IPv6:::1]) by ml01.01.org (Postfix) with ESMTP id 34DFA2237A4DE; Mon, 12 Feb 2018 02:33:55 -0800 (PST) X-Original-To: edk2-devel@lists.01.org Delivered-To: edk2-devel@lists.01.org Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=2607:f8b0:400e:c01::244; helo=mail-pl0-x244.google.com; envelope-from=moorthy.baskaravenkatraman-sambamoorthy@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-pl0-x244.google.com (mail-pl0-x244.google.com [IPv6:2607:f8b0:400e:c01::244]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 1D76122361E47 for ; Mon, 12 Feb 2018 02:26:14 -0800 (PST) Received: by mail-pl0-x244.google.com with SMTP id ay8so4834028plb.4 for ; Mon, 12 Feb 2018 02:32:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=d9V5iLsKmEgEWw4vzQDmR5LyDEoEpoatXr0PU2x204o=; b=Ec8EHh4fFUX2U1uPw1jfy4lDh5kgpri39NWCquz4kXj4Maits6HJrBAqpwDdYmDp1M QclfNQ12ljc8AbNsLQN1klWkTk88VcPZG6BDM3VU46XsFhyWfuNLzCTTeIZoauuKJOBd k0Dg1Xgo8LqmOkf+1bWWiMgEPkJdwtcJemnj0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=d9V5iLsKmEgEWw4vzQDmR5LyDEoEpoatXr0PU2x204o=; b=SnW+1RBoOUTy6CDrB9lIsxLTEpw+gK4c9qAZ83Iat6n5DkebgAB83FJY9r4eNTzAGv G8cbUL8rtJatF8QqLu3Nv63OscY0QBQzNaR1M8Zqy3WnSkZFrjDn+q+WBwVGDKStOqc2 gceawngoaKTakkgd4U7xjD9tOTdjU1ipQ48nDqV94zjm+dElav3Gp2AshegLcnIVGiuD N+9M/gq2V36c1XKW/mwDZDzvVRrpGo7+uGJqYM+mUDJeItpp0gb+t5+up8jPzbcyByuW tBN22DfQJj0LYqnsCCLX21SiQ1eTpwFpG7S+LZ9PgM4RlftxZmINhHjq45YtIGyeR+LK ccPg== X-Gm-Message-State: APf1xPBcAfwfAK/lbhDG0xdlQLlsCCdlt8ZsOJqMqv581U64qK5soU+k 0Bw1BckCFuljhl49Q6XuDgbg1TPLxZs= X-Received: by 2002:a17:902:bf01:: with SMTP id bi1-v6mr10207931plb.254.1518431523725; Mon, 12 Feb 2018 02:32:03 -0800 (PST) Received: from localhost.localdomain ([220.225.120.129]) by smtp.gmail.com with ESMTPSA id s82sm32355780pfa.151.2018.02.12.02.32.02 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 12 Feb 2018 02:32:03 -0800 (PST) From: Moorthy Baskaravenkatraman To: edk2-devel@lists.01.org Date: Mon, 12 Feb 2018 16:01:21 +0530 Message-Id: <20180212103122.10729-4-moorthy.baskaravenkatraman-sambamoorthy@linaro.org> X-Mailer: git-send-email 2.15.0 In-Reply-To: <20180212103122.10729-1-moorthy.baskaravenkatraman-sambamoorthy@linaro.org> References: <20180212103122.10729-1-moorthy.baskaravenkatraman-sambamoorthy@linaro.org> X-Mailman-Approved-At: Mon, 12 Feb 2018 02:33:53 -0800 Subject: [edk2] [PATCH v1 3/4] edk2-platforms:comcast: RDK DRI Application X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ard Biesheuvel MIME-Version: 1.0 Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" From: Kalyan Nagabhirava Application will Download platform code Image (kernel + DTB + rootfs) and writes into Flash partition. Cc: Ard Biesheuvel Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Moorthy Baskaravenkatraman --- Platform/Comcast/Application/Dri/Dri.inf | 43 ++++++++++++++++++++ Platform/Comcast/Application/DriSecureBoot/DriSecureBoot.inf | 43 ++++++++++++++++++++ Platform/Comcast/Application/Dri/Dri.c | 26 ++++++++++++ Platform/Comcast/Application/DriSecureBoot/DriSecureBoot.c | 32 +++++++++++++++ 4 files changed, 144 insertions(+) -- 2.15.0 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel diff --git a/Platform/Comcast/Application/Dri/Dri.inf b/Platform/Comcast/Application/Dri/Dri.inf new file mode 100644 index 000000000000..ba0656cbc6d7 --- /dev/null +++ b/Platform/Comcast/Application/Dri/Dri.inf @@ -0,0 +1,43 @@ +# +# Copyright (c) 2014-2018, Linaro Limited. All rights reserved. +# Copyright (c) 2016-2017, Comcast. All rights reserved. +# +# This program and the accompanying materials +# are licensed and made available under the terms and conditions of the BSD License +# which accompanies this distribution. The full text of the license may be found at +# http://opensource.org/licenses/bsd-license.php +# +# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, +# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. +# + +################################################################################ +# +# Defines Section - statements that will be processed to create a Makefile. +# +################################################################################ + +[Defines] + INF_VERSION = 0x0001001A + BASE_NAME = RdkDriLoader + FILE_GUID = 081ba18a-d71e-40a7-99a9-cdb86463966d + MODULE_TYPE = UEFI_APPLICATION + VERSION_STRING = 1.0 + ENTRY_POINT = DriEntryPoint + +[Sources] + Dri.c + +[Packages] + ArmPkg/ArmPkg.dec + EmbeddedPkg/EmbeddedPkg.dec + MdePkg/MdePkg.dec + MdeModulePkg/MdeModulePkg.dec + NetworkPkg/NetworkPkg.dec + ShellPkg/ShellPkg.dec + SecurityPkg/SecurityPkg.dec + Platform/Comcast/Library/RdkBootManagerLib/RdkBootManagerLib.dec + +[LibraryClasses] + RdkBootManagerLib + UefiApplicationEntryPoint diff --git a/Platform/Comcast/Application/DriSecureBoot/DriSecureBoot.inf b/Platform/Comcast/Application/DriSecureBoot/DriSecureBoot.inf new file mode 100644 index 000000000000..d31f8f8a5235 --- /dev/null +++ b/Platform/Comcast/Application/DriSecureBoot/DriSecureBoot.inf @@ -0,0 +1,43 @@ +# +# Copyright (c) 2014-2018, Linaro Limited. All rights reserved. +# Copyright (c) 2016-2017, Comcast. All rights reserved. +# +# This program and the accompanying materials +# are licensed and made available under the terms and conditions of the BSD License +# which accompanies this distribution. The full text of the license may be found at +# http://opensource.org/licenses/bsd-license.php +# +# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, +# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. +# + +################################################################################ +# +# Defines Section - statements that will be processed to create a Makefile. +# +################################################################################ + +[Defines] + INF_VERSION = 0x0001001A + BASE_NAME = RdkDriSecureLoader + FILE_GUID = dd52d1d7-0de2-4552-98e0-8dbee458a502 + MODULE_TYPE = UEFI_APPLICATION + VERSION_STRING = 1.0 + ENTRY_POINT = DriSecureBootEntryPoint + +[Sources] + DriSecureBoot.c + +[Packages] + ArmPkg/ArmPkg.dec + EmbeddedPkg/EmbeddedPkg.dec + MdePkg/MdePkg.dec + MdeModulePkg/MdeModulePkg.dec + ShellPkg/ShellPkg.dec + SecurityPkg/SecurityPkg.dec + NetworkPkg/NetworkPkg.dec + Platform/Comcast/Library/RdkBootManagerLib/RdkBootManagerLib.dec + +[LibraryClasses] + RdkBootManagerLib + UefiApplicationEntryPoint diff --git a/Platform/Comcast/Application/Dri/Dri.c b/Platform/Comcast/Application/Dri/Dri.c new file mode 100644 index 000000000000..4e5ede2e0ca4 --- /dev/null +++ b/Platform/Comcast/Application/Dri/Dri.c @@ -0,0 +1,26 @@ +/* +# Copyright (c) 2014-2018, Linaro Limited. All rights reserved. +# +# This program and the accompanying materials +# are licensed and made available under the terms and conditions of the BSD License +# which accompanies this distribution. The full text of the license may be found at +# http://opensource.org/licenses/bsd-license.php +# +# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, +# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. +# + */ +#include + +EFI_STATUS +EFIAPI +DriEntryPoint ( + IN EFI_HANDLE ImageHandle, + IN EFI_SYSTEM_TABLE *SystemTable + ) +{ + EFI_STATUS Status; + + Status = RdkHttpBoot (); + return Status; +} diff --git a/Platform/Comcast/Application/DriSecureBoot/DriSecureBoot.c b/Platform/Comcast/Application/DriSecureBoot/DriSecureBoot.c new file mode 100644 index 000000000000..abe10c029d27 --- /dev/null +++ b/Platform/Comcast/Application/DriSecureBoot/DriSecureBoot.c @@ -0,0 +1,32 @@ +/* +# Copyright (c) 2014-2018, Linaro Limited. All rights reserved. +# +# This program and the accompanying materials +# are licensed and made available under the terms and conditions of the BSD License +# which accompanies this distribution. The full text of the license may be found at +# http://opensource.org/licenses/bsd-license.php +# +# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, +# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. +# + */ +#include + +EFI_STATUS +EFIAPI +DriSecureBootEntryPoint ( + IN EFI_HANDLE ImageHandle, + IN EFI_SYSTEM_TABLE *SystemTable + ) +{ + EFI_STATUS Status; + + Status = RdkHttpBoot (); + + Status = RdkSecureBoot ( + ImageHandle, + SystemTable->BootServices + ); + + return Status; +}