Date: Thu, 27 Aug 1998 09:46:43 +0100 (BST) From: Doug Rabson <dfr@nlsystems.com> To: Roger Hardiman <roger@cs.strath.ac.uk> Cc: freebsd-alpha@FreeBSD.ORG Subject: Re: Recent Alpha typecast to brooktre848.c Message-ID: <Pine.BSF.4.01.9808270943230.17263-100000@herring.nlsystems.com> In-Reply-To: <35E4B618.56FD@cs.strath.ac.uk>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 27 Aug 1998, Roger Hardiman wrote: > Hi, > I work on the bt848 driver and was looking at the > recent typecast change from "u_long" to "(uintptr_t) (void*)" > in the driver. > Logs state this was for the Alpha kernel. > > I think this may be incorrect. > < *(*dma_prog)++ = (uintptr_t) (void *) *target_buffer; > --- > > *(*dma_prog)++ = (u_long) *target_buffer; > > The block of memory *dma_prog is pointing to is the > instruction list for the bt848 chip's internal RISC processor. > This is a set of 32 bit instructions. > uintptr_t is defined as an unsigned long in Alpha/types.h > so should this be a typecast to u_int32 and not uintptr_t > > Can someone working on this drop me an email. There are lots of > other (u_long) type casts in the driver when writing > to the dma_prog buffer which may need fixing. Probably the casts should be u_int32_t. I haven't tried to get the bt848 driver working on the alpha yet (I do have a card but I need to get an X server running first ...). This commit was one of Bruce's sweeps over the code tidying up casts from pointers to integers. -- Doug Rabson Mail: dfr@nlsystems.com Nonlinear Systems Ltd. Phone: +44 181 951 1891 Fax: +44 181 381 1039 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-alpha" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.01.9808270943230.17263-100000>