[Soekris] net4801 and linux
Michael Schulze
fry26 at genion.de
Fri Aug 1 21:27:05 UTC 2003
Am Freitag, 1. August 2003 22:45 schrieben Sie:
> In message: <200308011857.13120.fry26 at genion.de>
>
> Michael Schulze <fry26 at genion.de> writes:
> : That seems to work - thanks a lot.
>
> + if (hdr_type & (PCI_HEADER_TYPE_NORMAL |
> + PCI_HEADER_TYPE_CARDBUS | PCI_HEADER_TYPE_BRIDGE))
> + continue;
> +
> temp->hdr_type = hdr_type & 0x7f;
>
> This only works because there are no other bridges. This is a
well, yes. It bit less wrong would have been
(hdr_type & ~(PCI_HEADER....))
I suppose.
> complicated way of writing != 0. The header types are not bits.
OK, I mistakenly assumed they are.
> A more correct patch would be:
>
> + if (hdr_type & 0x7f > PCI_HEADER_TYPE_CARDBUS)
> + continue;
yep. Thanks
Michael
More information about the Soekris-tech
mailing list