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
Unknown Object (File)
Sun, Oct 12, 3:25 AM
Unknown Object (File)
Fri, Oct 10, 12:58 PM
Unknown Object (File)
Tue, Oct 7, 12:07 PM
Unknown Object (File)
Sep 10 2025, 11:36 AM
Unknown Object (File)
Sep 9 2025, 10:27 PM
Unknown Object (File)
Sep 2 2025, 11:04 PM
Unknown Object (File)
Aug 20 2025, 12:50 AM
Unknown Object (File)
Jul 31 2025, 12:26 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