On Fri, Dec 05, 2025 at 12:52:32PM -0500, Yury Norov (NVIDIA) wrote: > The macro was introduced in 1994, v1.0.4, for stacks protection. Since > that, people found better ways to protect stacks, and now the macro is > only used by i915 selftests. Move it to a local header and drop from > the kernel.h. > > Reviewed-by: Andy Shevchenko <[email protected]> > Acked-by: Randy Dunlap <[email protected]> > Acked-by: Jani Nikula <[email protected]> > Reviewed-by: Christophe Leroy (CS GROUP) <[email protected]> > Signed-off-by: Yury Norov (NVIDIA) <[email protected]> > --- > drivers/gpu/drm/i915/gt/selftest_ring_submission.c | 1 + > drivers/gpu/drm/i915/i915_selftest.h | 2 ++ > include/linux/kernel.h | 2 -- > 3 files changed, 3 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/i915/gt/selftest_ring_submission.c > b/drivers/gpu/drm/i915/gt/selftest_ring_submission.c > index 87ceb0f374b6..600333ae6c8c 100644 > --- a/drivers/gpu/drm/i915/gt/selftest_ring_submission.c > +++ b/drivers/gpu/drm/i915/gt/selftest_ring_submission.c > @@ -3,6 +3,7 @@ > * Copyright © 2020 Intel Corporation > */ > > +#include "i915_selftest.h" > #include "intel_engine_pm.h" > #include "selftests/igt_flush_test.h" > > diff --git a/drivers/gpu/drm/i915/i915_selftest.h > b/drivers/gpu/drm/i915/i915_selftest.h > index bdf3e22c0a34..72922028f4ba 100644 > --- a/drivers/gpu/drm/i915/i915_selftest.h > +++ b/drivers/gpu/drm/i915/i915_selftest.h > @@ -26,6 +26,8 @@ > > #include <linux/types.h> > > +#define STACK_MAGIC 0xdeadbeef > + > struct pci_dev; > struct drm_i915_private; > > diff --git a/include/linux/kernel.h b/include/linux/kernel.h > index 5b46924fdff5..61d63c57bc2d 100644 > --- a/include/linux/kernel.h > +++ b/include/linux/kernel.h > @@ -40,8 +40,6 @@ > > #include <uapi/linux/kernel.h> > > -#define STACK_MAGIC 0xdeadbeef > - > struct completion; > struct user; > > -- > 2.43.0 > >
Reviewed-by: Aaron Tomlin <[email protected]> -- Aaron Tomlin
