lkml.org 
[lkml]   [2003]   [Feb]   [3]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateMon, 3 Feb 2003 10:27:45 +0100 (CET)
FromJaroslav Kysela <>
SubjectRe: [PATCH][RFC] Various Fixes and Improved Error Checking (3/4)
On Sun, 2 Feb 2003, Adam Belay wrote:

> -	for (tmp = 0; tmp < 8 && pnp_port_valid(dev, tmp); tmp++)
> -		isapnp_write_word(ISAPNP_CFG_PORT+(tmp<<1), pnp_port_start(dev, tmp));
> -	for (tmp = 0; tmp < 2 && pnp_irq_valid(dev, tmp); tmp++) {
> -		int irq = pnp_irq(dev, tmp);
> +	for (tmp = 0; tmp < 8 && res->port_resource[tmp].flags & IORESOURCE_IO; tmp++)
> +		isapnp_write_word(ISAPNP_CFG_PORT+(tmp<<1), res->port_resource[tmp].start);
> +	for (tmp = 0; tmp < 2 && res->irq_resource[tmp].flags & IORESOURCE_IRQ; tmp++) {
> +		int irq = res->irq_resource[tmp].start;

Why you remove pnp_*_valid() checks? They are more robust. There is also 
check for UNSET flag.

						Jaroslav

-----
Jaroslav Kysela <perex@suse.cz>
Linux Kernel Sound Maintainer
ALSA Project, SuSE Labs
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 12:32    [from the cache]
©2003-2008