All of lore.kernel.org
 help / color / mirror / Atom feed
* [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
@ 2024-07-24  1:08 kernel test robot
  2024-07-24  6:07 ` Juergen Gross
  0 siblings, 1 reply; 9+ messages in thread
From: kernel test robot @ 2024-07-24  1:08 UTC (permalink / raw)
  To: Juergen Gross; +Cc: oe-kbuild-all, xen-devel, Boris Ostrovsky

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/xen/tip.git linux-next
head:   368990a7fe30737c990f628a60d26d9854a9e690
commit: 368990a7fe30737c990f628a60d26d9854a9e690 [12/12] xen: fix multicall debug data referencing
config: x86_64-randconfig-012-20240724 (https://download.01.org/0day-ci/archive/20240724/202407240907.u0NJHgTu-lkp@intel.com/config)
compiler: gcc-13 (Ubuntu 13.2.0-4ubuntu3) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240724/202407240907.u0NJHgTu-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202407240907.u0NJHgTu-lkp@intel.com/

All warnings (new ones prefixed by >>, old ones prefixed by <<):

>> WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/locking/locktorture.o
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/locking/test-ww_mutex.o
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/rcu/rcutorture.o
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/rcu/rcuscale.o
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/rcu/refscale.o
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/time/time_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/torture.o
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/resource_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in kernel/sysctl-test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in mm/kasan/kasan_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in mm/dmapool_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in fs/ext4/ext4-inode-test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in fs/fat/fat_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/kunit/kunit-test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/kunit/kunit-example-test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/math/rational-test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_hexdump.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_firmware.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/cpumask_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_hash.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_ida.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_list_sort.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_min_heap.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_sort.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_scanf.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_bitmap.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_uuid.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_xarray.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_maple_tree.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_meminit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_free_pages.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_kprobes.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_ref_tracker.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_fpu.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/atomic64_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/bitfield_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/checksum_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/list-test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/hashtable_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/test_bits.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/cmdline_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/slub_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/memcpy_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/is_signed_type_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/overflow_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/stackinit_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/fortify_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in lib/siphash_kunit.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/acpi/platform_profile.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/clk_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/clk-gate_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/clk/clk-fractional-divider_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_buddy_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_cmdline_parser_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_connector_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_damage_helper_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_dp_mst_helper_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_exec_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_format_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_framebuffer_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_gem_shmem_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_managed_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_mm_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_modes_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_plane_helper_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_probe_helper_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/gpu/drm/tests/drm_rect_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/input/tests/input_test.o
WARNING: modpost: missing MODULE_DESCRIPTION() in drivers/rtc/lib_test.o

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
  2024-07-24  1:08 [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data) kernel test robot
@ 2024-07-24  6:07 ` Juergen Gross
  2024-07-24  6:54   ` Jan Beulich
  0 siblings, 1 reply; 9+ messages in thread
From: Juergen Gross @ 2024-07-24  6:07 UTC (permalink / raw)
  To: kernel test robot; +Cc: oe-kbuild-all, xen-devel, Boris Ostrovsky


[-- Attachment #1.1.1: Type: text/plain, Size: 1232 bytes --]

On 24.07.24 03:08, kernel test robot wrote:
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/xen/tip.git linux-next
> head:   368990a7fe30737c990f628a60d26d9854a9e690
> commit: 368990a7fe30737c990f628a60d26d9854a9e690 [12/12] xen: fix multicall debug data referencing
> config: x86_64-randconfig-012-20240724 (https://download.01.org/0day-ci/archive/20240724/202407240907.u0NJHgTu-lkp@intel.com/config)
> compiler: gcc-13 (Ubuntu 13.2.0-4ubuntu3) 13.2.0
> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240724/202407240907.u0NJHgTu-lkp@intel.com/reproduce)
> 
> If you fix the issue in a separate patch/commit (i.e. not just a new version of
> the same patch/commit), kindly add following tags
> | Reported-by: kernel test robot <lkp@intel.com>
> | Closes: https://lore.kernel.org/oe-kbuild-all/202407240907.u0NJHgTu-lkp@intel.com/
> 
> All warnings (new ones prefixed by >>, old ones prefixed by <<):
> 
>>> WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)

With current infrastructure this is not easily fixable, as there is no way
to tag a percpu variable as __refdata.


Juergen

[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 3743 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 495 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
  2024-07-24  6:07 ` Juergen Gross
@ 2024-07-24  6:54   ` Jan Beulich
  2024-07-24  9:55     ` Jürgen Groß
  0 siblings, 1 reply; 9+ messages in thread
From: Jan Beulich @ 2024-07-24  6:54 UTC (permalink / raw)
  To: Juergen Gross
  Cc: oe-kbuild-all, xen-devel, Boris Ostrovsky, kernel test robot

On 24.07.2024 08:07, Juergen Gross wrote:
> On 24.07.24 03:08, kernel test robot wrote:
>> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/xen/tip.git linux-next
>> head:   368990a7fe30737c990f628a60d26d9854a9e690
>> commit: 368990a7fe30737c990f628a60d26d9854a9e690 [12/12] xen: fix multicall debug data referencing
>> config: x86_64-randconfig-012-20240724 (https://download.01.org/0day-ci/archive/20240724/202407240907.u0NJHgTu-lkp@intel.com/config)
>> compiler: gcc-13 (Ubuntu 13.2.0-4ubuntu3) 13.2.0
>> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240724/202407240907.u0NJHgTu-lkp@intel.com/reproduce)
>>
>> If you fix the issue in a separate patch/commit (i.e. not just a new version of
>> the same patch/commit), kindly add following tags
>> | Reported-by: kernel test robot <lkp@intel.com>
>> | Closes: https://lore.kernel.org/oe-kbuild-all/202407240907.u0NJHgTu-lkp@intel.com/
>>
>> All warnings (new ones prefixed by >>, old ones prefixed by <<):
>>
>>>> WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
> 
> With current infrastructure this is not easily fixable, as there is no way
> to tag a percpu variable as __refdata.

Would it be an option to drop the static initializer and set CPU0's value
from xen_parse_mc_debug()?

Jan

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
  2024-07-24  6:54   ` Jan Beulich
@ 2024-07-24  9:55     ` Jürgen Groß
  2025-03-27 14:13       ` Borislav Petkov
  0 siblings, 1 reply; 9+ messages in thread
From: Jürgen Groß @ 2024-07-24  9:55 UTC (permalink / raw)
  To: Jan Beulich; +Cc: oe-kbuild-all, xen-devel, Boris Ostrovsky, kernel test robot

On 24.07.24 08:54, Jan Beulich wrote:
> On 24.07.2024 08:07, Juergen Gross wrote:
>> On 24.07.24 03:08, kernel test robot wrote:
>>> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/xen/tip.git linux-next
>>> head:   368990a7fe30737c990f628a60d26d9854a9e690
>>> commit: 368990a7fe30737c990f628a60d26d9854a9e690 [12/12] xen: fix multicall debug data referencing
>>> config: x86_64-randconfig-012-20240724 (https://download.01.org/0day-ci/archive/20240724/202407240907.u0NJHgTu-lkp@intel.com/config)
>>> compiler: gcc-13 (Ubuntu 13.2.0-4ubuntu3) 13.2.0
>>> reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240724/202407240907.u0NJHgTu-lkp@intel.com/reproduce)
>>>
>>> If you fix the issue in a separate patch/commit (i.e. not just a new version of
>>> the same patch/commit), kindly add following tags
>>> | Reported-by: kernel test robot <lkp@intel.com>
>>> | Closes: https://lore.kernel.org/oe-kbuild-all/202407240907.u0NJHgTu-lkp@intel.com/
>>>
>>> All warnings (new ones prefixed by >>, old ones prefixed by <<):
>>>
>>>>> WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
>>
>> With current infrastructure this is not easily fixable, as there is no way
>> to tag a percpu variable as __refdata.
> 
> Would it be an option to drop the static initializer and set CPU0's value
> from xen_parse_mc_debug()?

It would hide this warning, yes.

OTOH I have another patch pending which will have the same problem, and this
time the solution would be more ugly, as the code would always be active in
a PV guest (yes, I could add an init function called very early during boot,
but ...).

I'd prefer a general way to handle this problem, like e.g. some kind of
__refdata tagging for percpu variables.


Juergen

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
  2024-07-24  9:55     ` Jürgen Groß
@ 2025-03-27 14:13       ` Borislav Petkov
  2025-03-27 14:21         ` Jürgen Groß
  0 siblings, 1 reply; 9+ messages in thread
From: Borislav Petkov @ 2025-03-27 14:13 UTC (permalink / raw)
  To: Jürgen Groß
  Cc: Jan Beulich, oe-kbuild-all, xen-devel, Boris Ostrovsky,
	kernel test robot, x86-ml, lkml

On Wed, Jul 24, 2024 at 11:55:39AM +0200, Jürgen Groß wrote:
> I'd prefer a general way to handle this problem, like e.g. some kind of
> __refdata tagging for percpu variables.

Any reason for not doing the trivial thing?

diff --git a/arch/x86/xen/multicalls.c b/arch/x86/xen/multicalls.c
index 10c660fae8b3..100bfaba3f4d 100644
--- a/arch/x86/xen/multicalls.c
+++ b/arch/x86/xen/multicalls.c
@@ -53,7 +53,7 @@ struct mc_debug_data {
 };
 
 static DEFINE_PER_CPU(struct mc_buffer, mc_buffer);
-static struct mc_debug_data mc_debug_data_early __initdata;
+static struct mc_debug_data mc_debug_data_early;
 static DEFINE_PER_CPU(struct mc_debug_data *, mc_debug_data) =
 	&mc_debug_data_early;
 static struct mc_debug_data __percpu *mc_debug_data_ptr;

---

since this breaks randbuilds:

WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
ERROR: modpost: Section mismatches detected.
Set CONFIG_SECTION_MISMATCH_WARN_ONLY=y to allow them.
make[2]: *** [scripts/Makefile.modpost:147: Module.symvers] Error 1
make[2]: *** Deleting file 'Module.symvers'
make[1]: *** [/mnt/kernel/kernel/linux/Makefile:1947: modpost] Error 2
make: *** [Makefile:251: __sub-make] Error 2

?

-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
  2025-03-27 14:13       ` Borislav Petkov
@ 2025-03-27 14:21         ` Jürgen Groß
  2025-03-27 14:40           ` Borislav Petkov
  0 siblings, 1 reply; 9+ messages in thread
From: Jürgen Groß @ 2025-03-27 14:21 UTC (permalink / raw)
  To: Borislav Petkov
  Cc: Jan Beulich, oe-kbuild-all, xen-devel, Boris Ostrovsky,
	kernel test robot, x86-ml, lkml


[-- Attachment #1.1.1: Type: text/plain, Size: 965 bytes --]

On 27.03.25 15:13, Borislav Petkov wrote:
> On Wed, Jul 24, 2024 at 11:55:39AM +0200, Jürgen Groß wrote:
>> I'd prefer a general way to handle this problem, like e.g. some kind of
>> __refdata tagging for percpu variables.
> 
> Any reason for not doing the trivial thing?
> 
> diff --git a/arch/x86/xen/multicalls.c b/arch/x86/xen/multicalls.c
> index 10c660fae8b3..100bfaba3f4d 100644
> --- a/arch/x86/xen/multicalls.c
> +++ b/arch/x86/xen/multicalls.c
> @@ -53,7 +53,7 @@ struct mc_debug_data {
>   };
>   
>   static DEFINE_PER_CPU(struct mc_buffer, mc_buffer);
> -static struct mc_debug_data mc_debug_data_early __initdata;
> +static struct mc_debug_data mc_debug_data_early;
>   static DEFINE_PER_CPU(struct mc_debug_data *, mc_debug_data) =
>   	&mc_debug_data_early;
>   static struct mc_debug_data __percpu *mc_debug_data_ptr;

Well, that is wasting nearly 3kB of the data section.

Maybe not a big deal, but still...


Juergen

[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 3743 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 495 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
  2025-03-27 14:21         ` Jürgen Groß
@ 2025-03-27 14:40           ` Borislav Petkov
  2025-03-27 15:15             ` Jürgen Groß
  0 siblings, 1 reply; 9+ messages in thread
From: Borislav Petkov @ 2025-03-27 14:40 UTC (permalink / raw)
  To: Jürgen Groß
  Cc: Jan Beulich, oe-kbuild-all, xen-devel, Boris Ostrovsky,
	kernel test robot, x86-ml, lkml

On Thu, Mar 27, 2025 at 03:21:45PM +0100, Jürgen Groß wrote:
> Well, that is wasting nearly 3kB of the data section.
> 
> Maybe not a big deal, but still...

We could do it until the proper fix is in place, no?

3K is meh, especially for the hypervisor kernel, I'd say...

-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
  2025-03-27 14:40           ` Borislav Petkov
@ 2025-03-27 15:15             ` Jürgen Groß
  2025-03-27 15:24               ` Borislav Petkov
  0 siblings, 1 reply; 9+ messages in thread
From: Jürgen Groß @ 2025-03-27 15:15 UTC (permalink / raw)
  To: Borislav Petkov
  Cc: Jan Beulich, oe-kbuild-all, xen-devel, Boris Ostrovsky,
	kernel test robot, x86-ml, lkml


[-- Attachment #1.1.1: Type: text/plain, Size: 825 bytes --]

On 27.03.25 15:40, Borislav Petkov wrote:
> On Thu, Mar 27, 2025 at 03:21:45PM +0100, Jürgen Groß wrote:
>> Well, that is wasting nearly 3kB of the data section.
>>
>> Maybe not a big deal, but still...
> 
> We could do it until the proper fix is in place, no?
> 
> 3K is meh, especially for the hypervisor kernel, I'd say...
> 

Yeah, that was my thinking.

Another approach could be to have:

-static DEFINE_PER_CPU(struct mc_debug_data *, mc_debug_data) =
-	&mc_debug_data_early;
+static DEFINE_PER_CPU(struct mc_debug_data *, mc_debug_data);

and to use an inline access function returning &mc_debug_data_early
if the percpu variable is NULL. This access function could be __ref.

It is a debug feature after all, so having a few additional instructions
isn't the end of the world.


Juergen

[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 3743 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 495 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data)
  2025-03-27 15:15             ` Jürgen Groß
@ 2025-03-27 15:24               ` Borislav Petkov
  0 siblings, 0 replies; 9+ messages in thread
From: Borislav Petkov @ 2025-03-27 15:24 UTC (permalink / raw)
  To: Jürgen Groß
  Cc: Jan Beulich, oe-kbuild-all, xen-devel, Boris Ostrovsky,
	kernel test robot, x86-ml, lkml

On Thu, Mar 27, 2025 at 04:15:11PM +0100, Jürgen Groß wrote:
> Another approach could be to have:
> 
> -static DEFINE_PER_CPU(struct mc_debug_data *, mc_debug_data) =
> -	&mc_debug_data_early;
> +static DEFINE_PER_CPU(struct mc_debug_data *, mc_debug_data);
> 
> and to use an inline access function returning &mc_debug_data_early
> if the percpu variable is NULL. This access function could be __ref.
> 
> It is a debug feature after all, so having a few additional instructions
> isn't the end of the world.

Yap, makes sense to me too.

Thx.

-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2025-03-27 15:25 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-24  1:08 [xen-tip:linux-next 12/12] WARNING: modpost: vmlinux: section mismatch in reference: mc_debug_data+0x0 (section: .data) -> mc_debug_data_early (section: .init.data) kernel test robot
2024-07-24  6:07 ` Juergen Gross
2024-07-24  6:54   ` Jan Beulich
2024-07-24  9:55     ` Jürgen Groß
2025-03-27 14:13       ` Borislav Petkov
2025-03-27 14:21         ` Jürgen Groß
2025-03-27 14:40           ` Borislav Petkov
2025-03-27 15:15             ` Jürgen Groß
2025-03-27 15:24               ` Borislav Petkov

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.