diff options
author | Robert Nagy <robert@cvs.openbsd.org> | 2005-06-23 14:57:49 +0000 |
---|---|---|
committer | Robert Nagy <robert@cvs.openbsd.org> | 2005-06-23 14:57:49 +0000 |
commit | cb5e0bad301f342ed829ba38117100ba1f80305d (patch) | |
tree | 1bd5bd6fc8fdb8e5e02a56a8d7ae97227ed736a2 /sys/dev/pci/bktr/bktr_core.c | |
parent | c9a278db00350903eb2712d244541e77ca5c7d8c (diff) |
Use proper type for 32 bit entity. s/long/int
This is needed for bktr(4) to work on sparc64.
testing and ok by mickey and Jacob Meuser <jakemsr@jakemsr.com>
Diffstat (limited to 'sys/dev/pci/bktr/bktr_core.c')
-rw-r--r-- | sys/dev/pci/bktr/bktr_core.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/sys/dev/pci/bktr/bktr_core.c b/sys/dev/pci/bktr/bktr_core.c index 9f95956de7e..27d2b1ddb29 100644 --- a/sys/dev/pci/bktr/bktr_core.c +++ b/sys/dev/pci/bktr/bktr_core.c @@ -1,4 +1,4 @@ -/* $OpenBSD: bktr_core.c,v 1.16 2005/06/22 12:26:32 mickey Exp $ */ +/* $OpenBSD: bktr_core.c,v 1.17 2005/06/23 14:57:48 robert Exp $ */ /* $FreeBSD: src/sys/dev/bktr/bktr_core.c,v 1.114 2000/10/31 13:09:56 roger Exp $ */ /* @@ -1346,7 +1346,7 @@ video_ioctl( bktr_ptr_t bktr, int unit, ioctl_cmd_t cmd, caddr_t arg, struct pro break; case BT848SFMT: /* set input format */ - temp = *(unsigned long *)arg & BT848_IFORM_FORMAT; + temp = *(unsigned int *)arg & BT848_IFORM_FORMAT; temp_iform = INB(bktr, BKTR_IFORM); temp_iform &= ~BT848_IFORM_FORMAT; temp_iform &= ~BT848_IFORM_XTSEL; @@ -1386,7 +1386,7 @@ video_ioctl( bktr_ptr_t bktr, int unit, ioctl_cmd_t cmd, caddr_t arg, struct pro temp_iform = INB(bktr, BKTR_IFORM); temp_iform &= ~BT848_IFORM_FORMAT; temp_iform &= ~BT848_IFORM_XTSEL; - switch(*(unsigned long *)arg & METEOR_FORM_MASK ) { + switch(*(unsigned int *)arg & METEOR_FORM_MASK ) { case 0: /* default */ case METEOR_FMT_NTSC: bktr->flags = (bktr->flags & ~METEOR_FORM_MASK) | @@ -1906,12 +1906,12 @@ tuner_ioctl( bktr_ptr_t bktr, int unit, ioctl_cmd_t cmd, caddr_t arg, struct pro case TVTUNER_SETCHNL: temp_mute( bktr, TRUE ); - temp = tv_channel( bktr, (int)*(unsigned long *)arg ); + temp = tv_channel( bktr, (int)*(unsigned int *)arg ); if ( temp < 0 ) { temp_mute( bktr, FALSE ); return( EINVAL ); } - *(unsigned long *)arg = temp; + *(unsigned int *)arg = temp; /* after every channel change, we must restart the MSP34xx */ /* audio chip to reselect NICAM STEREO or MONO audio */ @@ -1926,34 +1926,34 @@ tuner_ioctl( bktr_ptr_t bktr, int unit, ioctl_cmd_t cmd, caddr_t arg, struct pro break; case TVTUNER_GETCHNL: - *(unsigned long *)arg = bktr->tuner.channel; + *(unsigned int *)arg = bktr->tuner.channel; break; case TVTUNER_SETTYPE: - temp = *(unsigned long *)arg; + temp = *(unsigned int *)arg; if ( (temp < CHNLSET_MIN) || (temp > CHNLSET_MAX) ) return( EINVAL ); bktr->tuner.chnlset = temp; break; case TVTUNER_GETTYPE: - *(unsigned long *)arg = bktr->tuner.chnlset; + *(unsigned int *)arg = bktr->tuner.chnlset; break; case TVTUNER_GETSTATUS: temp = get_tuner_status( bktr ); - *(unsigned long *)arg = temp & 0xff; + *(unsigned int *)arg = temp & 0xff; break; case TVTUNER_SETFREQ: temp_mute( bktr, TRUE ); - temp = tv_freq( bktr, (int)*(unsigned long *)arg, TV_FREQUENCY); + temp = tv_freq( bktr, (int)*(unsigned int *)arg, TV_FREQUENCY); temp_mute( bktr, FALSE ); if ( temp < 0 ) { temp_mute( bktr, FALSE ); return( EINVAL ); } - *(unsigned long *)arg = temp; + *(unsigned int *)arg = temp; /* after every channel change, we must restart the MSP34xx */ /* audio chip to reselect NICAM STEREO or MONO audio */ @@ -1968,7 +1968,7 @@ tuner_ioctl( bktr_ptr_t bktr, int unit, ioctl_cmd_t cmd, caddr_t arg, struct pro break; case TVTUNER_GETFREQ: - *(unsigned long *)arg = bktr->tuner.frequency; + *(unsigned int *)arg = bktr->tuner.frequency; break; case TVTUNER_GETCHNLSET: @@ -2309,7 +2309,7 @@ bktr_common_ioctl( bktr_ptr_t bktr, ioctl_cmd_t cmd, caddr_t arg ) /* Unfortunatly Meteor driver codes DEV_RCA as DEV_0, so we */ /* stick with this system in our Meteor Emulation */ - switch(*(unsigned long *)arg & METEOR_DEV_MASK) { + switch(*(unsigned int *)arg & METEOR_DEV_MASK) { /* this is the RCA video input */ case 0: /* default */ |