|
72 | 72 | #include <net/sock.h> |
73 | 73 | #include <net/net_namespace.h> |
74 | 74 |
|
75 | | -#define CAN_ISOTP_VERSION "20200928" |
76 | | - |
77 | 75 | MODULE_DESCRIPTION("PF_CAN isotp 15765-2:2016 protocol"); |
78 | 76 | MODULE_LICENSE("Dual BSD/GPL"); |
79 | 77 | MODULE_AUTHOR("Oliver Hartkopp <socketcan@hartkopp.net>"); |
@@ -222,8 +220,8 @@ static int isotp_send_fc(struct sock *sk, int ae, u8 flowstatus) |
222 | 220 |
|
223 | 221 | can_send_ret = can_send(nskb, 1); |
224 | 222 | if (can_send_ret) |
225 | | - printk_once(KERN_NOTICE "can-isotp: %s: can_send_ret %d\n", |
226 | | - __func__, can_send_ret); |
| 223 | + pr_notice_once("can-isotp: %s: can_send_ret %d\n", |
| 224 | + __func__, can_send_ret); |
227 | 225 |
|
228 | 226 | dev_put(dev); |
229 | 227 |
|
@@ -769,7 +767,7 @@ static enum hrtimer_restart isotp_tx_timer_handler(struct hrtimer *hrtimer) |
769 | 767 |
|
770 | 768 | isotp_tx_burst: |
771 | 769 | skb = alloc_skb(so->ll.mtu + sizeof(struct can_skb_priv), |
772 | | - gfp_any()); |
| 770 | + GFP_ATOMIC); |
773 | 771 | if (!skb) { |
774 | 772 | dev_put(dev); |
775 | 773 | break; |
@@ -798,8 +796,8 @@ static enum hrtimer_restart isotp_tx_timer_handler(struct hrtimer *hrtimer) |
798 | 796 |
|
799 | 797 | can_send_ret = can_send(skb, 1); |
800 | 798 | if (can_send_ret) |
801 | | - printk_once(KERN_NOTICE "can-isotp: %s: can_send_ret %d\n", |
802 | | - __func__, can_send_ret); |
| 799 | + pr_notice_once("can-isotp: %s: can_send_ret %d\n", |
| 800 | + __func__, can_send_ret); |
803 | 801 |
|
804 | 802 | if (so->tx.idx >= so->tx.len) { |
805 | 803 | /* we are done */ |
@@ -942,8 +940,8 @@ static int isotp_sendmsg(struct socket *sock, struct msghdr *msg, size_t size) |
942 | 940 | err = can_send(skb, 1); |
943 | 941 | dev_put(dev); |
944 | 942 | if (err) { |
945 | | - printk_once(KERN_NOTICE "can-isotp: %s: can_send_ret %d\n", |
946 | | - __func__, err); |
| 943 | + pr_notice_once("can-isotp: %s: can_send_ret %d\n", |
| 944 | + __func__, err); |
947 | 945 | return err; |
948 | 946 | } |
949 | 947 |
|
@@ -1408,7 +1406,7 @@ static __init int isotp_module_init(void) |
1408 | 1406 | { |
1409 | 1407 | int err; |
1410 | 1408 |
|
1411 | | - pr_info("can: isotp protocol (rev " CAN_ISOTP_VERSION ")\n"); |
| 1409 | + pr_info("can: isotp protocol\n"); |
1412 | 1410 |
|
1413 | 1411 | err = can_proto_register(&isotp_can_proto); |
1414 | 1412 | if (err < 0) |
|
0 commit comments