On Wed, 2007-10-31 at 13:45 -0700, Dave Hansen wrote: > On Wed, 2007-10-31 at 08:49 -0800, Badari Pulavarty wrote: > > +#ifdef CONFIG_MEMORY_HOTREMOVE > > +int remove_memory(u64 start, u64 size) > > +{ > > + unsigned long start_pfn, end_pfn; > > + unsigned long timeout = 120 * HZ; > > + int ret; > > + start_pfn = start >> PAGE_SHIFT; > > + end_pfn = start_pfn + (size >> PAGE_SHIFT); > > + ret = offline_pages(start_pfn, end_pfn, timeout); > > + return ret; > > +} > > +EXPORT_SYMBOL_GPL(remove_memory); > > +#endif /* CONFIG_MEMORY_HOTREMOVE */ > > Did someone go and copy the ia64 verion? Tsk. Tsk. Bad Badari. :) > > Can we just make this a weak symbol in the generic mm/memory_hotplug.c? > Or, make this the generic memory_remove() function int there and have an > arch_remove_memory() hook called from there if the architectures need to > tweak it?
BTW, we do have generic remove_memory() which returns -EINVAL, if CONFIG_HOTPLUG_MEMORY_REMOVE is not set to cover all the arch that doesn't support it. Thanks, Badari _______________________________________________ Linuxppc-dev mailing list Linuxppc-dev@ozlabs.org https://ozlabs.org/mailman/listinfo/linuxppc-dev