[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PULL 15/24] bsd-user: Fix commentary issues
From: |
Daniel P . Berrangé |
Subject: |
Re: [PULL 15/24] bsd-user: Fix commentary issues |
Date: |
Mon, 26 Apr 2021 09:56:53 +0100 |
User-agent: |
Mutt/2.0.5 (2021-01-21) |
On Fri, Apr 23, 2021 at 02:39:50PM -0600, imp@bsdimp.com wrote:
> From: Warner Losh <imp@bsdimp.com>
>
> Lines > 80 or 90 characters
> C++ comments
> BSD /*- block comment convention removed.
>
> Signed-off-by: Warner Losh <imp@bsdimp.com>
> ---
> bsd-user/bsd-mman.h | 42 ++++++++++++++++++++++++++----------------
> 1 file changed, 26 insertions(+), 16 deletions(-)
>
> diff --git a/bsd-user/bsd-mman.h b/bsd-user/bsd-mman.h
> index 910e8c1921..5a64d0d425 100644
> --- a/bsd-user/bsd-mman.h
> +++ b/bsd-user/bsd-mman.h
> @@ -1,4 +1,4 @@
> -/*-
> +/*
> * Copyright (c) 1982, 1986, 1993
> * The Regents of the University of California. All rights reserved.
> *
> @@ -30,16 +30,20 @@
> * $FreeBSD: src/sys/sys/mman.h,v 1.42 2008/03/28 04:29:27 ps Exp $
> */
>
> -#define TARGET_FREEBSD_MAP_RESERVED0080 0x0080 /* previously misimplemented
> MAP_INHERIT */
> -#define TARGET_FREEBSD_MAP_RESERVED0100 0x0100 /* previously unimplemented
> MAP_NOEXTEND */
> -#define TARGET_FREEBSD_MAP_STACK 0x0400 /* region grows down, like a
> stack */
> -#define TARGET_FREEBSD_MAP_NOSYNC 0x0800 /* page to but do not sync
> underlying file */
> +#define TARGET_FREEBSD_MAP_RESERVED0080 0x0080
> + /* previously misimplemented MAP_INHERIT */
> +#define TARGET_FREEBSD_MAP_RESERVED0100 0x0100
> + /* previously unimplemented MAP_NOEXTEND */
> +#define TARGET_FREEBSD_MAP_STACK 0x0400
> + /* region grows down, like a stack */
> +#define TARGET_FREEBSD_MAP_NOSYNC 0x0800
> + /* page to but do not sync underlying file
> */
I find this indented following comment style more ambiguous as to
what constant the comment applies to. IMHO would be clearer as
/* previously misimplemented MAP_INHERIT */
#define TARGET_FREEBSD_MAP_RESERVED0080 0x0080
/* previously unimplemented MAP_NOEXTEND */
#define TARGET_FREEBSD_MAP_RESERVED0100 0x0100
/* region grows down, like a stack */
#define TARGET_FREEBSD_MAP_STACK 0x0400
/* page to but do not sync underlying file */
#define TARGET_FREEBSD_MAP_NOSYNC 0x0800
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
- Re: [PULL 11/24] bsd-user: style tweak: if 0 -> ifdef notyet for code needed in future, (continued)
[PULL 12/24] bsd-user: style tweak: if 0 -> ifdef notyet for code needed in future, imp, 2021/04/23
[PULL 20/24] bsd-user: introduce host_os.h for bsd-specific code and defaults, imp, 2021/04/23
[PULL 13/24] bsd-user: style tweak: if 0 -> ifdef notyet for code needed in future, imp, 2021/04/23
[PULL 14/24] bsd-user: style tweak: if 0 -> ifdef notyet for code needed in future, imp, 2021/04/23
[PULL 15/24] bsd-user: Fix commentary issues, imp, 2021/04/23
[PULL 19/24] bsd-user: use qemu_strtol in preference to strtol, imp, 2021/04/23
[PULL 16/24] bsd-user: Use preferred block comments, imp, 2021/04/23
[PULL 18/24] bsd-user: style changes for {}, imp, 2021/04/23
[PULL 22/24] bsd-user: create target_arch_cpu.h, imp, 2021/04/23