Skip to content

Commit 7b9414c

Browse files
andy-shevKAGA-KOKO
authored andcommitted
irqdomain: Remove stray '-' in the domain name
When the domain suffix is not supplied alloc_fwnode_name() unconditionally adds a separator. Fix the format strings to get rid of the stray '-' separator. Fixes: 1e7c052 ("irqdomain: Allow giving name suffix for domain") Signed-off-by: Andy Shevchenko <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Link: https://lore.kernel.org/all/[email protected]
1 parent c0ece64 commit 7b9414c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

kernel/irq/irqdomain.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,9 +149,9 @@ static int alloc_fwnode_name(struct irq_domain *domain, const struct fwnode_hand
149149
char *name;
150150

151151
if (bus_token == DOMAIN_BUS_ANY)
152-
name = kasprintf(GFP_KERNEL, "%pfw-%s", fwnode, suf);
152+
name = kasprintf(GFP_KERNEL, "%pfw%s%s", fwnode, sep, suf);
153153
else
154-
name = kasprintf(GFP_KERNEL, "%pfw-%s%s%d", fwnode, suf, sep, bus_token);
154+
name = kasprintf(GFP_KERNEL, "%pfw%s%s-%d", fwnode, sep, suf, bus_token);
155155
if (!name)
156156
return -ENOMEM;
157157

0 commit comments

Comments
 (0)