This patch changes the printk call into the preferred function pr_warn(). Since the intention is to just warn the user it is the best level of facility. Signed-off-by: Ioana Ciornei <ciorneiioana@xxxxxxxxx> --- net/ceph/messenger.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/net/ceph/messenger.c b/net/ceph/messenger.c index 6b15876..8f1582e 100644 --- a/net/ceph/messenger.c +++ b/net/ceph/messenger.c @@ -329,7 +329,8 @@ static void con_sock_state_init(struct ceph_connection *con) old_state = atomic_xchg(&con->sock_state, CON_SOCK_STATE_CLOSED); if (WARN_ON(old_state != CON_SOCK_STATE_NEW)) - printk("%s: unexpected old state %d\n", __func__, old_state); + pr_warn("%s: unexpected old state %d\n", __func__, + old_state); dout("%s con %p sock %d -> %d\n", __func__, con, old_state, CON_SOCK_STATE_CLOSED); } @@ -340,7 +341,8 @@ static void con_sock_state_connecting(struct ceph_connection *con) old_state = atomic_xchg(&con->sock_state, CON_SOCK_STATE_CONNECTING); if (WARN_ON(old_state != CON_SOCK_STATE_CLOSED)) - printk("%s: unexpected old state %d\n", __func__, old_state); + pr_warn("%s: unexpected old state %d\n", __func__, + old_state); dout("%s con %p sock %d -> %d\n", __func__, con, old_state, CON_SOCK_STATE_CONNECTING); } @@ -351,7 +353,8 @@ static void con_sock_state_connected(struct ceph_connection *con) old_state = atomic_xchg(&con->sock_state, CON_SOCK_STATE_CONNECTED); if (WARN_ON(old_state != CON_SOCK_STATE_CONNECTING)) - printk("%s: unexpected old state %d\n", __func__, old_state); + pr_warn("%s: unexpected old state %d\n", __func__, + old_state); dout("%s con %p sock %d -> %d\n", __func__, con, old_state, CON_SOCK_STATE_CONNECTED); } @@ -364,7 +367,8 @@ static void con_sock_state_closing(struct ceph_connection *con) if (WARN_ON(old_state != CON_SOCK_STATE_CONNECTING && old_state != CON_SOCK_STATE_CONNECTED && old_state != CON_SOCK_STATE_CLOSING)) - printk("%s: unexpected old state %d\n", __func__, old_state); + pr_warn("%s: unexpected old state %d\n", __func__, + old_state); dout("%s con %p sock %d -> %d\n", __func__, con, old_state, CON_SOCK_STATE_CLOSING); } @@ -378,7 +382,8 @@ static void con_sock_state_closed(struct ceph_connection *con) old_state != CON_SOCK_STATE_CLOSING && old_state != CON_SOCK_STATE_CONNECTING && old_state != CON_SOCK_STATE_CLOSED)) - printk("%s: unexpected old state %d\n", __func__, old_state); + pr_warn("%s: unexpected old state %d\n", __func__, + old_state); dout("%s con %p sock %d -> %d\n", __func__, con, old_state, CON_SOCK_STATE_CLOSED); } -- 2.6.4 -- To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html