From af0837ebf45f5e889e942b7cb70d4e2d94d52197 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tomasz=20Mo=C5=84?= Date: Mon, 17 Oct 2022 07:51:31 +0200 Subject: [PATCH] dts: bindings: add bindings zephyr,flash-disk MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add bindings to describe a block storage device based on flash map partition. Co-authored-by: Johann Fischer Signed-off-by: Tomasz Moń --- dts/bindings/misc/zephyr,flash-disk.yaml | 38 ++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 dts/bindings/misc/zephyr,flash-disk.yaml diff --git a/dts/bindings/misc/zephyr,flash-disk.yaml b/dts/bindings/misc/zephyr,flash-disk.yaml new file mode 100644 index 00000000000..4b7ba5568c8 --- /dev/null +++ b/dts/bindings/misc/zephyr,flash-disk.yaml @@ -0,0 +1,38 @@ +# Copyright (c) 2022 Nordic Semiconductor ASA +# SPDX-License-Identifier: Apache-2.0 + +description: Block storage device on flash partition + +compatible: "zephyr,flash-disk" + +include: base.yaml + +properties: + partition: + type: phandle + required: true + description: | + Backing storage flash map partition. + + disk-name: + type: string + required: true + description: | + Disk name. + + sector-size: + type: int + required: false + default: 512 + description: | + Emulated block device sector size in bytes. + + cache-size: + type: int + required: true + description: | + Size of statically allocated buffer size in bytes. The size should be + adequately chosen. On storage backends with uniform erase-blocks it + should be at least the erase-block-size, on storage backends with + non-uniform erase-blocks it should be at least the largest + erase-block-size.