From nobody Tue Feb 10 14:33:39 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (208.118.235.17 [208.118.235.17]) by mx.zohomail.com with SMTPS id 1508186292400670.4994968401307; Mon, 16 Oct 2017 13:38:12 -0700 (PDT) Received: from localhost ([::1]:35141 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e4C9D-0004Co-Ll for importer@patchew.org; Mon, 16 Oct 2017 16:38:03 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49351) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e4C57-0000q1-IM for qemu-devel@nongnu.org; Mon, 16 Oct 2017 16:33:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e4C54-0001xm-Q1 for qemu-devel@nongnu.org; Mon, 16 Oct 2017 16:33:49 -0400 Received: from isrv.corpit.ru ([86.62.121.231]:35699) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e4C54-0001xO-Hs; Mon, 16 Oct 2017 16:33:46 -0400 Received: from tsrv.corpit.ru (tsrv.tls.msk.ru [192.168.177.2]) by isrv.corpit.ru (Postfix) with ESMTP id 9EA7940D2F; Mon, 16 Oct 2017 23:33:43 +0300 (MSK) Received: from tls.msk.ru (mjt.vpn.tls.msk.ru [192.168.177.99]) by tsrv.corpit.ru (Postfix) with SMTP id B5900B0F; Mon, 16 Oct 2017 23:33:43 +0300 (MSK) Received: (nullmailer pid 12321 invoked by uid 1000); Mon, 16 Oct 2017 20:33:42 -0000 From: Michael Tokarev To: qemu-devel@nongnu.org Date: Mon, 16 Oct 2017 23:33:33 +0300 Message-Id: X-Mailer: git-send-email 2.11.0 In-Reply-To: References: In-Reply-To: References: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 86.62.121.231 Subject: [Qemu-devel] [PULL 06/14] linux-user: Add some random ioctls X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: qemu-trivial@nongnu.org, Marco A L Barbosa , Michael Tokarev Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" From: Marco A L Barbosa Signed-off-by: Marco A L Barbosa Reviewed-by: Laurent Vivier Signed-off-by: Michael Tokarev --- linux-user/ioctls.h | 5 +++++ linux-user/syscall.c | 1 + linux-user/syscall_defs.h | 7 +++++++ 3 files changed, 13 insertions(+) diff --git a/linux-user/ioctls.h b/linux-user/ioctls.h index e6997ff230..35cad6f944 100644 --- a/linux-user/ioctls.h +++ b/linux-user/ioctls.h @@ -173,6 +173,11 @@ IOCTL(SIOCGSTAMP, IOC_R, MK_PTR(MK_STRUCT(STRUCT_timeval))) IOCTL(SIOCGSTAMPNS, IOC_R, MK_PTR(MK_STRUCT(STRUCT_timespec))) =20 + IOCTL(RNDGETENTCNT, IOC_R, MK_PTR(TYPE_INT)) + IOCTL(RNDADDTOENTCNT, IOC_W, MK_PTR(TYPE_INT)) + IOCTL(RNDZAPENTCNT, 0, TYPE_NULL) + IOCTL(RNDCLEARPOOL, 0, TYPE_NULL) + IOCTL(CDROMPAUSE, 0, TYPE_NULL) IOCTL(CDROMSTART, 0, TYPE_NULL) IOCTL(CDROMSTOP, 0, TYPE_NULL) diff --git a/linux-user/syscall.c b/linux-user/syscall.c index 3ef4d1c568..9d4cc4cf5d 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -59,6 +59,7 @@ int __clone2(int (*fn)(void *), void *child_stack_base, #include #include #include +#include #include "qemu-common.h" #ifdef CONFIG_TIMERFD #include diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h index 40c5027e93..b3d55e35ac 100644 --- a/linux-user/syscall_defs.h +++ b/linux-user/syscall_defs.h @@ -1060,6 +1060,13 @@ struct target_pollfd { =20 #define TARGET_SIOCGIWNAME 0x8B01 /* get name =3D=3D wireless= protocol */ =20 +/* From */ + +#define TARGET_RNDGETENTCNT TARGET_IOR('R', 0x00, int) +#define TARGET_RNDADDTOENTCNT TARGET_IOW('R', 0x01, int) +#define TARGET_RNDZAPENTCNT TARGET_IO('R', 0x04) +#define TARGET_RNDCLEARPOOL TARGET_IO('R', 0x06) + /* From */ =20 #define TARGET_BLKROSET TARGET_IO(0x12,93) /* set device read-only (0 = =3D read-write) */ --=20 2.11.0