diff options
Diffstat (limited to 'net/802')
-rw-r--r-- | net/802/psnap.c | 9 | ||||
-rw-r--r-- | net/802/tr.c | 2 |
2 files changed, 7 insertions, 4 deletions
diff --git a/net/802/psnap.c b/net/802/psnap.c index 70980baeb682..bdbffa3cb043 100644 --- a/net/802/psnap.c +++ b/net/802/psnap.c | |||
@@ -51,7 +51,7 @@ static int snap_rcv(struct sk_buff *skb, struct net_device *dev, | |||
51 | int rc = 1; | 51 | int rc = 1; |
52 | struct datalink_proto *proto; | 52 | struct datalink_proto *proto; |
53 | static struct packet_type snap_packet_type = { | 53 | static struct packet_type snap_packet_type = { |
54 | .type = __constant_htons(ETH_P_SNAP), | 54 | .type = cpu_to_be16(ETH_P_SNAP), |
55 | }; | 55 | }; |
56 | 56 | ||
57 | if (unlikely(!pskb_may_pull(skb, 5))) | 57 | if (unlikely(!pskb_may_pull(skb, 5))) |
@@ -95,15 +95,16 @@ static int snap_request(struct datalink_proto *dl, | |||
95 | EXPORT_SYMBOL(register_snap_client); | 95 | EXPORT_SYMBOL(register_snap_client); |
96 | EXPORT_SYMBOL(unregister_snap_client); | 96 | EXPORT_SYMBOL(unregister_snap_client); |
97 | 97 | ||
98 | static char snap_err_msg[] __initdata = | 98 | static const char snap_err_msg[] __initconst = |
99 | KERN_CRIT "SNAP - unable to register with 802.2\n"; | 99 | KERN_CRIT "SNAP - unable to register with 802.2\n"; |
100 | 100 | ||
101 | static int __init snap_init(void) | 101 | static int __init snap_init(void) |
102 | { | 102 | { |
103 | snap_sap = llc_sap_open(0xAA, snap_rcv); | 103 | snap_sap = llc_sap_open(0xAA, snap_rcv); |
104 | 104 | if (!snap_sap) { | |
105 | if (!snap_sap) | ||
106 | printk(snap_err_msg); | 105 | printk(snap_err_msg); |
106 | return -EBUSY; | ||
107 | } | ||
107 | 108 | ||
108 | return 0; | 109 | return 0; |
109 | } | 110 | } |
diff --git a/net/802/tr.c b/net/802/tr.c index f47ae289d83b..e7eb13084d71 100644 --- a/net/802/tr.c +++ b/net/802/tr.c | |||
@@ -486,6 +486,7 @@ static struct rif_cache *rif_get_idx(loff_t pos) | |||
486 | } | 486 | } |
487 | 487 | ||
488 | static void *rif_seq_start(struct seq_file *seq, loff_t *pos) | 488 | static void *rif_seq_start(struct seq_file *seq, loff_t *pos) |
489 | __acquires(&rif_lock) | ||
489 | { | 490 | { |
490 | spin_lock_irq(&rif_lock); | 491 | spin_lock_irq(&rif_lock); |
491 | 492 | ||
@@ -517,6 +518,7 @@ static void *rif_seq_next(struct seq_file *seq, void *v, loff_t *pos) | |||
517 | } | 518 | } |
518 | 519 | ||
519 | static void rif_seq_stop(struct seq_file *seq, void *v) | 520 | static void rif_seq_stop(struct seq_file *seq, void *v) |
521 | __releases(&rif_lock) | ||
520 | { | 522 | { |
521 | spin_unlock_irq(&rif_lock); | 523 | spin_unlock_irq(&rif_lock); |
522 | } | 524 | } |