linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] OOM: print points as unsigned int
@ 2015-05-28  9:46 Wang Long
  2015-05-28 13:03 ` Michal Hocko
  0 siblings, 1 reply; 2+ messages in thread
From: Wang Long @ 2015-05-28  9:46 UTC (permalink / raw)
  To: akpm, mhocko, rientjes
  Cc: vdavydov, hannes, oleg, kirill.shutemov, linux-mm, linux-kernel,
	wanglong, long.wanglong, peifeiyue

In oom_kill_process(), the variable 'points' is unsigned int.
Print it as such.

Signed-off-by: Wang Long <long.wanglong@huawei.com>
---
 mm/oom_kill.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/mm/oom_kill.c b/mm/oom_kill.c
index 2b665da..056002c 100644
--- a/mm/oom_kill.c
+++ b/mm/oom_kill.c
@@ -528,7 +528,7 @@ void oom_kill_process(struct task_struct *p, gfp_t gfp_mask, int order,
 		dump_header(p, gfp_mask, order, memcg, nodemask);
 
 	task_lock(p);
-	pr_err("%s: Kill process %d (%s) score %d or sacrifice child\n",
+	pr_err("%s: Kill process %d (%s) score %u or sacrifice child\n",
 		message, task_pid_nr(p), p->comm, points);
 	task_unlock(p);
 
-- 
1.8.3.4

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] OOM: print points as unsigned int
  2015-05-28  9:46 [PATCH] OOM: print points as unsigned int Wang Long
@ 2015-05-28 13:03 ` Michal Hocko
  0 siblings, 0 replies; 2+ messages in thread
From: Michal Hocko @ 2015-05-28 13:03 UTC (permalink / raw)
  To: Wang Long
  Cc: akpm, rientjes, vdavydov, hannes, oleg, kirill.shutemov,
	linux-mm, linux-kernel, wanglong, peifeiyue

On Thu 28-05-15 09:46:44, Wang Long wrote:
> In oom_kill_process(), the variable 'points' is unsigned int.
> Print it as such.
> 
> Signed-off-by: Wang Long <long.wanglong@huawei.com>

I do not think this matter much in the real life but there is no reason
to use a wrong format type.

Acked-by: Michal Hocko <mhocko@suse.cz>

Thanks!

> ---
>  mm/oom_kill.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/mm/oom_kill.c b/mm/oom_kill.c
> index 2b665da..056002c 100644
> --- a/mm/oom_kill.c
> +++ b/mm/oom_kill.c
> @@ -528,7 +528,7 @@ void oom_kill_process(struct task_struct *p, gfp_t gfp_mask, int order,
>  		dump_header(p, gfp_mask, order, memcg, nodemask);
>  
>  	task_lock(p);
> -	pr_err("%s: Kill process %d (%s) score %d or sacrifice child\n",
> +	pr_err("%s: Kill process %d (%s) score %u or sacrifice child\n",
>  		message, task_pid_nr(p), p->comm, points);
>  	task_unlock(p);
>  
> -- 
> 1.8.3.4
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/

-- 
Michal Hocko
SUSE Labs

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-05-28 13:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-28  9:46 [PATCH] OOM: print points as unsigned int Wang Long
2015-05-28 13:03 ` Michal Hocko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).