diff options
| author | Osama Abdelkader <osama.abdelkader@gmail.com> | 2025-12-04 22:08:46 +0100 |
|---|---|---|
| committer | Denys Vlasenko <vda.linux@googlemail.com> | 2026-01-30 12:23:42 +0100 |
| commit | 8a347fd31aa2095be8eb683ad4f7627e525229f1 (patch) | |
| tree | 11e61da8f0db3f9675ef118556fed4df56e15bfd /scripts | |
| parent | 3fb6b31c716669e12f75a2accd31bb7685b1a1cb (diff) | |
| download | busybox-w32-8a347fd31aa2095be8eb683ad4f7627e525229f1.tar.gz busybox-w32-8a347fd31aa2095be8eb683ad4f7627e525229f1.tar.bz2 busybox-w32-8a347fd31aa2095be8eb683ad4f7627e525229f1.zip | |
lsblk: new applet
Add a simple lsblk utility that lists information about block devices.
Reads from /sys/block to enumerate devices and displays their size,
type, and mount point.
Features:
- Lists all block devices or specific devices
- Shows device size in human-readable format (B, K, M, G, T, P)
- Shows device type (disk, loop, partition)
- Shows mount point if device is mounted
- Sorts devices alphabetically
- Minimal implementation (~2.5 kb)
Mostly rewritten by vda.linux
function old new delta
lsblk_main - 511 +511
process_SYS_BLOCK_entry - 460 +460
.rodata 106856 106960 +104
read_ull - 81 +81
packed_usage 35924 35952 +28
compare_devices - 25 +25
applet_names 2856 2862 +6
applet_main 1644 1648 +4
------------------------------------------------------------------------------
(add/remove: 5/0 grow/shrink: 4/0 up/down: 1219/0) Total: 1219 bytes
Signed-off-by: Osama Abdelkader <osama.abdelkader@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions
