Re: [PATCH 1/2] cpu-hotplug: export cpu_hotplug_enable/cpu_hotplug_disable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2015-05-19 14:15+0200, Vitaly Kuznetsov:
> Loaded Hyper-V module will use these functions to disable CPU hotplug
> under certain circumstances.
> 
> Signed-off-by: Vitaly Kuznetsov <vkuznets@xxxxxxxxxx>
> ---
>  kernel/cpu.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/kernel/cpu.c b/kernel/cpu.c
> index 94bbe46..dc005e7 100644
> --- a/kernel/cpu.c
> +++ b/kernel/cpu.c
> @@ -193,6 +193,7 @@ void cpu_hotplug_disable(void)
>  	cpu_hotplug_disabled = 1;

(I think it would be safer to make this into a counter, at least, so
  cpu_hotplug_disable() |
                        | cpu_hotplug_disable()
  cpu_hotplug_enable()  |
 wouldn't end up with enabled hotplug, when this switch is intended for
 hotplug-and-die situations.)

>  	cpu_maps_update_done();
>  }
> +EXPORT_SYMBOL_GPL(cpu_hotplug_disable);
>  
>  void cpu_hotplug_enable(void)
>  {
> @@ -200,7 +201,7 @@ void cpu_hotplug_enable(void)
>  	cpu_hotplug_disabled = 0;
>  	cpu_maps_update_done();
>  }
> -
> +EXPORT_SYMBOL_GPL(cpu_hotplug_enable);
>  #endif	/* CONFIG_HOTPLUG_CPU */
>  
>  /* Need to know about CPUs going up/down? */
> -- 
> 1.9.3
> 
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux