[Crash-utility] [PATCH] Make 'irq -d' work on x86 kernel 3.11-rc

Dave Anderson anderson at redhat.com
Thu Aug 22 20:35:11 UTC 2013



----- Original Message -----
> Hi
> 
> On Thu, Aug 22, 2013 at 12:32 PM, Dave Anderson <anderson at redhat.com> wrote:
> >
> >
> > ----- Original Message -----
> >> Hi
> >>
> >> On Thu, Aug 22, 2013 at 8:44 AM, Anatol Pomozov
> >> <anatol.pomozov at gmail.com> wrote:
> >> > The scructure was renamed from gate_struct to gate_desc in 2.6.25 kernel
> >> >
> >> > Tested: works on 3.11 dump
> >> > ---
> >> >  x86_64.c | 7 ++++++-
> >> >  1 file changed, 6 insertions(+), 1 deletion(-)
> >> >
> >> > diff --git a/x86_64.c b/x86_64.c
> >> > index 4264bae..3e2d5b4 100755
> >> > --- a/x86_64.c
> >> > +++ b/x86_64.c
> >> > @@ -298,7 +298,12 @@ x86_64_init(int when)
> >> >                         machdep->machspec->modules_end =
> >> >                         MODULES_END_2_6_31;
> >> >                 }
> >> >                  STRUCT_SIZE_INIT(cpuinfo_x86, "cpuinfo_x86");
> >> > -               STRUCT_SIZE_INIT(gate_struct, "gate_struct");
> >> > +               if (STRUCT_EXISTS("gate_desc")) {
> >> > +                       STRUCT_SIZE_INIT(gate_struct, "gate_desc");
> >> It probably worth to rename 'gate_struct' variable to 'gate_desc' as well.
> >
> > Yeah, but there's almost 800 offset table members stored as it is -- if I kept
> > adding new ones for each kernel name change, it would add a few hundred more,
> > and for little benefit.  Anyway, it's the command output that's important.
> 
> Should we at least change user-visible string in
> 
>   symbols.c:9163: fprintf(fp, "                   gate_struct: %ld\n",

No.  It is "user-visible", however it's only for the "help -o" output, 
which is primarily of interest to crash developers, and not users.  
And in that function, I *do* want to show the member name exactly as it
is in the offset_table[] array.  Believe me, there are dozens of members
in that structure that no longer match up with their most recent kernel
version counterparts.

Dave




More information about the Crash-utility mailing list