Add legal and skeleton documentation files.

Change-Id: I40c982c165881593d88215913309e3177436da1c
Signed-off-by: Gyorgy Szing <Gyorgy.Szing@arm.com>
diff --git a/doc/Makefile b/doc/Makefile
new file mode 100644
index 0000000..d4bb2cb
--- /dev/null
+++ b/doc/Makefile
@@ -0,0 +1,20 @@
+# Minimal makefile for Sphinx documentation
+#
+
+# You can set these variables from the command line, and also
+# from the environment for the first two.
+SPHINXOPTS    ?=
+SPHINXBUILD   ?= sphinx-build
+SOURCEDIR     = .
+BUILDDIR      = _build
+
+# Put it first so that "make" without argument is like "make help".
+help:
+	@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
+
+.PHONY: help Makefile
+
+# Catch-all target: route all unknown targets to Sphinx using the new
+# "make mode" option.  $(O) is meant as a shortcut for $(SPHINXOPTS).
+%: Makefile
+	@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
diff --git a/doc/SphinxBuild.cmake b/doc/SphinxBuild.cmake
new file mode 100644
index 0000000..254d856
--- /dev/null
+++ b/doc/SphinxBuild.cmake
@@ -0,0 +1,18 @@
+#

+# Copyright (c) 2019, ARM Limited and Contributors. All rights reserved.

+#

+# SPDX-License-Identifier: BSD-3-Clause

+#

+

+# Minimal cmake script for running sphinx. Use as:

+# cmake -P SphinxBuild.cmake

+

+# Inputs:

+#   SPHINXOPTS : extra options for sphinx

+

+set(SPHINXBUILD "sphinx-build" CACHE PATH "Location of sphinx-build executable.")

+set(SPHNIX_BUILDDIR "_build" CACHE PATH "Directory to place sphinx outpot to.")

+

+exec_program(${SPHINXBUILD} ./

+             ARGS -M html ${CMAKE_CURRENT_LIST_DIR} ${SPHNIX_BUILDDIR} ${SPHINXOPTS}

+            )

diff --git a/doc/_static/TrustedFirmware-Logo_standard-white.png b/doc/_static/TrustedFirmware-Logo_standard-white.png
new file mode 100644
index 0000000..e7bff71
--- /dev/null
+++ b/doc/_static/TrustedFirmware-Logo_standard-white.png
Binary files differ
diff --git a/doc/_templates/.keep_me b/doc/_templates/.keep_me
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/doc/_templates/.keep_me
diff --git a/doc/build_instructions.rst b/doc/build_instructions.rst
new file mode 100644
index 0000000..5bc1149
--- /dev/null
+++ b/doc/build_instructions.rst
@@ -0,0 +1,12 @@
+Build Instructions

+==================

+

+TODO: add info here about:

+  * how to build the unit tests

+  * how to build documentation

+

+--------------

+

+*Copyright (c) 2019, Arm Limited and Contributors. All rights reserved.*

+

+SPDX-License-Identifier: BSD-3-Clause

diff --git a/doc/conf.py b/doc/conf.py
new file mode 100644
index 0000000..669fc46
--- /dev/null
+++ b/doc/conf.py
@@ -0,0 +1,96 @@
+# -*- coding: utf-8 -*-

+

+# -- Metadata about this file ------------------------------------------------

+__date__ = "08 October 2019"

+__copyright__ = "Copyright (c) 2019 ARM Limited; SPDX-License-Identifier: BSD-3-Clause"

+

+# Configuration file for the Sphinx documentation builder.

+

+# -- Path setup --------------------------------------------------------------

+

+# If extensions (or modules to document with autodoc) are in another directory,

+# add these directories to sys.path here. If the directory is relative to the

+# documentation root, use os.path.abspath to make it absolute, like shown here.

+#

+# import os

+# import sys

+# sys.path.insert(0, os.path.abspath('.'))

+

+# -- Project information -----------------------------------------------------

+project = 'TF-A Unit Tests'

+copyright = 'Copyright (c) 2019 ARM Limited'

+author = 'Imre Kis'

+

+# The full version, including alpha/beta/rc tags

+release = '0.0.1'

+

+

+# -- General configuration ---------------------------------------------------

+

+# Add any Sphinx extension module names here, as strings. They can be

+# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom

+# ones.

+extensions = ['sphinx.ext.autosectionlabel', 'sphinxcontrib.plantuml']

+

+# Add any paths that contain templates here, relative to this directory.

+templates_path = ['_templates']

+

+# The suffix(es) of source filenames.

+source_suffix = '.rst'

+

+# The master toctree document.

+master_doc = 'index'

+

+# The language for content autogenerated by Sphinx. Refer to documentation

+# for a list of supported languages.

+#

+# This is also used if you do content translation via gettext catalogs.

+# Usually you set "language" from the command line for these cases.

+language = None

+

+

+# List of patterns, relative to source directory, that match files and

+# directories to ignore when looking for source files.

+# This pattern also affects html_static_path and html_extra_path.

+exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']

+

+# The name of the Pygments (syntax highlighting) style to use.

+pygments_style = 'sphinx'

+

+# Load the contents of the global substitutions file into the 'rst_prolog'

+# variable. This ensures that the substitutions are all inserted into each page.

+with open('global_substitutions.txt', 'r') as subs:

+  rst_prolog = subs.read()

+# Minimum version of sphinx required

+needs_sphinx = '2.0'

+

+# -- Options for HTML output -------------------------------------------------

+

+# Don't show the "Built with Sphinx" footer

+html_show_sphinx = False

+

+# Don't show copyright info in the footer (we have this content in the page)

+html_show_copyright = False

+

+# The theme to use for HTML and HTML Help pages.  See the documentation for

+# a list of builtin themes.

+html_theme = "sphinx_rtd_theme"

+

+# The logo to display in the sidebar

+html_logo = 'resources/TrustedFirmware-Logo_standard-white.png'

+

+# Options for the "sphinx-rtd-theme" theme

+html_theme_options = {

+    'collapse_navigation': False, # Can expand and collapse sidebar entries

+    'prev_next_buttons_location': 'both', # Top and bottom of the page

+    'style_external_links': True # Display an icon next to external links

+}

+

+# -- Options for autosectionlabel --------------------------------------------

+

+# Only generate automatic section labels for document titles

+autosectionlabel_maxdepth = 1

+

+# -- Options for plantuml ----------------------------------------------------

+

+plantuml_output_format = 'svg_img'

diff --git a/doc/contributing.rst b/doc/contributing.rst
new file mode 100644
index 0000000..9993d84
--- /dev/null
+++ b/doc/contributing.rst
@@ -0,0 +1,15 @@
+Contributing

+============

+

+TODO: add info here about:

+  * DCO and commit message format

+  * tf.org repo loc and how to set up loal repo

+  * link to coding style

+  * link to sw requirements

+  * link to build instructions

+

+--------------

+

+*Copyright (c) 2019, Arm Limited and Contributors. All rights reserved.*

+

+SPDX-License-Identifier: BSD-3-Clause

diff --git a/doc/global_substitutions.txt b/doc/global_substitutions.txt
new file mode 100644
index 0000000..18cc48a
--- /dev/null
+++ b/doc/global_substitutions.txt
@@ -0,0 +1,63 @@
+.. |AArch32| replace:: :term:`AArch32`
+.. |AArch64| replace:: :term:`AArch64`
+.. |API| replace:: :term:`API`
+.. |CoT| replace:: :term:`CoT`
+.. |COT| replace:: :term:`COT`
+.. |CSS| replace:: :term:`CSS`
+.. |CVE| replace:: :term:`CVE`
+.. |DS-5| replace:: :term:`DS-5`
+.. |DT| replace:: :term:`DT`
+.. |EL| replace:: :term:`EL`
+.. |EHF| replace:: :term:`EHF`
+.. |FDT| replace:: :term:`FDT`
+.. |FIP| replace:: :term:`FIP`
+.. |FVP| replace:: :term:`FVP`
+.. |FWU| replace:: :term:`FWU`
+.. |GIC| replace:: :term:`GIC`
+.. |ISA| replace:: :term:`ISA`
+.. |Linaro| replace:: :term:`Linaro`
+.. |MMU| replace:: :term:`MMU`
+.. |MPAM| replace:: :term:`MPAM`
+.. |MPIDR| replace:: :term:`MPIDR`
+.. |OEN| replace:: :term:`OEN`
+.. |OP-TEE| replace:: :term:`OP-TEE`
+.. |OTE| replace:: :term:`OTE`
+.. |PDD| replace:: :term:`PDD`
+.. |PMF| replace:: :term:`PMF`
+.. |PSCI| replace:: :term:`PSCI`
+.. |RAS| replace:: :term:`RAS`
+.. |ROT| replace:: :term:`ROT`
+.. |SCMI| replace:: :term:`SCMI`
+.. |SCP| replace:: :term:`SCP`
+.. |SDEI| replace:: :term:`SDEI`
+.. |SDS| replace:: :term:`SDS`
+.. |SEA| replace:: :term:`SEA`
+.. |SiP| replace:: :term:`SiP`
+.. |SIP| replace:: :term:`SIP`
+.. |SMC| replace:: :term:`SMC`
+.. |SMCCC| replace:: :term:`SMCCC`
+.. |SoC| replace:: :term:`SoC`
+.. |SP| replace:: :term:`SP`
+.. |SPCI| replace:: :term:`SPCI`
+.. |SPD| replace:: :term:`SPD`
+.. |SPM| replace:: :term:`SPM`
+.. |SVE| replace:: :term:`SVE`
+.. |TBB| replace:: :term:`TBB`
+.. |TBBR| replace:: :term:`TBBR`
+.. |TEE| replace:: :term:`TEE`
+.. |TF-A| replace:: :term:`TF-A`
+.. |TF-M| replace:: :term:`TF-M`
+.. |TLB| replace:: :term:`TLB`
+.. |TLK| replace:: :term:`TLK`
+.. |TSP| replace:: :term:`TSP`
+.. |TZC| replace:: :term:`TZC`
+.. |UEFI| replace:: :term:`UEFI`
+.. |WDOG| replace:: :term:`WDOG`
+.. |XLAT| replace:: :term:`XLAT`
+
+..
+    --------------
+
+    *Copyright (c) 2019, Arm Limited and Contributors. All rights reserved.*
+
+    SPDX-License-Identifier: BSD-3-Clause
\ No newline at end of file
diff --git a/doc/index.rst b/doc/index.rst
new file mode 100644
index 0000000..ff41bc7
--- /dev/null
+++ b/doc/index.rst
@@ -0,0 +1,17 @@
+Welcome to TF-A Unit Tests's documentation!

+===========================================

+

+.. toctree::

+   :maxdepth: 2

+   :caption: Contents:

+

+   contributing

+   build_instructions

+   software_requirements

+   user_guide

+

+--------------

+

+*Copyright (c) 2019, Arm Limited and Contributors. All rights reserved.*

+

+SPDX-License-Identifier: BSD-3-Clause

diff --git a/doc/software_requirements.rst b/doc/software_requirements.rst
new file mode 100644
index 0000000..2cd19d1
--- /dev/null
+++ b/doc/software_requirements.rst
@@ -0,0 +1,13 @@
+Software Requirements

+=====================

+

+TODO: add info here about:

+  * what is needed to build and run unit tests

+  * list of supported dev env's

+  * setup instructions for windows and linux

+

+--------------

+

+*Copyright (c) 2019, Arm Limited and Contributors. All rights reserved.*

+

+SPDX-License-Identifier: BSD-3-Clause

diff --git a/doc/user_guide.rst b/doc/user_guide.rst
new file mode 100644
index 0000000..a3199d7
--- /dev/null
+++ b/doc/user_guide.rst
@@ -0,0 +1,10 @@
+User Guide

+==========

+

+TODO: add text here

+

+--------------

+

+*Copyright (c) 2019, Arm Limited and Contributors. All rights reserved.*

+

+SPDX-License-Identifier: BSD-3-Clause