Page MenuHomeFreeBSD

[draft] run clang-format over sys/dev/sound
Needs ReviewPublic

Authored by emaste on Apr 30 2024, 4:53 PM.
Tags
None
Referenced Files
F167780515: D45027.diff
Mon, Aug 24, 12:03 PM
Unknown Object (File)
Wed, Aug 5, 6:46 AM
Unknown Object (File)
Tue, Aug 4, 4:50 AM
Unknown Object (File)
Mon, Jul 27, 1:08 PM
Unknown Object (File)
Jul 25 2026, 2:25 AM
Unknown Object (File)
Jul 22 2026, 8:42 PM
Unknown Object (File)
Jul 19 2026, 5:33 PM
Unknown Object (File)
Jul 18 2026, 10:45 AM
Subscribers
None
This revision needs review, but there are no reviewers specified.

Details

Reviewers
None
Summary

Continuing experiments with clang-format (D30260, D26340), let me try running it over a reasonably large collection of kernel code. This review exists just to examine the sorts of things clang-format does, and identify potential changes we might want to have done upstream.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

emaste created this revision.
sys/dev/sound/fdt/audio_soc.c
28

.clang-format has include file ordering rules, and puts "opt_*.h" first. style(9) does not mention opt_*.h at all

190

Undesired extra space fixed by D29870

276–277

this is unfortunate

377–379

this is a mess

398–399

extra 2nd level indent

sys/dev/sound/pci/allegro_code.h
1403

apparently clang-format uses a trailing comma as an indicator that array initialization should be done one-per-line