Commit 8192cb91 authored by Martin Dalecki's avatar Martin Dalecki Committed by Linus Torvalds

[PATCH] kill warnings 7/19

- Fix improper __FUNCTION__ usage in af_irda.c

- Fix redundant white space usage there - I couldn't resist.
parent 5fd11be5
......@@ -211,14 +211,14 @@ static void irda_connect_confirm(void *instance, void *sap,
switch (sk->type) {
case SOCK_STREAM:
if (max_sdu_size != 0) {
ERROR(__FUNCTION__ "(), max_sdu_size must be 0\n");
ERROR("%s: max_sdu_size must be 0\n", __FUNCTION__);
return;
}
self->max_data_size = irttp_get_max_seg_size(self->tsap);
break;
case SOCK_SEQPACKET:
if (max_sdu_size == 0) {
ERROR(__FUNCTION__ "(), max_sdu_size cannot be 0\n");
ERROR("%s: max_sdu_size cannot be 0\n", __FUNCTION__);
return;
}
self->max_data_size = max_sdu_size;
......@@ -270,14 +270,14 @@ static void irda_connect_indication(void *instance, void *sap,
switch (sk->type) {
case SOCK_STREAM:
if (max_sdu_size != 0) {
ERROR(__FUNCTION__ "(), max_sdu_size must be 0\n");
ERROR("%s: max_sdu_size must be 0\n", __FUNCTION__);
return;
}
self->max_data_size = irttp_get_max_seg_size(self->tsap);
break;
case SOCK_SEQPACKET:
if (max_sdu_size == 0) {
ERROR(__FUNCTION__ "(), max_sdu_size cannot be 0\n");
ERROR("%s: max_sdu_size cannot be 0\n", __FUNCTION__);
return;
}
self->max_data_size = max_sdu_size;
......@@ -374,7 +374,7 @@ static void irda_getvalue_confirm(int result, __u16 obj_id,
self = (struct irda_sock *) priv;
if (!self) {
WARNING(__FUNCTION__ "(), lost myself!\n");
WARNING("%s: lost myself!\n", __FUNCTION__);
return;
}
......@@ -424,7 +424,7 @@ static void irda_selective_discovery_indication(discovery_t *discovery,
self = (struct irda_sock *) priv;
if (!self) {
WARNING(__FUNCTION__ "(), lost myself!\n");
WARNING("%s: lost myself!\n", __FUNCTION__);
return;
}
......@@ -482,7 +482,7 @@ static int irda_open_tsap(struct irda_sock *self, __u8 tsap_sel, char *name)
notify_t notify;
if (self->tsap) {
WARNING(__FUNCTION__ "(), busy!\n");
WARNING("%s: busy!\n", __FUNCTION__);
return -EBUSY;
}
......@@ -559,7 +559,7 @@ static int irda_find_lsap_sel(struct irda_sock *self, char *name)
ASSERT(self != NULL, return -1;);
if (self->iriap) {
WARNING(__FUNCTION__ "(), busy with a previous query\n");
WARNING("%s: busy with a previous query\n", __FUNCTION__);
return -EBUSY;
}
......@@ -1141,7 +1141,7 @@ static int irda_create(struct socket *sock, int protocol)
self->max_sdu_size_rx = TTP_SAR_UNBOUND;
break;
default:
ERROR(__FUNCTION__ "(), protocol not supported!\n");
ERROR("%s: protocol not supported!\n", __FUNCTION__);
return -ESOCKTNOSUPPORT;
}
break;
......@@ -1208,9 +1208,6 @@ void irda_destroy_socket(struct irda_sock *self)
/*
* Function irda_release (sock)
*
*
*
*/
static int irda_release(struct socket *sock)
{
......@@ -1423,9 +1420,6 @@ static inline int irda_data_wait(struct sock *sk)
/*
* Function irda_recvmsg_stream (sock, msg, size, flags, scm)
*
*
*
*/
static int irda_recvmsg_stream(struct socket *sock, struct msghdr *msg,
int size, int flags, struct scm_cookie *scm)
......@@ -1655,9 +1649,6 @@ static int irda_sendmsg_ultra(struct socket *sock, struct msghdr *msg,
/*
* Function irda_shutdown (sk, how)
*
*
*
*/
static int irda_shutdown(struct socket *sock, int how)
{
......@@ -1693,9 +1684,6 @@ static int irda_shutdown(struct socket *sock, int how)
/*
* Function irda_poll (file, sock, wait)
*
*
*
*/
static unsigned int irda_poll(struct file * file, struct socket *sock,
poll_table *wait)
......@@ -1758,9 +1746,6 @@ static unsigned int irda_poll(struct file * file, struct socket *sock,
/*
* Function irda_ioctl (sock, cmd, arg)
*
*
*
*/
static int irda_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
{
......@@ -2024,9 +2009,8 @@ static int irda_setsockopt(struct socket *sock, int level, int optname,
"(), setting max_sdu_size = %d\n", opt);
self->max_sdu_size_rx = opt;
} else {
WARNING(__FUNCTION__
"(), not allowed to set MAXSDUSIZE for this "
"socket type!\n");
WARNING("%s: not allowed to set MAXSDUSIZE for this socket type!\n",
__FUNCTION__);
return -ENOPROTOOPT;
}
break;
......@@ -2121,9 +2105,6 @@ static int irda_extract_ias_value(struct irda_ias_set *ias_opt,
/*
* Function irda_getsockopt (sock, level, optname, optval, optlen)
*
*
*
*/
static int irda_getsockopt(struct socket *sock, int level, int optname,
char *optval, int *optlen)
......@@ -2301,8 +2282,8 @@ static int irda_getsockopt(struct socket *sock, int level, int optname,
/* Check that we can proceed with IAP */
if (self->iriap) {
WARNING(__FUNCTION__
"(), busy with a previous query\n");
WARNING("%s: busy with a previous query\n",
__FUNCTION__);
kfree(ias_opt);
return -EBUSY;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment