----- Original Message ----- > Hi, > > I think the behaviour of the (undocumented) "list -h" command is hardly > useful. I believe the intention was to cover cases like struct anon_vma, which > is linked through a list_head (not at the beginning of the structure) and does > not have an external struct list_head. However, it doesn't work for that case: > > crash> struct -o anon_vma > struct anon_vma { > [0x0] struct anon_vma *root; > [0x4] spinlock_t lock; > [0x8] atomic_t external_refcount; > [0xc] struct list_head head; > } > > Now, let's have an anon_vma at 0xf0749d38 > crash> anon_vma 0xf0749d38 > struct anon_vma { > root = 0xf0749d38, > /* left out for brevity */ > head = { > next = 0xf6c34708, > prev = 0xf6c34d80 > } > } > > I would assume that I can walk all linked anon_vma's with > > list -o anon_vma.head -h 0xf0749d38 > > But that still expects a pointer to struct list_head. I would have to do > > list -o anon_vma.head -h 0xf0749d38+0xc > > That's awkward. But maybe it's how it should work, because it's not clear what > the "-h" should be doing. > > Anyway, I think the "list" command could help with walking the anon_vma list. > I can surely add another option letter for that purpose, but before doing > that, I'd like to ask if this is merely missing documentation and a bug in the > implemenatation of the existing "-h" option. > > Thanks for your patience, > Petr Tesarik To be honest with you, I don't recall what I had in mind, nor what I was working on when I added it, but given that it was never advertised, it wasn't meant for prime time. So by all means, you can try to coerce -h into working as you expected. Thanks, Dave -- Crash-utility mailing list Crash-utility@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/crash-utility