webgpu.h: Update BindingNotUsed enum values | Part 1

This CL renames current Undefined values to BindingNotUsed=0 (still the
default) for the following four enums:

- WGPUBufferBindingType
- WGPUSamplerBindingType
- WGPUTextureSampleType
- WGPUStorageTextureAccess

https://github.com/webgpu-native/webgpu-headers/pull/364

Bug: 377820810
Change-Id: Id75bd9f05a78e8f08a319ef70050f45423f37e3d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/215114
Commit-Queue: Kai Ninomiya <kainino@chromium.org>
Reviewed-by: Kai Ninomiya <kainino@chromium.org>
diff --git a/src/dawn/dawn.json b/src/dawn/dawn.json
index d719a2c..00b3fd9 100644
--- a/src/dawn/dawn.json
+++ b/src/dawn/dawn.json
@@ -381,7 +381,7 @@
     "buffer binding type": {
         "category": "enum",
         "values": [
-            {"value": 0, "name": "undefined", "jsrepr": "undefined", "valid": false},
+            {"value": 0, "name": "binding not used"},
             {"value": 1, "name": "uniform"},
             {"value": 2, "name": "storage"},
             {"value": 3, "name": "read only storage"}
@@ -391,7 +391,7 @@
         "category": "structure",
         "extensible": "in",
         "members": [
-            {"name": "type", "type": "buffer binding type", "default": "undefined"},
+            {"name": "type", "type": "buffer binding type", "default": "binding not used"},
             {"name": "has dynamic offset", "type": "bool", "default": "false"},
             {"name": "min binding size", "type": "uint64_t", "default": "0"}
         ]
@@ -400,7 +400,7 @@
     "sampler binding type": {
         "category": "enum",
         "values": [
-            {"value": 0, "name": "undefined", "jsrepr": "undefined", "valid": false},
+            {"value": 0, "name": "binding not used"},
             {"value": 1, "name": "filtering"},
             {"value": 2, "name": "non filtering"},
             {"value": 3, "name": "comparison"}
@@ -410,7 +410,7 @@
         "category": "structure",
         "extensible": "in",
         "members": [
-            {"name": "type", "type": "sampler binding type", "default": "undefined"}
+            {"name": "type", "type": "sampler binding type", "default": "binding not used"}
         ]
     },
     "static sampler binding layout": {
@@ -426,7 +426,7 @@
     "texture sample type": {
         "category": "enum",
         "values": [
-            {"value": 0, "name": "undefined", "jsrepr": "undefined", "valid": false},
+            {"value": 0, "name": "binding not used"},
             {"value": 1, "name": "float"},
             {"value": 2, "name": "unfilterable float"},
             {"value": 3, "name": "depth"},
@@ -438,7 +438,7 @@
         "category": "structure",
         "extensible": "in",
         "members": [
-            {"name": "sample type", "type": "texture sample type", "default": "undefined"},
+            {"name": "sample type", "type": "texture sample type", "default": "binding not used"},
             {"name": "view dimension", "type": "texture view dimension", "default": "2D"},
             {"name": "multisampled", "type": "bool", "default": "false"}
         ]
@@ -499,7 +499,7 @@
     "storage texture access": {
         "category": "enum",
         "values": [
-            {"value": 0, "name": "undefined", "jsrepr": "undefined", "valid": false},
+            {"value": 0, "name": "binding not used"},
             {"value": 1, "name": "write only"},
             {"value": 2, "name": "read only"},
             {"value": 3, "name": "read write"}
@@ -509,7 +509,7 @@
         "category": "structure",
         "extensible": "in",
         "members": [
-            {"name": "access", "type": "storage texture access", "default": "undefined"},
+            {"name": "access", "type": "storage texture access", "default": "binding not used"},
             {"name": "format", "type": "texture format", "default": "undefined"},
             {"name": "view dimension", "type": "texture view dimension", "default": "2D"}
         ]
diff --git a/src/dawn/native/BindGroup.cpp b/src/dawn/native/BindGroup.cpp
index af334cd..532d111 100644
--- a/src/dawn/native/BindGroup.cpp
+++ b/src/dawn/native/BindGroup.cpp
@@ -107,7 +107,7 @@
             maxBindingSize = device->GetLimits().v1.maxStorageBufferBindingSize;
             requiredBindingAlignment = device->GetLimits().v1.minStorageBufferOffsetAlignment;
             break;
-        case wgpu::BufferBindingType::Undefined:
+        case wgpu::BufferBindingType::BindingNotUsed:
             DAWN_UNREACHABLE();
     }
 
diff --git a/src/dawn/native/BindGroupLayoutInternal.cpp b/src/dawn/native/BindGroupLayoutInternal.cpp
index e9c03fd..b4124c6 100644
--- a/src/dawn/native/BindGroupLayoutInternal.cpp
+++ b/src/dawn/native/BindGroupLayoutInternal.cpp
@@ -96,7 +96,7 @@
 
     int bindingMemberCount = 0;
 
-    if (entry->buffer.type != wgpu::BufferBindingType::Undefined) {
+    if (entry->buffer.type != wgpu::BufferBindingType::BindingNotUsed) {
         bindingMemberCount++;
         const BufferBindingLayout& buffer = entry->buffer;
 
@@ -118,12 +118,12 @@
         }
     }
 
-    if (entry->sampler.type != wgpu::SamplerBindingType::Undefined) {
+    if (entry->sampler.type != wgpu::SamplerBindingType::BindingNotUsed) {
         bindingMemberCount++;
         DAWN_TRY(ValidateSamplerBindingType(entry->sampler.type));
     }
 
-    if (entry->texture.sampleType != wgpu::TextureSampleType::Undefined) {
+    if (entry->texture.sampleType != wgpu::TextureSampleType::BindingNotUsed) {
         bindingMemberCount++;
         const TextureBindingLayout& texture = entry->texture;
         // The kInternalResolveAttachmentSampleType is used internally and not a value
@@ -165,7 +165,7 @@
             "Sample type for multisampled texture binding was %s.", wgpu::TextureSampleType::Float);
     }
 
-    if (entry->storageTexture.access != wgpu::StorageTextureAccess::Undefined) {
+    if (entry->storageTexture.access != wgpu::StorageTextureAccess::BindingNotUsed) {
         bindingMemberCount++;
         const StorageTextureBindingLayout& storageTexture = entry->storageTexture;
         DAWN_TRY(ValidateStorageTextureAccess(storageTexture.access));
@@ -391,11 +391,11 @@
 }
 
 bool IsBufferBinding(const UnpackedPtr<BindGroupLayoutEntry>& binding) {
-    return binding->buffer.type != wgpu::BufferBindingType::Undefined;
+    return binding->buffer.type != wgpu::BufferBindingType::BindingNotUsed;
 }
 
 bool BindingHasDynamicOffset(const UnpackedPtr<BindGroupLayoutEntry>& binding) {
-    if (binding->buffer.type != wgpu::BufferBindingType::Undefined) {
+    if (binding->buffer.type != wgpu::BufferBindingType::BindingNotUsed) {
         return binding->buffer.hasDynamicOffset;
     }
     return false;
@@ -406,18 +406,18 @@
     bindingInfo.binding = BindingNumber(binding->binding);
     bindingInfo.visibility = binding->visibility;
 
-    if (binding->buffer.type != wgpu::BufferBindingType::Undefined) {
+    if (binding->buffer.type != wgpu::BufferBindingType::BindingNotUsed) {
         bindingInfo.bindingLayout = BufferBindingInfo(binding->buffer);
-    } else if (binding->sampler.type != wgpu::SamplerBindingType::Undefined) {
+    } else if (binding->sampler.type != wgpu::SamplerBindingType::BindingNotUsed) {
         bindingInfo.bindingLayout = SamplerBindingInfo(binding->sampler);
-    } else if (binding->texture.sampleType != wgpu::TextureSampleType::Undefined) {
+    } else if (binding->texture.sampleType != wgpu::TextureSampleType::BindingNotUsed) {
         if (binding->texture.viewDimension == kInternalInputAttachmentDim) {
             bindingInfo.bindingLayout = InputAttachmentBindingInfo(binding->texture.sampleType);
         } else {
             bindingInfo.bindingLayout =
                 TextureBindingInfo(binding->texture.WithTrivialFrontendDefaults());
         }
-    } else if (binding->storageTexture.access != wgpu::StorageTextureAccess::Undefined) {
+    } else if (binding->storageTexture.access != wgpu::StorageTextureAccess::BindingNotUsed) {
         bindingInfo.bindingLayout =
             StorageTextureBindingInfo(binding->storageTexture.WithTrivialFrontendDefaults());
     } else if (auto* staticSamplerBindingLayout = binding.Get<StaticSamplerBindingLayout>()) {
@@ -773,7 +773,7 @@
         case wgpu::BufferBindingType::Storage:
         case wgpu::BufferBindingType::ReadOnlyStorage:
             return true;
-        case wgpu::BufferBindingType::Undefined:
+        case wgpu::BufferBindingType::BindingNotUsed:
             break;
     }
     DAWN_UNREACHABLE();
diff --git a/src/dawn/native/BindingInfo.cpp b/src/dawn/native/BindingInfo.cpp
index 1fb2b05..bf7e214 100644
--- a/src/dawn/native/BindingInfo.cpp
+++ b/src/dawn/native/BindingInfo.cpp
@@ -57,7 +57,7 @@
 
     uint32_t PerStageBindingCounts::*perStageBindingCountMember = nullptr;
 
-    if (entry->buffer.type != wgpu::BufferBindingType::Undefined) {
+    if (entry->buffer.type != wgpu::BufferBindingType::BindingNotUsed) {
         ++bindingCounts->bufferCount;
         const BufferBindingLayout& buffer = entry->buffer;
 
@@ -82,21 +82,21 @@
                 perStageBindingCountMember = &PerStageBindingCounts::storageBufferCount;
                 break;
 
-            case wgpu::BufferBindingType::Undefined:
+            case wgpu::BufferBindingType::BindingNotUsed:
                 // Can't get here due to the enclosing if statement.
                 DAWN_UNREACHABLE();
                 break;
         }
-    } else if (entry->sampler.type != wgpu::SamplerBindingType::Undefined) {
+    } else if (entry->sampler.type != wgpu::SamplerBindingType::BindingNotUsed) {
         perStageBindingCountMember = &PerStageBindingCounts::samplerCount;
-    } else if (entry->texture.sampleType != wgpu::TextureSampleType::Undefined) {
+    } else if (entry->texture.sampleType != wgpu::TextureSampleType::BindingNotUsed) {
         if (entry->texture.viewDimension == kInternalInputAttachmentDim) {
             // Internal use only.
             return;
         } else {
             perStageBindingCountMember = &PerStageBindingCounts::sampledTextureCount;
         }
-    } else if (entry->storageTexture.access != wgpu::StorageTextureAccess::Undefined) {
+    } else if (entry->storageTexture.access != wgpu::StorageTextureAccess::BindingNotUsed) {
         perStageBindingCountMember = &PerStageBindingCounts::storageTextureCount;
     } else if (entry.Get<ExternalTextureBindingLayout>()) {
         perStageBindingCountMember = &PerStageBindingCounts::externalTextureCount;
diff --git a/src/dawn/native/CommandBufferStateTracker.cpp b/src/dawn/native/CommandBufferStateTracker.cpp
index 04500a9..c403f97 100644
--- a/src/dawn/native/CommandBufferStateTracker.cpp
+++ b/src/dawn/native/CommandBufferStateTracker.cpp
@@ -174,7 +174,7 @@
                     break;
                 case wgpu::StorageTextureAccess::ReadOnly:
                     continue;
-                case wgpu::StorageTextureAccess::Undefined:
+                case wgpu::StorageTextureAccess::BindingNotUsed:
                 default:
                     DAWN_UNREACHABLE();
             }
diff --git a/src/dawn/native/Format.cpp b/src/dawn/native/Format.cpp
index a0f98c0..384d631 100644
--- a/src/dawn/native/Format.cpp
+++ b/src/dawn/native/Format.cpp
@@ -66,14 +66,14 @@
         case wgpu::TextureSampleType::Sint:
         case wgpu::TextureSampleType::Uint:
         case wgpu::TextureSampleType::Depth:
-        case wgpu::TextureSampleType::Undefined:
+        case wgpu::TextureSampleType::BindingNotUsed:
             // When the compiler complains that you need to add a case statement here, please
             // also add a corresponding static assert below!
             break;
     }
 
-    static_assert(static_cast<uint32_t>(wgpu::TextureSampleType::Undefined) == 0);
-    if (sampleType == wgpu::TextureSampleType::Undefined) {
+    static_assert(static_cast<uint32_t>(wgpu::TextureSampleType::BindingNotUsed) == 0);
+    if (sampleType == wgpu::TextureSampleType::BindingNotUsed) {
         return SampleTypeBit::None;
     }
 
diff --git a/src/dawn/native/PassResourceUsageTracker.cpp b/src/dawn/native/PassResourceUsageTracker.cpp
index 93de037..cc48199 100644
--- a/src/dawn/native/PassResourceUsageTracker.cpp
+++ b/src/dawn/native/PassResourceUsageTracker.cpp
@@ -126,7 +126,7 @@
                     case wgpu::BufferBindingType::ReadOnlyStorage:
                         BufferUsedAs(buffer, kReadOnlyStorageBuffer, bindingInfo.visibility);
                         break;
-                    case wgpu::BufferBindingType::Undefined:
+                    case wgpu::BufferBindingType::BindingNotUsed:
                         DAWN_UNREACHABLE();
                 }
             },
@@ -156,7 +156,7 @@
                     case wgpu::StorageTextureAccess::ReadOnly:
                         TextureViewUsedAs(view, kReadOnlyStorageTexture, bindingInfo.visibility);
                         break;
-                    case wgpu::StorageTextureAccess::Undefined:
+                    case wgpu::StorageTextureAccess::BindingNotUsed:
                         DAWN_UNREACHABLE();
                 }
             },
diff --git a/src/dawn/native/PipelineLayout.cpp b/src/dawn/native/PipelineLayout.cpp
index 578c6b0..f752bfc 100644
--- a/src/dawn/native/PipelineLayout.cpp
+++ b/src/dawn/native/PipelineLayout.cpp
@@ -202,17 +202,17 @@
             modifiedEntry->buffer.type == mergedEntry.buffer.type &&
             modifiedEntry->sampler.type == mergedEntry.sampler.type &&
             // Compatibility between these sample types is checked below.
-            (modifiedEntry->texture.sampleType != wgpu::TextureSampleType::Undefined) ==
-                (mergedEntry.texture.sampleType != wgpu::TextureSampleType::Undefined) &&
+            (modifiedEntry->texture.sampleType != wgpu::TextureSampleType::BindingNotUsed) ==
+                (mergedEntry.texture.sampleType != wgpu::TextureSampleType::BindingNotUsed) &&
             modifiedEntry->storageTexture.access == mergedEntry.storageTexture.access;
 
         // Minimum buffer binding size excluded because we take the maximum seen across stages.
-        if (modifiedEntry->buffer.type != wgpu::BufferBindingType::Undefined) {
+        if (modifiedEntry->buffer.type != wgpu::BufferBindingType::BindingNotUsed) {
             compatible = compatible && modifiedEntry->buffer.hasDynamicOffset ==
                                            mergedEntry.buffer.hasDynamicOffset;
         }
 
-        if (modifiedEntry->texture.sampleType != wgpu::TextureSampleType::Undefined) {
+        if (modifiedEntry->texture.sampleType != wgpu::TextureSampleType::BindingNotUsed) {
             // Sample types are compatible if they are exactly equal,
             // or if the |modifiedEntry| is Float and the |mergedEntry| is UnfilterableFloat.
             // Note that the |mergedEntry| never has type Float. Texture bindings all start
@@ -229,7 +229,7 @@
                 modifiedEntry->texture.multisampled == mergedEntry.texture.multisampled;
         }
 
-        if (modifiedEntry->storageTexture.access != wgpu::StorageTextureAccess::Undefined) {
+        if (modifiedEntry->storageTexture.access != wgpu::StorageTextureAccess::BindingNotUsed) {
             compatible =
                 compatible &&
                 modifiedEntry->storageTexture.format == mergedEntry.storageTexture.format &&
diff --git a/src/dawn/native/ProgrammableEncoder.cpp b/src/dawn/native/ProgrammableEncoder.cpp
index cd77359..60a933a 100644
--- a/src/dawn/native/ProgrammableEncoder.cpp
+++ b/src/dawn/native/ProgrammableEncoder.cpp
@@ -160,7 +160,7 @@
             case kInternalStorageBufferBinding:
                 requiredAlignment = GetDevice()->GetLimits().v1.minStorageBufferOffsetAlignment;
                 break;
-            case wgpu::BufferBindingType::Undefined:
+            case wgpu::BufferBindingType::BindingNotUsed:
                 DAWN_UNREACHABLE();
         }
 
diff --git a/src/dawn/native/ShaderModule.cpp b/src/dawn/native/ShaderModule.cpp
index af80855..70c4c38 100644
--- a/src/dawn/native/ShaderModule.cpp
+++ b/src/dawn/native/ShaderModule.cpp
@@ -179,7 +179,7 @@
             // Note that Float is compatible with both Float and UnfilterableFloat.
             return wgpu::TextureSampleType::Float;
         case tint::inspector::ResourceBinding::SampledKind::kUnknown:
-            return wgpu::TextureSampleType::Undefined;
+            return wgpu::TextureSampleType::BindingNotUsed;
     }
     DAWN_UNREACHABLE();
 }
diff --git a/src/dawn/native/d3d11/BindGroupTrackerD3D11.cpp b/src/dawn/native/d3d11/BindGroupTrackerD3D11.cpp
index 01a3423..cd4775d 100644
--- a/src/dawn/native/d3d11/BindGroupTrackerD3D11.cpp
+++ b/src/dawn/native/d3d11/BindGroupTrackerD3D11.cpp
@@ -232,7 +232,7 @@
                         }
                         break;
                     }
-                    case wgpu::BufferBindingType::Undefined:
+                    case wgpu::BufferBindingType::BindingNotUsed:
                         DAWN_UNREACHABLE();
                 }
                 return {};
@@ -370,7 +370,7 @@
                         deviceContext->CSSetShaderResources(bindingSlot, 1, &nullSRV);
                         break;
                     }
-                    case wgpu::BufferBindingType::Undefined:
+                    case wgpu::BufferBindingType::BindingNotUsed:
                         DAWN_UNREACHABLE();
                 }
             },
@@ -494,10 +494,11 @@
                             break;
                         }
                         case wgpu::BufferBindingType::Uniform:
-                        case wgpu::BufferBindingType::ReadOnlyStorage:
-                        case wgpu::BufferBindingType::Undefined: {
+                        case wgpu::BufferBindingType::ReadOnlyStorage: {
                             break;
                         }
+                        case wgpu::BufferBindingType::BindingNotUsed:
+                            DAWN_UNREACHABLE();
                     }
                     return {};
                 },
diff --git a/src/dawn/native/d3d11/PipelineLayoutD3D11.cpp b/src/dawn/native/d3d11/PipelineLayoutD3D11.cpp
index 1a87c9e..e7e52dd 100644
--- a/src/dawn/native/d3d11/PipelineLayoutD3D11.cpp
+++ b/src/dawn/native/d3d11/PipelineLayoutD3D11.cpp
@@ -77,7 +77,7 @@
                         case wgpu::BufferBindingType::ReadOnlyStorage:
                             mIndexInfo[group][bindingIndex] = shaderResourceViewIndex++;
                             break;
-                        case wgpu::BufferBindingType::Undefined:
+                        case wgpu::BufferBindingType::BindingNotUsed:
                             DAWN_UNREACHABLE();
                     }
                 },
@@ -102,7 +102,7 @@
                         case wgpu::StorageTextureAccess::ReadOnly:
                             mIndexInfo[group][bindingIndex] = shaderResourceViewIndex++;
                             break;
-                        case wgpu::StorageTextureAccess::Undefined:
+                        case wgpu::StorageTextureAccess::BindingNotUsed:
                             DAWN_UNREACHABLE();
                     }
                 },
diff --git a/src/dawn/native/d3d11/ShaderModuleD3D11.cpp b/src/dawn/native/d3d11/ShaderModuleD3D11.cpp
index b0d4f72..aa6e140 100644
--- a/src/dawn/native/d3d11/ShaderModuleD3D11.cpp
+++ b/src/dawn/native/d3d11/ShaderModuleD3D11.cpp
@@ -147,7 +147,7 @@
                             srcBindingPoint, tint::hlsl::writer::binding::Storage{
                                                  dstBindingPoint.group, dstBindingPoint.binding});
                         break;
-                    case wgpu::BufferBindingType::Undefined:
+                    case wgpu::BufferBindingType::BindingNotUsed:
                         DAWN_UNREACHABLE();
                         break;
                 }
diff --git a/src/dawn/native/d3d12/BindGroupD3D12.cpp b/src/dawn/native/d3d12/BindGroupD3D12.cpp
index 6adf65e..3149aa5 100644
--- a/src/dawn/native/d3d12/BindGroupD3D12.cpp
+++ b/src/dawn/native/d3d12/BindGroupD3D12.cpp
@@ -140,7 +140,7 @@
                                                       descriptorHeapOffsets[bindingIndex]));
                         break;
                     }
-                    case wgpu::BufferBindingType::Undefined:
+                    case wgpu::BufferBindingType::BindingNotUsed:
                         DAWN_UNREACHABLE();
                 }
             },
@@ -190,7 +190,7 @@
                                                       descriptorHeapOffsets[bindingIndex]));
                         break;
                     }
-                    case wgpu::StorageTextureAccess::Undefined:
+                    case wgpu::StorageTextureAccess::BindingNotUsed:
                         DAWN_UNREACHABLE();
                 }
             },
diff --git a/src/dawn/native/d3d12/BindGroupLayoutD3D12.cpp b/src/dawn/native/d3d12/BindGroupLayoutD3D12.cpp
index 2cf9ce6..875e863 100644
--- a/src/dawn/native/d3d12/BindGroupLayoutD3D12.cpp
+++ b/src/dawn/native/d3d12/BindGroupLayoutD3D12.cpp
@@ -51,7 +51,7 @@
                     return D3D12_DESCRIPTOR_RANGE_TYPE_UAV;
                 case wgpu::BufferBindingType::ReadOnlyStorage:
                     return D3D12_DESCRIPTOR_RANGE_TYPE_SRV;
-                case wgpu::BufferBindingType::Undefined:
+                case wgpu::BufferBindingType::BindingNotUsed:
                     DAWN_UNREACHABLE();
             }
         },
@@ -71,7 +71,7 @@
                     return D3D12_DESCRIPTOR_RANGE_TYPE_UAV;
                 case wgpu::StorageTextureAccess::ReadOnly:
                     return D3D12_DESCRIPTOR_RANGE_TYPE_SRV;
-                case wgpu::StorageTextureAccess::Undefined:
+                case wgpu::StorageTextureAccess::BindingNotUsed:
                     DAWN_UNREACHABLE();
             }
         },
diff --git a/src/dawn/native/d3d12/CommandBufferD3D12.cpp b/src/dawn/native/d3d12/CommandBufferD3D12.cpp
index b422f40..668f7b6 100644
--- a/src/dawn/native/d3d12/CommandBufferD3D12.cpp
+++ b/src/dawn/native/d3d12/CommandBufferD3D12.cpp
@@ -527,7 +527,7 @@
                     commandList->SetComputeRootShaderResourceView(parameterIndex, bufferLocation);
                 }
                 break;
-            case wgpu::BufferBindingType::Undefined:
+            case wgpu::BufferBindingType::BindingNotUsed:
                 DAWN_UNREACHABLE();
         }
     }
diff --git a/src/dawn/native/d3d12/PipelineLayoutD3D12.cpp b/src/dawn/native/d3d12/PipelineLayoutD3D12.cpp
index 4d47ab8..33fd776 100644
--- a/src/dawn/native/d3d12/PipelineLayoutD3D12.cpp
+++ b/src/dawn/native/d3d12/PipelineLayoutD3D12.cpp
@@ -65,7 +65,7 @@
             return D3D12_ROOT_PARAMETER_TYPE_UAV;
         case wgpu::BufferBindingType::ReadOnlyStorage:
             return D3D12_ROOT_PARAMETER_TYPE_SRV;
-        case wgpu::BufferBindingType::Undefined:
+        case wgpu::BufferBindingType::BindingNotUsed:
             DAWN_UNREACHABLE();
     }
 }
diff --git a/src/dawn/native/d3d12/ShaderModuleD3D12.cpp b/src/dawn/native/d3d12/ShaderModuleD3D12.cpp
index 293a710..4fd8126 100644
--- a/src/dawn/native/d3d12/ShaderModuleD3D12.cpp
+++ b/src/dawn/native/d3d12/ShaderModuleD3D12.cpp
@@ -222,7 +222,7 @@
                             srcBindingPoint, tint::hlsl::writer::binding::Storage{
                                                  dstBindingPoint.group, dstBindingPoint.binding});
                         break;
-                    case wgpu::BufferBindingType::Undefined:
+                    case wgpu::BufferBindingType::BindingNotUsed:
                         DAWN_UNREACHABLE();
                         break;
                 }
diff --git a/src/dawn/native/metal/ShaderModuleMTL.mm b/src/dawn/native/metal/ShaderModuleMTL.mm
index c8bfe03..173489a 100644
--- a/src/dawn/native/metal/ShaderModuleMTL.mm
+++ b/src/dawn/native/metal/ShaderModuleMTL.mm
@@ -161,7 +161,7 @@
                             arrayLengthFromUniform.bindpoint_to_size_index.emplace(
                                 srcBindingPoint, dstBindingPoint.binding);
                             break;
-                        case wgpu::BufferBindingType::Undefined:
+                        case wgpu::BufferBindingType::BindingNotUsed:
                             DAWN_UNREACHABLE();
                             break;
                     }
diff --git a/src/dawn/native/opengl/CommandBufferGL.cpp b/src/dawn/native/opengl/CommandBufferGL.cpp
index 91dc7b4..34c622a 100644
--- a/src/dawn/native/opengl/CommandBufferGL.cpp
+++ b/src/dawn/native/opengl/CommandBufferGL.cpp
@@ -339,7 +339,7 @@
                         case wgpu::BufferBindingType::ReadOnlyStorage:
                             target = GL_SHADER_STORAGE_BUFFER;
                             break;
-                        case wgpu::BufferBindingType::Undefined:
+                        case wgpu::BufferBindingType::BindingNotUsed:
                             DAWN_UNREACHABLE();
                     }
 
@@ -409,7 +409,7 @@
                         case wgpu::StorageTextureAccess::ReadOnly:
                             access = GL_READ_ONLY;
                             break;
-                        case wgpu::StorageTextureAccess::Undefined:
+                        case wgpu::StorageTextureAccess::BindingNotUsed:
                             DAWN_UNREACHABLE();
                     }
 
diff --git a/src/dawn/native/opengl/PipelineLayoutGL.cpp b/src/dawn/native/opengl/PipelineLayoutGL.cpp
index 46b634b..d59e2a8 100644
--- a/src/dawn/native/opengl/PipelineLayoutGL.cpp
+++ b/src/dawn/native/opengl/PipelineLayoutGL.cpp
@@ -63,7 +63,7 @@
                             mIndexInfo[group][bindingIndex] = ssboIndex;
                             ssboIndex++;
                             break;
-                        case wgpu::BufferBindingType::Undefined:
+                        case wgpu::BufferBindingType::BindingNotUsed:
                             DAWN_UNREACHABLE();
                     }
                 },
diff --git a/src/dawn/native/opengl/ShaderModuleGL.cpp b/src/dawn/native/opengl/ShaderModuleGL.cpp
index 98310b5..2adfbf6 100644
--- a/src/dawn/native/opengl/ShaderModuleGL.cpp
+++ b/src/dawn/native/opengl/ShaderModuleGL.cpp
@@ -348,7 +348,7 @@
                             srcBindingPoint,
                             tint::glsl::writer::binding::Storage{dstBindingPoint.binding});
                         break;
-                    case wgpu::BufferBindingType::Undefined:
+                    case wgpu::BufferBindingType::BindingNotUsed:
                         DAWN_UNREACHABLE();
                         break;
                 }
diff --git a/src/dawn/native/vulkan/BindGroupLayoutVk.cpp b/src/dawn/native/vulkan/BindGroupLayoutVk.cpp
index 584674d..13a766d 100644
--- a/src/dawn/native/vulkan/BindGroupLayoutVk.cpp
+++ b/src/dawn/native/vulkan/BindGroupLayoutVk.cpp
@@ -82,7 +82,7 @@
                         return VK_DESCRIPTOR_TYPE_STORAGE_BUFFER_DYNAMIC;
                     }
                     return VK_DESCRIPTOR_TYPE_STORAGE_BUFFER;
-                case wgpu::BufferBindingType::Undefined:
+                case wgpu::BufferBindingType::BindingNotUsed:
                     DAWN_UNREACHABLE();
                     return VK_DESCRIPTOR_TYPE_STORAGE_BUFFER;
             }
diff --git a/src/dawn/native/vulkan/ShaderModuleVk.cpp b/src/dawn/native/vulkan/ShaderModuleVk.cpp
index 9266b2d..3ff33cd 100644
--- a/src/dawn/native/vulkan/ShaderModuleVk.cpp
+++ b/src/dawn/native/vulkan/ShaderModuleVk.cpp
@@ -278,7 +278,7 @@
                                 tint::spirv::writer::binding::Storage{dstBindingPoint.group,
                                                                       dstBindingPoint.binding});
                             break;
-                        case wgpu::BufferBindingType::Undefined:
+                        case wgpu::BufferBindingType::BindingNotUsed:
                             DAWN_UNREACHABLE();
                             break;
                     }
diff --git a/src/dawn/node/binding/Converter.cpp b/src/dawn/node/binding/Converter.cpp
index 980a52f..d4034fe 100644
--- a/src/dawn/node/binding/Converter.cpp
+++ b/src/dawn/node/binding/Converter.cpp
@@ -1389,7 +1389,7 @@
 }
 
 bool Converter::Convert(wgpu::BufferBindingType& out, const interop::GPUBufferBindingType& in) {
-    out = wgpu::BufferBindingType::Undefined;
+    out = wgpu::BufferBindingType::BindingNotUsed;
     switch (in) {
         case interop::GPUBufferBindingType::kUniform:
             out = wgpu::BufferBindingType::Uniform;
@@ -1405,7 +1405,7 @@
 }
 
 bool Converter::Convert(wgpu::TextureSampleType& out, const interop::GPUTextureSampleType& in) {
-    out = wgpu::TextureSampleType::Undefined;
+    out = wgpu::TextureSampleType::BindingNotUsed;
     switch (in) {
         case interop::GPUTextureSampleType::kFloat:
             out = wgpu::TextureSampleType::Float;
@@ -1427,7 +1427,7 @@
 }
 
 bool Converter::Convert(wgpu::SamplerBindingType& out, const interop::GPUSamplerBindingType& in) {
-    out = wgpu::SamplerBindingType::Undefined;
+    out = wgpu::SamplerBindingType::BindingNotUsed;
     switch (in) {
         case interop::GPUSamplerBindingType::kFiltering:
             out = wgpu::SamplerBindingType::Filtering;
@@ -1444,7 +1444,7 @@
 
 bool Converter::Convert(wgpu::StorageTextureAccess& out,
                         const interop::GPUStorageTextureAccess& in) {
-    out = wgpu::StorageTextureAccess::Undefined;
+    out = wgpu::StorageTextureAccess::BindingNotUsed;
     switch (in) {
         case interop::GPUStorageTextureAccess::kWriteOnly:
             out = wgpu::StorageTextureAccess::WriteOnly;
diff --git a/src/dawn/tests/unittests/validation/GetBindGroupLayoutValidationTests.cpp b/src/dawn/tests/unittests/validation/GetBindGroupLayoutValidationTests.cpp
index 07f4a18..d186ee8 100644
--- a/src/dawn/tests/unittests/validation/GetBindGroupLayoutValidationTests.cpp
+++ b/src/dawn/tests/unittests/validation/GetBindGroupLayoutValidationTests.cpp
@@ -485,7 +485,7 @@
                     BindGroupLayoutCacheEq(pipeline.GetBindGroupLayout(0)));
     }
 
-    binding.buffer.type = wgpu::BufferBindingType::Undefined;
+    binding.buffer.type = wgpu::BufferBindingType::BindingNotUsed;
     binding.buffer.minBindingSize = 0;
     {
         binding.texture.sampleType = wgpu::TextureSampleType::UnfilterableFloat;
@@ -511,7 +511,7 @@
                     BindGroupLayoutCacheEq(pipeline.GetBindGroupLayout(0)));
     }
 
-    binding.texture.sampleType = wgpu::TextureSampleType::Undefined;
+    binding.texture.sampleType = wgpu::TextureSampleType::BindingNotUsed;
     {
         binding.sampler.type = wgpu::SamplerBindingType::Filtering;
         wgpu::RenderPipeline pipeline = RenderPipelineFromFragmentShader(R"(
diff --git a/tools/android/webgpu/src/test/java/android/dawn/EnumsTest.kt b/tools/android/webgpu/src/test/java/android/dawn/EnumsTest.kt
index 82d60a6..25f1026 100644
--- a/tools/android/webgpu/src/test/java/android/dawn/EnumsTest.kt
+++ b/tools/android/webgpu/src/test/java/android/dawn/EnumsTest.kt
@@ -9,7 +9,7 @@
     fun uniqueEnumsBufferBindingType() {
         val values = HashSet<BufferBindingType>()
         arrayOf(
-            BufferBindingType.Undefined,
+            BufferBindingType.BindingNotUsed,
             BufferBindingType.Uniform,
             BufferBindingType.Storage,
             BufferBindingType.ReadOnlyStorage