[PATCH][resent] drivers/sound/ad1848.c fixes "cast to pointer from integer of different size"-warnin

Matthias Welwarsky (matze@stud.fbi.fh-darmstadt.de)
Sun, 15 Nov 1998 22:04:27 +0100


This is a multi-part message in MIME format.
--------------0A67F3C9A2DC445E859D65BE
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Hi Alan and list,

this fixes a compiler warning (and a possible bug) in ad1848.c by
changing two variables from int to long, when compiled on architectures
where sizeof(void *) != sizeof(int). The patch is relative 2.1.129-pre1.
Don't know if this is really a problem in this context but I learned to
be picky about this special warning since I own that Alpha ;-)

Gruss,
Matthias

PS: please disregard the first mail, forgot the attachement, stupid me
:-(
--------------0A67F3C9A2DC445E859D65BE
Content-Type: text/plain; charset=us-ascii; name="drivers_sound_ad1848_c-2.1.129pre1-1.patch"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="drivers_sound_ad1848_c-2.1.129pre1-1.patch"

--- linux/drivers/sound/ad1848.c.~1~ Sun Nov 15 19:39:00 1998
+++ linux/drivers/sound/ad1848.c Sun Nov 15 20:12:31 1998
@@ -78,7 +78,7 @@
int supported_rec_devices, orig_rec_devices;
int *levels;
short mixer_reroute[32];
- int dev_no;
+ long dev_no;
volatile unsigned long timer_ticks;
int timer_running;
int irq_ok;
@@ -1721,7 +1721,7 @@
*/


- int my_dev;
+ long my_dev;
char dev_name[100];
int e;

@@ -1958,12 +1958,12 @@
{
unsigned char status;
ad1848_info *devc;
- int dev;
+ long dev;
int alt_stat = 0xff;
unsigned char c930_stat = 0;
int cnt = 0;

- dev = (int)dev_id;
+ dev = (long)dev_id;
devc = (ad1848_info *) audio_devs[dev]->devc;

interrupt_again: /* Jump back here if int status doesn't reset */

--------------0A67F3C9A2DC445E859D65BE--

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