From nobody Sat Dec 28 21:17:22 2024 X-Original-To: dev-commits-src-all@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 4YLFYt3t8Vz5jD3S; Sat, 28 Dec 2024 21:17:22 +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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4YLFYt0zW6z43xg; Sat, 28 Dec 2024 21:17:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1735420642; 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=jSfezpO/i0wuhDp0VvdO/EP0QH1gaGnSXYMpXEs9fRs=; b=Ik0LGWGxajC5c4GZuTipywPuJ7SHyRfe2+WHtdMt0t2UPzhMD0w14OyxnY+VEFdQPfhC/R bSN29IhpGaS6cgtGgVZA44b14l8XUJSk3bmJlJJdn9uYuLhi05M2+l2Rga0FVwHI7ilhET BfiG4vFp2yETpYEZ/mtmzDcf/PEp+HS4b08tViy159ts6hZ1zf4TC0pWu2Qtr/JnmyJsl1 swO8Y3P9Nai+2HUgWXIv//s+itn0bQnVJ5AC08/5QUULbwVqKFkVH3AllowCzs/dV0dQXI na/5qa8uSOHrzdk/gRFSh+aYspRtd8S08n4k9aTOnXNe7ShIZF9TJtJRVkj5zg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1735420642; 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=jSfezpO/i0wuhDp0VvdO/EP0QH1gaGnSXYMpXEs9fRs=; b=BqnrkidniNxrJb+x9kKu0Eq2BhSZhtKBKPxgw5+82NnosTh9gKWHJqIfvEO+xiR3L+4K3q KTVG0ABaQO2DJeflidDMt6xw1cYtmATX5LbDH8HzPkhHWApnHHS6cKeXEdE4kgmAiG3wxB Cg8Hf5LwFLhuvG9WzLOECAEg8I8vGNCJU42H04KCm6i335FcfefWoPApxz6EyhzPl2QSFA ElLL+3ronW8a1aNASRir0EMYvrrBaXAo4Ks822E+wL6C+AA6HZUD7Cr1s9NfYvF/WFZgPF MlBjG/unRRRFhmzvHpDRE30vCQu9xFf5l3MjC/UcTWwpvuTTksBaOd1krOuKsg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1735420642; a=rsa-sha256; cv=none; b=BD0ImeG+8I04HnEg5YxYIx+agl6dCIX2AHPuVQpFRLpYpt4QkX9SMfaC/OwdAf+xNVjMvq MujCsFguInckmXfifdjx1dugVHAq/hgUKTb/AyJ0efXeAq1UuQLvQmO1t75aETo6HVo7AR tP4+tqOujYv0hrw/PJ88IJDEPDM+3qFU2USM4yAgF9NrW1eWECBMPHJuTslN9it1CwFRV1 O0Jpi+ReyUwWnND6ozmgS5rNUu3tQ9ZNN/UB8/tYOr0drs6/CPJXe/qMajz4T8KODvbc63 f8gm7vit4XTzerhoi1jYcokaj/HWYPEqh9/irTdmyKp9kO5rMSAhQKyeuKxmUQ== 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 4YLFYt0Y3mzh4H; Sat, 28 Dec 2024 21:17:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4BSLHMxQ001278; Sat, 28 Dec 2024 21:17:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4BSLHMcD001275; Sat, 28 Dec 2024 21:17:22 GMT (envelope-from git) Date: Sat, 28 Dec 2024 21:17:22 GMT Message-Id: <202412282117.4BSLHMcD001275@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Warner Losh Subject: git: 792e47a51a42 - main - ocs_fc: print instance_index value rather than pointer itself in ocs_cam.c List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: imp X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 792e47a51a422ed434ee93d1151737c4d5c9761a Auto-Submitted: auto-generated The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=792e47a51a422ed434ee93d1151737c4d5c9761a commit 792e47a51a422ed434ee93d1151737c4d5c9761a Author: Fuqian Huang AuthorDate: 2024-12-28 21:12:35 +0000 Commit: Warner Losh CommitDate: 2024-12-28 21:12:35 +0000 ocs_fc: print instance_index value rather than pointer itself in ocs_cam.c In function ocs_scsi_recv_tmf, print instance_index rather than the pointer itself to avoid printing out kernel pointer to user space. PR: 238659 Signed-off-by: Fuqian Huang Reviewed-by: imp --- sys/dev/ocs_fc/ocs_cam.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/ocs_fc/ocs_cam.c b/sys/dev/ocs_fc/ocs_cam.c index a944c7628d85..772e7ca1c383 100644 --- a/sys/dev/ocs_fc/ocs_cam.c +++ b/sys/dev/ocs_fc/ocs_cam.c @@ -700,8 +700,8 @@ int32_t ocs_scsi_recv_tmf(ocs_io_t *tmfio, uint64_t lun, ocs_scsi_tmf_cmd_e cmd, trsrc = &fcp->targ_rsrc_wildcard; } - device_printf(tmfio->ocs->dev, "%s: io=%p cmd=%#x LU=%lx en=%s\n", - __func__, tmfio, cmd, (unsigned long)lun, + device_printf(tmfio->ocs->dev, "%s: io=%u(index) cmd=%#x LU=%lx en=%s\n", + __func__, tmfio->instance_index, cmd, (unsigned long)lun, trsrc ? (trsrc->enabled ? "T" : "F") : "X"); if (trsrc) { inot = (struct ccb_immediate_notify *)STAILQ_FIRST(&trsrc->inot);