* Re: crash failure with 2.6.36-rc3 vmcore [not found] <837631540.119231283612666731.JavaMail.root@zmail06.collab.prod.int.phx2.redhat.com> @ 2010-09-04 15:07 ` caiqian 2010-09-04 17:55 ` Guenter Roeck 0 siblings, 1 reply; 9+ messages in thread From: caiqian @ 2010-09-04 15:07 UTC (permalink / raw) To: Guenter Roeck; +Cc: Dave Anderson, tj, gregkh, linux-kernel Sorry for the confusion. Here is some background. The test here was to use the crash utility to analyse a vmcore generated from kdump. This commit caused its subcommand mod -S failed to gather the module section data from the in-kernel data structure as it looks like it still depends on this field. I am not sure if that the crash utility just need to be adjusted to cope with this kernel change. >From http://people.redhat.com/anderson/crash_sources/symbols.c /* * Gather the module section data from the in-kernel data structures. */ static int add_symbol_file_kallsyms(struct load_module *lm, struct gnu_request *req) { int len, buflen, done, nsections, retval; ulong vaddr, array_entry, attribute, owner, name, address; long name_type; char buf[BUFSIZE]; char section_name[BUFSIZE]; ulong section_vaddr; if (!(st->flags & (MODSECT_V1|MODSECT_V2|MODSECT_V3|MODSECT_UNKNOWN))) { STRUCT_SIZE_INIT(module_sect_attr, "module_sect_attr"); MEMBER_OFFSET_INIT(module_sect_attrs, "module", "sect_attrs"); MEMBER_OFFSET_INIT(module_sect_attrs_attrs, "module_sect_attrs", "attrs"); MEMBER_OFFSET_INIT(module_sect_attrs_nsections, "module_sect_attrs", "nsections"); MEMBER_OFFSET_INIT(module_sect_attr_mattr, "module_sect_attr", "mattr"); MEMBER_OFFSET_INIT(module_sect_attr_name, "module_sect_attr", "name"); MEMBER_OFFSET_INIT(module_sect_attr_address, "module_sect_attr", "address"); MEMBER_OFFSET_INIT(module_attribute_attr, "module_attribute", "attr"); MEMBER_OFFSET_INIT(module_sect_attr_attr, "module_sect_attr", "attr"); MEMBER_OFFSET_INIT(module_sections_attrs, "module_sections", "attrs"); MEMBER_OFFSET_INIT(attribute_owner, "attribute", "owner"); ... owner = attribute + OFFSET(attribute_owner); ----- "Guenter Roeck" <guenter.roeck@ericsson.com> wrote: > Hi, > > On Sat, Sep 04, 2010 at 02:01:06AM -0400, CAI Qian wrote: > > > > > crash> mod -S > > > > > > mod: invalid structure member offset: attribute_owner > > > FILE: symbols.c LINE: 8577 FUNCTION: > add_symbol_file_kallsyms() > > > > > > MODULE NAME SIZE OBJECT FILE > > > ffffffffa000de60 dm_mod 76230 > > > > /lib/modules/2.6.36-rc2-mm1-wqfix-mkdfix+/kernel/drivers/md/dm-mod.ko > > > [/usr/bin/crash] error trace: 4affb0 => 4f3236 => 4f12b5 => > 4e587a > > > > > > 4e587a: OFFSET_verify.clone.4+186 > > > 4f12b5: add_symbol_file+933 > > > 4f3236: load_module_symbols+566 > > > 4affb0: do_module_cmd+1264 > > > > > > mod: invalid structure member offset: attribute_owner > > > FILE: symbols.c LINE: 8577 FUNCTION: > add_symbol_file_kallsyms() > > What do I have to do to reproduce this crash ? > > Was the module in question compiled w/ the kernel, or separately ? > Did it use the correct kernel header files for compilation ? > Was the kernel version -rc3, or some other patched version ? > > Just wondering, since the above message says > 2.6.36-rc2-mm1-wqfix-mkdfix+, > which seems to indicate that it included some modifications. > > Thanks, > Guenter > > > This failure was due to this commit, > > > > commit 6fd69dc578fa0b1bbc3aad70ae3af9a137211707 > > Author: Guenter Roeck <guenter.roeck@ericsson.com> > > Date: Wed Jul 28 22:09:26 2010 -0700 > > > > sysfs: Remove owner field from sysfs struct attribute > > > > Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com> > > Acked-by: Tejun Heo <tj@kernel.org> > > Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> > > > > diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h > > index 8bf06b6..3c92121 100644 > > --- a/include/linux/sysfs.h > > +++ b/include/linux/sysfs.h > > @@ -22,14 +22,8 @@ struct kobject; > > struct module; > > enum kobj_ns_type; > > > > -/* FIXME > > - * The *owner field is no longer used. > > - * x86 tree has been cleaned up. The owner > > - * attribute is still left for other arches. > > - */ > > struct attribute { > > const char *name; > > - struct module *owner; > > mode_t mode; > > #ifdef CONFIG_DEBUG_LOCK_ALLOC > > struct lock_class_key *key; ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: crash failure with 2.6.36-rc3 vmcore 2010-09-04 15:07 ` crash failure with 2.6.36-rc3 vmcore caiqian @ 2010-09-04 17:55 ` Guenter Roeck 2010-09-05 3:17 ` CAI Qian 0 siblings, 1 reply; 9+ messages in thread From: Guenter Roeck @ 2010-09-04 17:55 UTC (permalink / raw) To: caiqian@redhat.com Cc: Dave Anderson, tj@kernel.org, gregkh@suse.de, linux-kernel On Sat, Sep 04, 2010 at 11:07:43AM -0400, caiqian@redhat.com wrote: > Sorry for the confusion. Here is some background. The test here was to use the crash utility to analyse a vmcore generated from kdump. This commit caused its subcommand mod -S failed to gather the module section data from the in-kernel data structure as it looks like it still depends on this field. I am not sure if that the crash utility just need to be adjusted to cope with this kernel change. > That would be the proper fix. Question is what version of the crash utility you are using. The one included in my distribution (reporting to be version 4.1.0) doesn't include the code below. Thanks, Guenter > From http://people.redhat.com/anderson/crash_sources/symbols.c > /* > * Gather the module section data from the in-kernel data structures. > */ > static int > add_symbol_file_kallsyms(struct load_module *lm, struct gnu_request *req) > { > int len, buflen, done, nsections, retval; > ulong vaddr, array_entry, attribute, owner, name, address; > long name_type; > char buf[BUFSIZE]; > char section_name[BUFSIZE]; > ulong section_vaddr; > > if (!(st->flags & (MODSECT_V1|MODSECT_V2|MODSECT_V3|MODSECT_UNKNOWN))) { > STRUCT_SIZE_INIT(module_sect_attr, "module_sect_attr"); > MEMBER_OFFSET_INIT(module_sect_attrs, > "module", "sect_attrs"); > MEMBER_OFFSET_INIT(module_sect_attrs_attrs, > "module_sect_attrs", "attrs"); > MEMBER_OFFSET_INIT(module_sect_attrs_nsections, > "module_sect_attrs", "nsections"); > MEMBER_OFFSET_INIT(module_sect_attr_mattr, > "module_sect_attr", "mattr"); > MEMBER_OFFSET_INIT(module_sect_attr_name, > "module_sect_attr", "name"); > MEMBER_OFFSET_INIT(module_sect_attr_address, > "module_sect_attr", "address"); > MEMBER_OFFSET_INIT(module_attribute_attr, > "module_attribute", "attr"); > MEMBER_OFFSET_INIT(module_sect_attr_attr, > "module_sect_attr", "attr"); > MEMBER_OFFSET_INIT(module_sections_attrs, > "module_sections", "attrs"); > MEMBER_OFFSET_INIT(attribute_owner, > "attribute", "owner"); > ... > owner = attribute + OFFSET(attribute_owner); > > > ----- "Guenter Roeck" <guenter.roeck@ericsson.com> wrote: > > > Hi, > > > > On Sat, Sep 04, 2010 at 02:01:06AM -0400, CAI Qian wrote: > > > > > > > crash> mod -S > > > > > > > > mod: invalid structure member offset: attribute_owner > > > > FILE: symbols.c LINE: 8577 FUNCTION: > > add_symbol_file_kallsyms() > > > > > > > > MODULE NAME SIZE OBJECT FILE > > > > ffffffffa000de60 dm_mod 76230 > > > > > > /lib/modules/2.6.36-rc2-mm1-wqfix-mkdfix+/kernel/drivers/md/dm-mod.ko > > > > [/usr/bin/crash] error trace: 4affb0 => 4f3236 => 4f12b5 => > > 4e587a > > > > > > > > 4e587a: OFFSET_verify.clone.4+186 > > > > 4f12b5: add_symbol_file+933 > > > > 4f3236: load_module_symbols+566 > > > > 4affb0: do_module_cmd+1264 > > > > > > > > mod: invalid structure member offset: attribute_owner > > > > FILE: symbols.c LINE: 8577 FUNCTION: > > add_symbol_file_kallsyms() > > > > What do I have to do to reproduce this crash ? > > > > Was the module in question compiled w/ the kernel, or separately ? > > Did it use the correct kernel header files for compilation ? > > Was the kernel version -rc3, or some other patched version ? > > > > Just wondering, since the above message says > > 2.6.36-rc2-mm1-wqfix-mkdfix+, > > which seems to indicate that it included some modifications. > > > > Thanks, > > Guenter > > > > > This failure was due to this commit, > > > > > > commit 6fd69dc578fa0b1bbc3aad70ae3af9a137211707 > > > Author: Guenter Roeck <guenter.roeck@ericsson.com> > > > Date: Wed Jul 28 22:09:26 2010 -0700 > > > > > > sysfs: Remove owner field from sysfs struct attribute > > > > > > Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com> > > > Acked-by: Tejun Heo <tj@kernel.org> > > > Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> > > > > > > diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h > > > index 8bf06b6..3c92121 100644 > > > --- a/include/linux/sysfs.h > > > +++ b/include/linux/sysfs.h > > > @@ -22,14 +22,8 @@ struct kobject; > > > struct module; > > > enum kobj_ns_type; > > > > > > -/* FIXME > > > - * The *owner field is no longer used. > > > - * x86 tree has been cleaned up. The owner > > > - * attribute is still left for other arches. > > > - */ > > > struct attribute { > > > const char *name; > > > - struct module *owner; > > > mode_t mode; > > > #ifdef CONFIG_DEBUG_LOCK_ALLOC > > > struct lock_class_key *key; ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: crash failure with 2.6.36-rc3 vmcore 2010-09-04 17:55 ` Guenter Roeck @ 2010-09-05 3:17 ` CAI Qian 2010-09-05 5:06 ` Guenter Roeck 0 siblings, 1 reply; 9+ messages in thread From: CAI Qian @ 2010-09-05 3:17 UTC (permalink / raw) To: Guenter Roeck; +Cc: Dave Anderson, tj, gregkh, linux-kernel ----- "Guenter Roeck" <guenter.roeck@ericsson.com> wrote: > On Sat, Sep 04, 2010 at 11:07:43AM -0400, caiqian@redhat.com wrote: > > Sorry for the confusion. Here is some background. The test here was > to use the crash utility to analyse a vmcore generated from kdump. > This commit caused its subcommand mod -S failed to gather the module > section data from the in-kernel data structure as it looks like it > still depends on this field. I am not sure if that the crash utility > just need to be adjusted to cope with this kernel change. > > > That would be the proper fix. > > Question is what version of the crash utility you are using. > The one included in my distribution (reporting to be version 4.1.0) > doesn't include the code below. The latest upstream version 5.0.7, and can be found here, http://people.redhat.com/anderson/ > > Thanks, > Guenter > > > From http://people.redhat.com/anderson/crash_sources/symbols.c > > /* > > * Gather the module section data from the in-kernel data > structures. > > */ > > static int > > add_symbol_file_kallsyms(struct load_module *lm, struct gnu_request > *req) > > { > > int len, buflen, done, nsections, retval; > > ulong vaddr, array_entry, attribute, owner, name, address; > > long name_type; > > char buf[BUFSIZE]; > > char section_name[BUFSIZE]; > > ulong section_vaddr; > > > > if (!(st->flags & > (MODSECT_V1|MODSECT_V2|MODSECT_V3|MODSECT_UNKNOWN))) { > > STRUCT_SIZE_INIT(module_sect_attr, > "module_sect_attr"); > > MEMBER_OFFSET_INIT(module_sect_attrs, > > "module", "sect_attrs"); > > MEMBER_OFFSET_INIT(module_sect_attrs_attrs, > > "module_sect_attrs", "attrs"); > > MEMBER_OFFSET_INIT(module_sect_attrs_nsections, > > "module_sect_attrs", "nsections"); > > MEMBER_OFFSET_INIT(module_sect_attr_mattr, > > "module_sect_attr", "mattr"); > > MEMBER_OFFSET_INIT(module_sect_attr_name, > > "module_sect_attr", "name"); > > MEMBER_OFFSET_INIT(module_sect_attr_address, > > "module_sect_attr", "address"); > > MEMBER_OFFSET_INIT(module_attribute_attr, > > "module_attribute", "attr"); > > MEMBER_OFFSET_INIT(module_sect_attr_attr, > > "module_sect_attr", "attr"); > > MEMBER_OFFSET_INIT(module_sections_attrs, > > "module_sections", "attrs"); > > MEMBER_OFFSET_INIT(attribute_owner, > > "attribute", "owner"); > > ... > > owner = attribute + OFFSET(attribute_owner); > > > > > > ----- "Guenter Roeck" <guenter.roeck@ericsson.com> wrote: > > > > > Hi, > > > > > > On Sat, Sep 04, 2010 at 02:01:06AM -0400, CAI Qian wrote: > > > > > > > > > crash> mod -S > > > > > > > > > > mod: invalid structure member offset: attribute_owner > > > > > FILE: symbols.c LINE: 8577 FUNCTION: > > > add_symbol_file_kallsyms() > > > > > > > > > > MODULE NAME SIZE OBJECT FILE > > > > > ffffffffa000de60 dm_mod 76230 > > > > > > > > > /lib/modules/2.6.36-rc2-mm1-wqfix-mkdfix+/kernel/drivers/md/dm-mod.ko > > > > > [/usr/bin/crash] error trace: 4affb0 => 4f3236 => 4f12b5 => > > > 4e587a > > > > > > > > > > 4e587a: OFFSET_verify.clone.4+186 > > > > > 4f12b5: add_symbol_file+933 > > > > > 4f3236: load_module_symbols+566 > > > > > 4affb0: do_module_cmd+1264 > > > > > > > > > > mod: invalid structure member offset: attribute_owner > > > > > FILE: symbols.c LINE: 8577 FUNCTION: > > > add_symbol_file_kallsyms() > > > > > > What do I have to do to reproduce this crash ? > > > > > > Was the module in question compiled w/ the kernel, or separately > ? > > > Did it use the correct kernel header files for compilation ? > > > Was the kernel version -rc3, or some other patched version ? > > > > > > Just wondering, since the above message says > > > 2.6.36-rc2-mm1-wqfix-mkdfix+, > > > which seems to indicate that it included some modifications. > > > > > > Thanks, > > > Guenter > > > > > > > This failure was due to this commit, > > > > > > > > commit 6fd69dc578fa0b1bbc3aad70ae3af9a137211707 > > > > Author: Guenter Roeck <guenter.roeck@ericsson.com> > > > > Date: Wed Jul 28 22:09:26 2010 -0700 > > > > > > > > sysfs: Remove owner field from sysfs struct attribute > > > > > > > > Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com> > > > > Acked-by: Tejun Heo <tj@kernel.org> > > > > Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> > > > > > > > > diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h > > > > index 8bf06b6..3c92121 100644 > > > > --- a/include/linux/sysfs.h > > > > +++ b/include/linux/sysfs.h > > > > @@ -22,14 +22,8 @@ struct kobject; > > > > struct module; > > > > enum kobj_ns_type; > > > > > > > > -/* FIXME > > > > - * The *owner field is no longer used. > > > > - * x86 tree has been cleaned up. The owner > > > > - * attribute is still left for other arches. > > > > - */ > > > > struct attribute { > > > > const char *name; > > > > - struct module *owner; > > > > mode_t mode; > > > > #ifdef CONFIG_DEBUG_LOCK_ALLOC > > > > struct lock_class_key *key; ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: crash failure with 2.6.36-rc3 vmcore 2010-09-05 3:17 ` CAI Qian @ 2010-09-05 5:06 ` Guenter Roeck 2010-09-05 6:22 ` Greg KH 0 siblings, 1 reply; 9+ messages in thread From: Guenter Roeck @ 2010-09-05 5:06 UTC (permalink / raw) To: CAI Qian; +Cc: Dave Anderson, tj@kernel.org, gregkh@suse.de, linux-kernel On Sat, Sep 04, 2010 at 11:17:34PM -0400, CAI Qian wrote: > > ----- "Guenter Roeck" <guenter.roeck@ericsson.com> wrote: > > > On Sat, Sep 04, 2010 at 11:07:43AM -0400, caiqian@redhat.com wrote: > > > Sorry for the confusion. Here is some background. The test here was > > to use the crash utility to analyse a vmcore generated from kdump. > > This commit caused its subcommand mod -S failed to gather the module > > section data from the in-kernel data structure as it looks like it > > still depends on this field. I am not sure if that the crash utility > > just need to be adjusted to cope with this kernel change. > > > > > That would be the proper fix. > > > > Question is what version of the crash utility you are using. > > The one included in my distribution (reporting to be version 4.1.0) > > doesn't include the code below. > The latest upstream version 5.0.7, and can be found here, > http://people.redhat.com/anderson/ I browsed through the code a bit. Looks like the module owner will need to make the necessary changes. The code now seems to depend on kernel internal structure elements. Not sure if that is a good idea in the first place. At least for the attribute owner it will have to be changed to not depend on its existence. Of course, one could also argue that the field should be re-introduced in the kernel to make the utility work w/o changes. However, I don't think it would be a good idea to hold the kernel hostage for such problems. Thanks, Guenter > > > > Thanks, > > Guenter > > > > > From http://people.redhat.com/anderson/crash_sources/symbols.c > > > /* > > > * Gather the module section data from the in-kernel data > > structures. > > > */ > > > static int > > > add_symbol_file_kallsyms(struct load_module *lm, struct gnu_request > > *req) > > > { > > > int len, buflen, done, nsections, retval; > > > ulong vaddr, array_entry, attribute, owner, name, address; > > > long name_type; > > > char buf[BUFSIZE]; > > > char section_name[BUFSIZE]; > > > ulong section_vaddr; > > > > > > if (!(st->flags & > > (MODSECT_V1|MODSECT_V2|MODSECT_V3|MODSECT_UNKNOWN))) { > > > STRUCT_SIZE_INIT(module_sect_attr, > > "module_sect_attr"); > > > MEMBER_OFFSET_INIT(module_sect_attrs, > > > "module", "sect_attrs"); > > > MEMBER_OFFSET_INIT(module_sect_attrs_attrs, > > > "module_sect_attrs", "attrs"); > > > MEMBER_OFFSET_INIT(module_sect_attrs_nsections, > > > "module_sect_attrs", "nsections"); > > > MEMBER_OFFSET_INIT(module_sect_attr_mattr, > > > "module_sect_attr", "mattr"); > > > MEMBER_OFFSET_INIT(module_sect_attr_name, > > > "module_sect_attr", "name"); > > > MEMBER_OFFSET_INIT(module_sect_attr_address, > > > "module_sect_attr", "address"); > > > MEMBER_OFFSET_INIT(module_attribute_attr, > > > "module_attribute", "attr"); > > > MEMBER_OFFSET_INIT(module_sect_attr_attr, > > > "module_sect_attr", "attr"); > > > MEMBER_OFFSET_INIT(module_sections_attrs, > > > "module_sections", "attrs"); > > > MEMBER_OFFSET_INIT(attribute_owner, > > > "attribute", "owner"); > > > ... > > > owner = attribute + OFFSET(attribute_owner); > > > > > > > > > ----- "Guenter Roeck" <guenter.roeck@ericsson.com> wrote: > > > > > > > Hi, > > > > > > > > On Sat, Sep 04, 2010 at 02:01:06AM -0400, CAI Qian wrote: > > > > > > > > > > > crash> mod -S > > > > > > > > > > > > mod: invalid structure member offset: attribute_owner > > > > > > FILE: symbols.c LINE: 8577 FUNCTION: > > > > add_symbol_file_kallsyms() > > > > > > > > > > > > MODULE NAME SIZE OBJECT FILE > > > > > > ffffffffa000de60 dm_mod 76230 > > > > > > > > > > > > /lib/modules/2.6.36-rc2-mm1-wqfix-mkdfix+/kernel/drivers/md/dm-mod.ko > > > > > > [/usr/bin/crash] error trace: 4affb0 => 4f3236 => 4f12b5 => > > > > 4e587a > > > > > > > > > > > > 4e587a: OFFSET_verify.clone.4+186 > > > > > > 4f12b5: add_symbol_file+933 > > > > > > 4f3236: load_module_symbols+566 > > > > > > 4affb0: do_module_cmd+1264 > > > > > > > > > > > > mod: invalid structure member offset: attribute_owner > > > > > > FILE: symbols.c LINE: 8577 FUNCTION: > > > > add_symbol_file_kallsyms() > > > > > > > > What do I have to do to reproduce this crash ? > > > > > > > > Was the module in question compiled w/ the kernel, or separately > > ? > > > > Did it use the correct kernel header files for compilation ? > > > > Was the kernel version -rc3, or some other patched version ? > > > > > > > > Just wondering, since the above message says > > > > 2.6.36-rc2-mm1-wqfix-mkdfix+, > > > > which seems to indicate that it included some modifications. > > > > > > > > Thanks, > > > > Guenter > > > > > > > > > This failure was due to this commit, > > > > > > > > > > commit 6fd69dc578fa0b1bbc3aad70ae3af9a137211707 > > > > > Author: Guenter Roeck <guenter.roeck@ericsson.com> > > > > > Date: Wed Jul 28 22:09:26 2010 -0700 > > > > > > > > > > sysfs: Remove owner field from sysfs struct attribute > > > > > > > > > > Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com> > > > > > Acked-by: Tejun Heo <tj@kernel.org> > > > > > Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> > > > > > > > > > > diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h > > > > > index 8bf06b6..3c92121 100644 > > > > > --- a/include/linux/sysfs.h > > > > > +++ b/include/linux/sysfs.h > > > > > @@ -22,14 +22,8 @@ struct kobject; > > > > > struct module; > > > > > enum kobj_ns_type; > > > > > > > > > > -/* FIXME > > > > > - * The *owner field is no longer used. > > > > > - * x86 tree has been cleaned up. The owner > > > > > - * attribute is still left for other arches. > > > > > - */ > > > > > struct attribute { > > > > > const char *name; > > > > > - struct module *owner; > > > > > mode_t mode; > > > > > #ifdef CONFIG_DEBUG_LOCK_ALLOC > > > > > struct lock_class_key *key; ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: crash failure with 2.6.36-rc3 vmcore 2010-09-05 5:06 ` Guenter Roeck @ 2010-09-05 6:22 ` Greg KH 0 siblings, 0 replies; 9+ messages in thread From: Greg KH @ 2010-09-05 6:22 UTC (permalink / raw) To: Guenter Roeck; +Cc: CAI Qian, Dave Anderson, tj@kernel.org, linux-kernel On Sat, Sep 04, 2010 at 10:06:25PM -0700, Guenter Roeck wrote: > I browsed through the code a bit. Looks like the module owner will need to make > the necessary changes. The code now seems to depend on kernel internal structure > elements. Not sure if that is a good idea in the first place. At least for > the attribute owner it will have to be changed to not depend on its existence. > > Of course, one could also argue that the field should be re-introduced in > the kernel to make the utility work w/o changes. However, I don't think it > would be a good idea to hold the kernel hostage for such problems. You're kidding, right? You should have tools flexable to handle the fact that the internal kernel structures change all the time like this. If not, your tools are broken. good luck, greg k-h ^ permalink raw reply [flat|nested] 9+ messages in thread
[parent not found: <471005677.1486991283866304732.JavaMail.root@zmail05.collab.prod.int.phx2.redhat.com>]
* Re: crash failure with 2.6.36-rc3 vmcore [not found] <471005677.1486991283866304732.JavaMail.root@zmail05.collab.prod.int.phx2.redhat.com> @ 2010-09-07 13:35 ` Dave Anderson 0 siblings, 0 replies; 9+ messages in thread From: Dave Anderson @ 2010-09-07 13:35 UTC (permalink / raw) To: Greg KH; +Cc: CAI Qian, tj, linux-kernel, Guenter Roeck ----- "Greg KH" <gregkh@suse.de> wrote: > On Sat, Sep 04, 2010 at 10:06:25PM -0700, Guenter Roeck wrote: > > I browsed through the code a bit. Looks like the module owner will need to make > > the necessary changes. The code now seems to depend on kernel internal structure > > elements. Not sure if that is a good idea in the first place. At least for > > the attribute owner it will have to be changed to not depend on its existence. > > > > Of course, one could also argue that the field should be re-introduced in > > the kernel to make the utility work w/o changes. However, I don't think it > > would be a good idea to hold the kernel hostage for such problems. > > You're kidding, right? You should have tools flexable to handle the > fact that the internal kernel structures change all the time like > this. If not, your tools are broken. Greg, You are exactly right -- I am the owner/maintainer of the crash utility, and kernel changes such as this require changes to the tool all the time. This whole thread should never have been brought up on this list, but I've been away for a few days, and was unable to nip it in the bud. It should have been restricted to the crash-utility@redhat.com mailing list. Sorry for all the noise... Dave Anderson ^ permalink raw reply [flat|nested] 9+ messages in thread
[parent not found: <856089343.1931201283439399228.JavaMail.root@zmail06.collab.prod.int.phx2.redhat.com>]
* crash failure with 2.6.36-rc3 vmcore [not found] <856089343.1931201283439399228.JavaMail.root@zmail06.collab.prod.int.phx2.redhat.com> @ 2010-09-04 6:01 ` CAI Qian 2010-09-04 14:20 ` Greg KH 2010-09-04 14:43 ` Guenter Roeck 0 siblings, 2 replies; 9+ messages in thread From: CAI Qian @ 2010-09-04 6:01 UTC (permalink / raw) To: Dave Anderson, guenter.roeck, tj, gregkh; +Cc: linux-kernel > crash> mod -S > > mod: invalid structure member offset: attribute_owner > FILE: symbols.c LINE: 8577 FUNCTION: add_symbol_file_kallsyms() > > MODULE NAME SIZE OBJECT FILE > ffffffffa000de60 dm_mod 76230 > /lib/modules/2.6.36-rc2-mm1-wqfix-mkdfix+/kernel/drivers/md/dm-mod.ko > [/usr/bin/crash] error trace: 4affb0 => 4f3236 => 4f12b5 => 4e587a > > 4e587a: OFFSET_verify.clone.4+186 > 4f12b5: add_symbol_file+933 > 4f3236: load_module_symbols+566 > 4affb0: do_module_cmd+1264 > > mod: invalid structure member offset: attribute_owner > FILE: symbols.c LINE: 8577 FUNCTION: add_symbol_file_kallsyms() This failure was due to this commit, commit 6fd69dc578fa0b1bbc3aad70ae3af9a137211707 Author: Guenter Roeck <guenter.roeck@ericsson.com> Date: Wed Jul 28 22:09:26 2010 -0700 sysfs: Remove owner field from sysfs struct attribute Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com> Acked-by: Tejun Heo <tj@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h index 8bf06b6..3c92121 100644 --- a/include/linux/sysfs.h +++ b/include/linux/sysfs.h @@ -22,14 +22,8 @@ struct kobject; struct module; enum kobj_ns_type; -/* FIXME - * The *owner field is no longer used. - * x86 tree has been cleaned up. The owner - * attribute is still left for other arches. - */ struct attribute { const char *name; - struct module *owner; mode_t mode; #ifdef CONFIG_DEBUG_LOCK_ALLOC struct lock_class_key *key; ^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: crash failure with 2.6.36-rc3 vmcore 2010-09-04 6:01 ` CAI Qian @ 2010-09-04 14:20 ` Greg KH 2010-09-04 14:43 ` Guenter Roeck 1 sibling, 0 replies; 9+ messages in thread From: Greg KH @ 2010-09-04 14:20 UTC (permalink / raw) To: CAI Qian; +Cc: Dave Anderson, guenter.roeck, tj, linux-kernel On Sat, Sep 04, 2010 at 02:01:06AM -0400, CAI Qian wrote: > > > crash> mod -S > > > > mod: invalid structure member offset: attribute_owner > > FILE: symbols.c LINE: 8577 FUNCTION: add_symbol_file_kallsyms() > > > > MODULE NAME SIZE OBJECT FILE > > ffffffffa000de60 dm_mod 76230 > > /lib/modules/2.6.36-rc2-mm1-wqfix-mkdfix+/kernel/drivers/md/dm-mod.ko > > [/usr/bin/crash] error trace: 4affb0 => 4f3236 => 4f12b5 => 4e587a > > > > 4e587a: OFFSET_verify.clone.4+186 > > 4f12b5: add_symbol_file+933 > > 4f3236: load_module_symbols+566 > > 4affb0: do_module_cmd+1264 > > > > mod: invalid structure member offset: attribute_owner > > FILE: symbols.c LINE: 8577 FUNCTION: add_symbol_file_kallsyms() > This failure was due to this commit, > > commit 6fd69dc578fa0b1bbc3aad70ae3af9a137211707 <snip> I don't understand, is this patch causing a problem, or did you forget to rebuild your code? confused, greg k-h ^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: crash failure with 2.6.36-rc3 vmcore 2010-09-04 6:01 ` CAI Qian 2010-09-04 14:20 ` Greg KH @ 2010-09-04 14:43 ` Guenter Roeck 1 sibling, 0 replies; 9+ messages in thread From: Guenter Roeck @ 2010-09-04 14:43 UTC (permalink / raw) To: CAI Qian; +Cc: Dave Anderson, tj@kernel.org, gregkh@suse.de, linux-kernel Hi, On Sat, Sep 04, 2010 at 02:01:06AM -0400, CAI Qian wrote: > > > crash> mod -S > > > > mod: invalid structure member offset: attribute_owner > > FILE: symbols.c LINE: 8577 FUNCTION: add_symbol_file_kallsyms() > > > > MODULE NAME SIZE OBJECT FILE > > ffffffffa000de60 dm_mod 76230 > > /lib/modules/2.6.36-rc2-mm1-wqfix-mkdfix+/kernel/drivers/md/dm-mod.ko > > [/usr/bin/crash] error trace: 4affb0 => 4f3236 => 4f12b5 => 4e587a > > > > 4e587a: OFFSET_verify.clone.4+186 > > 4f12b5: add_symbol_file+933 > > 4f3236: load_module_symbols+566 > > 4affb0: do_module_cmd+1264 > > > > mod: invalid structure member offset: attribute_owner > > FILE: symbols.c LINE: 8577 FUNCTION: add_symbol_file_kallsyms() What do I have to do to reproduce this crash ? Was the module in question compiled w/ the kernel, or separately ? Did it use the correct kernel header files for compilation ? Was the kernel version -rc3, or some other patched version ? Just wondering, since the above message says 2.6.36-rc2-mm1-wqfix-mkdfix+, which seems to indicate that it included some modifications. Thanks, Guenter > This failure was due to this commit, > > commit 6fd69dc578fa0b1bbc3aad70ae3af9a137211707 > Author: Guenter Roeck <guenter.roeck@ericsson.com> > Date: Wed Jul 28 22:09:26 2010 -0700 > > sysfs: Remove owner field from sysfs struct attribute > > Signed-off-by: Guenter Roeck <guenter.roeck@ericsson.com> > Acked-by: Tejun Heo <tj@kernel.org> > Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> > > diff --git a/include/linux/sysfs.h b/include/linux/sysfs.h > index 8bf06b6..3c92121 100644 > --- a/include/linux/sysfs.h > +++ b/include/linux/sysfs.h > @@ -22,14 +22,8 @@ struct kobject; > struct module; > enum kobj_ns_type; > > -/* FIXME > - * The *owner field is no longer used. > - * x86 tree has been cleaned up. The owner > - * attribute is still left for other arches. > - */ > struct attribute { > const char *name; > - struct module *owner; > mode_t mode; > #ifdef CONFIG_DEBUG_LOCK_ALLOC > struct lock_class_key *key; ^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2010-09-07 13:36 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <837631540.119231283612666731.JavaMail.root@zmail06.collab.prod.int.phx2.redhat.com>
2010-09-04 15:07 ` crash failure with 2.6.36-rc3 vmcore caiqian
2010-09-04 17:55 ` Guenter Roeck
2010-09-05 3:17 ` CAI Qian
2010-09-05 5:06 ` Guenter Roeck
2010-09-05 6:22 ` Greg KH
[not found] <471005677.1486991283866304732.JavaMail.root@zmail05.collab.prod.int.phx2.redhat.com>
2010-09-07 13:35 ` Dave Anderson
[not found] <856089343.1931201283439399228.JavaMail.root@zmail06.collab.prod.int.phx2.redhat.com>
2010-09-04 6:01 ` CAI Qian
2010-09-04 14:20 ` Greg KH
2010-09-04 14:43 ` Guenter Roeck
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox