From nobody Mon Sep 09 22:48:38 2024 X-Original-To: bugs@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 4X2hny5Lnrz5VLBm for ; Mon, 09 Sep 2024 22:48:38 +0000 (UTC) (envelope-from bugzilla-noreply@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 4X2hny11TJz4CRY for ; Mon, 9 Sep 2024 22:48:38 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1725922118; a=rsa-sha256; cv=none; b=EV3ndFaWWqv1TPstO7vQzGXWmQQ/YmJJU1Wmha46ssjybU4XMWj/6+iaev9h66QkT/277C NlFylL0BgXQ6AGgaz1Vdk2YYx9bN16JBufwwih3HuhEoTZrpZxqPnpmiEvusDzQpODy3yC RzHsCwnoiwDj+v1ZlHNVjTc9WITa6dghmv3r43x7hyyQJzg5GmitUlOvB9kAbq0zv9rwSP 4hj9wgSSqmeI+uHHSKx4I/ZgkrVRibgVD+qMn1YjyieUbGgF80HYulLU+UEGYkcwea/J4J uwuHxCcLsmDL8yUSICAKZbo4VwCjd4lx20tdVH1Mzy7mq9j67SnXXXD9dct75g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1725922118; 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=9VQYO9MMq7vIWzCJuPuGzoqSYmaeUk8disvoPWjM+7c=; b=HSGT0y/7VAa9THDOtnskzQGblC+T/4/SGEYC6Mt9Cso4KmFXeLZOkbPWRZFSzI9BeOrdww bmQIMWuHhL2kYRNLBgBQ0vo5HIGfqPWIC13B5SrWHxTgZeFtAZgrzYW9WkNiKIG/kSglX3 nOlEUCbsxs7EYCvd1nh2x4Q8y7a8wc3dtCxyU/aAMA7Hw4dPZuteKzMkywsEvmD0Hatc+a Nm3w/s82pMIffqCuAFSLFjH12zUFy7bqSPObH0ke7ygBain9ups7fQ7wJPfmOnrAB2MP0G ZNknj3XXMKgKFYUQBNfowjVPSm7y5AEpRlxgVirUJXG3O18icgv7AoxLdN9VLQ== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (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 4X2hny0dHCzMQW for ; Mon, 9 Sep 2024 22:48:38 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 489MmbVV087390 for ; Mon, 9 Sep 2024 22:48:37 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 489MmbX6087389 for bugs@FreeBSD.org; Mon, 9 Sep 2024 22:48:37 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 281402] zfs: kmsan reports Uninitialized UMA memory from zio_data_buf_alloc Date: Mon, 09 Sep 2024 22:48:38 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: asomers@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@FreeBSD.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D281402 Bug ID: 281402 Summary: zfs: kmsan reports Uninitialized UMA memory from zio_data_buf_alloc Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: asomers@FreeBSD.org With kmsan enabled, ZFS rapidly reports the use of uninitialized memory whenever a pool uses both raidz and file-backed vdevs. For example: $ truncate -s 1g /tmp/a /tmp/b $ sudo zpool create testpool raidz /tmp/a /tmp/ That is sufficien to generate warnings like this: MSan: Uninitialized UMA memory in g_disk_start, offset 0/32768, addr 0xfffffe00454a4000, from zio_data_buf_alloc+0xd8 #0 0xffffffff833e7ffc at kmsan_report_hook+0x15c #1 0xffffffff82d58ffd at g_disk_start+0x26d #2 0xffffffff82d6e4f7 at g_io_request+0x13e7 #3 0xffffffff82d6e4f7 at g_io_request+0x13e7 #4 0xffffffff846c75c8 at ufs_strategy+0x418 #5 0xffffffff85427a97 at VOP_STRATEGY_APV+0x107 #6 0xffffffff8368ae75 at bufstrategy+0x195 #7 0xffffffff8368a64a at bufwrite+0xc3a #8 0xffffffff8369c518 at vfs_bio_awrite+0x848 #9 0xffffffff8466258f at ffs_syncvnode+0x127f #10 0xffffffff84659f9c at ffs_fsync+0xac #11 0xffffffff85420a77 at VOP_FSYNC_APV+0x107 #12 0xffffffff877a79c0 at zfs_file_fsync+0x200 #13 0xffffffff86f58ad0 at vdev_file_io_start+0x140 #14 0xffffffff878a8253 at zio_vdev_io_start+0xd53 #15 0xffffffff8787b8c0 at zio_nowait+0x6c0 #16 0xffffffff8787b02c at zio_flush+0x13c #17 0xffffffff875fa2b3 at vdev_config_sync+0x563 MSan: Uninitialized UMA memory in dmasync, offset 0/32768, addr 0xfffffe00454a4000, from zio_data_buf_alloc+0xd8 #0 0xffffffff833e7ffc at kmsan_report_hook+0x15c #1 0xffffffff833e7e6b at kmsan_bus_dmamap_sync+0x25b #2 0xffffffff82759f9f at vtblk_request_execute_cb+0x11df #3 0xffffffff8336ccb5 at bus_dmamap_load_mem+0x1975 #4 0xffffffff8336b310 at bus_dmamap_load_bio+0x150 #5 0xffffffff82757867 at vtblk_startio+0xb07 #6 0xffffffff8275aae5 at vtblk_strategy+0x175 #7 0xffffffff82d59e08 at g_disk_start+0x1078 #8 0xffffffff82d6e4f7 at g_io_request+0x13e7 #9 0xffffffff82d6e4f7 at g_io_request+0x13e7 #10 0xffffffff846c75c8 at ufs_strategy+0x418 #11 0xffffffff85427a97 at VOP_STRATEGY_APV+0x107 #12 0xffffffff8368ae75 at bufstrategy+0x195 #13 0xffffffff8368a64a at bufwrite+0xc3a #14 0xffffffff8369c518 at vfs_bio_awrite+0x848 #15 0xffffffff8466258f at ffs_syncvnode+0x127f #16 0xffffffff84659f9c at ffs_fsync+0xac #17 0xffffffff85420a77 at VOP_FSYNC_APV+0x107 Unfortunately, zio_data_buf_alloc is called from 37 different places, and I don't know how to tell which of the callers is responsible for not initiali= zing its memory. --=20 You are receiving this mail because: You are the assignee for the bug.=