* [PATCH 1/1] skb->tail can be offset
@ 2010-02-15 22:12 Serge E. Hallyn
[not found] ` <20100215221214.GA21108-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
0 siblings, 1 reply; 2+ messages in thread
From: Serge E. Hallyn @ 2010-02-15 22:12 UTC (permalink / raw)
To: Oren Laadan; +Cc: Linux Containers
Needed for socket c/r on 64-bit arches.
Signed-off-by: Serge E. Hallyn <serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
---
net/checkpoint.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/checkpoint.c b/net/checkpoint.c
index c6b6341..ee13050 100644
--- a/net/checkpoint.c
+++ b/net/checkpoint.c
@@ -97,19 +97,19 @@ static void sock_record_header_info(struct sk_buff *skb,
h->mac_len = skb->mac_len;
h->skb_len = skb->len;
h->hdr_len = skb->data - skb->head;
- h->lin_len = ((unsigned long)skb->tail - (unsigned long)skb->head);
h->frg_len = skb->data_len;
-
h->data_offset = (skb->data - skb->head);
#ifdef NET_SKBUFF_DATA_USES_OFFSET
h->transport_header = skb->transport_header;
h->network_header = skb->network_header;
h->mac_header = skb->mac_header;
+ h->lin_len = (unsigned long) skb->tail;
#else
h->transport_header = skb->transport_header - skb->head;
h->network_header = skb->network_header - skb->head;
h->mac_header = skb->mac_header - skb->head;
+ h->lin_len = ((unsigned long) skb->tail - (unsigned long) skb->head);
#endif
memcpy(h->cb, skb->cb, sizeof(skb->cb));
--
1.6.0.6
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/1] skb->tail can be offset
[not found] ` <20100215221214.GA21108-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
@ 2010-02-16 10:02 ` Oren Laadan
0 siblings, 0 replies; 2+ messages in thread
From: Oren Laadan @ 2010-02-16 10:02 UTC (permalink / raw)
To: Serge E. Hallyn; +Cc: Linux Containers
Nice catch -- applied.
Serge E. Hallyn wrote:
> Needed for socket c/r on 64-bit arches.
>
> Signed-off-by: Serge E. Hallyn <serue-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
> ---
> net/checkpoint.c | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/net/checkpoint.c b/net/checkpoint.c
> index c6b6341..ee13050 100644
> --- a/net/checkpoint.c
> +++ b/net/checkpoint.c
> @@ -97,19 +97,19 @@ static void sock_record_header_info(struct sk_buff *skb,
> h->mac_len = skb->mac_len;
> h->skb_len = skb->len;
> h->hdr_len = skb->data - skb->head;
> - h->lin_len = ((unsigned long)skb->tail - (unsigned long)skb->head);
> h->frg_len = skb->data_len;
> -
> h->data_offset = (skb->data - skb->head);
>
> #ifdef NET_SKBUFF_DATA_USES_OFFSET
> h->transport_header = skb->transport_header;
> h->network_header = skb->network_header;
> h->mac_header = skb->mac_header;
> + h->lin_len = (unsigned long) skb->tail;
> #else
> h->transport_header = skb->transport_header - skb->head;
> h->network_header = skb->network_header - skb->head;
> h->mac_header = skb->mac_header - skb->head;
> + h->lin_len = ((unsigned long) skb->tail - (unsigned long) skb->head);
> #endif
>
> memcpy(h->cb, skb->cb, sizeof(skb->cb));
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-02-16 10:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-15 22:12 [PATCH 1/1] skb->tail can be offset Serge E. Hallyn
[not found] ` <20100215221214.GA21108-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org>
2010-02-16 10:02 ` Oren Laadan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox