On Sun, 27 Nov 2022 22:05:07 +0000 Wol <antlists@xxxxxxxxxxxxxxx> wrote: > When mdadm creates an array - IF IT SUPPORTED TRIM - you could tell it > "this is a blank array, don't bother initialising it". So it would > initialise an internal bitmap to say "all these stripes are empty". > > As the file system above sends writes down, mdadm would update the > bitmap to say "these stripes are in use". > > AND THIS IS WHAT I MEAN BY "SUPPORTING TRIM" - when the filesystem sends > a trim command, saying "I'm no longer using these blocks", MDADM WOULD > REMEMBER, and if appropriate clear the bitmap. mdadm supports TRIM in the sense that it properly passes down TRIM of the array to participant member devices, for them to do their own underlying storage management operations. Even from the complex RAID levels such as RAID5 and RAID6. This is commendable and IIRC far from always was the case. Stretching "TRIM support" to mean a hypothetical used-blocks-accounting feature and use of that to speed-up rebuilds, is a surefire way to get misunderstood in a conversation. As is saying "mdadm doesn't support TRIM" only due to it not having that specific advanced feature. -- With respect, Roman