diff mbox series

[4/6] xdrgen: Rename enum's declaration Jinja2 template

Message ID 20240930005016.13374-6-cel@kernel.org (mailing list archive)
State New
Headers show
Series Continued work on xdrgen | expand

Commit Message

Chuck Lever Sept. 30, 2024, 12:50 a.m. UTC
From: Chuck Lever <chuck.lever@oracle.com>

"close.j2" is a confusing name.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
---
 tools/net/sunrpc/xdrgen/generators/enum.py                      | 2 +-
 .../xdrgen/templates/C/enum/declaration/{close.j2 => enum.j2}   | 0
 2 files changed, 1 insertion(+), 1 deletion(-)
 rename tools/net/sunrpc/xdrgen/templates/C/enum/declaration/{close.j2 => enum.j2} (100%)
diff mbox series

Patch

diff --git a/tools/net/sunrpc/xdrgen/generators/enum.py b/tools/net/sunrpc/xdrgen/generators/enum.py
index 855e43f4ae38..e37b5c297821 100644
--- a/tools/net/sunrpc/xdrgen/generators/enum.py
+++ b/tools/net/sunrpc/xdrgen/generators/enum.py
@@ -18,7 +18,7 @@  class XdrEnumGenerator(SourceGenerator):
     def emit_declaration(self, node: _XdrEnum) -> None:
         """Emit one declaration pair for an XDR enum type"""
         if node.name in public_apis:
-            template = self.environment.get_template("declaration/close.j2")
+            template = self.environment.get_template("declaration/enum.j2")
             print(template.render(name=node.name))
 
     def emit_definition(self, node: _XdrEnum) -> None:
diff --git a/tools/net/sunrpc/xdrgen/templates/C/enum/declaration/close.j2 b/tools/net/sunrpc/xdrgen/templates/C/enum/declaration/enum.j2
similarity index 100%
rename from tools/net/sunrpc/xdrgen/templates/C/enum/declaration/close.j2
rename to tools/net/sunrpc/xdrgen/templates/C/enum/declaration/enum.j2