diff options
author | bde <bde@FreeBSD.org> | 1996-08-31 14:48:13 +0000 |
---|---|---|
committer | bde <bde@FreeBSD.org> | 1996-08-31 14:48:13 +0000 |
commit | 7d4c1814f6c8b48aaba422848781244a3a8e1685 (patch) | |
tree | d30aec0f7e14e7c815c7a2ac90c600b28f51abf5 /sys/i386/isa | |
parent | f8b5cfc537cc8181d579a4fd086b618c24806f74 (diff) | |
download | FreeBSD-src-7d4c1814f6c8b48aaba422848781244a3a8e1685.zip FreeBSD-src-7d4c1814f6c8b48aaba422848781244a3a8e1685.tar.gz |
Don't depend in the kernel on the gcc feature of doing arithmetic on
pointers of type `void *'. Warn about this in future.
Diffstat (limited to 'sys/i386/isa')
-rw-r--r-- | sys/i386/isa/if_cx.c | 2 | ||||
-rw-r--r-- | sys/i386/isa/istallion.c | 18 | ||||
-rw-r--r-- | sys/i386/isa/wt.c | 4 |
3 files changed, 12 insertions, 12 deletions
diff --git a/sys/i386/isa/if_cx.c b/sys/i386/isa/if_cx.c index c1114c7..0cbc959 100644 --- a/sys/i386/isa/if_cx.c +++ b/sys/i386/isa/if_cx.c @@ -176,7 +176,7 @@ static struct mbuf *makembuf (void *buf, unsigned len) bcopy (buf, mtod (p, caddr_t) + p->m_len, n); p->m_len += n; - buf += n; + buf = (char *)buf + n; len -= n; } return (m); diff --git a/sys/i386/isa/istallion.c b/sys/i386/isa/istallion.c index 88fd624..7181445 100644 --- a/sys/i386/isa/istallion.c +++ b/sys/i386/isa/istallion.c @@ -33,7 +33,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: istallion.c,v 1.3 1996/06/12 04:26:35 gpalmer Exp $ + * $Id: istallion.c,v 1.4 1996/06/18 01:22:25 bde Exp $ */ /*****************************************************************************/ @@ -2631,7 +2631,7 @@ static char *stli_ecpgetmemptr(stlibrd_t *brdp, unsigned long offset, int line) ptr = 0; val = 0; } else { - ptr = brdp->vaddr + (offset % ECP_ATPAGESIZE); + ptr = (char *) brdp->vaddr + (offset % ECP_ATPAGESIZE); val = (unsigned char) (offset / ECP_ATPAGESIZE); } outb((brdp->iobase + ECP_ATMEMPR), val); @@ -2721,7 +2721,7 @@ static char *stli_ecpeigetmemptr(stlibrd_t *brdp, unsigned long offset, int line ptr = 0; val = 0; } else { - ptr = brdp->vaddr + (offset % ECP_EIPAGESIZE); + ptr = (char *) brdp->vaddr + (offset % ECP_EIPAGESIZE); if (offset < ECP_EIPAGESIZE) val = ECP_EIENABLE; else @@ -2773,7 +2773,7 @@ static char *stli_ecpmcgetmemptr(stlibrd_t *brdp, unsigned long offset, int line ptr = 0; val = 0; } else { - ptr = brdp->vaddr + (offset % ECP_MCPAGESIZE); + ptr = (char *) brdp->vaddr + (offset % ECP_MCPAGESIZE); val = ((unsigned char) (offset / ECP_MCPAGESIZE)) | ECP_MCENABLE; } outb((brdp->iobase + ECP_MCCONFR), val); @@ -2854,7 +2854,7 @@ static char *stli_onbgetmemptr(stlibrd_t *brdp, unsigned long offset, int line) __LINE__, brdp->brdnr); ptr = 0; } else { - ptr = brdp->vaddr + (offset % ONB_ATPAGESIZE); + ptr = (char *) brdp->vaddr + (offset % ONB_ATPAGESIZE); } return(ptr); } @@ -2945,7 +2945,7 @@ static char *stli_onbegetmemptr(stlibrd_t *brdp, unsigned long offset, int line) ptr = 0; val = 0; } else { - ptr = brdp->vaddr + (offset % ONB_EIPAGESIZE); + ptr = (char *) brdp->vaddr + (offset % ONB_EIPAGESIZE); if (offset < ONB_EIPAGESIZE) val = ONB_EIENABLE; else @@ -3014,7 +3014,7 @@ static char *stli_bbygetmemptr(stlibrd_t *brdp, unsigned long offset, int line) ptr = 0; val = 0; } else { - ptr = brdp->vaddr + (offset % BBY_PAGESIZE); + ptr = (char *) brdp->vaddr + (offset % BBY_PAGESIZE); val = (unsigned char) (offset / BBY_PAGESIZE); } outb((brdp->iobase + BBY_ATCONFR), val); @@ -3074,7 +3074,7 @@ static char *stli_stalgetmemptr(stlibrd_t *brdp, unsigned long offset, int line) __LINE__, brdp->brdnr); ptr = 0; } else { - ptr = brdp->vaddr + (offset % STAL_PAGESIZE); + ptr = (char *) brdp->vaddr + (offset % STAL_PAGESIZE); } return(ptr); } @@ -3090,7 +3090,7 @@ static void stli_stalreset(stlibrd_t *brdp) printf("stli_stalreset(brdp=%x)\n", (int) brdp); #endif - vecp = (volatile unsigned long *) (brdp->vaddr + 0x30); + vecp = (volatile unsigned long *) ((char *) brdp->vaddr + 0x30); *vecp = 0xffff0000; outb(brdp->iobase, 0); for (i = 0; (i < 1000); i++) diff --git a/sys/i386/isa/wt.c b/sys/i386/isa/wt.c index 2b4c792..9c5f5af 100644 --- a/sys/i386/isa/wt.c +++ b/sys/i386/isa/wt.c @@ -20,7 +20,7 @@ * the original CMU copyright notice. * * Version 1.3, Thu Nov 11 12:09:13 MSK 1993 - * $Id: wt.c,v 1.32 1996/04/08 19:40:57 smpatel Exp $ + * $Id: wt.c,v 1.33 1996/07/23 21:51:50 phk Exp $ * */ @@ -692,7 +692,7 @@ wtintr (int u) } if (t->dmacount < t->dmatotal) { /* continue i/o */ - t->dmavaddr += t->bsize; + t->dmavaddr = (char *)t->dmavaddr + t->bsize; wtdma (t); TRACE (("continue i/o, %d\n", t->dmacount)); return; |