Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev Constify.



details:   https://anonhg.NetBSD.org/src/rev/5bfd7689c41d
branches:  trunk
changeset: 934553:5bfd7689c41d
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Sat Jun 13 22:15:57 2020 +0000

description:
Constify.

diffstat:

 sys/dev/cgd.c    |  10 +++++-----
 sys/dev/cgdvar.h |   4 ++--
 2 files changed, 7 insertions(+), 7 deletions(-)

diffs (59 lines):

diff -r d99a886bad9f -r 5bfd7689c41d sys/dev/cgd.c
--- a/sys/dev/cgd.c     Sat Jun 13 22:15:06 2020 +0000
+++ b/sys/dev/cgd.c     Sat Jun 13 22:15:57 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cgd.c,v 1.132 2020/06/13 22:15:06 riastradh Exp $ */
+/* $NetBSD: cgd.c,v 1.133 2020/06/13 22:15:57 riastradh Exp $ */
 
 /*-
  * Copyright (c) 2002 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cgd.c,v 1.132 2020/06/13 22:15:06 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cgd.c,v 1.133 2020/06/13 22:15:57 riastradh Exp $");
 
 #include <sys/types.h>
 #include <sys/param.h>
@@ -386,7 +386,7 @@
 static int     cgd_ioctl_get(dev_t, void *, struct lwp *);
 static int     cgdinit(struct cgd_softc *, const char *, struct vnode *,
                        struct lwp *);
-static void    cgd_cipher(struct cgd_softc *, void *, void *,
+static void    cgd_cipher(struct cgd_softc *, void *, const void *,
                           size_t, daddr_t, size_t, int);
 
 static void    cgd_selftest(void);
@@ -1535,11 +1535,11 @@
 }
 
 static void
-cgd_cipher(struct cgd_softc *sc, void *dstv, void *srcv,
+cgd_cipher(struct cgd_softc *sc, void *dstv, const void *srcv,
     size_t len, daddr_t blkno, size_t secsize, int dir)
 {
        char            *dst = dstv;
-       char            *src = srcv;
+       const char      *src = srcv;
        cfunc_cipher    *cipher = sc->sc_cfuncs->cf_cipher;
        size_t          blocksize = sc->sc_cdata.cf_blocksize;
        size_t          todo;
diff -r d99a886bad9f -r 5bfd7689c41d sys/dev/cgdvar.h
--- a/sys/dev/cgdvar.h  Sat Jun 13 22:15:06 2020 +0000
+++ b/sys/dev/cgdvar.h  Sat Jun 13 22:15:57 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cgdvar.h,v 1.20 2020/06/13 18:38:33 riastradh Exp $ */
+/* $NetBSD: cgdvar.h,v 1.21 2020/06/13 22:15:58 riastradh Exp $ */
 
 /*-
  * Copyright (c) 2002 The NetBSD Foundation, Inc.
@@ -87,7 +87,7 @@
        struct buf              *cx_obp;
        struct buf              *cx_nbp;
        void                    *cx_dstv;
-       void                    *cx_srcv;
+       const void              *cx_srcv;
        size_t                   cx_len;
        daddr_t                  cx_blkno;
        size_t                   cx_secsize;



Home | Main Index | Thread Index | Old Index