Thanks Dave,
ioctl related data structures are common.
I did not find the -u switch in the help for struct command in crash.
Hopefully, my version of crash supports it.
Dheeraj
On Fri, Mar 7, 2008 at 8:32 PM, Dave Anderson <anderson(a)redhat.com> wrote:
Dheeraj Sangamkar wrote:
> Hi,
> When I debug ioctls, I get parameters which are pointers to structures
> in user space.
> I am unable to use the struct command to print these structures.
>
> Currently I am using "rd -u" to read the content of user memory and
> decode it based on the structure information I have.
>
> Am I missing something? Is there an easier way to do this?
As an addendum to the steps I described in my last post, it's possible
that in your particular case that the ioctl-related data structures in
user space are also "known" by the kernel, i.e. structures that are
common to both user-space and kernel-space. If that's true,
then you don't need the "add-symbol-file" step -- just make
sure that you are in the crash context of the process that
owns the user-space instance, determine the user-space address
of the structure, and simply use the "struct -u" option.
Dave
--
Crash-utility mailing list
Crash-utility(a)redhat.com
https://www.redhat.com/mailman/listinfo/crash-utility