View Source DtsBuddy.Paths (dts_buddy v0.1.0)
Helper module to remove paths juggling out of DtsBuddy.Backend
Summary
Functions
Configfs directory.
DTBO directory for a given <name>
Location of the DTBO file to be written for the given <name>.
Location of the DTS file to be written for the given <name>.
Overlay directory for a given <name>
Overlays directory.
Status file path for a given <name>
Checks that an overlay name is safe to splice into filesystem paths.
Location of a writable directory for the given <name>. Should be configurable by the user as people maybe have configurations diverging from the common nerves convention to have /data writable ?
Functions
@spec config_dir() :: <<_::144>>
Configfs directory.
DTBO directory for a given <name>
Location of the DTBO file to be written for the given <name>.
Location of the DTS file to be written for the given <name>.
Overlay directory for a given <name>
@spec overlays_dir() :: binary()
Overlays directory.
Status file path for a given <name>
Checks that an overlay name is safe to splice into filesystem paths.
Names are used verbatim to build both writable file paths (under /data) and
configfs directories (under /sys/kernel/config/device-tree/overlays). Allowing
path separators or .. would let a caller escape those trees, so we restrict
names to a conservative alphabet of letters, digits, _ and -.
Location of a writable directory for the given <name>. Should be configurable by the user as people maybe have configurations diverging from the common nerves convention to have /data writable ?