drm/tegra: Fix compilation of variadic macro
Jon Hunter
maintainerPATCH 1/1 drm/tegra: Fix compilation of variadic macro
Commit 43636451db8c ("drm/tegra: Implement job submission part of new UAPI") added the macro 'SUBMIT_ERR' that in turns makes use of the macro '__VA_OPT__'. The '__VA_OPT__' macro is not supported by older versions of GCC and so causes build failures when using older versions of GCC. Fix this by using the '##__VA_ARGS__' macro instead.
--- drivers/gpu/drm/tegra/submit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/tegra/submit.c +1 -1
@@ -24,7 +24,7 @@#define SUBMIT_ERR (context, fmt, ...) \ dev_err_ratelimited(context->client->base.dev, \ "%s: job submission failed: " fmt "\n", \ - current->comm __VA_OPT__(,) __VA_ARGS__) + current->comm, ##__VA_ARGS__)static struct tegra_drm_mapping *tegra_drm_mapping_get (struct tegra_drm_context *context,u32 id)
Signature · 1 line
2.25.1
Quoted 19 lines · Jon Hunter
Commit
43636451db8c("drm/tegra: Implement job submission part of new UAPI") added the macro 'SUBMIT_ERR' that in turns makes use of the macro '__VA_OPT__'. The '__VA_OPT__' macro is not supported by older versions of GCC and so causes build failures when using older versions of GCC. Fix this by using the '##__VA_ARGS__' macro instead.Fixes 43636451db8c ("drm/tegra: Implement job submission part of new UAPI")Signed-off-by Jon Hunter <[email protected]>--- drivers/gpu/drm/tegra/submit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/gpu/drm/tegra/submit.c +0
-0
drivers/gpu/drm/tegra/submit.c line 30
Quoted 8 lines
drivers/gpu/drm/tegra/submit.c +1
-1@@ -24,7 +24,7 @@#define SUBMIT_ERR (context, fmt, ...) \ dev_err_ratelimited(context->client->base.dev, \ "%s: job submission failed: " fmt "\n", \ - current->comm __VA_OPT__(,) __VA_ARGS__) + current->comm, ##__VA_ARGS__)static struct tegra_drm_mapping *tegra_drm_mapping_get (struct tegra_drm_context *context,u32 id)
Thanks for taking care of this.
Thierry Reding
AppliedQuoted 6 lines · Jon Hunter
Commit
43636451db8c("drm/tegra: Implement job submission part of new UAPI") added the macro 'SUBMIT_ERR' that in turns makes use of the macro '__VA_OPT__'. The '__VA_OPT__' macro is not supported by older versions of GCC and so causes build failures when using older versions of GCC. Fix this by using the '##__VA_ARGS__' macro instead.
Quoted 6 lines
Fixes 43636451db8c ("drm/tegra: Implement job submission part of new UAPI")Signed-off-by Jon Hunter <[email protected]>--- drivers/gpu/drm/tegra/submit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Applied, thanks.
Thierry