/* This could be made generic for all sysdev classes.  */
struct memory_block* find_memory_block(struct mem_section *section)
/* This could be made generic for all sysdev classes.  */
struct memory_block* find_memory_block(struct mem_section *section)
{
	struct kobject *kobj;
	struct sys_device *sysdev;
	struct memory_block *mem;
	char name[sizeof(MEMORY_CLASS_NAME) + 9 + 1];
	sprintf(&name[0], "%s%d", MEMORY_CLASS_NAME, __section_nr(section));
	kobj = kset_find_obj(&memory_sysdev_class.kset, name);
	if (!kobj)
		return NULL;
	sysdev = container_of(kobj, struct sys_device, kobj);
	mem = container_of(sysdev, struct memory_block, sysdev);
	return mem;
}