* [RFC PATCH] drm/sched: Fix preprocessor guard
@ 2025-02-18 12:41 Philipp Stanner
2025-02-18 18:18 ` Tvrtko Ursulin
2025-03-03 15:07 ` Philipp Stanner
0 siblings, 2 replies; 3+ messages in thread
From: Philipp Stanner @ 2025-02-18 12:41 UTC (permalink / raw)
To: Matthew Brost, Danilo Krummrich, Philipp Stanner,
Christian König, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, David Airlie, Simona Vetter, Tvrtko Ursulin
Cc: dri-devel, linux-kernel
When writing the header guard for gpu_scheduler_trace.h, a typo,
apparently, occurred.
Fix the typo and document the scope of the guard.
Fixes: 353da3c520b4 ("drm/amdgpu: add tracepoint for scheduler (v2)")
Signed-off-by: Philipp Stanner <phasta@kernel.org>
---
I just discovered this. But I have little understanding of what is going
on in this header in the first place, so I kindly ask for comments on
this entire guard line with its logical or ||
The code hasn't been touched since 2015. So it seems it at least didn't
cause bugs.
P.
---
drivers/gpu/drm/scheduler/gpu_scheduler_trace.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h b/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
index c75302ca3427..f56e77e7f6d0 100644
--- a/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
+++ b/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
@@ -21,7 +21,7 @@
*
*/
-#if !defined(_GPU_SCHED_TRACE_H) || defined(TRACE_HEADER_MULTI_READ)
+#if !defined(_GPU_SCHED_TRACE_H_) || defined(TRACE_HEADER_MULTI_READ)
#define _GPU_SCHED_TRACE_H_
#include <linux/stringify.h>
@@ -106,7 +106,7 @@ TRACE_EVENT(drm_sched_job_wait_dep,
__entry->seqno)
);
-#endif
+#endif /* _GPU_SCHED_TRACE_H_ */
/* This part must be outside protection */
#undef TRACE_INCLUDE_PATH
--
2.47.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [RFC PATCH] drm/sched: Fix preprocessor guard
2025-02-18 12:41 [RFC PATCH] drm/sched: Fix preprocessor guard Philipp Stanner
@ 2025-02-18 18:18 ` Tvrtko Ursulin
2025-03-03 15:07 ` Philipp Stanner
1 sibling, 0 replies; 3+ messages in thread
From: Tvrtko Ursulin @ 2025-02-18 18:18 UTC (permalink / raw)
To: Philipp Stanner, Matthew Brost, Danilo Krummrich,
Christian König, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, David Airlie, Simona Vetter
Cc: dri-devel, linux-kernel
On 18/02/2025 12:41, Philipp Stanner wrote:
> When writing the header guard for gpu_scheduler_trace.h, a typo,
> apparently, occurred.
>
> Fix the typo and document the scope of the guard.
>
> Fixes: 353da3c520b4 ("drm/amdgpu: add tracepoint for scheduler (v2)")
> Signed-off-by: Philipp Stanner <phasta@kernel.org>
> ---
> I just discovered this. But I have little understanding of what is going
> on in this header in the first place, so I kindly ask for comments on
> this entire guard line with its logical or ||
>
> The code hasn't been touched since 2015. So it seems it at least didn't
> cause bugs.
No other header includes so it never caused a problem.
> P.
> ---
> drivers/gpu/drm/scheduler/gpu_scheduler_trace.h | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h b/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
> index c75302ca3427..f56e77e7f6d0 100644
> --- a/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
> +++ b/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
> @@ -21,7 +21,7 @@
> *
> */
>
> -#if !defined(_GPU_SCHED_TRACE_H) || defined(TRACE_HEADER_MULTI_READ)
> +#if !defined(_GPU_SCHED_TRACE_H_) || defined(TRACE_HEADER_MULTI_READ)
> #define _GPU_SCHED_TRACE_H_
>
> #include <linux/stringify.h>
> @@ -106,7 +106,7 @@ TRACE_EVENT(drm_sched_job_wait_dep,
> __entry->seqno)
> );
>
> -#endif
> +#endif /* _GPU_SCHED_TRACE_H_ */
>
> /* This part must be outside protection */
> #undef TRACE_INCLUDE_PATH
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
Regards,
Tvrtko
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [RFC PATCH] drm/sched: Fix preprocessor guard
2025-02-18 12:41 [RFC PATCH] drm/sched: Fix preprocessor guard Philipp Stanner
2025-02-18 18:18 ` Tvrtko Ursulin
@ 2025-03-03 15:07 ` Philipp Stanner
1 sibling, 0 replies; 3+ messages in thread
From: Philipp Stanner @ 2025-03-03 15:07 UTC (permalink / raw)
To: Philipp Stanner, Matthew Brost, Danilo Krummrich,
Christian König, Maarten Lankhorst, Maxime Ripard,
Thomas Zimmermann, David Airlie, Simona Vetter, Tvrtko Ursulin
Cc: dri-devel, linux-kernel
On Tue, 2025-02-18 at 13:41 +0100, Philipp Stanner wrote:
> When writing the header guard for gpu_scheduler_trace.h, a typo,
> apparently, occurred.
>
> Fix the typo and document the scope of the guard.
>
> Fixes: 353da3c520b4 ("drm/amdgpu: add tracepoint for scheduler (v2)")
> Signed-off-by: Philipp Stanner <phasta@kernel.org>
Applied to drm-misc-fixes with Tvrtko's RB
> ---
> I just discovered this. But I have little understanding of what is
> going
> on in this header in the first place, so I kindly ask for comments on
> this entire guard line with its logical or ||
>
> The code hasn't been touched since 2015. So it seems it at least
> didn't
> cause bugs.
>
> P.
> ---
> drivers/gpu/drm/scheduler/gpu_scheduler_trace.h | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
> b/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
> index c75302ca3427..f56e77e7f6d0 100644
> --- a/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
> +++ b/drivers/gpu/drm/scheduler/gpu_scheduler_trace.h
> @@ -21,7 +21,7 @@
> *
> */
>
> -#if !defined(_GPU_SCHED_TRACE_H) || defined(TRACE_HEADER_MULTI_READ)
> +#if !defined(_GPU_SCHED_TRACE_H_) ||
> defined(TRACE_HEADER_MULTI_READ)
> #define _GPU_SCHED_TRACE_H_
>
> #include <linux/stringify.h>
> @@ -106,7 +106,7 @@ TRACE_EVENT(drm_sched_job_wait_dep,
> __entry->seqno)
> );
>
> -#endif
> +#endif /* _GPU_SCHED_TRACE_H_ */
>
> /* This part must be outside protection */
> #undef TRACE_INCLUDE_PATH
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-03-03 15:07 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-18 12:41 [RFC PATCH] drm/sched: Fix preprocessor guard Philipp Stanner
2025-02-18 18:18 ` Tvrtko Ursulin
2025-03-03 15:07 ` Philipp Stanner
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.