[2.4 patch] fix four OSS u16 comparisons

Adrian Bunk (bunk@fs.tum.de)
Sun, 22 Jun 2003 02:13:26 +0200


The patch below fixees four OSS drivers that compared an u16 with
0xFFFFFF ...

cu
Adrian

--- linux-2.4.22-pre1-full/drivers/sound/ymfpci.c.old 2003-06-22 02:07:21.000000000 +0200
+++ linux-2.4.22-pre1-full/drivers/sound/ymfpci.c 2003-06-22 02:07:44.000000000 +0200
@@ -2460,7 +2460,7 @@
}

eid = ymfpci_codec_read(codec, AC97_EXTENDED_ID);
- if (eid==0xFFFFFF) {
+ if (eid==0xFFFF) {
printk(KERN_WARNING "ymfpci: no codec attached ?\n");
goto out_kfree;
}
--- linux-2.4.22-pre1-full/drivers/sound/i810_audio.c.old 2003-06-22 02:08:17.000000000 +0200
+++ linux-2.4.22-pre1-full/drivers/sound/i810_audio.c 2003-06-22 02:08:34.000000000 +0200
@@ -2921,7 +2921,7 @@
/* Don't attempt to get eid until powerup is complete */
eid = i810_ac97_get(codec, AC97_EXTENDED_ID);

- if(eid==0xFFFFFF)
+ if(eid==0xFFFF)
{
printk(KERN_WARNING "i810_audio: no codec attached ?\n");
kfree(codec);
--- linux-2.4.22-pre1-full/drivers/sound/cs46xx.c.old 2003-06-22 02:09:03.000000000 +0200
+++ linux-2.4.22-pre1-full/drivers/sound/cs46xx.c 2003-06-22 02:09:18.000000000 +0200
@@ -4260,7 +4260,7 @@

eid = cs_ac97_get(codec, AC97_EXTENDED_ID);

- if(eid==0xFFFFFF)
+ if(eid==0xFFFF)
{
printk(KERN_WARNING "cs46xx: codec %d not present\n",num_ac97);
kfree(codec);
--- linux-2.4.22-pre1-full/drivers/sound/ali5455.c.old 2003-06-22 02:11:07.000000000 +0200
+++ linux-2.4.22-pre1-full/drivers/sound/ali5455.c 2003-06-22 02:11:26.000000000 +0200
@@ -3277,7 +3277,7 @@
card->ac97_status = 0;
/* Don't attempt to get eid until powerup is complete */
eid = ali_ac97_get(codec, AC97_EXTENDED_ID);
- if (eid == 0xFFFFFF) {
+ if (eid == 0xFFFF) {
printk(KERN_ERR "ali_audio: no codec attached ?\n");
kfree(codec);
break;
-
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/