diff --git a/fs/gfs2/glock.c b/fs/gfs2/glock.c
index d4fa395..f30fde9 100644
--- a/fs/gfs2/glock.c
+++ b/fs/gfs2/glock.c
@@ -2315,17 +2315,17 @@
 	unsigned int x;
 	int error = -ENOBUFS;
 
-	printk("  %s\n", str);
-	printk("    owner = %ld\n",
+	printk(KERN_INFO "  %s\n", str);
+	printk(KERN_INFO "    owner = %ld\n",
 		   (gh->gh_owner) ? (long)gh->gh_owner->pid : -1);
-	printk("    gh_state = %u\n", gh->gh_state);
-	printk("    gh_flags =");
+	printk(KERN_INFO "    gh_state = %u\n", gh->gh_state);
+	printk(KERN_INFO "    gh_flags =");
 	for (x = 0; x < 32; x++)
 		if (gh->gh_flags & (1 << x))
 			printk(" %u", x);
 	printk(" \n");
-	printk("    error = %d\n", gh->gh_error);
-	printk("    gh_iflags =");
+	printk(KERN_INFO "    error = %d\n", gh->gh_error);
+	printk(KERN_INFO "    gh_iflags =");
 	for (x = 0; x < 32; x++)
 		if (test_bit(x, &gh->gh_iflags))
 			printk(" %u", x);
@@ -2348,17 +2348,17 @@
 	unsigned int x;
 	int error = -ENOBUFS;
 
-	printk("  Inode:\n");
-	printk("    num = %llu %llu\n",
+	printk(KERN_INFO "  Inode:\n");
+	printk(KERN_INFO "    num = %llu %llu\n",
 		    ip->i_num.no_formal_ino, ip->i_num.no_addr);
-	printk("    type = %u\n", IF2DT(ip->i_di.di_mode));
-	printk("    i_count = %d\n", atomic_read(&ip->i_count));
-	printk("    i_flags =");
+	printk(KERN_INFO "    type = %u\n", IF2DT(ip->i_di.di_mode));
+	printk(KERN_INFO "    i_count = %d\n", atomic_read(&ip->i_count));
+	printk(KERN_INFO "    i_flags =");
 	for (x = 0; x < 32; x++)
 		if (test_bit(x, &ip->i_flags))
 			printk(" %u", x);
 	printk(" \n");
-	printk("    vnode = %s\n", (ip->i_vnode) ? "yes" : "no");
+	printk(KERN_INFO "    vnode = %s\n", (ip->i_vnode) ? "yes" : "no");
 
 	error = 0;
 
@@ -2381,30 +2381,30 @@
 
 	spin_lock(&gl->gl_spin);
 
-	printk("Glock (%u, %llu)\n",
+	printk(KERN_INFO "Glock (%u, %llu)\n",
 		    gl->gl_name.ln_type,
 		    gl->gl_name.ln_number);
-	printk("  gl_flags =");
+	printk(KERN_INFO "  gl_flags =");
 	for (x = 0; x < 32; x++)
 		if (test_bit(x, &gl->gl_flags))
 			printk(" %u", x);
 	printk(" \n");
-	printk("  gl_ref = %d\n", atomic_read(&gl->gl_ref.refcount));
-	printk("  gl_state = %u\n", gl->gl_state);
-	printk("  req_gh = %s\n", (gl->gl_req_gh) ? "yes" : "no");
-	printk("  req_bh = %s\n", (gl->gl_req_bh) ? "yes" : "no");
-	printk("  lvb_count = %d\n", atomic_read(&gl->gl_lvb_count));
-	printk("  object = %s\n", (gl->gl_object) ? "yes" : "no");
-	printk("  le = %s\n",
+	printk(KERN_INFO "  gl_ref = %d\n", atomic_read(&gl->gl_ref.refcount));
+	printk(KERN_INFO "  gl_state = %u\n", gl->gl_state);
+	printk(KERN_INFO "  req_gh = %s\n", (gl->gl_req_gh) ? "yes" : "no");
+	printk(KERN_INFO "  req_bh = %s\n", (gl->gl_req_bh) ? "yes" : "no");
+	printk(KERN_INFO "  lvb_count = %d\n", atomic_read(&gl->gl_lvb_count));
+	printk(KERN_INFO "  object = %s\n", (gl->gl_object) ? "yes" : "no");
+	printk(KERN_INFO "  le = %s\n",
 		   (list_empty(&gl->gl_le.le_list)) ? "no" : "yes");
-	printk("  reclaim = %s\n",
+	printk(KERN_INFO "  reclaim = %s\n",
 		    (list_empty(&gl->gl_reclaim)) ? "no" : "yes");
 	if (gl->gl_aspace)
-		printk("  aspace = %lu\n",
+		printk(KERN_INFO "  aspace = %lu\n",
 			    gl->gl_aspace->i_mapping->nrpages);
 	else
-		printk("  aspace = no\n");
-	printk("  ail = %d\n", atomic_read(&gl->gl_ail_count));
+		printk(KERN_INFO "  aspace = no\n");
+	printk(KERN_INFO "  ail = %d\n", atomic_read(&gl->gl_ail_count));
 	if (gl->gl_req_gh) {
 		error = dump_holder("Request", gl->gl_req_gh);
 		if (error)
@@ -2438,7 +2438,7 @@
 				goto out;
 		} else {
 			error = -ENOBUFS;
-			printk("  Inode: busy\n");
+			printk(KERN_INFO "  Inode: busy\n");
 		}
 	}
 
diff --git a/fs/gfs2/locking.c b/fs/gfs2/locking.c
index 2d2f8fe..0f4c50e 100644
--- a/fs/gfs2/locking.c
+++ b/fs/gfs2/locking.c
@@ -46,18 +46,17 @@
 	list_for_each_entry(lw, &lmh_list, lw_list) {
 		if (!strcmp(lw->lw_ops->lm_proto_name, proto->lm_proto_name)) {
 			up(&lmh_lock);
-			printk("GFS2: protocol %s already exists\n",
+			printk(KERN_INFO "GFS2: protocol %s already exists\n",
 			       proto->lm_proto_name);
 			return -EEXIST;
 		}
 	}
 
-	lw = kmalloc(sizeof(struct lmh_wrapper), GFP_KERNEL);
+	lw = kzalloc(sizeof(struct lmh_wrapper), GFP_KERNEL);
 	if (!lw) {
 		up(&lmh_lock);
 		return -ENOMEM;
 	}
-	memset(lw, 0, sizeof(struct lmh_wrapper));
 
 	lw->lw_ops = proto;
 	list_add(&lw->lw_list, &lmh_list);
@@ -90,7 +89,7 @@
 
 	up(&lmh_lock);
 
-	printk("GFS2: can't unregister lock protocol %s\n",
+	printk(KERN_WARNING "GFS2: can't unregister lock protocol %s\n",
 	       proto->lm_proto_name);
 }
 
@@ -136,7 +135,7 @@
 			request_module(proto_name);
 			goto retry;
 		}
-		printk("GFS2: can't find protocol %s\n", proto_name);
+		printk(KERN_INFO "GFS2: can't find protocol %s\n", proto_name);
 		error = -ENOENT;
 		goto out;
 	}
diff --git a/fs/gfs2/locking/dlm/lock.c b/fs/gfs2/locking/dlm/lock.c
index 666d696..1799d22 100644
--- a/fs/gfs2/locking/dlm/lock.c
+++ b/fs/gfs2/locking/dlm/lock.c
@@ -34,7 +34,7 @@
 	struct gdlm_ls *ls = lp->ls;
 
 	if (!mode) {
-		printk("lock_dlm: bast mode zero %x,%llx\n",
+		printk(KERN_INFO "lock_dlm: bast mode zero %x,%llx\n",
 			lp->lockname.ln_type, lp->lockname.ln_number);
 		return;
 	}
@@ -408,7 +408,7 @@
 	int error;
 
 	if (lp->hold_null) {
-		printk("lock_dlm: lvb already held\n");
+		printk(KERN_INFO "lock_dlm: lvb already held\n");
 		return 0;
 	}
 
@@ -429,7 +429,8 @@
 	wait_for_completion(&lpn->ast_wait);
 	error = lp->lksb.sb_status;
 	if (error) {
-		printk("lock_dlm: hold_null_lock dlm error %d\n", error);
+		printk(KERN_INFO "lock_dlm: hold_null_lock dlm error %d\n",
+		       error);
 		gdlm_delete_lp(lpn);
 		lpn = NULL;
 	}
diff --git a/fs/gfs2/locking/dlm/main.c b/fs/gfs2/locking/dlm/main.c
index 2c13c916..1c0943d 100644
--- a/fs/gfs2/locking/dlm/main.c
+++ b/fs/gfs2/locking/dlm/main.c
@@ -22,7 +22,7 @@
 
 	error = gfs_register_lockproto(&gdlm_ops);
 	if (error) {
-		printk("lock_dlm:  can't register protocol: %d\n", error);
+		printk(KERN_WARNING "lock_dlm:  can't register protocol: %d\n", error);
 		return error;
 	}
 
@@ -42,7 +42,7 @@
 	gdlm_drop_count = GDLM_DROP_COUNT;
 	gdlm_drop_period = GDLM_DROP_PERIOD;
 
-	printk("Lock_DLM (built %s %s) installed\n", __DATE__, __TIME__);
+	printk(KERN_INFO "Lock_DLM (built %s %s) installed\n", __DATE__, __TIME__);
 	return 0;
 }
 
diff --git a/fs/gfs2/locking/dlm/plock.c b/fs/gfs2/locking/dlm/plock.c
index 3828472..f7ac582 100644
--- a/fs/gfs2/locking/dlm/plock.c
+++ b/fs/gfs2/locking/dlm/plock.c
@@ -83,7 +83,7 @@
 
 	spin_lock(&ops_lock);
 	if (!list_empty(&op->list)) {
-		printk("plock op on list\n");
+		printk(KERN_INFO "plock op on list\n");
 		list_del(&op->list);
 	}
 	spin_unlock(&ops_lock);
@@ -127,7 +127,7 @@
 
 	spin_lock(&ops_lock);
 	if (!list_empty(&op->list)) {
-		printk("punlock op on list\n");
+		printk(KERN_INFO "punlock op on list\n");
 		list_del(&op->list);
 	}
 	spin_unlock(&ops_lock);
@@ -162,7 +162,7 @@
 
 	spin_lock(&ops_lock);
 	if (!list_empty(&op->list)) {
-		printk("plock_get op on list\n");
+		printk(KERN_INFO "plock_get op on list\n");
 		list_del(&op->list);
 	}
 	spin_unlock(&ops_lock);
@@ -242,7 +242,7 @@
 	if (found)
 		wake_up(&recv_wq);
 	else
-		printk("gdlm dev_write no op %x %llx\n", info.fsid,
+		printk(KERN_INFO "gdlm dev_write no op %x %llx\n", info.fsid,
 			info.number);
 	return count;
 }
@@ -285,13 +285,14 @@
 
 	rv = misc_register(&plock_dev_misc);
 	if (rv)
-		printk("gdlm_plock_init: misc_register failed %d", rv);
+		printk(KERN_INFO "gdlm_plock_init: misc_register failed %d",
+		       rv);
 	return rv;
 }
 
 void gdlm_plock_exit(void)
 {
 	if (misc_deregister(&plock_dev_misc) < 0)
-		printk("gdlm_plock_exit: misc_deregister failed");
+		printk(KERN_INFO "gdlm_plock_exit: misc_deregister failed");
 }
 
diff --git a/fs/gfs2/locking/nolock/main.c b/fs/gfs2/locking/nolock/main.c
index b716e33..7ede090 100644
--- a/fs/gfs2/locking/nolock/main.c
+++ b/fs/gfs2/locking/nolock/main.c
@@ -44,11 +44,10 @@
 		sscanf(c, "%u", &jid);
 	}
 
-	nl = kmalloc(sizeof(struct nolock_lockspace), GFP_KERNEL);
+	nl = kzalloc(sizeof(struct nolock_lockspace), GFP_KERNEL);
 	if (!nl)
 		return -ENOMEM;
 
-	memset(nl, 0, sizeof(struct nolock_lockspace));
 	nl->nl_lvb_size = min_lvb_size;
 
 	lockstruct->ls_jid = jid;
@@ -147,10 +146,8 @@
 	struct nolock_lockspace *nl = (struct nolock_lockspace *)lock;
 	int error = 0;
 
-	*lvbp = kmalloc(nl->nl_lvb_size, GFP_KERNEL);
-	if (*lvbp)
-		memset(*lvbp, 0, nl->nl_lvb_size);
-	else
+	*lvbp = kzalloc(nl->nl_lvb_size, GFP_KERNEL);
+	if (!*lvbp)
 		error = -ENOMEM;
 
 	return error;
@@ -246,11 +243,11 @@
 
 	error = gfs_register_lockproto(&nolock_ops);
 	if (error) {
-		printk("lock_nolock: can't register protocol: %d\n", error);
+		printk(KERN_WARNING "lock_nolock: can't register protocol: %d\n", error);
 		return error;
 	}
 
-	printk("Lock_Nolock (built %s %s) installed\n", __DATE__, __TIME__);
+	printk(KERN_INFO "Lock_Nolock (built %s %s) installed\n", __DATE__, __TIME__);
 	return 0;
 }
 
diff --git a/fs/gfs2/ondisk.c b/fs/gfs2/ondisk.c
index 854b504..964abd2 100644
--- a/fs/gfs2/ondisk.c
+++ b/fs/gfs2/ondisk.c
@@ -17,7 +17,7 @@
 #include "gfs2.h"
 #include <linux/gfs2_ondisk.h>
 
-#define pv(struct, member, fmt) printk("  "#member" = "fmt"\n", struct->member);
+#define pv(struct, member, fmt) printk(KERN_INFO "  "#member" = "fmt"\n", struct->member);
 #define pa(struct, member, count) print_array(#member, struct->member, count);
 
 /**
@@ -32,11 +32,11 @@
 {
 	int x;
 
-	printk("  %s =\n", title);
+	printk(KERN_INFO "  %s =\n" KERN_INFO, title);
 	for (x = 0; x < count; x++) {
 		printk("%.2X ", (unsigned char)buf[x]);
 		if (x % 16 == 15)
-			printk("\n");
+			printk("\n" KERN_INFO);
 	}
 	if (x % 16)
 		printk("\n");
@@ -338,7 +338,7 @@
 
 	memset(buf, 0, GFS2_FNAMESIZE + 1);
 	memcpy(buf, name, de->de_name_len);
-	printk("  name = %s\n", buf);
+	printk(KERN_INFO "  name = %s\n", buf);
 }
 
 void gfs2_leaf_in(struct gfs2_leaf *lf, char *buf)
@@ -401,7 +401,7 @@
 
 	memset(buf, 0, GFS2_EA_MAX_NAME_LEN + 1);
 	memcpy(buf, name, ea->ea_name_len);
-	printk("  name = %s\n", buf);
+	printk(KERN_INFO "  name = %s\n", buf);
 }
 
 void gfs2_log_header_in(struct gfs2_log_header *lh, char *buf)
diff --git a/fs/gfs2/ops_fstype.c b/fs/gfs2/ops_fstype.c
index 751178a..a85f1a2 100644
--- a/fs/gfs2/ops_fstype.c
+++ b/fs/gfs2/ops_fstype.c
@@ -772,13 +772,13 @@
 
 	sdp = init_sbd(sb);
 	if (!sdp) {
-		printk("GFS2: can't alloc struct gfs2_sbd\n");
+		printk(KERN_WARNING "GFS2: can't alloc struct gfs2_sbd\n");
 		return -ENOMEM;
 	}
 
 	error = gfs2_mount_args(sdp, (char *)data, 0);
 	if (error) {
-		printk("GFS2: can't parse mount arguments\n");
+		printk(KERN_WARNING "GFS2: can't parse mount arguments\n");
 		goto fail;
 	}
 
diff --git a/fs/gfs2/ops_super.c b/fs/gfs2/ops_super.c
index cd45ec9..48a9452 100644
--- a/fs/gfs2/ops_super.c
+++ b/fs/gfs2/ops_super.c
@@ -12,8 +12,8 @@
 #include <linux/spinlock.h>
 #include <linux/completion.h>
 #include <linux/buffer_head.h>
-#include <linux/vmalloc.h>
 #include <linux/statfs.h>
+#include <linux/vmalloc.h>
 #include <linux/seq_file.h>
 #include <linux/mount.h>
 #include <linux/kthread.h>
diff --git a/fs/gfs2/super.c b/fs/gfs2/super.c
index be80771..60e2666 100644
--- a/fs/gfs2/super.c
+++ b/fs/gfs2/super.c
@@ -94,7 +94,7 @@
 	if (sb->sb_header.mh_magic != GFS2_MAGIC ||
 	    sb->sb_header.mh_type != GFS2_METATYPE_SB) {
 		if (!silent)
-			printk("GFS2: not a GFS2 filesystem\n");
+			printk(KERN_WARNING "GFS2: not a GFS2 filesystem\n");
 		return -EINVAL;
 	}
 
@@ -110,11 +110,11 @@
 				break;
 
 		if (!gfs2_old_fs_formats[x]) {
-			printk("GFS2: code version (%u, %u) is incompatible "
+			printk(KERN_WARNING "GFS2: code version (%u, %u) is incompatible "
 			       "with ondisk format (%u, %u)\n",
 			       GFS2_FORMAT_FS, GFS2_FORMAT_MULTI,
 			       sb->sb_fs_format, sb->sb_multihost_format);
-			printk("GFS2: I don't know how to upgrade this FS\n");
+			printk(KERN_WARNING "GFS2: I don't know how to upgrade this FS\n");
 			return -EINVAL;
 		}
 	}
@@ -125,23 +125,23 @@
 				break;
 
 		if (!gfs2_old_multihost_formats[x]) {
-			printk("GFS2: code version (%u, %u) is incompatible "
+			printk(KERN_WARNING "GFS2: code version (%u, %u) is incompatible "
 			       "with ondisk format (%u, %u)\n",
 			       GFS2_FORMAT_FS, GFS2_FORMAT_MULTI,
 			       sb->sb_fs_format, sb->sb_multihost_format);
-			printk("GFS2: I don't know how to upgrade this FS\n");
+			printk(KERN_WARNING "GFS2: I don't know how to upgrade this FS\n");
 			return -EINVAL;
 		}
 	}
 
 	if (!sdp->sd_args.ar_upgrade) {
-		printk("GFS2: code version (%u, %u) is incompatible "
+		printk(KERN_WARNING "GFS2: code version (%u, %u) is incompatible "
 		       "with ondisk format (%u, %u)\n",
 		       GFS2_FORMAT_FS, GFS2_FORMAT_MULTI,
 		       sb->sb_fs_format, sb->sb_multihost_format);
-		printk("GFS2: Use the \"upgrade\" mount option to upgrade "
+		printk(KERN_INFO "GFS2: Use the \"upgrade\" mount option to upgrade "
 		       "the FS\n");
-		printk("GFS2: See the manual for more details\n");
+		printk(KERN_INFO "GFS2: See the manual for more details\n");
 		return -EINVAL;
 	}
 
