Page MenuHomeFreeBSD

msdos: Use getblk rather than bread to write out FAT copy
AbandonedPublic

Authored by imp on Mar 13 2023, 5:11 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Sep 23, 11:49 AM
Unknown Object (File)
Wed, Sep 18, 1:51 AM
Unknown Object (File)
Mon, Sep 9, 4:07 AM
Unknown Object (File)
Sat, Sep 7, 8:27 AM
Unknown Object (File)
Thu, Sep 5, 5:40 PM
Unknown Object (File)
Wed, Aug 28, 5:37 PM
Unknown Object (File)
Aug 23 2024, 2:09 PM
Unknown Object (File)
Aug 23 2024, 2:09 PM
Subscribers

Details

Reviewers
markj
Summary

We don't need to read the old contents of the backup FAT before updating
it with the new, so use getblk rather than bread to get the m_buf to to
the write.

Sponsored by: Netflix

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 50326
Build 47218: arc lint + arc unit

Event Timeline

imp requested review of this revision.Mar 13 2023, 5:11 PM
imp created this revision.

This change took us from 32s down to only 25s though...

do we always overwrite the whole block?

do we always overwrite the whole block?

Hmmm, we did in my testing, but I see the code that blsize != cpsize, so I'm just going to drop thia.

I guess you could make it bread or getblk depending on cpsize?