Fix warnings related to -Wall -Wcast-qual
This commit is contained in:
parent
5a24726ba3
commit
697457a133
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=43351
@ -1,5 +1,5 @@
|
||||
/* $NetBSD: if_de.c,v 1.80 1998/09/25 18:06:53 matt Exp $ */
|
||||
/* $Id: if_de.c,v 1.94 1999/01/27 23:45:41 dillon Exp $ */
|
||||
/* $Id: if_de.c,v 1.95 1999/01/28 00:57:52 dillon Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1994-1997 Matt Thomas (matt@3am-software.com)
|
||||
@ -2412,7 +2412,7 @@ tulip_srom_decode(
|
||||
/*
|
||||
* Save the hardware address.
|
||||
*/
|
||||
bcopy((v_caddr_t) shp->sh_ieee802_address, (v_caddr_t) sc->tulip_enaddr, 6);
|
||||
bcopy((c_caddr_t) shp->sh_ieee802_address, (v_caddr_t) sc->tulip_enaddr, 6);
|
||||
/*
|
||||
* If this is a multiple port card, add the adapter index to the last
|
||||
* byte of the hardware address. (if it isn't multiport, adding 0
|
||||
|
@ -27,7 +27,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: if_fxp.c,v 1.60 1999/01/27 23:45:42 dillon Exp $
|
||||
* $Id: if_fxp.c,v 1.61 1999/01/28 00:57:53 dillon Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -1290,7 +1290,7 @@ fxp_init(xsc)
|
||||
* zero and must be one bits in this structure and this is the easiest
|
||||
* way to initialize them all to proper values.
|
||||
*/
|
||||
bcopy(fxp_cb_config_template, (void *)&cbp->cb_status,
|
||||
bcopy(fxp_cb_config_template, (volatile void *)&cbp->cb_status,
|
||||
sizeof(fxp_cb_config_template));
|
||||
|
||||
cbp->cb_status = 0;
|
||||
|
@ -25,7 +25,7 @@
|
||||
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
|
||||
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
* $Id: syscons.c,v 1.294 1999/01/26 09:58:37 yokota Exp $
|
||||
* $Id: syscons.c,v 1.295 1999/01/28 01:59:48 dillon Exp $
|
||||
*/
|
||||
|
||||
#include "sc.h"
|
||||
@ -172,7 +172,9 @@ static long scrn_time_stamp;
|
||||
static int saver_mode = CONS_LKM_SAVER; /* LKM/user saver */
|
||||
static int run_scrn_saver = FALSE; /* should run the saver? */
|
||||
static int scrn_idle = FALSE; /* about to run the saver */
|
||||
#if NSPLASH > 0
|
||||
static int scrn_saver_failed;
|
||||
#endif
|
||||
u_char scr_map[256];
|
||||
u_char scr_rmap[256];
|
||||
static int initial_video_mode; /* initial video mode # */
|
||||
|
@ -32,7 +32,7 @@
|
||||
*
|
||||
* from tahoe: in_cksum.c 1.2 86/01/05
|
||||
* from: @(#)in_cksum.c 1.3 (Berkeley) 1/19/91
|
||||
* $Id: in_cksum.c,v 1.13 1998/04/15 17:26:15 bde Exp $
|
||||
* $Id: in_cksum.c,v 1.14 1999/01/28 01:59:50 dillon Exp $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -278,7 +278,7 @@ in_cksum_partial(psum, w, len)
|
||||
if ((1 & (int) w) && (len > 0)) {
|
||||
sum <<= 8;
|
||||
su.c[0] = *(const char *)w;
|
||||
w = (u_short *)((const char *)w + 1);
|
||||
w = (const u_short *)((const char *)w + 1);
|
||||
len--;
|
||||
byte_swapped = 1;
|
||||
}
|
||||
|
@ -23,7 +23,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: kern_environment.c,v 1.4 1999/01/15 17:24:56 msmith Exp $
|
||||
* $Id: kern_environment.c,v 1.5 1999/01/27 21:24:50 dillon Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -71,7 +71,7 @@ getenv(char *name)
|
||||
int
|
||||
getenv_int(char *name, int *data)
|
||||
{
|
||||
char *value, *vtp;
|
||||
const char *value, *vtp;
|
||||
quad_t iv;
|
||||
|
||||
if ((value = getenv(name)) == NULL)
|
||||
|
@ -46,7 +46,7 @@
|
||||
* in Germany will I accept domestic beer. This code may or may not work
|
||||
* and I certainly make no claims as to its fitness for *any* purpose.
|
||||
*
|
||||
* $Id: kern_threads.c,v 1.11 1999/01/27 10:14:05 bde Exp $
|
||||
* $Id: kern_threads.c,v 1.12 1999/01/27 21:49:56 dillon Exp $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -79,7 +79,7 @@ thr_sleep(struct proc *p, struct thr_sleep_args *uap) {
|
||||
/*
|
||||
* Get timespec struct
|
||||
*/
|
||||
if ((error = copyin((caddr_t) uap->timeout, (caddr_t) &ts, sizeof ts)) != 0) {
|
||||
if ((error = copyin((c_caddr_t) uap->timeout, (caddr_t) &ts, sizeof ts)) != 0) {
|
||||
p->p_wakeup = 0;
|
||||
return error;
|
||||
}
|
||||
|
@ -36,7 +36,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)tty.c 8.8 (Berkeley) 1/21/94
|
||||
* $Id: tty.c,v 1.110 1998/12/08 10:22:07 bde Exp $
|
||||
* $Id: tty.c,v 1.111 1999/01/08 17:31:12 eivind Exp $
|
||||
*/
|
||||
|
||||
/*-
|
||||
@ -809,7 +809,7 @@ ttioctl(tp, cmd, data, flag)
|
||||
ISSET(constty->t_state, TS_CONNECTED))
|
||||
return (EBUSY);
|
||||
#ifndef UCONSOLE
|
||||
if (error = suser(p->p_ucred, &p->p_acflag))
|
||||
if ((error = suser(p->p_ucred, &p->p_acflag)) != 0)
|
||||
return (error);
|
||||
#endif
|
||||
constty = tp;
|
||||
|
@ -13,7 +13,7 @@
|
||||
* bad that happens because of using this software isn't the responsibility
|
||||
* of the author. This software is distributed AS-IS.
|
||||
*
|
||||
* $Id: vfs_aio.c,v 1.38 1999/01/27 21:49:57 dillon Exp $
|
||||
* $Id: vfs_aio.c,v 1.39 1999/01/28 00:57:47 dillon Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -1472,7 +1472,7 @@ aio_suspend(struct proc *p, struct aio_suspend_args *uap)
|
||||
/*
|
||||
* Get timespec struct
|
||||
*/
|
||||
if ((error = copyin((caddr_t) uap->timeout, (caddr_t) &ts, sizeof ts)) != 0) {
|
||||
if ((error = copyin((c_caddr_t) uap->timeout, (caddr_t) &ts, sizeof ts)) != 0) {
|
||||
return error;
|
||||
}
|
||||
|
||||
|
@ -36,7 +36,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)vfs_syscalls.c 8.13 (Berkeley) 4/15/94
|
||||
* $Id: vfs_syscalls.c,v 1.113 1999/01/24 06:28:37 bde Exp $
|
||||
* $Id: vfs_syscalls.c,v 1.114 1999/01/27 21:49:58 dillon Exp $
|
||||
*/
|
||||
|
||||
/* For 4.3 integer FS ID compatibility */
|
||||
@ -111,7 +111,9 @@ mount(p, uap)
|
||||
struct vfsconf *vfsp;
|
||||
int error, flag = 0, flag2 = 0;
|
||||
struct vattr va;
|
||||
#ifdef COMPAT_43
|
||||
u_long fstypenum;
|
||||
#endif
|
||||
struct nameidata nd;
|
||||
char fstypename[MFSNAMELEN];
|
||||
|
||||
|
@ -36,7 +36,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)vfs_init.c 8.3 (Berkeley) 1/4/94
|
||||
* $Id: vfs_init.c,v 1.41 1998/12/07 21:58:30 archie Exp $
|
||||
* $Id: vfs_init.c,v 1.42 1999/01/28 00:57:47 dillon Exp $
|
||||
*/
|
||||
|
||||
|
||||
@ -231,7 +231,7 @@ vfs_rm_vnodeops(const void *data)
|
||||
struct vnodeop_desc *desc;
|
||||
int i, j, k;
|
||||
|
||||
opv = (struct vnodeopv_desc *)data;
|
||||
opv = (const struct vnodeopv_desc *)data;
|
||||
/* Lower ref counts on descs in the table and release if zero */
|
||||
opv_desc_vector = *(opv->opv_desc_vector_p);
|
||||
for (i = 0; (desc = opv->opv_desc_ops[i].opve_op); i++) {
|
||||
|
@ -36,7 +36,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)vfs_syscalls.c 8.13 (Berkeley) 4/15/94
|
||||
* $Id: vfs_syscalls.c,v 1.113 1999/01/24 06:28:37 bde Exp $
|
||||
* $Id: vfs_syscalls.c,v 1.114 1999/01/27 21:49:58 dillon Exp $
|
||||
*/
|
||||
|
||||
/* For 4.3 integer FS ID compatibility */
|
||||
@ -111,7 +111,9 @@ mount(p, uap)
|
||||
struct vfsconf *vfsp;
|
||||
int error, flag = 0, flag2 = 0;
|
||||
struct vattr va;
|
||||
#ifdef COMPAT_43
|
||||
u_long fstypenum;
|
||||
#endif
|
||||
struct nameidata nd;
|
||||
char fstypename[MFSNAMELEN];
|
||||
|
||||
|
@ -34,7 +34,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)nfs_vfsops.c 8.12 (Berkeley) 5/20/95
|
||||
* $Id: nfs_vfsops.c,v 1.79 1998/12/04 22:54:54 archie Exp $
|
||||
* $Id: nfs_vfsops.c,v 1.80 1999/01/28 00:57:51 dillon Exp $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -142,8 +142,8 @@ VFS_SET(nfs_vfsops, nfs, VFCF_NETWORK);
|
||||
* server for a diskless/dataless machine. It is initialized below just
|
||||
* to ensure that it is allocated to initialized data (.data not .bss).
|
||||
*/
|
||||
struct nfs_diskless nfs_diskless = { { 0 } };
|
||||
struct nfsv3_diskless nfsv3_diskless = { { 0 } };
|
||||
struct nfs_diskless nfs_diskless = { { { 0 } } };
|
||||
struct nfsv3_diskless nfsv3_diskless = { { { 0 } } };
|
||||
int nfs_diskless_valid = 0;
|
||||
|
||||
SYSCTL_INT(_vfs_nfs, OID_AUTO, diskless_valid, CTLFLAG_RD,
|
||||
|
@ -34,7 +34,7 @@
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* @(#)nfs_vfsops.c 8.12 (Berkeley) 5/20/95
|
||||
* $Id: nfs_vfsops.c,v 1.79 1998/12/04 22:54:54 archie Exp $
|
||||
* $Id: nfs_vfsops.c,v 1.80 1999/01/28 00:57:51 dillon Exp $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -142,8 +142,8 @@ VFS_SET(nfs_vfsops, nfs, VFCF_NETWORK);
|
||||
* server for a diskless/dataless machine. It is initialized below just
|
||||
* to ensure that it is allocated to initialized data (.data not .bss).
|
||||
*/
|
||||
struct nfs_diskless nfs_diskless = { { 0 } };
|
||||
struct nfsv3_diskless nfsv3_diskless = { { 0 } };
|
||||
struct nfs_diskless nfs_diskless = { { { 0 } } };
|
||||
struct nfsv3_diskless nfsv3_diskless = { { { 0 } } };
|
||||
int nfs_diskless_valid = 0;
|
||||
|
||||
SYSCTL_INT(_vfs_nfs, OID_AUTO, diskless_valid, CTLFLAG_RD,
|
||||
|
@ -1,5 +1,5 @@
|
||||
/* $NetBSD: if_de.c,v 1.80 1998/09/25 18:06:53 matt Exp $ */
|
||||
/* $Id: if_de.c,v 1.94 1999/01/27 23:45:41 dillon Exp $ */
|
||||
/* $Id: if_de.c,v 1.95 1999/01/28 00:57:52 dillon Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1994-1997 Matt Thomas (matt@3am-software.com)
|
||||
@ -2412,7 +2412,7 @@ tulip_srom_decode(
|
||||
/*
|
||||
* Save the hardware address.
|
||||
*/
|
||||
bcopy((v_caddr_t) shp->sh_ieee802_address, (v_caddr_t) sc->tulip_enaddr, 6);
|
||||
bcopy((c_caddr_t) shp->sh_ieee802_address, (v_caddr_t) sc->tulip_enaddr, 6);
|
||||
/*
|
||||
* If this is a multiple port card, add the adapter index to the last
|
||||
* byte of the hardware address. (if it isn't multiport, adding 0
|
||||
|
@ -27,7 +27,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $Id: if_fxp.c,v 1.60 1999/01/27 23:45:42 dillon Exp $
|
||||
* $Id: if_fxp.c,v 1.61 1999/01/28 00:57:53 dillon Exp $
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -1290,7 +1290,7 @@ fxp_init(xsc)
|
||||
* zero and must be one bits in this structure and this is the easiest
|
||||
* way to initialize them all to proper values.
|
||||
*/
|
||||
bcopy(fxp_cb_config_template, (void *)&cbp->cb_status,
|
||||
bcopy(fxp_cb_config_template, (volatile void *)&cbp->cb_status,
|
||||
sizeof(fxp_cb_config_template));
|
||||
|
||||
cbp->cb_status = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user