From nobody Thu Apr 20 17:36:10 2023 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Q2Pvt6dwKz46M7f; Thu, 20 Apr 2023 17:36:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Q2Pvt4rDSz3JFb; Thu, 20 Apr 2023 17:36:10 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1682012170; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CLuksVCbVWcisCBzs5MwqECmOnTAmwekWhCgC4y8wfk=; b=A/ouw9i5Y2zJ097IdpwsQW8tI5AbsgXWvauUp1bHqmrlrM8AZd8tmbcMNkoDd4IDhV19Tk RBedlat75PXTWY0+/A06jfX4+sYQ/m8wkxwTPL65AUR3FEOxfE4D70/JBSBlWqm3IkOH0b 2u0UvwD5V47s45Xbk/Y0ZkgyuCbbtoa412pheI4c8Qj0jtTcQiHrkmA0xdYGn2S2aiJFyy KPAlrBTWoL6qwDtGaPeFBDTRo3ztvAUmVSPKt/C8sYVm9JH534C9e430SBETRlnbPQq84t 87pwlXVMCsnJfgsFnVOghxYhrohtcIWoc12BPjZ3dIZyiJuTD+/b4t6Sw78kYA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1682012170; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CLuksVCbVWcisCBzs5MwqECmOnTAmwekWhCgC4y8wfk=; b=VA5GVg2TC12LSqRscwuUAfssD7aHkU45zv1DDK1Z/6f51entlRJpiS8ueawNIVZ/NJ1HQ/ /AlN5hFJN1r3Xk8792XBOpIWuHxAgh773WRfmTlhT/qmr7vtPmlW6g9QGw5ByXY9AmSk6U xDoJuf+EqfvPsfnSUJUZGz6z6Sl1Bbtzmer9EsneefzJ1Bipa6A2YXGYM5Q5YmltTxGeoC FpUXGoFS4sQJIsAQMGeiHlRUwAWyjJiL0rf8irfU0xuaVQHcIOlU4kz8Ws1QgL8a7aRTDu RSJ6l1ZAM4himJOQ/UrYdPJXHtYhDE7XhxDAHGrpsv35PWj8HlBHfXa+CEl6sg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1682012170; a=rsa-sha256; cv=none; b=CKon+F5SA4AanGRaQ5/s3pkifjU7t0q7QCL2/hWbLSiITG7CBmZPHM+KT5/HBs3ugnJnZL uBy+RWXwqgfBPLzLRLQWQnX0pN5FQTplJh9dVTVNxqLfXVZMb5ELlg7mM729yQaHrzFJ6Z Kh8HWwTlfkkw6Cpx7PDXf7KZqSaC82s5PtCXnBvEC0W0ofJuNzNE3lBQJSPUsWn0DWWkyN 0V64dVC3IQBFcY87Ae282d1bqN0PRoamz/31+FR/QP4G/U8h+SBkc7M0etdn4UT/LPozNA 5pqCzEq06XY2szPAKa3PCgwkJKyPXtlwIO4Pko9QZMs46oNkCBSWQpOW3G1dHw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Q2Pvt3vFgzmnq; Thu, 20 Apr 2023 17:36:10 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 33KHaAqa077228; Thu, 20 Apr 2023 17:36:10 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 33KHaAYw077227; Thu, 20 Apr 2023 17:36:10 GMT (envelope-from git) Date: Thu, 20 Apr 2023 17:36:10 GMT Message-Id: <202304201736.33KHaAYw077227@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: 1a149d65baed - main - dtrace: get rid of uchar_t types List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 1a149d65baed31b90a0b8abe2d6c5a568122a5ec Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=1a149d65baed31b90a0b8abe2d6c5a568122a5ec commit 1a149d65baed31b90a0b8abe2d6c5a568122a5ec Author: Christos Margiolis AuthorDate: 2023-04-20 16:19:42 +0000 Commit: Mark Johnston CommitDate: 2023-04-20 17:35:56 +0000 dtrace: get rid of uchar_t types Callers are specifying uint8_t anyway and this slightly reduces dependencies on compatibility typedefs. No functional change intended. Reviewed by: markj, mhorne MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D39490 --- sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h | 4 ++-- sys/cddl/dev/dtrace/amd64/dtrace_subr.c | 4 ++-- sys/cddl/dev/dtrace/i386/dtrace_subr.c | 4 ++-- sys/cddl/dev/dtrace/x86/instr_size.c | 12 ++++++------ 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h b/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h index 5cad5a3b18c9..d3d8fbca6164 100644 --- a/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h +++ b/sys/cddl/contrib/opensolaris/uts/common/sys/dtrace.h @@ -2399,8 +2399,8 @@ extern void dtrace_safe_synchronous_signal(void); extern int dtrace_mach_aframes(void); #if defined(__i386) || defined(__amd64) -extern int dtrace_instr_size(uchar_t *instr); -extern int dtrace_instr_size_isa(uchar_t *, model_t, int *); +extern int dtrace_instr_size(uint8_t *instr); +extern int dtrace_instr_size_isa(uint8_t *, model_t, int *); extern void dtrace_invop_callsite(void); #endif extern void dtrace_invop_add(int (*)(uintptr_t, struct trapframe *, uintptr_t)); diff --git a/sys/cddl/dev/dtrace/amd64/dtrace_subr.c b/sys/cddl/dev/dtrace/amd64/dtrace_subr.c index 2521afc7b443..c4a36e851c3f 100644 --- a/sys/cddl/dev/dtrace/amd64/dtrace_subr.c +++ b/sys/cddl/dev/dtrace/amd64/dtrace_subr.c @@ -449,7 +449,7 @@ dtrace_trap(struct trapframe *frame, u_int type) * Offset the instruction pointer to the instruction * following the one causing the fault. */ - frame->tf_rip += dtrace_instr_size((u_char *) frame->tf_rip); + frame->tf_rip += dtrace_instr_size((uint8_t *) frame->tf_rip); return (1); /* Page fault. */ case T_PAGEFLT: @@ -461,7 +461,7 @@ dtrace_trap(struct trapframe *frame, u_int type) * Offset the instruction pointer to the instruction * following the one causing the fault. */ - frame->tf_rip += dtrace_instr_size((u_char *) frame->tf_rip); + frame->tf_rip += dtrace_instr_size((uint8_t *) frame->tf_rip); return (1); default: /* Handle all other traps in the usual way. */ diff --git a/sys/cddl/dev/dtrace/i386/dtrace_subr.c b/sys/cddl/dev/dtrace/i386/dtrace_subr.c index 69a07e8ee968..dedc1ffe84c8 100644 --- a/sys/cddl/dev/dtrace/i386/dtrace_subr.c +++ b/sys/cddl/dev/dtrace/i386/dtrace_subr.c @@ -449,7 +449,7 @@ dtrace_trap(struct trapframe *frame, u_int type) * Offset the instruction pointer to the instruction * following the one causing the fault. */ - frame->tf_eip += dtrace_instr_size((u_char *) frame->tf_eip); + frame->tf_eip += dtrace_instr_size((uint8_t *) frame->tf_eip); return (1); /* Page fault. */ case T_PAGEFLT: @@ -461,7 +461,7 @@ dtrace_trap(struct trapframe *frame, u_int type) * Offset the instruction pointer to the instruction * following the one causing the fault. */ - frame->tf_eip += dtrace_instr_size((u_char *) frame->tf_eip); + frame->tf_eip += dtrace_instr_size((uint8_t *) frame->tf_eip); return (1); default: /* Handle all other traps in the usual way. */ diff --git a/sys/cddl/dev/dtrace/x86/instr_size.c b/sys/cddl/dev/dtrace/x86/instr_size.c index 6eea987244b1..a2a9b9342566 100644 --- a/sys/cddl/dev/dtrace/x86/instr_size.c +++ b/sys/cddl/dev/dtrace/x86/instr_size.c @@ -49,8 +49,8 @@ typedef u_int model_t; #define DATAMODEL_NATIVE 0 -int dtrace_instr_size(uchar_t *); -int dtrace_instr_size_isa(uchar_t *, model_t, int *); +int dtrace_instr_size(uint8_t *); +int dtrace_instr_size_isa(uint8_t *, model_t, int *); #endif #include @@ -83,7 +83,7 @@ static int dtrace_dis_get_byte(void *p) { int ret; - uchar_t **instr = p; + uint8_t **instr = p; ret = **instr; *instr += 1; @@ -101,7 +101,7 @@ dtrace_dis_get_byte(void *p) */ /* ARGSUSED2 */ static int -dtrace_dis_isize(uchar_t *instr, dis_isize_t which, model_t model, int *rmindex) +dtrace_dis_isize(uint8_t *instr, dis_isize_t which, model_t model, int *rmindex) { int sz; dis86_t x; @@ -127,13 +127,13 @@ dtrace_dis_isize(uchar_t *instr, dis_isize_t which, model_t model, int *rmindex) } int -dtrace_instr_size_isa(uchar_t *instr, model_t model, int *rmindex) +dtrace_instr_size_isa(uint8_t *instr, model_t model, int *rmindex) { return (dtrace_dis_isize(instr, DIS_ISIZE_INSTR, model, rmindex)); } int -dtrace_instr_size(uchar_t *instr) +dtrace_instr_size(uint8_t *instr) { return (dtrace_dis_isize(instr, DIS_ISIZE_INSTR, DATAMODEL_NATIVE, NULL));