From patchwork Sat Feb 16 10:34:20 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 158561 Delivered-To: patch@linaro.org Received: by 2002:a02:48:0:0:0:0:0 with SMTP id 69csp384346jaa; Sat, 16 Feb 2019 02:34:33 -0800 (PST) X-Google-Smtp-Source: AHgI3IY5d5XYvkvAKj48mI04dAS0BME0XfgclY30Ngz1c+33gOXy1GLEoQYk4UK4mF+nMCTJhRW4 X-Received: by 2002:a63:d842:: with SMTP id k2mr9288562pgj.8.1550313273102; Sat, 16 Feb 2019 02:34:33 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550313273; cv=none; d=google.com; s=arc-20160816; b=H143GNruLUWSTc9plGCPEdK684AYwW+vRbDq94r6Kac9WhpqsqPx2r89EAvjy/5gNl 6DosxNU9aqJqkPh+arSibsvZNN1eToDjg7QJevgqkhRpawD5ppTV64ZJy7HgqrXRLBYv UZVyEySuDT4IYjsdaq7Tsi5IxIEDzdXUnDBNmgyHF4Pd7tJ1rvqQN4QkTh/EtnSFvLog WUfix3DQ8QKjLtZVgG1Xlk9JThx+C8Vv2RhjUycVxGN4F8fTqesRgy9+D4bnzWHJAYsP X1dg9s/xWELEGMDt3oFDgEgPDYQ3bSmq8OsIEmUGGhSHYSOHK5wMloKlMPN1794XvRfT 75wA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:message-id:date:to:from:dkim-signature:delivered-to; bh=zhYcXwHQXutVCodbhqw6F+SwXdZrf2RIfK9c4lYkKEw=; b=a6XfS5Vj98QzKbM6oHLcMcV0fCXwNwDKkPUn1D2v9xVAlTXKgtylaH0Fccw/mzregY 3OoM0kHiSYmAIhro62wTHeaWA+6mjYDfVfPfLpgSq7Dq4dBVJyO7HuEkflEQAUqwn//b BTSsCJLGOYRYdIrcNmUWpvCIK37o47MQid3HSpBdLax6PpIj4R+LW4PdWbzwZAvfu5l4 t/G/xq0CmcbUK+fzSqdz0W95QrDMKHEnYv+itiid1sXwnIWXEJyUwJhFvjAGVm2oxgZt PumCfVMLj+Pmob+bflTPXkklqYOWntUN3sUzhSp3wTSqBZtL0Qd84/0yNwdW+Z2ffysB 7vGw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=yt4YvkLW; spf=pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 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. [2001:19d0:306:5::1]) by mx.google.com with ESMTPS id n4si7126711pgv.512.2019.02.16.02.34.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 16 Feb 2019 02:34:33 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 as permitted sender) client-ip=2001:19d0:306:5::1; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=yt4YvkLW; spf=pass (google.com: best guess record for domain of edk2-devel-bounces@lists.01.org designates 2001:19d0:306:5::1 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 A4B93208D615C; Sat, 16 Feb 2019 02:34:31 -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=2a00:1450:4864:20::344; helo=mail-wm1-x344.google.com; envelope-from=ard.biesheuvel@linaro.org; receiver=edk2-devel@lists.01.org Received: from mail-wm1-x344.google.com (mail-wm1-x344.google.com [IPv6:2a00:1450:4864:20::344]) (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 0C1C0208D6147 for ; Sat, 16 Feb 2019 02:34:29 -0800 (PST) Received: by mail-wm1-x344.google.com with SMTP id j125so12133080wmj.1 for ; Sat, 16 Feb 2019 02:34:29 -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:mime-version :content-transfer-encoding; bh=4eSLjW4gITVvCfIa3S2lWLu/EnCjKK4jyRsokqmwYuE=; b=yt4YvkLWWS+fEuzNeZ57UkbKbOTi5JXdBe4R/KKhtvLOMeR8K6lw1CiCwLait42E20 DxawgWEawUj8JyflRl7Y8PEf5DPSI6y4qWVn+bsv3/gUv0oPYk4QLEcdGjUrhsxbd+vE Wp7aQP5x2mZUeL/0wtzSmi3DeEXGWlGtaJfblU37ord6AKAYMjU93hOkFKOfOkGjE+uO KnXGO+OmD5Id+kooVPAW8XV/wD7Uj5d7PNjg6FZAM/GeyP6xxIRc7i+oubn1umHPBzYE zrP7lxd+IsZoTVGo6VkbTyh+hihE1Vn2Uvv2jSU2IWwtKzXCo34YGA0S4ZuI0NTl6bYu l4+w== 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:mime-version :content-transfer-encoding; bh=4eSLjW4gITVvCfIa3S2lWLu/EnCjKK4jyRsokqmwYuE=; b=iUD20xZ4F3r2Fg3NntQuYyzHzfi1cuxy5cff0igEk/676srQQzI6A0s/9+kaMBGz/m 4CwvG5Rk+zXFT1WNikBW13xc3CQ347u+ObrhoM4e/DgpwOID3u6O2huB/j44r4JWQzkf p5LHGup4bq1oxRCmsD/4+Iw8P1KBC4t33TuAE2oZccHAxgSGcIUId2Ji2vZPGUxaS9cI TmOx4SouC04xFTvusN/H/wNKW5s+Tua6ZgrCKjqpyyIun87Ru1bL1ZVyEE65j4NjH/wQ 7U94RIWtzdy7cezZHapiJBrNqGwBIsmN5jAhNcJEaNP/MYSsWmNM/Jf+utb/2xDgrzaC vsCQ== X-Gm-Message-State: AHQUAub4KI5BkmaWBQmf6DOCH4KsEDawWwhYmLMujvGh411GnEqpU/S+ Ly+w0+nUnyP3e/874yjn88FtHUF4YzE= X-Received: by 2002:a1c:9c15:: with SMTP id f21mr8954493wme.94.1550313267596; Sat, 16 Feb 2019 02:34:27 -0800 (PST) Received: from sudo.home ([2a01:cb1d:112:6f00:ddaf:5369:7280:8c79]) by smtp.gmail.com with ESMTPSA id u10sm4740314wrr.33.2019.02.16.02.34.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 16 Feb 2019 02:34:26 -0800 (PST) From: Ard Biesheuvel To: edk2-devel@lists.01.org Date: Sat, 16 Feb 2019 11:34:20 +0100 Message-Id: <20190216103422.10907-1-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Subject: [edk2] [PATCH edk2-platforms 0/2] Platform/RaspberryPi3: add RNG support X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: edk2-devel-bounces@lists.01.org Sender: "edk2-devel" Add a RNG driver for the BCM283x and wire it up for the Raspberry Pi 3 platform so that the random number generator is accessible to the OS loader via the EFI_RNG_PROTOCOL. This is used by the KASLR implementation in the arm64 Linux kernel to randomize the placement of various parts of the kernel. Changes since v2: - move the RNG specific SoC definitions into the Bcm2836.h common header - add patch that wires up the driver into the RPi3 platform Cc: Pete Batard Cc: Jeremy Linton Cc: Leif Lindholm Ard Biesheuvel (2): Silicon/Bcm2836: add random number generator driver Platform/RaspberryPi3: add RNG driver Platform/RaspberryPi/RPi3/RPi3.dsc | 5 + Platform/RaspberryPi/RPi3/RPi3.fdf | 5 + Silicon/Broadcom/Bcm283x/Drivers/RngDxe/RngDxe.c | 203 ++++++++++++++++++++ Silicon/Broadcom/Bcm283x/Drivers/RngDxe/RngDxe.inf | 45 +++++ Silicon/Broadcom/Bcm283x/Include/IndustryStandard/Bcm2836.h | 9 + 5 files changed, 267 insertions(+) create mode 100644 Silicon/Broadcom/Bcm283x/Drivers/RngDxe/RngDxe.c create mode 100644 Silicon/Broadcom/Bcm283x/Drivers/RngDxe/RngDxe.inf -- 2.20.1 _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel Reviewed-by: Leif Lindholm