* [PATCH 2/2] mm: Changed pr_warning() to pr_warn()
@ 2014-03-08 3:51 Choi Gi-yong
2014-03-08 4:00 ` Joe Perches
0 siblings, 1 reply; 5+ messages in thread
From: Choi Gi-yong @ 2014-03-08 3:51 UTC (permalink / raw)
To: tj; +Cc: linux-kernel, Choi Gi-yong
Signed-off-by: Choi Gi-yong <yong@gnoy.org>
---
mm/percpu.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/mm/percpu.c b/mm/percpu.c
index 6528ffa..dca284f 100644
--- a/mm/percpu.c
+++ b/mm/percpu.c
@@ -813,7 +813,7 @@ fail_unlock:
fail_unlock_mutex:
mutex_unlock(&pcpu_alloc_mutex);
if (warn_limit) {
- pr_warning("PERCPU: allocation failed, size=%zu align=%zu, "
+ pr_warn("PERCPU: allocation failed, size=%zu align=%zu, "
"%s\n", size, align, err);
dump_stack();
if (!--warn_limit)
@@ -1397,7 +1397,7 @@ static int __init percpu_alloc_setup(char *str)
pcpu_chosen_fc = PCPU_FC_PAGE;
#endif
else
- pr_warning("PERCPU: unknown allocator %s specified\n", str);
+ pr_warn("PERCPU: unknown allocator %s specified\n", str);
return 0;
}
@@ -1690,7 +1690,7 @@ int __init pcpu_embed_first_chunk(size_t reserved_size, size_t dyn_size,
/* warn if maximum distance is further than 75% of vmalloc space */
if (max_distance > VMALLOC_TOTAL * 3 / 4) {
- pr_warning("PERCPU: max_distance=0x%zx too large for vmalloc "
+ pr_warn("PERCPU: max_distance=0x%zx too large for vmalloc "
"space 0x%lx\n", max_distance,
VMALLOC_TOTAL);
#ifdef CONFIG_NEED_PER_CPU_PAGE_FIRST_CHUNK
@@ -1774,7 +1774,7 @@ int __init pcpu_page_first_chunk(size_t reserved_size,
ptr = alloc_fn(cpu, PAGE_SIZE, PAGE_SIZE);
if (!ptr) {
- pr_warning("PERCPU: failed to allocate %s page "
+ pr_warn("PERCPU: failed to allocate %s page "
"for cpu%u\n", psize_str, cpu);
goto enomem;
}
--
1.8.3.2
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 2/2] mm: Changed pr_warning() to pr_warn()
2014-03-08 3:51 [PATCH 2/2] mm: Changed pr_warning() to pr_warn() Choi Gi-yong
@ 2014-03-08 4:00 ` Joe Perches
0 siblings, 0 replies; 5+ messages in thread
From: Joe Perches @ 2014-03-08 4:00 UTC (permalink / raw)
To: Choi Gi-yong; +Cc: tj, linux-kernel
On Sat, 2014-03-08 at 12:51 +0900, Choi Gi-yong wrote:
> diff --git a/mm/percpu.c b/mm/percpu.c
[]
> @@ -813,7 +813,7 @@ fail_unlock:
> fail_unlock_mutex:
> mutex_unlock(&pcpu_alloc_mutex);
> if (warn_limit) {
> - pr_warning("PERCPU: allocation failed, size=%zu align=%zu, "
> + pr_warn("PERCPU: allocation failed, size=%zu align=%zu, "
> "%s\n", size, align, err);
If you're going do to this, please coalesce
the format fragments.
pr_warn("PERCPU: allocation failed, size=%zu align=%zu, %s\n",
size, align, err);
> @@ -1690,7 +1690,7 @@ int __init pcpu_embed_first_chunk(size_t reserved_size, size_t dyn_size,
>
> /* warn if maximum distance is further than 75% of vmalloc space */
> if (max_distance > VMALLOC_TOTAL * 3 / 4) {
> - pr_warning("PERCPU: max_distance=0x%zx too large for vmalloc "
> + pr_warn("PERCPU: max_distance=0x%zx too large for vmalloc "
> "space 0x%lx\n", max_distance,
> VMALLOC_TOTAL);
here too
pr_warn("PERCPU: max_distance=0x%zx too large for vmalloc space 0x%lx\n",
max_distance, VMALLOC_TOTAL);
> @@ -1774,7 +1774,7 @@ int __init pcpu_page_first_chunk(size_t reserved_size,
>
> ptr = alloc_fn(cpu, PAGE_SIZE, PAGE_SIZE);
> if (!ptr) {
> - pr_warning("PERCPU: failed to allocate %s page "
> + pr_warn("PERCPU: failed to allocate %s page "
> "for cpu%u\n", psize_str, cpu);
etc.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 2/2] mm: Changed pr_warning() to pr_warn()
2014-03-09 22:15 ` Joe Perches
@ 2014-03-13 0:33 ` 최(Choi)기용(Gi-yong)
0 siblings, 0 replies; 5+ messages in thread
From: 최(Choi)기용(Gi-yong) @ 2014-03-13 0:33 UTC (permalink / raw)
To: Joe Perches; +Cc: tj, linux-kernel
Okay, i'll practice on file in drivers/staging.
Thank you for your help :)
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 2/2] mm: Changed pr_warning() to pr_warn()
2014-03-09 8:15 Choi Gi-yong
@ 2014-03-09 22:15 ` Joe Perches
2014-03-13 0:33 ` 최(Choi)기용(Gi-yong)
0 siblings, 1 reply; 5+ messages in thread
From: Joe Perches @ 2014-03-09 22:15 UTC (permalink / raw)
To: Choi Gi-yong; +Cc: tj, linux-kernel
On Sun, 2014-03-09 at 17:15 +0900, Choi Gi-yong wrote:
> Signed-off-by: Choi Gi-yong <yong@gnoy.org>
[]
> diff --git a/mm/percpu.c b/mm/percpu.c
> @@ -812,8 +812,8 @@ fail_unlock:
> fail_unlock_mutex:
> mutex_unlock(&pcpu_alloc_mutex);
> if (warn_limit) {
> - pr_warn("PERCPU: allocation failed, size=%zu align=%zu, "
> - "%s\n", size, align, err);
> + pr_warn("PERCPU: allocation failed, size=%zu align=%zu, %s\n",
> + size, align, err);
The second line should use 3 tabs for indentation.
pr_warn("PERCPU: allocation failed, size=%zu align=%zu, %s\n",
size, align, err);
If you want to become familiar with kernel style
and patching something, please practice on some
files in drivers/staging.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH 2/2] mm: Changed pr_warning() to pr_warn()
@ 2014-03-09 8:15 Choi Gi-yong
2014-03-09 22:15 ` Joe Perches
0 siblings, 1 reply; 5+ messages in thread
From: Choi Gi-yong @ 2014-03-09 8:15 UTC (permalink / raw)
To: joe; +Cc: tj, linux-kernel, Choi Gi-yong
Signed-off-by: Choi Gi-yong <yong@gnoy.org>
---
mm/percpu.c | 13 ++++++-------
1 file changed, 6 insertions(+), 7 deletions(-)
diff --git a/mm/percpu.c b/mm/percpu.c
index ff6cce2..061f312 100644
--- a/mm/percpu.c
+++ b/mm/percpu.c
@@ -812,8 +812,8 @@ fail_unlock:
fail_unlock_mutex:
mutex_unlock(&pcpu_alloc_mutex);
if (warn_limit) {
- pr_warn("PERCPU: allocation failed, size=%zu align=%zu, "
- "%s\n", size, align, err);
+ pr_warn("PERCPU: allocation failed, size=%zu align=%zu, %s\n",
+ size, align, err);
dump_stack();
if (!--warn_limit)
pr_info("PERCPU: limit reached, disable warning\n");
@@ -1689,9 +1689,8 @@ int __init pcpu_embed_first_chunk(size_t reserved_size, size_t dyn_size,
/* warn if maximum distance is further than 75% of vmalloc space */
if (max_distance > VMALLOC_TOTAL * 3 / 4) {
- pr_warn("PERCPU: max_distance=0x%zx too large for vmalloc "
- "space 0x%lx\n", max_distance,
- VMALLOC_TOTAL);
+ pr_warn("PERCPU: max_distance=0x%zx too large for vmalloc space 0x%lx\n",
+ max_distance, VMALLOC_TOTAL);
#ifdef CONFIG_NEED_PER_CPU_PAGE_FIRST_CHUNK
/* and fail if we have fallback */
rc = -EINVAL;
@@ -1773,8 +1772,8 @@ int __init pcpu_page_first_chunk(size_t reserved_size,
ptr = alloc_fn(cpu, PAGE_SIZE, PAGE_SIZE);
if (!ptr) {
- pr_warn("PERCPU: failed to allocate %s page "
- "for cpu%u\n", psize_str, cpu);
+ pr_warn("PERCPU: failed to allocate %s page for cpu%u\n",
+ psize_str, cpu);
goto enomem;
}
/* kmemleak tracks the percpu allocations separately */
--
1.8.3.2
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2014-03-13 0:33 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-03-08 3:51 [PATCH 2/2] mm: Changed pr_warning() to pr_warn() Choi Gi-yong
2014-03-08 4:00 ` Joe Perches
2014-03-09 8:15 Choi Gi-yong
2014-03-09 22:15 ` Joe Perches
2014-03-13 0:33 ` 최(Choi)기용(Gi-yong)
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®