Merge "Produce API documentation"

This commit is contained in:
Jenkins 2017-05-25 08:03:31 +00:00 committed by Gerrit Code Review
commit b7924c0c83
5 changed files with 38 additions and 7 deletions

View File

@ -69,6 +69,7 @@ class MBR(object):
Primary partitions are created first - and must also be passed in Primary partitions are created first - and must also be passed in
first. first.
The extended partition layout is done in the way, that there is The extended partition layout is done in the way, that there is
one entry in the MBR (the last) that uses the whole disk. one entry in the MBR (the last) that uses the whole disk.
EBR (extended boot records) are used to describe the partitions EBR (extended boot records) are used to describe the partitions
@ -76,21 +77,29 @@ class MBR(object):
be used for all partitions and arbitrarily many partitions can be be used for all partitions and arbitrarily many partitions can be
created in the same way (the EBR is placed as block 0 in each created in the same way (the EBR is placed as block 0 in each
partition itself). partition itself).
In conjunction with a fixed and 'fits all' partition alignment the In conjunction with a fixed and 'fits all' partition alignment the
major design focus is maximum performance for the installed image major design focus is maximum performance for the installed image
(vs. minimal size). (vs. minimal size).
Because of the chosen default alignment of 1MiB there will be Because of the chosen default alignment of 1MiB there will be
(1MiB - 512B) unused disk space for the MBR and also the same (1MiB - 512B) unused disk space for the MBR and also the same
size unused in every partition. size unused in every partition.
Assuming that 512 byte blocks are used, the resulting layout for Assuming that 512 byte blocks are used, the resulting layout for
extended partitions looks like (blocks offset in extended extended partitions looks like (blocks offset in extended
partition given): partition given):
0: MBR - 2047 blocks unused
2048: EBR for partition 1 - 2047 blocks unused ======== ==============================================
4096: Start of data for partition 1 Offset Description
... ======== ==============================================
X: EBR for partition N - 2047 blocks unused 0 MBR - 2047 blocks unused
X+2048: Start of data for partition N 2048 EBR for partition 1 - 2047 blocks unused
4096 Start of data for partition 1
... ...
X EBR for partition N - 2047 blocks unused
X+2048 Start of data for partition N
======== ==============================================
Direct (native) writing of MBR, EBR (partition table) is Direct (native) writing of MBR, EBR (partition table) is
implemented - no other parititoning library or tools is used - implemented - no other parititoning library or tools is used -

View File

@ -5,7 +5,7 @@ import os
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones. # ones.
sys.path.append(os.path.abspath('../lib')) sys.path.append(os.path.abspath('../lib'))
extensions = ['oslosphinx', 'element_deps'] extensions = ['oslosphinx', 'element_deps', 'sphinx.ext.autodoc']
# Add any paths that contain templates here, relative to this directory. # Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates'] templates_path = ['_templates']

View File

@ -35,6 +35,13 @@ and testing your changes. When you are done editing, use ``git
review`` to submit changes to the upstream gerrit. review`` to submit changes to the upstream gerrit.
Python module documentation
---------------------------
For internal documentation on the DIB python components, see the
:ref:`modindex`
Finding Work Finding Work
------------ ------------

View File

@ -56,3 +56,9 @@ Table of Contents
developer/index developer/index
elements elements
specs/README specs/README
.. # just link this on the dev page
.. toctree::
:hidden:
api/autoindex

View File

@ -21,6 +21,15 @@ build-dir = doc/build
source-dir = doc/source source-dir = doc/source
warning-is-error = 1 warning-is-error = 1
[pbr]
autodoc_index_modules = 1
autodoc_exclude_modules =
setup.py
diskimage_builder.tests.*
diskimage_builder.block_device.tests.*
# elements are a weird mix of scripts & python
diskimage_builder.elements.*
[files] [files]
packages = packages =
diskimage_builder diskimage_builder