QEMU-Devel Archive on lore.kernel.org
 help / color / Atom feed
From: Laurent Vivier <laurent@vivier.eu>
To: Aleksandar Markovic <aleksandar.markovic@rt-rk.com>,
	qemu-devel@nongnu.org
Cc: amarkovic@wavecomp.com
Subject: Re: [PATCH v5 01/20] linux-user: Fix some constants in termbits.h
Date: Tue, 14 Jan 2020 15:16:35 +0100
Message-ID: <058379d1-02b2-f26b-001a-686433245da9@vivier.eu> (raw)
In-Reply-To: <1578947683-21011-2-git-send-email-aleksandar.markovic@rt-rk.com>

Le 13/01/2020 à 21:34, Aleksandar Markovic a écrit :
> From: Aleksandar Markovic <amarkovic@wavecomp.com>
> 
> Some constants were defined in terms of host, instead of target,
> as they should be.
> 
> Some additional trivial changes in this patch were forced by
> checkpatch.pl.
> 
> Reviewed-by: Max Filippov <jcmvbkbc@gmail.com>
> Signed-off-by: Aleksandar Markovic <amarkovic@wavecomp.com>
> ---
>  linux-user/aarch64/termbits.h    |   4 +-
>  linux-user/alpha/termbits.h      |  10 +--
>  linux-user/arm/termbits.h        |   4 +-
>  linux-user/cris/termbits.h       |   4 +-
>  linux-user/hppa/termbits.h       |   4 +-
>  linux-user/i386/termbits.h       |   4 +-
>  linux-user/m68k/termbits.h       |   4 +-
>  linux-user/microblaze/termbits.h |   4 +-
>  linux-user/mips/termbits.h       |   4 +-
>  linux-user/nios2/termbits.h      |   4 +-
>  linux-user/openrisc/termbits.h   |   6 +-
>  linux-user/ppc/termbits.h        |   4 +-
>  linux-user/riscv/termbits.h      |   4 +-
>  linux-user/s390x/termbits.h      |  26 ++++---
>  linux-user/sh4/termbits.h        |   4 +-
>  linux-user/sparc/termbits.h      |   4 +-
>  linux-user/sparc64/termbits.h    |   4 +-
>  linux-user/x86_64/termbits.h     |   6 +-
>  linux-user/xtensa/termbits.h     | 156 ++++++++++++++++++++++-----------------
>  19 files changed, 141 insertions(+), 119 deletions(-)
> 
...
> diff --git a/linux-user/s390x/termbits.h b/linux-user/s390x/termbits.h
> index 9affa8f..79a71c2 100644
> --- a/linux-user/s390x/termbits.h
> +++ b/linux-user/s390x/termbits.h
> @@ -128,8 +128,8 @@ struct target_ktermios {
>  #define TARGET_B9600	0000015
>  #define TARGET_B19200	0000016
>  #define TARGET_B38400	0000017
> -#define TARGET_EXTA B19200
> -#define TARGET_EXTB B38400
> +#define TARGET_EXTA     TARGET_B19200
> +#define TARGET_EXTB     TARGET_B38400
>  #define TARGET_CSIZE	0000060
>  #define TARGET_CS5	0000000
>  #define TARGET_CS6	0000020
> @@ -234,7 +234,7 @@ struct target_ktermios {
>  #define TARGET_TIOCGSOFTCAR	0x5419
>  #define TARGET_TIOCSSOFTCAR	0x541A
>  #define TARGET_FIONREAD	0x541B
> -#define TARGET_TIOCINQ		FIONREAD
> +#define TARGET_TIOCINQ      TARGET_FIONREAD
>  #define TARGET_TIOCLINUX	0x541C
>  #define TARGET_TIOCCONS	0x541D
>  #define TARGET_TIOCGSERIAL	0x541E
> @@ -248,14 +248,18 @@ struct target_ktermios {
>  #define TARGET_TIOCSBRK	0x5427  /* BSD compatibility */
>  #define TARGET_TIOCCBRK	0x5428  /* BSD compatibility */
>  #define TARGET_TIOCGSID	0x5429  /* Return the session ID of FD */
> -#define TARGET_TCGETS2		_IOR('T',0x2A, struct termios2)
> -#define TARGET_TCSETS2		_IOW('T',0x2B, struct termios2)
> -#define TARGET_TCSETSW2	_IOW('T',0x2C, struct termios2)
> -#define TARGET_TCSETSF2	_IOW('T',0x2D, struct termios2)
> -#define TARGET_TIOCGPTN	_IOR('T',0x30, unsigned int) /* Get Pty Number (of pty-mux device) */
> -#define TARGET_TIOCSPTLCK	_IOW('T',0x31, int)  /* Lock/unlock Pty */
> -#define TARGET_TIOCGDEV	_IOR('T',0x32, unsigned int) /* Get real dev no below /dev/console */
> -#define TARGET_TIOCGPTPEER      TARGET_IO('T', 0x41) /* Safely open the slave */
> +#define TARGET_TCGETS2          TARGET_IOR('T', 0x2A, struct termios2)
> +#define TARGET_TCSETS2          TARGET_IOW('T', 0x2B, struct termios2)
> +#define TARGET_TCSETSW2         TARGET_IOW('T', 0x2C, struct termios2)
> +#define TARGET_TCSETSF2         TARGET_IOW('T', 0x2D, struct termios2)

should be target_termios2

> +/* Get Pty Number (of pty-mux device) */
> +#define TARGET_TIOCGPTN         TARGET_IOR('T', 0x30, unsigned int)
> +/* Lock/unlock Pty */
> +#define TARGET_TIOCSPTLCK       TARGET_IOW('T', 0x31, int)
> +/* Get real dev no below /dev/console */
> +#define TARGET_TIOCGDEV         TARGET_IOR('T', 0x32, unsigned int)
> +/* Safely open the slave */
> +#define TARGET_TIOCGPTPEER      TARGET_IO('T', 0x41)
>  
>  #define TARGET_FIONCLEX	0x5450  /* these numbers need to be adjusted. */
>  #define TARGET_FIOCLEX		0x5451
...
> diff --git a/linux-user/xtensa/termbits.h b/linux-user/xtensa/termbits.h
> index d1e09e6..d92fe9c 100644
> --- a/linux-user/xtensa/termbits.h
> +++ b/linux-user/xtensa/termbits.h
...
> @@ -286,43 +286,61 @@ struct target_ktermios {
>  # define TARGET_TIOCPKT_IOCTL      64
>  
>  
> -#define TARGET_TIOCNOTTY   _IO('T', 34)
> -#define TARGET_TIOCSETD    _IOW('T', 35, int)
> -#define TARGET_TIOCGETD    _IOR('T', 36, int)
> -#define TARGET_TCSBRKP     _IOW('T', 37, int)   /* Needed for POSIX tcsendbreak()*/
> -#define TARGET_TIOCSBRK    _IO('T', 39)         /* BSD compatibility */
> -#define TARGET_TIOCCBRK    _IO('T', 40)         /* BSD compatibility */
> -#define TARGET_TIOCGSID    _IOR('T', 41, pid_t) /* Return the session ID of FD*/
> -#define TARGET_TCGETS2     _IOR('T', 42, struct termios2)
> -#define TARGET_TCSETS2     _IOW('T', 43, struct termios2)
> -#define TARGET_TCSETSW2    _IOW('T', 44, struct termios2)
> -#define TARGET_TCSETSF2    _IOW('T', 45, struct termios2)
> -#define TARGET_TIOCGRS485  _IOR('T', 46, struct serial_rs485)
> -#define TARGET_TIOCSRS485  _IOWR('T', 47, struct serial_rs485)
> -#define TARGET_TIOCGPTN    _IOR('T',0x30, unsigned int) /* Get Pty Number (of pty-mux device) */
> -#define TARGET_TIOCSPTLCK  _IOW('T',0x31, int)  /* Lock/unlock Pty */
> -#define TARGET_TIOCGDEV    _IOR('T',0x32, unsigned int) /* Get primary device node of /dev/console */
> -#define TARGET_TIOCSIG     _IOW('T',0x36, int)  /* Generate signal on Pty slave */
> -#define TARGET_TIOCVHANGUP _IO('T', 0x37)
> -#define TARGET_TIOCGPKT    _IOR('T', 0x38, int) /* Get packet mode state */
> -#define TARGET_TIOCGPTLCK  _IOR('T', 0x39, int) /* Get Pty lock state */
> -#define TARGET_TIOCGEXCL   _IOR('T', 0x40, int) /* Get exclusive mode state */
> -#define TARGET_TIOCGPTPEER _IO('T', 0x41) /* Safely open the slave */
> -
> -#define TARGET_TIOCSERCONFIG   _IO('T', 83)
> -#define TARGET_TIOCSERGWILD    _IOR('T', 84,  int)
> -#define TARGET_TIOCSERSWILD    _IOW('T', 85,  int)
> +#define TARGET_TIOCNOTTY   TARGET_IO('T', 34)
> +#define TARGET_TIOCSETD    TARGET_IOW('T', 35, int)
> +#define TARGET_TIOCGETD    TARGET_IOR('T', 36, int)
> +/* Needed for POSIX tcsendbreak()*/
> +#define TARGET_TCSBRKP     TARGET_IOW('T', 37, int)
> +/* BSD compatibility */
> +#define TARGET_TIOCSBRK    TARGET_IO('T', 39)
> +/* BSD compatibility */
> +#define TARGET_TIOCCBRK    TARGET_IO('T', 40)
> +/* Return the session ID of FD*/
> +#define TARGET_TIOCGSID    TARGET_IOR('T', 41, pid_t)
> +#define TARGET_TCGETS2     TARGET_IOR('T', 42, struct termios2)
> +#define TARGET_TCSETS2     TARGET_IOW('T', 43, struct termios2)
> +#define TARGET_TCSETSW2    TARGET_IOW('T', 44, struct termios2)
> +#define TARGET_TCSETSF2    TARGET_IOW('T', 45, struct termios2)

should be target_termios2

Thanks,
Laurent


  reply index

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-13 20:34 [PATCH v5 00/20] linux-user: Misc patches for 5.0 Aleksandar Markovic
2020-01-13 20:34 ` [PATCH v5 01/20] linux-user: Fix some constants in termbits.h Aleksandar Markovic
2020-01-14 14:16   ` Laurent Vivier [this message]
2020-01-13 20:34 ` [PATCH v5 02/20] linux-user: alpha: Update syscall numbers to kernel 5.5 rc3 level Aleksandar Markovic
2020-01-14 15:12   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 03/20] linux-user: m68k: " Aleksandar Markovic
2020-01-14 15:03   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 04/20] linux-user: microblaze: " Aleksandar Markovic
2020-01-14 15:06   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 05/20] linux-user: mips: " Aleksandar Markovic
2020-01-14 16:39   ` Laurent Vivier
2020-02-04 11:56     ` Aleksandar Markovic
2020-02-04 22:34       ` Laurent Vivier
2020-02-04 22:53         ` Aleksandar Markovic
2020-01-13 20:34 ` [PATCH v5 06/20] linux-user: x86_64: " Aleksandar Markovic
2020-01-14 15:16   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 07/20] linux-user: xtensa: " Aleksandar Markovic
2020-01-14 15:08   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 08/20] linux-user: xtensa: Remove unused constant TARGET_NR_syscall_count Aleksandar Markovic
2020-01-14 14:59   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 09/20] linux-user: Add support for FS_IOC_<GET|SET>VERSION ioctls Aleksandar Markovic
2020-01-14 14:21   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 10/20] linux-user: Add support for FS_IOC32_<GET|SET>FLAGS ioctls Aleksandar Markovic
2020-01-14 14:24   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 11/20] linux-user: Add support for FS_IOC32_<GET|SET>VERSION ioctls Aleksandar Markovic
2020-01-14 14:24   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 12/20] linux-user: Add support for FS_IOC_FS<GET|SET>XATTR ioctls Aleksandar Markovic
2020-01-14 14:29   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 13/20] linux-user: Add support for FITRIM ioctl Aleksandar Markovic
2020-01-14 14:32   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 14/20] linux-user: Add support for FIFREEZE and FITHAW ioctls Aleksandar Markovic
2020-01-14 14:34   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 15/20] linux-user: Add support for FD<SETEMSGTRESH|SETMAXERRS|GETMAXERRS> ioctls Aleksandar Markovic
2020-01-14 14:36   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 16/20] linux-user: Add support for FDFMT<BEG|TRK|END> ioctls Aleksandar Markovic
2020-01-14 14:38   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 17/20] linux-user: Add support for FDGETFDCSTAT ioctl Aleksandar Markovic
2020-01-14 14:42   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 18/20] configure: Detect kcov support and introduce CONFIG_KCOV Aleksandar Markovic
2020-01-14 14:48   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 19/20] linux-user: Add support for KCOV_<ENABLE|DISABLE> ioctls Aleksandar Markovic
2020-01-14 14:49   ` Laurent Vivier
2020-01-13 20:34 ` [PATCH v5 20/20] linux-user: Add support for KCOV_INIT_TRACE ioctl Aleksandar Markovic
2020-01-14 14:53   ` Laurent Vivier

Reply instructions:

You may reply publically to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=058379d1-02b2-f26b-001a-686433245da9@vivier.eu \
    --to=laurent@vivier.eu \
    --cc=aleksandar.markovic@rt-rk.com \
    --cc=amarkovic@wavecomp.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

QEMU-Devel Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/qemu-devel/0 qemu-devel/git/0.git
	git clone --mirror https://lore.kernel.org/qemu-devel/1 qemu-devel/git/1.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 qemu-devel qemu-devel/ https://lore.kernel.org/qemu-devel \
		qemu-devel@nongnu.org
	public-inbox-index qemu-devel

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.nongnu.qemu-devel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git