All of lore.kernel.org
 help / color / mirror / Atom feed
From: "slackfan@users.sourceforge.net" <slackfan@users.sourceforge.net>
To: kernel-janitors@vger.kernel.org
Subject: [KJ] [PATCH] arch/i386/kernel/process.c
Date: Fri, 21 Oct 2005 18:58:23 +0000	[thread overview]
Message-ID: <4359539D.2060608@users.sourceforge.net> (raw)

printk() calls should include appropriate KERN_* constant

Signed-off-by: Anton Brondz <anton.slack@tele2.no>

*--- linux-2.6.14-rc4.orig/arch/i386/kernel/process.c	2005-10-11 01:19:19.000000000 +0000*
*+++ linux-2.6.14-rc4/arch/i386/kernel/process.c	2005-10-20 22:42:41.000000000 +0000*
@@ -259,13 +259,13 @@ static void mwait_idle(void)
 void __devinit select_idle_routine(const struct cpuinfo_x86 *c)
 {
 	if (cpu_has(c, X86_FEATURE_MWAIT)) {
-		printk("monitor/mwait feature present.\n");
+		printk(KERN_INFO "monitor/mwait feature present.\n");
 		/*
 		 * Skip, if setup has overridden idle.
 		 * One CPU supports mwait => All CPUs supports mwait
 		 */
 		if (!pm_idle) {
-			printk("using mwait in idle threads.\n");
+			printk(KERN_INFO "using mwait in idle threads.\n");
 			pm_idle = mwait_idle;
 		}
 	}
@@ -274,14 +274,14 @@ void __devinit select_idle_routine(const
 static int __init idle_setup (char *str)
 {
 	if (!strncmp(str, "poll", 4)) {
-		printk("using polling idle threads.\n");
+		printk(KERN_DEBUG "using polling idle threads.\n");
 		pm_idle = poll_idle;
 #ifdef CONFIG_X86_SMP
 		if (smp_num_siblings > 1)
-			printk("WARNING: polling idle and HT enabled, performance may degrade.\n");
+			printk(KERN_NOTICE "WARNING: polling idle and HT enabled, performance may degrade.\n");
 #endif
 	} else if (!strncmp(str, "halt", 4)) {
-		printk("using halt in idle threads.\n");
+		printk(KERN_INFO "using halt in idle threads.\n");
 		pm_idle = default_idle;
 	}
 
@@ -296,19 +296,19 @@ void show_regs(struct pt_regs * regs)
 	unsigned long cr0 = 0L, cr2 = 0L, cr3 = 0L, cr4 = 0L;
 
 	printk("\n");
-	printk("Pid: %d, comm: %20s\n", current->pid, current->comm);
-	printk("EIP: %04x:[<%08lx>] CPU: %d\n",0xffff & regs->xcs,regs->eip, smp_processor_id());
-	print_symbol("EIP is at %s\n", regs->eip);
+	printk(KERN_DEBUG "Pid: %d, comm: %20s\n", current->pid, current->comm);
+	printk(KERN_DEBUG "EIP: %04x:[<%08lx>] CPU: %d\n",0xffff & regs->xcs,regs->eip, smp_processor_id());
+	print_symbol(KERN_DEBUG "EIP is at %s\n", regs->eip);
 
 	if (user_mode(regs))
-		printk(" ESP: %04x:%08lx",0xffff & regs->xss,regs->esp);
-	printk(" EFLAGS: %08lx    %s  (%s)\n",
+		printk(KERN_DEBUG " ESP: %04x:%08lx",0xffff & regs->xss,regs->esp);
+	printk(KERN_DEBUG " EFLAGS: %08lx    %s  (%s)\n",
 	       regs->eflags, print_tainted(), system_utsname.release);
-	printk("EAX: %08lx EBX: %08lx ECX: %08lx EDX: %08lx\n",
+	printk(KERN_DEBUG "EAX: %08lx EBX: %08lx ECX: %08lx EDX: %08lx\n",
 		regs->eax,regs->ebx,regs->ecx,regs->edx);
-	printk("ESI: %08lx EDI: %08lx EBP: %08lx",
+	printk(KERN_DEBUG "ESI: %08lx EDI: %08lx EBP: %08lx",
 		regs->esi, regs->edi, regs->ebp);
-	printk(" DS: %04x ES: %04x\n",
+	printk(KERN_DEBUG " DS: %04x ES: %04x\n",
 		0xffff & regs->xds,0xffff & regs->xes);
 
 	cr0 = read_cr0();
@@ -317,7 +317,7 @@ void show_regs(struct pt_regs * regs)
 	if (current_cpu_data.x86 > 4) {
 		cr4 = read_cr4();
 	}
-	printk("CR0: %08lx CR2: %08lx CR3: %08lx CR4: %08lx\n", cr0, cr2, cr3, cr4);
+	printk(KERN_DEBUG "CR0: %08lx CR2: %08lx CR3: %08lx CR4: %08lx\n", cr0, cr2, cr3, cr4);
 	show_trace(NULL, &regs->esp);
 }
 
@@ -420,7 +420,7 @@ void release_thread(struct task_struct *
 	if (dead_task->mm) {
 		// temporary debugging check
 		if (dead_task->mm->context.size) {
-			printk("WARNING: dead process %8s still has LDT? <%p/%d>\n",
+			printk(KERN_WARNING "WARNING: dead process %8s still has LDT? <%p/%d>\n",
 					dead_task->comm,
 					dead_task->mm->context.ldt,
 					dead_task->mm->context.size);


_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.osdl.org
https://lists.osdl.org/mailman/listinfo/kernel-janitors

             reply	other threads:[~2005-10-21 18:58 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-10-21 18:58 slackfan [this message]
2005-10-24 19:38 ` [KJ] [PATCH] arch/i386/kernel/process.c Alexey Dobriyan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4359539D.2060608@users.sourceforge.net \
    --to=slackfan@users.sourceforge.net \
    --cc=kernel-janitors@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.