Re: [PATCH] PNP: have quirk_system_pci_resources() include io resources.
From: Rene Herman
Date: Wed Jun 25 2008 - 18:16:58 EST
This is a multi-part message in MIME format.On 25-06-08 23:46, Rene Herman wrote:
On 25-06-08 23:16, Andrew Morton wrote:
On Wed, 25 Jun 2008 19:58:20 +0200
Rene Herman <rene.herman@xxxxxxxxxxxx> wrote:
+ unsigned int type;
+
+ type = pci_resource_flags(pdev, i) &
+ (IORESOURCE_IO | IORESOURCE_MEM);
pci_resource_flags() returns an unsigned long.
But I think you're right and resource.flags is wrong. Because there's
no way in which we'll ever be able to use bits 32-63 of that field
anyway.
I suppose that Someone(tm) should convert resource.flags to a u32 or
something. Minor issue.
Yes, did notice but pnp_get_resource() then takes those same flags as an
unsigned int -- had to pick one or the other and "the smallest one" then
seemed best...
semi-arguably, the pnp_get_resource() is simply wrong though, so maybe
this patch. After this, the quirks one should indeed be an unsigned long
also. Bjorn?
Rene.