From 3855baf8d9b5fc1182b38e0214d6203b71896af3 Mon Sep 17 00:00:00 2001
From: patacongo
Synopsis.
- Setup the loop device at <dev-path> to access the file at <file-path> as a block device:
+ Setup the loop device at <dev-path> to access the file at <file-path> as a block device.
+ Example:
+
+nsh> dd if=/dev/zero of=/tmp/image bs=512 count=512
+nsh> ls -l /tmp
+/tmp:
+ -rw-rw-rw- 262144 IMAGE
+nsh> losetup /dev/loop0 /tmp/image
+nsh> ls -l /dev
+/dev:
+ brw-rw-rw- 0 loop0
+nsh> mkfatfs /dev/loop0
+nsh> mount -t vfat /dev/loop0 /mnt/example
+nsh> ls -l /mnt
+ls -l /mnt
+/mnt:
+ drw-rw-rw- 0 example/
+