scarlet-storm
6a389701b2
homework: Ensure we don't stack block devices
...
Ensure we don't create a loop device on top of a physical block device.
This leads to huge performance degradation of discard operations if the
physical device does not support discard_on_zeroes.
- loop device historical semantics dictates that when the device is
discarded, it needs to return zero data on read. This can be
implemented easily on a filesystem. since fallocate zero-range
would return immediately & the holes are handled at the filesystem
level to return zero data on read.
- For a raw block device, the feature (discard_zeroes_data) depends on
the capabilities of the physical device that is exposed to the
block layer by the driver. This means that to guarantee that the loop
device stacked on a block device returns zero on discarded data,
it needs to convert discarded range into write_zero op on the block device.
https://github.com/torvalds/linux/blob/63676eefb7a026d04b51dcb7aaf54f358517a2ec/drivers/block/loop.c#L773
For example on one of my local nvme I can see the following:
cat /sys/class/block/nvme1n1/queue/write_zeroes_max_bytes
131072
cat /sys/class/block/nvme0n1/queue/discard_max_hw_bytes
2199023255040
This means maximum size of a write_zero operation can be 128KiB &
maximum size of discard operation can be 2TiB on the block device.
So discarding for example 1TB of data, which would be a single block
device operation, gets split into 8.3 million block device operations
when issued on top of stacked loop device.
2026-02-17 18:23:35 +05:30
scarlet-storm
292525dd20
homework: Use same sector size when probing the device
...
If there is an explicit sector size specified in the user record,
use the same when probing the file using libblkid. The default
is 512 bytes, which will not be able to find the signatures, if the
partition table on regular file was created assuming 4k sectors
2026-02-17 18:23:35 +05:30
scarlet-storm
118cccf97f
homework: Align partitions to 1MiB
...
Align partitions to 1MiB for consistency with regular partition tools
which use 1MiB alignment by default
2026-02-17 18:23:35 +05:30
scarlet-storm
fc280b64e8
homework: Auto-probe luks sector size
...
Auto-probe the luks sector size, if not explicitly
specified in the home record
2026-02-17 18:23:35 +05:30
scarlet-storm
a24f11798b
homework: Remove zeroing of PMBR
...
Remove zeroing of PMBR before writing out the new partition table.
There is no reason, to do this explicitly ?
2026-02-17 18:23:35 +05:30
scarlet-storm
2790a782ce
homework: Use same sector size as fdisk context
...
Ensure we use the same sector size as used in the created
fdisk context when converting between sectors and bytes.
2026-02-17 18:23:35 +05:30
David Santamaría Rogado
e723d29513
hwdb: sensor: unknown add colon to sensor match
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
5e526f2df3
hwdb: sensor: yours add comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
803b160c62
hwdb: sensor: wortmann in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
f8bc2d82bb
hwdb: sensor: voyo fix dmi match format
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
cafe374172
hwdb: sensor: trekstor in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
5f558de699
hwdb: sensor: toshiba refactor
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
ef14307f36
hwdb: sensor: thundersoft reformat dmi match
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
1f2ebc1cf3
hwdb: sensor: teclast refactor
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
2c56b39439
hwdb: sensor: schneider remove number part match
...
Following Hans de Goede (jwrdegoede) way to match
BIOS versions, remove the last number part.
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
e86bac6d89
hwdb: sensor: rca in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
43e0f0e2fb
hwdb: sensor: reeder in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
7e1f8ba2e3
hwdb: sensor: purism in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
0eca6a1612
hwdb: sensor: prowise add comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
b3dea1b1a3
hwdb: sensor: predia reformat dmi match
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
a774da6ca4
hwdb: sensor: positivo simplify dmi matches
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
79e3e35f8c
hwdb: sensor: point-of-view refactor
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
f06b18f2d2
hwdb: sensor: ployer in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
9034a9b6d6
hwdb: sensor: pipo refactor
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
31434bda83
hwdb: sensor: pine64 in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
8515b8bb77
hwdb: sensor: peaq add comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
01f785ee02
hwdb: sensor: passion in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
f65d619959
hwdb: sensor: orangepi in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
9ebebd1f66
hwdb: sensor: one-netbook refactor
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
fc555941b7
hwdb: sensor: onda refactor
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
fdbc3bbc42
hwdb: sensor: odys add comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
5ee338bb4f
hwdb: sensor: nuvision refactor
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
9804d61c08
hwdb: sensor: myria in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
6954c86b72
hwdb: sensor: msi add comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
c020655998
hwdb: sensor: mpman in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
c53f6f438d
hwdb: sensor: microtech in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
7f4eb94ca4
hwdb: sensor: metaphyuni in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
71c050790c
hwdb: sensor: medion add fixme notes
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
62cc9602b9
hwdb: sensor: mediacom in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
5c1e6da471
hwdb: sensor: linx in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
67f2332cb0
hwdb: sensor: lenovo refactor
...
when in a device is also needed to set the location haven't been merged
on purpose.
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
c610bff933
hwdb: sensor: lamina add comments
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
f8b2a756ae
hwdb: sensor: kd kurio add in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
99a83b5021
hwdb: sensor: kazam add in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
d60181d235
hwdb: sensor: jumper prefer bios version over ct
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
bb227adf22
hwdb: sensor: irbis in-line comentting
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
94329e0a06
hwdb: sensor: it-works refactor
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
61a4440d5f
hwdb: sensor: iota 360 is the model
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
eae6322e50
hwdb: sensor: huawei add in-line comment
2026-02-17 13:35:49 +01:00
David Santamaría Rogado
fadb0b53f7
hwdb: sensor: hp refactor
2026-02-17 13:35:49 +01:00