Skip to contentSkip to conversation

unexport phys_proc_id and cpu_core_id

PATCH In review Adrian Bunk 3 participants 5 messages May 6, 2005 – Jul 9, 2005

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 unexport phys_proc_id and cpu_core_id

Back in January, Andi Kleen added EXPORT_SYMBOL(phys_proc_id), stating:
This is needed for the powernow k8 driver to manage AMD dual core systems.

This EXPORT_SYMBOL was never used.

I asked him on 13 Mar 2005 whether it's really required, but he didn't answer to my email.

2.6.12-rc3 adds cpu_core_id with a similarly unused EXPORT_SYMBOL(cpu_core_id).

It's OK to export symbols when these exports are required, but unless someone can explain why they are required now, they should be removed before 2.6.12 and then re-added when they are actually used.

---

 arch/i386/kernel/smpboot.c   |    2 --
 arch/x86_64/kernel/smpboot.c |    2 --
 2 files changed, 4 deletions(-)
arch/i386/kernel/smpboot.c renamed from arch/i386/kernel/smpboot.c.old +0 -2
@@ -67,12 +67,10 @@
 /* Package ID of each logical CPU */
 int phys_proc_id[NR_CPUS] __cacheline_aligned_mostly_readonly =
 			{[0 ... NR_CPUS-1] = BAD_APICID};
-EXPORT_SYMBOL(phys_proc_id);
 
 /* Core ID of each logical CPU */
 int cpu_core_id[NR_CPUS] __cacheline_aligned_mostly_readonly =
 			{[0 ... NR_CPUS-1] = BAD_APICID};
-EXPORT_SYMBOL(cpu_core_id);
 
 cpumask_t cpu_sibling_map[NR_CPUS] __cacheline_aligned_mostly_readonly;
 cpumask_t cpu_core_map[NR_CPUS] __cacheline_aligned_mostly_readonly;
arch/x86_64/kernel/smpboot.c renamed from arch/x86_64/kernel/smpboot.c.old +0 -2
@@ -67,8 +67,6 @@
 /* Package ID of each logical CPU */
 u8 phys_proc_id[NR_CPUS] = { [0 ... NR_CPUS-1] = BAD_APICID };
 u8 cpu_core_id[NR_CPUS] = { [0 ... NR_CPUS-1] = BAD_APICID };
-EXPORT_SYMBOL(phys_proc_id);
-EXPORT_SYMBOL(cpu_core_id);
 
 /* Bitmask of currently online CPUs */
 cpumask_t cpu_online_map;
#1 lore raw
Quoted 8 lines · Adrian Bunk

Back in January, Andi Kleen added EXPORT_SYMBOL(phys_proc_id), stating:
This is needed for the powernow k8 driver to manage AMD dual core systems.

This EXPORT_SYMBOL was never used.

I asked him on 13 Mar 2005 whether it's really required, but he didn't answer to my email.

It is superceeded now with cpu_core_map[]/cpu_core_id[]

Quoted 7 lines

2.6.12-rc3 adds cpu_core_id with a similarly unused EXPORT_SYMBOL(cpu_core_id).

It's OK to export symbols when these exports are required, but unless someone can explain why they are required now, they should be removed before 2.6.12 and then re-added when they are actually used.

The dual powernowk8 driver really uses them, although the merging process seems to be a bit slow.

Andrew, please don't apply the patch.

-Andi

Quoted 36 lines

---

 arch/i386/kernel/smpboot.c   |    2 --
 arch/x86_64/kernel/smpboot.c |    2 --
 2 files changed, 4 deletions(-)
arch/i386/kernel/smpboot.c renamed from arch/i386/kernel/smpboot.c.old +0 -2
@@ -67,12 +67,10 @@
 /* Package ID of each logical CPU */
 int phys_proc_id[NR_CPUS] __cacheline_aligned_mostly_readonly =
 			{[0 ... NR_CPUS-1] = BAD_APICID};
-EXPORT_SYMBOL(phys_proc_id);
 
 /* Core ID of each logical CPU */
 int cpu_core_id[NR_CPUS] __cacheline_aligned_mostly_readonly =
 			{[0 ... NR_CPUS-1] = BAD_APICID};
-EXPORT_SYMBOL(cpu_core_id);
 
 cpumask_t cpu_sibling_map[NR_CPUS] __cacheline_aligned_mostly_readonly;
 cpumask_t cpu_core_map[NR_CPUS] __cacheline_aligned_mostly_readonly;
arch/x86_64/kernel/smpboot.c renamed from arch/x86_64/kernel/smpboot.c.old +0 -2
@@ -67,8 +67,6 @@
 /* Package ID of each logical CPU */
 u8 phys_proc_id[NR_CPUS] = { [0 ... NR_CPUS-1] = BAD_APICID };
 u8 cpu_core_id[NR_CPUS] = { [0 ... NR_CPUS-1] = BAD_APICID };
-EXPORT_SYMBOL(phys_proc_id);
-EXPORT_SYMBOL(cpu_core_id);
 
 /* Bitmask of currently online CPUs */
 cpumask_t cpu_online_map;
#2 lore raw
Quoted 15 lines · Andi Kleen
Quoted 8 lines · Adrian Bunk

Back in January, Andi Kleen added EXPORT_SYMBOL(phys_proc_id), stating:
This is needed for the powernow k8 driver to manage AMD dual core systems.

This EXPORT_SYMBOL was never used.

I asked him on 13 Mar 2005 whether it's really required, but he didn't answer to my email.

It is superceeded now with cpu_core_map[]/cpu_core_id[]

Quoted 4 lines

2.6.12-rc3 adds cpu_core_id with a similarly unused EXPORT_SYMBOL(cpu_core_id).

Quoted 8 lines
Quoted 3 lines

It's OK to export symbols when these exports are required, but unless someone can explain why they are required now, they should be removed before 2.6.12 and then re-added when they are actually used.

The dual powernowk8 driver really uses them, although the merging process seems to be a bit slow.

Andrew, please don't apply the patch.

Is there any time when you expect to submit the dual powernowk8 driver you've added the EXPORT_SYMBOL for five months ago?

I'd prefer if we'd not add EXPORT_SYMBOL's before the potential users are available...

Quoted 1 line

-Andi

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed
#3 lore raw
Quoted 23 lines · Adrian Bunk
Quoted 22 lines · Andi Kleen
Quoted 8 lines · Adrian Bunk

Back in January, Andi Kleen added EXPORT_SYMBOL(phys_proc_id), stating:
This is needed for the powernow k8 driver to manage AMD dual core systems.

This EXPORT_SYMBOL was never used.

I asked him on 13 Mar 2005 whether it's really required, but he didn't answer to my email.

It is superceeded now with cpu_core_map[]/cpu_core_id[]

Quoted 7 lines

2.6.12-rc3 adds cpu_core_id with a similarly unused EXPORT_SYMBOL(cpu_core_id).

It's OK to export symbols when these exports are required, but unless someone can explain why they are required now, they should be removed before 2.6.12 and then re-added when they are actually used.

The dual powernowk8 driver really uses them, although the merging process seems to be a bit slow.

Quoted 7 lines
Quoted 1 line

Andrew, please don't apply the patch.

Is there any time when you expect to submit the dual powernowk8 driver you've added the EXPORT_SYMBOL for five months ago?

I'd prefer if we'd not add EXPORT_SYMBOL's before the potential users are available...

powernow-k8 dual-core support got merged a few days ago.

Dave

#4 lore raw
Quoted 26 lines · Dave Jones
Quoted 25 lines · Adrian Bunk
Quoted 23 lines · Andi Kleen
Quoted 8 lines · Adrian Bunk

Back in January, Andi Kleen added EXPORT_SYMBOL(phys_proc_id), stating:
This is needed for the powernow k8 driver to manage AMD dual core systems.

This EXPORT_SYMBOL was never used.

I asked him on 13 Mar 2005 whether it's really required, but he didn't answer to my email.

It is superceeded now with cpu_core_map[]/cpu_core_id[]

Quoted 7 lines

2.6.12-rc3 adds cpu_core_id with a similarly unused EXPORT_SYMBOL(cpu_core_id).

It's OK to export symbols when these exports are required, but unless someone can explain why they are required now, they should be removed before 2.6.12 and then re-added when they are actually used.

The dual powernowk8 driver really uses them, although the merging process seems to be a bit slow.

Andrew, please don't apply the patch.

Quoted 7 lines
Quoted 5 lines

Is there any time when you expect to submit the dual powernowk8 driver you've added the EXPORT_SYMBOL for five months ago?

I'd prefer if we'd not add EXPORT_SYMBOL's before the potential users are available...

powernow-k8 dual-core support got merged a few days ago.

My patch to unexport these two variables wouldn't break it today...

Quoted 1 line

Dave

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed