~ubuntu-branches/ubuntu/precise/linux-ti-omap4/precise

« back to all changes in this revision

Viewing changes to net/ipv6/ipcomp6.c

  • Committer: Bazaar Package Importer
  • Author(s): Paolo Pisati
  • Date: 2011-06-29 15:23:51 UTC
  • mfrom: (26.1.1 natty-proposed)
  • Revision ID: james.westby@ubuntu.com-20110629152351-xs96tm303d95rpbk
Tags: 3.0.0-1200.2
* Rebased against 3.0.0-6.7
* BSP from TI based on 3.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
55
55
{
56
56
        struct net *net = dev_net(skb->dev);
57
57
        __be32 spi;
58
 
        struct ipv6hdr *iph = (struct ipv6hdr*)skb->data;
 
58
        const struct ipv6hdr *iph = (const struct ipv6hdr *)skb->data;
59
59
        struct ip_comp_hdr *ipcomph =
60
60
                (struct ip_comp_hdr *)(skb->data + offset);
61
61
        struct xfrm_state *x;
64
64
                return;
65
65
 
66
66
        spi = htonl(ntohs(ipcomph->cpi));
67
 
        x = xfrm_state_lookup(net, skb->mark, (xfrm_address_t *)&iph->daddr, spi, IPPROTO_COMP, AF_INET6);
 
67
        x = xfrm_state_lookup(net, skb->mark, (const xfrm_address_t *)&iph->daddr,
 
68
                              spi, IPPROTO_COMP, AF_INET6);
68
69
        if (!x)
69
70
                return;
70
71