Patch: linux-2.5.7-pre1/net/ipv4/ipmr.c did not compile

Patch: linux-2.5.7-pre1/net/ipv4/ipmr.c did not compile

Post by Adam J. Richte » Fri, 15 Mar 2002 03:00:09



        It looks like sk->num became inet_sk(sk)->num in 2.5.7-pre1,
but one of these changes was missed in net/ipv4/ipmr.c.  Here is
the patch.

Adam J. Richter     __     ______________   4880 Stevens Creek Blvd, Suite 104

+1 408 261-6630         | g g d r a s i l   United States of America
fax +1 408 261-6631      "Free Software For The Rest Of Us."

--- linux-2.5.7-pre1/net/ipv4/ipmr.c    Thu Mar  7 18:18:31 2002

        switch(optname)
        {
                case MRT_INIT:
-                       if(sk->type!=SOCK_RAW || sk->num!=IPPROTO_IGMP)
+                       if(sk->type!=SOCK_RAW ||
+                          inet_sk(sk)->num!=IPPROTO_IGMP)
                                return -EOPNOTSUPP;
                        if(optlen!=sizeof(int))
                                return -ENOPROTOOPT;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in

More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

 
 
 

1. Patch?: linux-2.5.45/net/ipv4/netfilter dst.pmtu compilation fixes

also see
http://marc.theaimsgroup.com/?l=linux-kernel&m=103614599321384&w=1

linux-2.5.45 appears to have replaced dst_entry.pmtu with
dst_entry.metrics[RTAX_PMTU] and created a helper function
dst_pmtu(struct dst_entry*), presumably to simplify future changes
like this one.   Now the
files compile.  That is as much as I have tested.

 I am not currently familiar with this code, so I could easily
have misunderstood something in this patch.

--- linux-2.5.45.orig/net/ipv4/netfilter/ipt_TCPMSS.c   2002-10-31
01:42:56.000000000 +0100
+++ linux-2.5.45/net/ipv4/netfilter/ipt_TCPMSS.c        2002-11-01

                        return NF_DROP; /* or IPT_CONTINUE ?? */
                }

-               if((*pskb)->dst->pmtu <= (sizeof(struct iphdr) +
sizeof(struct tcphdr))) {
+               if( dst_pmtu( (*pskb)->dst ) <= (sizeof(struct iphdr) +
sizeof(struct tcphdr))) {
                        if (net_ratelimit())
                                printk(KERN_ERR
-                                       "ipt_tcpmss_target: unknown or
invalid path-MTU (%d)\n", (*pskb)->dst->pmtu);
+                                       "ipt_tcpmss_target: unknown or
invalid path-MTU (%d)\n", dst_pmtu( (*pskb)->dst ) );
                        return NF_DROP; /* or IPT_CONTINUE ?? */
                }

-               newmss = (*pskb)->dst->pmtu - sizeof(struct iphdr) -
sizeof(struct tcphdr);
+               newmss = dst_pmtu( (*pskb)->dst ) - sizeof(struct iphdr)
- sizeof(struct tcphdr);
        } else
                newmss = tcpmssinfo->mss;

--
+----------------------------------------------+
|Jaquemet Loic                                 |
|Intern in WesternGeco, Schlumberger in Gatwick|
|Phone: 44-(0)1293-55-6876                     |
|Eleve ingenieur en informatique FIIFO, ORSAY  |
+----------------------------------------------+
http://sourceforge.net/projects/ffss/

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in

More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

2. Need help disabling screen blanker

3. ipv4: move proc stuff from net/ipv4/af_inet.c to net/ipv4/proc.c

4. how to log all boot messages?

5. Patch?: linux-2.5.45/net - __secpath_destroy made net depend on ipv4

6. help: staircase when printing

7. 2.5.32 : net/ipv4/netfilter/ipfwadm_core.c compile error

8. ISP Recommendations

9. 2.5.7-pre1 fix for api-caused ipmr.c compile failure

10. Remove compile warning from net/ipv4/netfilter/ip_nat_helper.c

11. linux-2.4.3/drivers/net/wan/dscc4.c does not compile

12. Patch??: linux-2.5.6-pre1/drivers/scsi/advansys.c DMA-mapping fixes

13. Patch?: linux-2.5.6-pre1/drivers/scsi/pci2000.c compilation fixes + pci device ID table