* [PATCH] x86/pci: remove early PCI pr_debug statements
@ 2009-11-16 21:21 Alex Chiang
2009-11-24 21:52 ` Jesse Barnes
0 siblings, 1 reply; 2+ messages in thread
From: Alex Chiang @ 2009-11-16 21:21 UTC (permalink / raw)
To: Jesse Barnes; +Cc: linux-pci, linux-kernel
commit db635adc turned -DDEBUG for x86/pci on when CONFIG_PCI_DEBUG
is set. In general, I agree with that change.
However, it exposes a bunch of very low level PCI debugging in the
early x86 path, such as:
0 reading 2 from a: ffff
1 reading 2 from a: ffff
2 reading 2 from a: ffff
3 reading 2 from a: 300
3 reading 2 from 0: 1002
3 reading 2 from 2: 515e
These statements add a lot of noise to the boot and aren't likely to
be necessary even when handling random upstream bug reports.
[In contrast, statements such as these:
pci 0000:02:04.0: found [14e4:164a] class 000200 header type 00
pci 0000:02:04.0: reg 10: [mem 0xf8000000-0xf9ffffff 64bit]
pci 0000:02:04.0: reg 30: [mem 0x00000000-0x0001ffff pref]
are indeed useful when remote debugging users' machines]
Remove the noisy printks and save electrons everywhere.
Cc: Bjorn Helgaas <bjorn.helgaas@hp.com>
Cc: Yinghai Lu <yinghai@kernel.org>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Alex Chiang <achiang@hp.com>
---
diff --git a/arch/x86/pci/early.c b/arch/x86/pci/early.c
index aaf26ae..d1067d5 100644
--- a/arch/x86/pci/early.c
+++ b/arch/x86/pci/early.c
@@ -12,8 +12,6 @@ u32 read_pci_config(u8 bus, u8 slot, u8 func, u8 offset)
u32 v;
outl(0x80000000 | (bus<<16) | (slot<<11) | (func<<8) | offset, 0xcf8);
v = inl(0xcfc);
- if (v != 0xffffffff)
- pr_debug("%x reading 4 from %x: %x\n", slot, offset, v);
return v;
}
@@ -22,7 +20,6 @@ u8 read_pci_config_byte(u8 bus, u8 slot, u8 func, u8 offset)
u8 v;
outl(0x80000000 | (bus<<16) | (slot<<11) | (func<<8) | offset, 0xcf8);
v = inb(0xcfc + (offset&3));
- pr_debug("%x reading 1 from %x: %x\n", slot, offset, v);
return v;
}
@@ -31,28 +28,24 @@ u16 read_pci_config_16(u8 bus, u8 slot, u8 func, u8 offset)
u16 v;
outl(0x80000000 | (bus<<16) | (slot<<11) | (func<<8) | offset, 0xcf8);
v = inw(0xcfc + (offset&2));
- pr_debug("%x reading 2 from %x: %x\n", slot, offset, v);
return v;
}
void write_pci_config(u8 bus, u8 slot, u8 func, u8 offset,
u32 val)
{
- pr_debug("%x writing to %x: %x\n", slot, offset, val);
outl(0x80000000 | (bus<<16) | (slot<<11) | (func<<8) | offset, 0xcf8);
outl(val, 0xcfc);
}
void write_pci_config_byte(u8 bus, u8 slot, u8 func, u8 offset, u8 val)
{
- pr_debug("%x writing to %x: %x\n", slot, offset, val);
outl(0x80000000 | (bus<<16) | (slot<<11) | (func<<8) | offset, 0xcf8);
outb(val, 0xcfc + (offset&3));
}
void write_pci_config_16(u8 bus, u8 slot, u8 func, u8 offset, u16 val)
{
- pr_debug("%x writing to %x: %x\n", slot, offset, val);
outl(0x80000000 | (bus<<16) | (slot<<11) | (func<<8) | offset, 0xcf8);
outw(val, 0xcfc + (offset&2));
}
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] x86/pci: remove early PCI pr_debug statements
2009-11-16 21:21 [PATCH] x86/pci: remove early PCI pr_debug statements Alex Chiang
@ 2009-11-24 21:52 ` Jesse Barnes
0 siblings, 0 replies; 2+ messages in thread
From: Jesse Barnes @ 2009-11-24 21:52 UTC (permalink / raw)
To: Alex Chiang; +Cc: linux-pci, linux-kernel
On Mon, 16 Nov 2009 14:21:13 -0700
Alex Chiang <achiang@hp.com> wrote:
> commit db635adc turned -DDEBUG for x86/pci on when CONFIG_PCI_DEBUG
> is set. In general, I agree with that change.
>
> However, it exposes a bunch of very low level PCI debugging in the
> early x86 path, such as:
>
> 0 reading 2 from a: ffff
> 1 reading 2 from a: ffff
> 2 reading 2 from a: ffff
> 3 reading 2 from a: 300
> 3 reading 2 from 0: 1002
> 3 reading 2 from 2: 515e
>
> These statements add a lot of noise to the boot and aren't likely to
> be necessary even when handling random upstream bug reports.
>
> [In contrast, statements such as these:
>
> pci 0000:02:04.0: found [14e4:164a] class 000200 header type
> 00 pci 0000:02:04.0: reg 10: [mem 0xf8000000-0xf9ffffff 64bit]
> pci 0000:02:04.0: reg 30: [mem 0x00000000-0x0001ffff pref]
>
> are indeed useful when remote debugging users' machines]
>
> Remove the noisy printks and save electrons everywhere.
Applied, thanks.
--
Jesse Barnes, Intel Open Source Technology Center
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-11-24 21:52 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-11-16 21:21 [PATCH] x86/pci: remove early PCI pr_debug statements Alex Chiang
2009-11-24 21:52 ` Jesse Barnes
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox