From owner-freebsd-fs@freebsd.org Wed Apr 7 19:50:22 2021 Return-Path: Delivered-To: freebsd-fs@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 308315C27EB for ; Wed, 7 Apr 2021 19:50:22 +0000 (UTC) (envelope-from alexander.lochmann@tu-dortmund.de) Received: from unimail.uni-dortmund.de (mx1.hrz.uni-dortmund.de [129.217.128.51]) (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 (2048 bits) client-digest SHA256) (Client CN "unimail.tu-dortmund.de", Issuer "DFN-Verein Global Issuing CA" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4FFw3d2Xl1z4gVN for ; Wed, 7 Apr 2021 19:50:20 +0000 (UTC) (envelope-from alexander.lochmann@tu-dortmund.de) Received: from [192.168.111.113] (p4fd97827.dip0.t-ipconnect.de [79.217.120.39]) (authenticated bits=0) by unimail.uni-dortmund.de (8.16.1/8.16.1) with ESMTPSA id 137JoI0W016455 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Wed, 7 Apr 2021 21:50:18 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tu-dortmund.de; s=unimail; t=1617825018; bh=yXBKj17aWR45f1GYHXP4syuXLnZDYBeKQa5+LWGgKtQ=; h=To:From:Subject:Date; b=iXxm1mH9qrpI3eflzqrisIXa70BP6jGFPUoQ+Dyorh68oqDVrc612As4UyVFtctbB el4KXDAIfelrPr98PdkNlEq8T4Sacpy8qO/yj6LboJB+ZBD/9QZNIQHUmQ9wHuQyi+ S1t3LbwLMPD64qTvVswV0JIt6sImA3sD+xYGb8PI= To: freebsd-fs@freebsd.org From: Alexander Lochmann Subject: [struct mount] Outdated locking documentation for mnt_uppers Message-ID: <53c970ad-bd87-5d7b-8a6c-4e526d96b93b@tu-dortmund.de> Date: Wed, 7 Apr 2021 21:50:18 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.9.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: de-DE Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 4FFw3d2Xl1z4gVN X-Spamd-Bar: ----- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=tu-dortmund.de header.s=unimail header.b=iXxm1mH9; dmarc=none; spf=pass (mx1.freebsd.org: domain of alexander.lochmann@tu-dortmund.de designates 129.217.128.51 as permitted sender) smtp.mailfrom=alexander.lochmann@tu-dortmund.de X-Spamd-Result: default: False [-5.20 / 15.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; RWL_MAILSPIKE_GOOD(0.00)[129.217.128.51:from]; R_SPF_ALLOW(-0.20)[+ip4:129.217.128.0/24]; TO_DN_NONE(0.00)[]; RCVD_DKIM_ARC_DNSWL_MED(-0.50)[]; RCVD_IN_DNSWL_MED(-0.20)[129.217.128.51:from]; DKIM_TRACE(0.00)[tu-dortmund.de:+]; NEURAL_HAM_SHORT(-1.00)[-1.000]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:680, ipnet:129.217.0.0/16, country:DE]; MID_RHS_MATCH_FROM(0.00)[]; RECEIVED_SPAMHAUS_PBL(0.00)[79.217.120.39:received]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; R_DKIM_ALLOW(-0.20)[tu-dortmund.de:s=unimail]; FROM_HAS_DN(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-fs@freebsd.org]; DMARC_NA(0.00)[tu-dortmund.de]; RCPT_COUNT_ONE(0.00)[1]; DWL_DNSWL_LOW(-1.00)[tu-dortmund.de:dkim]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[]; MAILMAN_DEST(0.00)[freebsd-fs] X-Mailman-Approved-At: Thu, 08 Apr 2021 04:43:09 +0000 X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Apr 2021 19:50:22 -0000 Hi folks, I came accross the locking documentation for struct mount. According to the definition [1], mnt_uppers should be accessed using the global mountlist_mtx. However, the code uses the MNT_ILOCK macro, which uses the mnt_mtx. Is the locking documentation still valid? Shouldn't it be updated? Regards, Alex [1] https://github.com/freebsd/freebsd-src/blob/main/sys/sys/mount.h#L246 -- Technische Universität Dortmund Alexander Lochmann PGP key: 0xBC3EF6FD Otto-Hahn-Str. 16 phone: +49.231.7556141 D-44227 Dortmund fax: +49.231.7556116 http://ess.cs.tu-dortmund.de/Staff/al