summaryrefslogtreecommitdiff
path: root/recipes-core
diff options
context:
space:
mode:
authorSerhii Voloshynov <serhii.voloshynov@globallogic.com>2021-11-26 11:33:41 +0200
committerSerhii Voloshynov <serhii.voloshynov@globallogic.com>2021-11-29 13:56:15 +0200
commitba35462741987d9aac561272ce72c8bc0ee650bd (patch)
treec396171c94008c9ef585af13957533e03e9abe78 /recipes-core
parent1f060beda52daf8ee1d6fab74cad518bec7f1144 (diff)
downloadmeta-mlinux-ba35462741987d9aac561272ce72c8bc0ee650bd.tar.gz
meta-mlinux-ba35462741987d9aac561272ce72c8bc0ee650bd.tar.bz2
meta-mlinux-ba35462741987d9aac561272ce72c8bc0ee650bd.zip
add udev rules for ubi partitions.
it creates links /dev/ubi_config1 -> ubi0_4 /dev/ubi_config2 -> ubi0_5 /dev/ubi_oem1 -> ubi0_6 /dev/ubi_oem2 -> ubi0_7 /dev/ubi_rootfs1 -> ubi0_2 /dev/ubi_rootfs2 -> ubi0_3 /dev/ubi_uenv1 -> ubi0_0 /dev/ubi_uenv2 -> ubi0_1 /dev/ubi_user-data -> ubi0_8
Diffstat (limited to 'recipes-core')
-rw-r--r--recipes-core/udev/eudev/ubi.rules7
-rw-r--r--recipes-core/udev/eudev_%.bbappend4
2 files changed, 11 insertions, 0 deletions
diff --git a/recipes-core/udev/eudev/ubi.rules b/recipes-core/udev/eudev/ubi.rules
new file mode 100644
index 0000000..f681e27
--- /dev/null
+++ b/recipes-core/udev/eudev/ubi.rules
@@ -0,0 +1,7 @@
+SUBSYSTEM!="ubi", GOTO="ubi_end"
+# only ubi devices
+KERNEL!="ubi*", GOTO="ubi_end"
+
+SUBSYSTEM=="ubi", KERNEL=="ubi*_*", SYMLINK+="ubi_%s{name}"
+
+LABEL="ubi_end"
diff --git a/recipes-core/udev/eudev_%.bbappend b/recipes-core/udev/eudev_%.bbappend
index 364288e..539cfb2 100644
--- a/recipes-core/udev/eudev_%.bbappend
+++ b/recipes-core/udev/eudev_%.bbappend
@@ -6,6 +6,7 @@ PR .= ".mlinux7"
# add custom rules for persistent modem device names
SRC_URI += "file://cellular_radios.rules \
file://cellular_radios.sh \
+ file://ubi.rules \
file://${MACHINE}.rules"
do_install_append() {
@@ -15,4 +16,7 @@ do_install_append() {
install -m 755 ${WORKDIR}/cellular_radios.sh ${D}${sysconfdir}/udev/scripts/
}
+do_install_append_mtcap3() {
+ install -m 644 ${WORKDIR}/ubi.rules ${D}${sysconfdir}/udev/rules.d/
+}