kernelnewbies.kernelnewbies.org archive mirror
 help / color / mirror / Atom feed
* Tracing memory address access in kernel
@ 2018-12-04 10:24 Pritam Bankar
  2018-12-04 13:23 ` Chriz Chow
  2018-12-07 19:49 ` Sudip Mukherjee
  0 siblings, 2 replies; 3+ messages in thread
From: Pritam Bankar @ 2018-12-04 10:24 UTC (permalink / raw)
  To: kernelnewbies

Hello,

I am facing issue of memory corruption where only one field of
allocated structure is getting corrupted. I have bio structure and one
of the page in bio vector is getting set to NULL.

crash> struct bio_vec 0xffff88009dc5eb00

struct bio_vec {
  bv_page = 0xffffea000a434b80,
  bv_len = 4096,
  bv_offset = 0
}

crash> struct bio_vec 0xffff88009dc5eb10
struct bio_vec {
  bv_page = 0x0,
  bv_len = 4096,
  bv_offset = 0

}

crash> struct bio_vec 0xffff88009dc5eb20
struct bio_vec {
  bv_page = 0xffffea000a467500,
  bv_len = 4096,
  bv_offset = 0

}

I have allocated contagious memory for bio vectors. As you can see in
second bio vector bv_page is getting set to NULL. This address is
valid till the time I do some operations in my module. After some
operations bv_page is getting set to NULL. Other fields are having
valid data.

Is there any debugging technique / tool available which will track
access to specific memory access?  I would like to dump stack every
time bv_page is accessed or modified

Thanks and regards,
Pritam Bankar

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-12-07 19:50 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-04 10:24 Tracing memory address access in kernel Pritam Bankar
2018-12-04 13:23 ` Chriz Chow
2018-12-07 19:49 ` Sudip Mukherjee

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).