aboutsummaryrefslogtreecommitdiffstats
path: root/net/iucv
diff options
context:
space:
mode:
Diffstat (limited to 'net/iucv')
-rw-r--r--net/iucv/af_iucv.c19
-rw-r--r--net/iucv/iucv.c9
2 files changed, 22 insertions, 6 deletions
diff --git a/net/iucv/af_iucv.c b/net/iucv/af_iucv.c
index 29f7baa25110..af3192d2a5a3 100644
--- a/net/iucv/af_iucv.c
+++ b/net/iucv/af_iucv.c
@@ -8,6 +8,9 @@
8 * Author(s): Jennifer Hunt <jenhunt@us.ibm.com> 8 * Author(s): Jennifer Hunt <jenhunt@us.ibm.com>
9 */ 9 */
10 10
11#define KMSG_COMPONENT "af_iucv"
12#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt
13
11#include <linux/module.h> 14#include <linux/module.h>
12#include <linux/types.h> 15#include <linux/types.h>
13#include <linux/list.h> 16#include <linux/list.h>
@@ -616,6 +619,8 @@ static int iucv_sock_sendmsg(struct kiocb *iocb, struct socket *sock,
616 struct iucv_sock *iucv = iucv_sk(sk); 619 struct iucv_sock *iucv = iucv_sk(sk);
617 struct sk_buff *skb; 620 struct sk_buff *skb;
618 struct iucv_message txmsg; 621 struct iucv_message txmsg;
622 char user_id[9];
623 char appl_id[9];
619 int err; 624 int err;
620 625
621 err = sock_error(sk); 626 err = sock_error(sk);
@@ -651,8 +656,15 @@ static int iucv_sock_sendmsg(struct kiocb *iocb, struct socket *sock,
651 err = iucv_message_send(iucv->path, &txmsg, 0, 0, 656 err = iucv_message_send(iucv->path, &txmsg, 0, 0,
652 (void *) skb->data, skb->len); 657 (void *) skb->data, skb->len);
653 if (err) { 658 if (err) {
654 if (err == 3) 659 if (err == 3) {
655 printk(KERN_ERR "AF_IUCV msg limit exceeded\n"); 660 user_id[8] = 0;
661 memcpy(user_id, iucv->dst_user_id, 8);
662 appl_id[8] = 0;
663 memcpy(appl_id, iucv->dst_name, 8);
664 pr_err("Application %s on z/VM guest %s"
665 " exceeds message limit\n",
666 user_id, appl_id);
667 }
656 skb_unlink(skb, &iucv->send_skb_q); 668 skb_unlink(skb, &iucv->send_skb_q);
657 err = -EPIPE; 669 err = -EPIPE;
658 goto fail; 670 goto fail;
@@ -1190,7 +1202,8 @@ static int __init afiucv_init(void)
1190 int err; 1202 int err;
1191 1203
1192 if (!MACHINE_IS_VM) { 1204 if (!MACHINE_IS_VM) {
1193 printk(KERN_ERR "AF_IUCV connection needs VM as base\n"); 1205 pr_err("The af_iucv module cannot be loaded"
1206 " without z/VM\n");
1194 err = -EPROTONOSUPPORT; 1207 err = -EPROTONOSUPPORT;
1195 goto out; 1208 goto out;
1196 } 1209 }
diff --git a/net/iucv/iucv.c b/net/iucv/iucv.c
index 6bf51f7e597f..8f57d4f4328a 100644
--- a/net/iucv/iucv.c
+++ b/net/iucv/iucv.c
@@ -30,6 +30,9 @@
30 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 30 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
31 */ 31 */
32 32
33#define KMSG_COMPONENT "iucv"
34#define pr_fmt(fmt) KMSG_COMPONENT ": " fmt
35
33#include <linux/module.h> 36#include <linux/module.h>
34#include <linux/moduleparam.h> 37#include <linux/moduleparam.h>
35#include <linux/spinlock.h> 38#include <linux/spinlock.h>
@@ -424,8 +427,8 @@ static void iucv_declare_cpu(void *data)
424 err = "Paging or storage error"; 427 err = "Paging or storage error";
425 break; 428 break;
426 } 429 }
427 printk(KERN_WARNING "iucv_register: iucv_declare_buffer " 430 pr_warning("Defining an interrupt buffer on CPU %i"
428 "on cpu %i returned error 0x%02x (%s)\n", cpu, rc, err); 431 " failed with 0x%02x (%s)\n", cpu, rc, err);
429 return; 432 return;
430 } 433 }
431 434
@@ -1652,7 +1655,7 @@ static void iucv_external_interrupt(u16 code)
1652 BUG_ON(p->iptype < 0x01 || p->iptype > 0x09); 1655 BUG_ON(p->iptype < 0x01 || p->iptype > 0x09);
1653 work = kmalloc(sizeof(struct iucv_irq_list), GFP_ATOMIC); 1656 work = kmalloc(sizeof(struct iucv_irq_list), GFP_ATOMIC);
1654 if (!work) { 1657 if (!work) {
1655 printk(KERN_WARNING "iucv_external_interrupt: out of memory\n"); 1658 pr_warning("iucv_external_interrupt: out of memory\n");
1656 return; 1659 return;
1657 } 1660 }
1658 memcpy(&work->data, p, sizeof(work->data)); 1661 memcpy(&work->data, p, sizeof(work->data));