From: Wolfgang Wegner <ww@kt.e-technik.uni-dortmund.de>
To: Wolfgang Wegner <ww@kt.e-technik.uni-dortmund.de>
Cc: linux-kernel@vger.kernel.org
Subject: sk_buff modification problem
Date: Sun, 26 May 2002 01:00:25 +0200 [thread overview]
Message-ID: <20020526010025.A18021@bigmac.e-technik.uni-dortmund.de> (raw)
In-Reply-To: <20020524100434.B1778@bigmac.e-technik.uni-dortmund.de>
Hi,
as my first post was a bit confused maybe, I try again - hopefully
more specific...
i am trying to do a modification in the kernel to get a more precise
timestamp directly from a modified network driver, and am having some
difficulty (or maybe misunderstanding) with sk_buff's... Kernel used
is 2.4.18.
Here's a list what I modified:
- struct sk_buff has a new member, struct ww_timestamp rcvtime, containing
the actual timestamp and a flag is_valid. The flag is initialized to
"0" in alloc_skb as well as skb_headerinit, and the complete struct
is copied in skb_clone and copy_skb_header.
- the driver (currently orinoco.c from pcmcia_cs) is modified to fill
the my_timestamp struct and sets is_valid.
- when passing the packet to a socket, this new timestamp is evaluated
(in sock_recv_timestamp, where both sk_buff _and_ sock are known)
The problem is: in sock_recv_timestamp, is_valid is reset to 0 - and i
have no idea why. To track it down I tried to put some printk's in the
sk_buff handling functions and sock_recv_timestamp, but it seems there
is not even any copying done (as "&skb" is the same in orinoco.c and
sock_recv_timestamp):
> May 24 08:55:43 licht kernel: skb_head_from_pool, skb=cfaa6d80
> May 24 08:55:43 licht kernel: orinoco.c: skb=cfaa6d80
> May 24 08:55:43 licht kernel: skb=cfaa6d80, timestamp.is_valid=0!
> May 24 08:55:43 licht kernel: skb_head_from_pool, skb=cfaa6d80
> May 24 08:55:43 licht kernel: skb_head_from_pool, skb=cf0fa200
In case somebody wants to look at it, the patch is at
http://www-kt.e-technik.uni-dortmund.de/m_ww/l-k/patch-2.4.18-ww3.gz
and the orinoco_ev_rx part of orinoco.c is at
http://www-kt.e-technik.uni-dortmund.de/m_ww/l-k/orinoco.c
I am really out of ideas here, especially I do not know how to
debug it, because I do not see any further possibility where (and
why) the value gets overwritten.
Thanks,
Wolfgang
next prev parent reply other threads:[~2002-05-25 23:00 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-05-24 8:04 sk_buff misunderstanding? Wolfgang Wegner
2002-05-24 7:52 ` David S. Miller
2002-05-24 8:11 ` Wolfgang Wegner
2002-05-25 23:00 ` Wolfgang Wegner [this message]
2002-05-26 17:35 ` sk_buff modification problem -> (almost) solved Wolfgang Wegner
2002-05-26 19:52 ` kuznet
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20020526010025.A18021@bigmac.e-technik.uni-dortmund.de \
--to=ww@kt.e-technik.uni-dortmund.de \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®