FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.

» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Crash Utility

LinkBack Thread Tools
Old 04-04-2010, 01:06 AM
Dave Anderson
Default Not working on 2.6.34-rc2-mm1

----- "Zhang Le" <r0bertz@gentoo.org> wrote:

> I got this on 2.6.34-rc2-mm1:
> crash: invalid structure member offset: pglist_data_bdata
> FILE: memory.c LINE: 12097 FUNCTION: dump_memory_nodes()
> [/usr/bin/crash] error trace: => 81356bc
> 81356bc: OFFSET_verify+140
> any pointers on how to fix this?
> Zhang, Le

Actually that particular issue was addressed in crash version 5.0.2
that was just released this week:

- Fix for initialization-time failure on 2.6.34 and later kernels that
were configured with CONFIG_NO_BOOTMEM. Without the patch, the crash
session fails with the error message "crash: invalid structure member
offset: pglist_data_bdata".

However, if 2.6.34-rc2-mm1 has this patch (and I presume that is since it's
in 2.6.34-rc3), then you're temporarily out of luck:


commit dd17c8f72993f9461e9c19250e3f155d6d99df22
Author: Rusty Russell <rusty@rustcorp.com.au>
Date: Thu Oct 29 22:34:15 2009 +0900

percpu: remove per_cpu__ prefix.

Now that the return from alloc_percpu is compatible with the address
of per-cpu vars, it makes sense to hand around the address of per-cpu
variables. To make this sane, we remove the per_cpu__ prefix we used
created to stop people accidentally using these vars directly.

Now we have sparse, we can use that (next patch).

tj: * Updated to convert stuff which were missed by or added after the
original patch.

* Kill per_cpu_var() macro.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Tejun Heo <tj@kernel.org>
Reviewed-by: Christoph Lameter <cl@linux-foundation.org>

diff --git a/include/linux/percpu-defs.h b/include/linux/percpu-defs.h
index 5a5d6ce..ee99f6c 100644
--- a/include/linux/percpu-defs.h
+++ b/include/linux/percpu-defs.h
@@ -2,12 +2,6 @@

- * Determine the real variable name from the name visible in the
- * kernel sources.
- */
-#define per_cpu_var(var) per_cpu__##var
* Base implementations of per-CPU variable declarations and definitions, where
* the section in which the variable is to be placed is provided by the
* 'sec' argument. This may be used to affect the parameters governing the
@@ -56,24 +50,24 @@
#define DECLARE_PER_CPU_SECTION(type, name, sec)
extern __PCPU_DUMMY_ATTRS char __pcpu_scope_##name;
- extern __PCPU_ATTRS(sec) __typeof__(type) per_cpu__##name
+ extern __PCPU_ATTRS(sec) __typeof__(type) name

#define DEFINE_PER_CPU_SECTION(type, name, sec)
__PCPU_DUMMY_ATTRS char __pcpu_scope_##name;
extern __PCPU_DUMMY_ATTRS char __pcpu_unique_##name;
__PCPU_DUMMY_ATTRS char __pcpu_unique_##name;
- __typeof__(type) per_cpu__##name
+ __typeof__(type) name
* Normal declaration and definition macros.
#define DECLARE_PER_CPU_SECTION(type, name, sec)
- extern __PCPU_ATTRS(sec) __typeof__(type) per_cpu__##name
+ extern __PCPU_ATTRS(sec) __typeof__(type) name

#define DEFINE_PER_CPU_SECTION(type, name, sec)
- __typeof__(type) per_cpu__##name
+ __typeof__(type) name

@@ -137,8 +131,8 @@
* Intermodule exports for per-CPU variables.
-#define EXPORT_PER_CPU_SYMBOL(var) EXPORT_SYMBOL(per_cpu__##var)
-#define EXPORT_PER_CPU_SYMBOL_GPL(var) EXPORT_SYMBOL_GPL(per_cpu__##var)

#endif /* _LINUX_PERCPU_DEFS_H */


That patch changes all "per_cpu__xxx" symbols to no longer have
the "per_cpu__" prefix -- which breaks quite a few things in the
crash utility, and it will not initialize.

I'm working on a fix for it, and will release a new version of
crash, hopefully this coming week.


Crash-utility mailing list

Thread Tools

All times are GMT. The time now is 10:07 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org