lkml.org 
[lkml]   [1998]   [Nov]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH][resent] drivers/sound/ad1848.c fixes "cast to pointer from integer of different size"-warning
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
:-(--- 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 */
\
 
 \ /
  Last update: 2005-03-22 13:45    [W:0.043 / U:0.124 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site