Re: [RFC PATCH]: ACPI: Automatically online hot-added memory

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

 



On Tue, Mar 09, 2010 at 09:12:03AM -0500, Prarit Bhargava wrote:
> New sockets have on-die memory controllers.  This means that in certain
> HW configurations the memory behind the socket comes and goes as the socket
> is physically enabled and disabled.
> 
> Since the cpu bringup code does on node memory allocations, the memory on the
> added socket must be onlined first.
> 
> Add a .config option to automatically online hot added memory, and enable it
> in the acpi memory add path.

This seems like the right thing to do.

> +config ACPI_HOTPLUG_MEMORY_AUTO_ONLINE
> +	bool "Automatically online hotplugged memory"
> +	depends on ACPI_HOTPLUG_MEMORY
> +	default n

default !S390? default x86?

> +		result = online_pages(info->start_addr >> PAGE_SHIFT,
> +				      info->length >> PAGE_SHIFT);
> +		if (!result)
> +			set_memory_state(info->start_addr, MEM_ONLINE);
> +		else
> +			printk("Memory online failed.\n");

That probably wants to be more descriptive and have a loglevel. What 
happens if this fails? The CPU presumably can't be brought up?

-- 
Matthew Garrett | mjg59@xxxxxxxxxxxxx
--
To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux