Skip to content

Commit

Permalink
IO resources: fix/remove printk
Browse files Browse the repository at this point in the history
Andrew Morton noticed that the printk in kernel/resource.c was buggy:

| start and end have type resource_size_t.  Such types CANNOT be printed
| unless cast to a known type.
|
| Because there is a %s following an incorrect %lld, the above code will
| crash the machine.

... and it's probably quite unneeded as well, so remove it.

Reported-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
  • Loading branch information
Ingo Molnar committed Sep 4, 2008
1 parent 268364a commit 1cf44ba
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions kernel/resource.c
Original file line number Diff line number Diff line change
Expand Up @@ -549,13 +549,9 @@ static void __init __reserve_region_with_split(struct resource *root,
}

if (!res) {
printk(KERN_DEBUG " __reserve_region_with_split: (%s) [%llx, %llx], res: (%s) [%llx, %llx]\n",
conflict->name, conflict->start, conflict->end,
name, start, end);

/* failed, split and try again */

/* conflict coverred whole area */
/* conflict covered whole area */
if (conflict->start <= start && conflict->end >= end)
return;

Expand Down

0 comments on commit 1cf44ba

Please sign in to comment.