[PATCH] Transform kmem_cache_alloc()+memset(0) -> kmem_cache_zalloc().
[powerpc.git] / net / core / filter.c
index 6732782..0df843b 100644 (file)
@@ -178,7 +178,7 @@ unsigned int sk_run_filter(struct sk_buff *skb, struct sock_filter *filter, int
 load_w:
                        ptr = load_pointer(skb, k, 4, &tmp);
                        if (ptr != NULL) {
-                               A = ntohl(get_unaligned((u32 *)ptr));
+                               A = ntohl(get_unaligned((__be32 *)ptr));
                                continue;
                        }
                        break;
@@ -187,7 +187,7 @@ load_w:
 load_h:
                        ptr = load_pointer(skb, k, 2, &tmp);
                        if (ptr != NULL) {
-                               A = ntohs(get_unaligned((u16 *)ptr));
+                               A = ntohs(get_unaligned((__be16 *)ptr));
                                continue;
                        }
                        break;
@@ -261,7 +261,7 @@ load_b:
                 */
                switch (k-SKF_AD_OFF) {
                case SKF_AD_PROTOCOL:
-                       A = htons(skb->protocol);
+                       A = ntohs(skb->protocol);
                        continue;
                case SKF_AD_PKTTYPE:
                        A = skb->pkt_type;