diff --git a/src/.clang-format b/src/.clang-format index bda295b8785..5f6a4c11cef 100644 --- a/src/.clang-format +++ b/src/.clang-format @@ -311,3 +311,10 @@ ForEachMacros: - pan_foreach_instr_in_block_rev - pan_foreach_predecessor - pan_foreach_successor + +# Disable clang formatting by default. Drivers that use clang-format +# inherit from this .clang-format file and re-enable formatting: +# +# DisableFormat: false +# +DisableFormat: true diff --git a/src/amd/compiler/.clang-format b/src/amd/compiler/.clang-format index dc1fd83e19c..6db4906beba 100644 --- a/src/amd/compiler/.clang-format +++ b/src/amd/compiler/.clang-format @@ -1,5 +1,6 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false ColumnLimit: 100 diff --git a/src/amd/vulkan/.clang-format b/src/amd/vulkan/.clang-format index 658c071a00a..89b21c245ce 100644 --- a/src/amd/vulkan/.clang-format +++ b/src/amd/vulkan/.clang-format @@ -1,3 +1,4 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false ColumnLimit: 120 diff --git a/src/amd/vulkan/bvh/.clang-format b/src/amd/vulkan/bvh/.clang-format index 5a6f8912c58..1b8c74f2038 100644 --- a/src/amd/vulkan/bvh/.clang-format +++ b/src/amd/vulkan/bvh/.clang-format @@ -2,6 +2,7 @@ # SPDX-License-Identifier: MIT BasedOnStyle: InheritParentConfig +DisableFormat: false TypenameMacros: - REF diff --git a/src/asahi/.clang-format b/src/asahi/.clang-format index b7f6d08fbaf..d974a0547a6 100644 --- a/src/asahi/.clang-format +++ b/src/asahi/.clang-format @@ -1,5 +1,6 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false AlignConsecutiveBitFields: true ColumnLimit: 80 diff --git a/src/compiler/nir/.clang-format b/src/compiler/nir/.clang-format index c32cf21ec98..087b5d85ea4 100644 --- a/src/compiler/nir/.clang-format +++ b/src/compiler/nir/.clang-format @@ -1,4 +1,5 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false ColumnLimit: 0 Cpp11BracedListStyle: false diff --git a/src/egl/.clang-format b/src/egl/.clang-format index 8beedb5fb85..eb64970a340 100644 --- a/src/egl/.clang-format +++ b/src/egl/.clang-format @@ -1,4 +1,5 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false ColumnLimit: 80 AlwaysBreakAfterReturnType: All diff --git a/src/freedreno/.clang-format b/src/freedreno/.clang-format index 3036a9d696d..44e7d5d3c26 100644 --- a/src/freedreno/.clang-format +++ b/src/freedreno/.clang-format @@ -1,5 +1,6 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false AlignConsecutiveBitFields: true ColumnLimit: 80 diff --git a/src/freedreno/vulkan/.clang-format b/src/freedreno/vulkan/.clang-format index 15354909bee..f7f9e5755db 100644 --- a/src/freedreno/vulkan/.clang-format +++ b/src/freedreno/vulkan/.clang-format @@ -1,5 +1,6 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false AlwaysBreakAfterReturnType: TopLevel BinPackParameters: false diff --git a/src/gallium/drivers/d3d12/.clang-format b/src/gallium/drivers/d3d12/.clang-format index 5cffedcf4c8..df404228853 100644 --- a/src/gallium/drivers/d3d12/.clang-format +++ b/src/gallium/drivers/d3d12/.clang-format @@ -1,5 +1,6 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false ColumnLimit: 120 SortIncludes: false diff --git a/src/gallium/drivers/i915/.clang-format b/src/gallium/drivers/i915/.clang-format index bbfb4e86723..f60c7e4f800 100644 --- a/src/gallium/drivers/i915/.clang-format +++ b/src/gallium/drivers/i915/.clang-format @@ -1,4 +1,5 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false ColumnLimit: 80 diff --git a/src/gallium/drivers/r600/sfn/.clang-format b/src/gallium/drivers/r600/sfn/.clang-format index 82398b0a331..98865becac6 100644 --- a/src/gallium/drivers/r600/sfn/.clang-format +++ b/src/gallium/drivers/r600/sfn/.clang-format @@ -1,5 +1,6 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false AlwaysBreakAfterReturnType: TopLevel AllowShortEnumsOnASingleLine: false diff --git a/src/panfrost/.clang-format b/src/panfrost/.clang-format index b7f6d08fbaf..d974a0547a6 100644 --- a/src/panfrost/.clang-format +++ b/src/panfrost/.clang-format @@ -1,5 +1,6 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false AlignConsecutiveBitFields: true ColumnLimit: 80 diff --git a/src/util/perf/.clang-format b/src/util/perf/.clang-format index 7bdaa2210d7..11f7a8e3bd6 100644 --- a/src/util/perf/.clang-format +++ b/src/util/perf/.clang-format @@ -1,5 +1,6 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false BinPackParameters: false diff --git a/src/virtio/vulkan/.clang-format b/src/virtio/vulkan/.clang-format index 48aba350561..4fa27125b6a 100644 --- a/src/virtio/vulkan/.clang-format +++ b/src/virtio/vulkan/.clang-format @@ -1,5 +1,6 @@ BasedOnStyle: InheritParentConfig +DisableFormat: false AlwaysBreakAfterReturnType: TopLevel BinPackParameters: false