Re: via82xx.c vs. sonypi.c i/o region conflict on vaio

From: Jeff Garzik
Date: Wed Jul 14 2004 - 14:34:23 EST


Greg Ingram wrote:
I modified the sound driver to grab only 128 ports instead of 256 and the
driver works fine on this hardware. In 2.6.7, it's line 2049 or so of
sound/pci/via82xx.c:

old: if ((chip->res_port = request_region(chip->port, 256, card->driver)) == NULL) {
new: if ((chip->res_port = request_region(chip->port, 256, card->driver)) == NULL) {


I don't see any difference between these two lines.

Regardless, I see two bugs:

1) Hardcoding 256 for resource size. Should be using pci_resource_len()

2) via82xx sound driver should be using pci_request_regions() and pci_release_regions(), not request_region. Doing this eliminates issue #1.

Jeff



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/