From 7d4f711413205d796187e1e53fbea5affd365cd8 Mon Sep 17 00:00:00 2001 From: Jia Zhang Date: Wed, 6 Jun 2018 10:00:55 -0400 Subject: meta-intel-sgx: Initial support of linux-sgx-driver As the initial support, linux-sgx-driver is integrated into this layer. SDK and PSW will be provided soon. Signed-off-by: Jia Zhang --- meta-intel-sgx/README.md | 23 +++++++++++++++ meta-intel-sgx/conf/layer.conf | 18 ++++++++++++ .../intel-sgx-driver/intel-sgx-driver_2.1.bb | 34 ++++++++++++++++++++++ 3 files changed, 75 insertions(+) create mode 100644 meta-intel-sgx/README.md create mode 100644 meta-intel-sgx/conf/layer.conf create mode 100644 meta-intel-sgx/recipes-kernel/intel-sgx-driver/intel-sgx-driver_2.1.bb diff --git a/meta-intel-sgx/README.md b/meta-intel-sgx/README.md new file mode 100644 index 0000000..d1b8444 --- /dev/null +++ b/meta-intel-sgx/README.md @@ -0,0 +1,23 @@ +### Overview +This layer provides the support of Intel Software Guard Extensions +(Intel SGX), which is an Intel technology for application developers +seeking to protect select code and data from disclosure or modification. + +The Linux SGX software stack is comprised of the Intel SGX driver, the +Intel SGX SDK, and the Intel SGX Platform Software. + +### Intel SGX Driver +The recipe sgx-driver provides a out-of-tree driver for the Linux Intel +SGX software stack, which will be used until the driver upstreaming process +is complete. + +### Intel SGX SDK and PSW +The recipes are still in development. + +### Hardware Support +Please check [this site](https://github.com/ayeks/SGX-hardware) for the +latest information. + +### Reference +- [SGX driver](https://github.com/intel/linux-sgx-driver) +- [SGX SDK and PSW](https://github.com/intel/linux-sgx) diff --git a/meta-intel-sgx/conf/layer.conf b/meta-intel-sgx/conf/layer.conf new file mode 100644 index 0000000..6c09840 --- /dev/null +++ b/meta-intel-sgx/conf/layer.conf @@ -0,0 +1,18 @@ +# We have a conf and classes directory, add to BBPATH +BBPATH .= ":${LAYERDIR}" + +# We have recipes-* directories, add to BBFILES +BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \ + ${LAYERDIR}/recipes-*/*/*.bbappend" + +BBFILE_COLLECTIONS += "intel-sgx" +BBFILE_PATTERN_intel-sgx = "^${LAYERDIR}/" +BBFILE_PRIORITY_intel-sgx = "10" + +BBLAYERS_LAYERINDEX_NAME_intel-sgx = "meta-intel-sgx" + +LAYERDEPENDS_intel-sgx = "\ + core \ +" + +LAYERSERIES_COMPAT_intel-sgx = "sumo" diff --git a/meta-intel-sgx/recipes-kernel/intel-sgx-driver/intel-sgx-driver_2.1.bb b/meta-intel-sgx/recipes-kernel/intel-sgx-driver/intel-sgx-driver_2.1.bb new file mode 100644 index 0000000..b1abcd5 --- /dev/null +++ b/meta-intel-sgx/recipes-kernel/intel-sgx-driver/intel-sgx-driver_2.1.bb @@ -0,0 +1,34 @@ +SUMMARY = "Intel SGX Linux DDDriver" +DESCRIPTION = "Intel(R) Software Guard Extensions (Intel(R) SGX) \ +is an Intel technology for application developers seeking to \ +protect select code and data from disclosure or modification." +HOMEPAGE = "https://github.com/intel/linux-sgx-driver" + +LICENSE = "GPLv2" +LIC_FILES_CHKSUM = "file://License.txt;md5=b54f8941f6087efb6be3deb0f1e617f7" + +DEPENDS = "virtual/kernel" + +PV = "2.1+git${SRCPV}" + +SRC_URI = "\ + git://github.com/intel/linux-sgx-driver.git \ +" +SRCREV = "2a509c203533f9950fa3459fe91864051bc021a2" + +S = "${WORKDIR}/git" + +inherit module + +EXTRA_OEMAKE += "KDIR='${STAGING_KERNEL_DIR}'" + +MODULE_NAME = "isgx" + +do_install () { + dir="${D}/lib/modules/${KERNEL_VERSION}/kernel/${MODULE_NAME}" + + install -d "$dir" + install -m 0644 "${MODULE_NAME}.ko" "$dir" +} + +RPROVIDES_${PN} += "kernel-module-${MODULE_NAME}" -- cgit v1.2.3-54-g00ecf