Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ff741906 authored by Ashok Raj's avatar Ashok Raj Committed by Tony Luck
Browse files

[IA64] support for cpu0 removal



here is the BSP removal support for IA64. Its pretty much the same thing that
was released a while back, but has your feedback incorporated.

- Removed CONFIG_BSP_REMOVE_WORKAROUND and associated cmdline param
- Fixed compile issue with sn2/zx1 due to a undefined fix_b0_for_bsp
- some formatting nits (whitespace etc)

This has been tested on tiger and long back by alex on hp systems as well.

Signed-off-by: default avatarAshok Raj <ashok.raj@intel.com>
Signed-off-by: default avatarTony Luck <tony.luck@intel.com>
parent db9edfd7
Loading
Loading
Loading
Loading
+19 −0
Original line number Diff line number Diff line
@@ -272,6 +272,25 @@ config SCHED_SMT
	  Intel IA64 chips with MultiThreading at a cost of slightly increased
	  overhead in some places. If unsure say N here.

config PERMIT_BSP_REMOVE
	bool "Support removal of Bootstrap Processor"
	depends on HOTPLUG_CPU
	default n
	---help---
	Say Y here if your platform SAL will support removal of BSP with HOTPLUG_CPU
	support. 

config FORCE_CPEI_RETARGET
	bool "Force assumption that CPEI can be re-targetted"
	depends on PERMIT_BSP_REMOVE
	default n
	---help---
	Say Y if you need to force the assumption that CPEI can be re-targetted to
	any cpu in the system. This hint is available via ACPI 3.0 specifications.
	Tiger4 systems are capable of re-directing CPEI to any CPU other than BSP.
	This option it useful to enable this feature on older BIOS's as well.
	You can also enable this by using boot command line option force_cpei=1.

config PREEMPT
	bool "Preemptible Kernel"
        help
+2 −0
Original line number Diff line number Diff line
@@ -114,6 +114,8 @@ CONFIG_FORCE_MAX_ZONEORDER=17
CONFIG_SMP=y
CONFIG_NR_CPUS=4
CONFIG_HOTPLUG_CPU=y
CONFIG_PERMIT_BSP_REMOVE=y
CONFIG_FORCE_CPEI_RETARGET=y
# CONFIG_SCHED_SMT is not set
# CONFIG_PREEMPT is not set
CONFIG_SELECT_MEMORY_MODEL=y
+8 −4
Original line number Diff line number Diff line
@@ -287,15 +287,19 @@ acpi_parse_plat_int_src(acpi_table_entry_header * header,
unsigned int can_cpei_retarget(void)
{
	extern int cpe_vector;
	extern unsigned int force_cpei_retarget;

	/*
	 * Only if CPEI is supported and the override flag
	 * is present, otherwise return that its re-targettable
	 * if we are in polling mode.
	 */
	if (cpe_vector > 0 && !acpi_cpei_override)
		return 0;
	if (cpe_vector > 0) {
		if (acpi_cpei_override || force_cpei_retarget)
			return 1;
		else
			return 0;
	}
	return 1;
}

+6 −0
Original line number Diff line number Diff line
@@ -631,6 +631,7 @@ get_target_cpu (unsigned int gsi, int vector)
{
#ifdef CONFIG_SMP
	static int cpu = -1;
	extern int cpe_vector;

	/*
	 * In case of vector shared by multiple RTEs, all RTEs that
@@ -653,6 +654,11 @@ get_target_cpu (unsigned int gsi, int vector)
	if (!cpu_online(smp_processor_id()))
		return cpu_physical_id(smp_processor_id());

#ifdef CONFIG_ACPI
		if (cpe_vector > 0 && vector == IA64_CPEP_VECTOR)
			return get_cpei_target_cpu();
#endif

#ifdef CONFIG_NUMA
	{
		int num_cpus, cpu_index, iosapic_index, numa_cpu, i = 0;
+12 −1
Original line number Diff line number Diff line
@@ -163,8 +163,19 @@ void fixup_irqs(void)
{
	unsigned int irq;
	extern void ia64_process_pending_intr(void);
	extern void ia64_disable_timer(void);
	extern volatile int time_keeper_id;

	ia64_disable_timer();

	/*
	 * Find a new timesync master
	 */
	if (smp_processor_id() == time_keeper_id) {
		time_keeper_id = first_cpu(cpu_online_map);
		printk ("CPU %d is now promoted to time-keeper master\n", time_keeper_id);
	}

	ia64_set_itv(1<<16);
	/*
	 * Phase 1: Locate irq's bound to this cpu and
	 * relocate them for cpu removal.
Loading