mirror of
https://github.com/torvalds/linux.git
synced 2026-04-20 07:43:57 -04:00
The Devicetree bindings document does not have to say in the title that
it is a "binding", but instead just describe the hardware.
Drop trailing "Node|Tree|Generic bindings" in various forms (also with
trailing full stop):
find Documentation/devicetree/bindings/ -type f -name '*.yaml' \
-not -name 'trivial-devices.yaml' \
-exec sed -i -e 's/^title: \(.*\) [nN]ode [bB]indings\?\.\?$/title: \1/' {} \;
find Documentation/devicetree/bindings/ -type f -name '*.yaml' \
-not -name 'trivial-devices.yaml' \
-exec sed -i -e 's/^title: \(.*\) [tT]ree [bB]indings\?\.\?$/title: \1/' {} \;
find Documentation/devicetree/bindings/ -type f -name '*.yaml' \
-not -name 'trivial-devices.yaml' \
-exec sed -i -e 's/^title: \(.*\) [gG]eneric [bB]indings\?\.\?$/title: \1/' {} \;
find Documentation/devicetree/bindings/ -type f -name '*.yaml' \
-not -name 'trivial-devices.yaml' \
-exec sed -i -e 's/^title: \(.*\) [bB]indings\? description\.\?$/title: \1/' {} \;
find Documentation/devicetree/bindings/ -type f -name '*.yaml' \
-not -name 'trivial-devices.yaml' \
-exec sed -i -e 's/^title: \(.*\) [bB]indings\? document\.\?$/title: \1/' {} \;
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Acked-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Acked-by: Ulf Hansson <ulf.hansson@linaro.org> # MMC
Acked-by: Stephen Boyd <sboyd@kernel.org> # clk
Acked-by: Vinod Koul <vkoul@kernel.org> # phy
Acked-by: Mark Brown <broonie@kernel.org>
Link: https://lore.kernel.org/r/20221216163815.522628-6-krzysztof.kozlowski@linaro.org
Signed-off-by: Rob Herring <robh@kernel.org>
98 lines
3.2 KiB
YAML
98 lines
3.2 KiB
YAML
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
|
|
%YAML 1.2
|
|
---
|
|
$id: http://devicetree.org/schemas/reserved-memory/shared-dma-pool.yaml#
|
|
$schema: http://devicetree.org/meta-schemas/core.yaml#
|
|
|
|
title: /reserved-memory DMA pool
|
|
|
|
maintainers:
|
|
- devicetree-spec@vger.kernel.org
|
|
|
|
allOf:
|
|
- $ref: "reserved-memory.yaml"
|
|
|
|
properties:
|
|
compatible:
|
|
oneOf:
|
|
- const: shared-dma-pool
|
|
description: >
|
|
This indicates a region of memory meant to be used as a shared
|
|
pool of DMA buffers for a set of devices. It can be used by an
|
|
operating system to instantiate the necessary pool management
|
|
subsystem if necessary.
|
|
|
|
- const: restricted-dma-pool
|
|
description: >
|
|
This indicates a region of memory meant to be used as a pool
|
|
of restricted DMA buffers for a set of devices. The memory
|
|
region would be the only region accessible to those devices.
|
|
When using this, the no-map and reusable properties must not
|
|
be set, so the operating system can create a virtual mapping
|
|
that will be used for synchronization. The main purpose for
|
|
restricted DMA is to mitigate the lack of DMA access control
|
|
on systems without an IOMMU, which could result in the DMA
|
|
accessing the system memory at unexpected times and/or
|
|
unexpected addresses, possibly leading to data leakage or
|
|
corruption. The feature on its own provides a basic level of
|
|
protection against the DMA overwriting buffer contents at
|
|
unexpected times. However, to protect against general data
|
|
leakage and system memory corruption, the system needs to
|
|
provide way to lock down the memory access, e.g., MPU. Note
|
|
that since coherent allocation needs remapping, one must set
|
|
up another device coherent pool by shared-dma-pool and use
|
|
dma_alloc_from_dev_coherent instead for atomic coherent
|
|
allocation.
|
|
|
|
linux,cma-default:
|
|
type: boolean
|
|
description: >
|
|
If this property is present, then Linux will use the region for
|
|
the default pool of the contiguous memory allocator.
|
|
|
|
linux,dma-default:
|
|
type: boolean
|
|
description: >
|
|
If this property is present, then Linux will use the region for
|
|
the default pool of the consistent DMA allocator.
|
|
|
|
if:
|
|
properties:
|
|
compatible:
|
|
contains:
|
|
const: restricted-dma-pool
|
|
then:
|
|
properties:
|
|
no-map: false
|
|
reusable: false
|
|
|
|
unevaluatedProperties: false
|
|
|
|
examples:
|
|
- |
|
|
reserved-memory {
|
|
#address-cells = <1>;
|
|
#size-cells = <1>;
|
|
ranges;
|
|
|
|
/* global autoconfigured region for contiguous allocations */
|
|
linux,cma {
|
|
compatible = "shared-dma-pool";
|
|
reusable;
|
|
size = <0x4000000>;
|
|
alignment = <0x2000>;
|
|
linux,cma-default;
|
|
};
|
|
|
|
display_reserved: framebuffer@78000000 {
|
|
reg = <0x78000000 0x800000>;
|
|
};
|
|
|
|
restricted_dma_reserved: restricted-dma-pool@50000000 {
|
|
compatible = "restricted-dma-pool";
|
|
reg = <0x50000000 0x4000000>;
|
|
};
|
|
};
|
|
|
|
...
|