From nobody Fri Jan 20 03:23:23 2023 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 4NylFS3kbYz30vRD; Fri, 20 Jan 2023 03:23:24 +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 4NylFR5qydz3n9k; Fri, 20 Jan 2023 03:23:23 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674185003; 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=Q0GXGPGai++zQrXtD5oIaiPfMf7IZF6AuKoSqy8fHv8=; b=IGEqgRHQH/1udzJlnibYkhhwinD5zb0qqloutUXoZmmKdnzpaTzKHJw4Tz3a+UHPFR59wI qdDCZp8ToABhBhAtdkF6KGu+sQp3034cIZg6VvwwVxiZsSHB92SrcdkEJXLahoUzHuIGt2 FyC7MFlm8UuT63IjwyfbiEr+XDoSB4OM4SR4iK9cxYV9X8rucneRgpx0mkwqRwNyvty9jq dT/zD84LPc/qwKM0bcFULYCiv1U8mmA5bM3EP/K/ZCn39QMdVT6LISfaPvn+DRGO2FocZb /RkCvBjCVZQTvnJIMuV9sJMrkf/R1ZLy8q9KNrA1wztLeSOamuMnDn61//4Kfw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1674185003; 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=Q0GXGPGai++zQrXtD5oIaiPfMf7IZF6AuKoSqy8fHv8=; b=LEc3i7u0v6+1h/XJtqqdJvGISgbMOahfXPUE0QehcBdZShuhswLv6kYe+A/buMx9bM5WGg MDR68DvOlwX6+suw5IGY29XJ6QPXkbclFBVTgOUY1RGaHRmFZO54vL8jxuattvfeEdeTAa WLEAZpnc9egIefdSQuZQiLpwtHv9yF1klOg00S5P019KrCFhBA0bsRd/JHxw4Yy2MV5wg0 T5I7ELFV3U5NeNQJj4ruHWBoUrdBnnmrhwzPxHRV/pcBhtfUd+XxlHI0PDo8jQLIM8UVar +SuKJcHaez3btlYv6lKIrN+A/mYEmf+ckoQpSPd06RU8V+pesb1kGBT79hMy9Q== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1674185003; a=rsa-sha256; cv=none; b=vjv1YKbNqGzf3hUDXVTiN53lPPrnMhIsGu8t9KtzPR4G28RTvHGr7lLpyGtgSBqpILeu2s r8GgbjUXQyufJEiLeZpMHiDBMkJgCs+6BfKLg0bvEaloG+Cd2I9vttcF+GY0BPwru9UYwV N3OVe88WpULGWwKvJPqr4YNPtsw+Jn5Y57DvwwjCQu6Cx1hjq9marqZkkTkj/qIVSjBCSv D4AgzE3odW1mp2xI6CoNwGuUJD23o4g2RtHzPnreEHg6PB1HUNj5SwCPAS8d77kXQHF8de na9zNC6vhdj2ijQsjIuHQW9NCBE5AJfpGuqU2hXH+x6MgEjgGHJ6dE8FEJM1bQ== 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 4NylFR4VsbzG9J; Fri, 20 Jan 2023 03:23:23 +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 30K3NNgv042085; Fri, 20 Jan 2023 03:23:23 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 30K3NN6m042084; Fri, 20 Jan 2023 03:23:23 GMT (envelope-from git) Date: Fri, 20 Jan 2023 03:23:23 GMT Message-Id: <202301200323.30K3NN6m042084@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Konstantin Belousov Subject: git: 1797e69477cd - stable/13 - tmpfs: minor style 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: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kib X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: 1797e69477cdfbd3f0e59c52fda8a9877f5a6544 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by kib: URL: https://cgit.FreeBSD.org/src/commit/?id=1797e69477cdfbd3f0e59c52fda8a9877f5a6544 commit 1797e69477cdfbd3f0e59c52fda8a9877f5a6544 Author: Konstantin Belousov AuthorDate: 2022-10-24 13:30:38 +0000 Commit: Konstantin Belousov CommitDate: 2023-01-20 03:18:56 +0000 tmpfs: minor style Tested by: pho (cherry picked from commit e77f2f9dc683bb5ac725c5844fc36c831138e841) --- sys/fs/tmpfs/tmpfs_vnops.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/sys/fs/tmpfs/tmpfs_vnops.c b/sys/fs/tmpfs/tmpfs_vnops.c index f46c0ef9490f..788e966fedb7 100644 --- a/sys/fs/tmpfs/tmpfs_vnops.c +++ b/sys/fs/tmpfs/tmpfs_vnops.c @@ -479,8 +479,9 @@ tmpfs_stat(struct vop_stat_args *v) if (vp->v_type == VREG) { obj = node->tn_reg.tn_aobj; sb->st_blocks = (u_quad_t)obj->resident_page_count * PAGE_SIZE; - } else + } else { sb->st_blocks = node->tn_size; + } sb->st_blocks /= S_BLKSIZE; return (vop_stat_helper_post(v, error)); } @@ -513,12 +514,13 @@ tmpfs_getattr(struct vop_getattr_args *v) vap->va_gen = node->tn_gen; vap->va_flags = node->tn_flags; vap->va_rdev = (vp->v_type == VBLK || vp->v_type == VCHR) ? - node->tn_rdev : NODEV; + node->tn_rdev : NODEV; if (vp->v_type == VREG) { obj = node->tn_reg.tn_aobj; vap->va_bytes = (u_quad_t)obj->resident_page_count * PAGE_SIZE; - } else + } else { vap->va_bytes = node->tn_size; + } vap->va_filerev = 0; return (0);