Received: by 2002:ab2:710b:0:b0:1ef:a325:1205 with SMTP id z11csp919872lql; Tue, 12 Mar 2024 01:51:07 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUsMh/EMAuJj1BY8ehmaxkowL4AODWNLwubIoStIjjFRYvB8LNb+QLLHeNjpbUg+i10xyDSzVjTPQq/ESJsHxFs4zqfChlATU0CTw3a2w== X-Google-Smtp-Source: AGHT+IHaD4awh6cUYXr2HVucae2xz1TBfbz0gBZT8inaXJ+bMh97WtDLoLaf1a2i8Opj28VBL7Q4 X-Received: by 2002:a05:690c:4610:b0:60a:1d7d:b801 with SMTP id gw16-20020a05690c461000b0060a1d7db801mr6822446ywb.1.1710233466857; Tue, 12 Mar 2024 01:51:06 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710233466; cv=pass; d=google.com; s=arc-20160816; b=kUISG3noj+LFF0IbO7rEYia1R9bxL82Ls6beHt67P4R4NtDQsubgcutSmT+S9xIkDX RCpuMiKwkqHttmVZOKBUCGh0VXEzzpEqEgRaj7Yl9J95yn6gBmepoDZIl5xKB2Boqdxo mLQ7q//xmizckdU/7Yh7dswMHyYrCOd0ZOUyQah4sEaSrPtGLxl6X4CEspcV0vgmlPot /11her7rqZvwSX3qdS+wzHPyJUXA8kK2ybR5+120+k8slo7mZqVH5E0s3bC1kal1zIgS v0EdvKdfdnFlUf3i6ONZfiJxLQr0A4jTKbv1AjVhZIdQSUyz9LL7BpzZQWu8sO7GvOW8 8s+g== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=a3Jmq7r1qrsa2BfxePyEQWY3/DbM68gRlP6vHCXoRUk=; fh=kpkUy21MMkjrhh1Gw0bk+8DoCITbWflt8ZZDkOqY4Z0=; b=H/JPiQw9aKE8tBOT+GoSMPZSWsgFolfAXKgMQjSwNB7Yt5MtAePpj0PdyFPmDkmqKZ ALoCypmzbjeZgsNjOma2m6DHht2AAh6mTX9IdCc9QCS1TtSmguPJ9+Pox9XcWq9zz7St KL/CegmMpxCjKywJg7DxYXe5Y3hgsb0SpWB1Ll2mZ0hCqs/wUuqROl8EhJObhP6oFN3Z w9i88h5hwTY+Fh+/zx5xSkW6mhiKDV2VKCYoFzeljW+ESfOuHGCJWnfsXj62w1uGM7Yt yXC4wsmv9jTnv5FRoP52aenmdbCPgIGSFVmDk5IQETCYnTSU7cvmvWXUvZgu2WwyIdhb 8nLg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=GkTfJF0x; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-ext4+bounces-1601-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-ext4+bounces-1601-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id p188-20020a6342c5000000b005dc905460f4si6640106pga.3.2024.03.12.01.51.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Mar 2024 01:51:06 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4+bounces-1601-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=GkTfJF0x; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-ext4+bounces-1601-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-ext4+bounces-1601-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 83154281377 for ; Tue, 12 Mar 2024 08:51:06 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id F01B777F11; Tue, 12 Mar 2024 08:50:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="GkTfJF0x" X-Original-To: linux-ext4@vger.kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 65B876997B; Tue, 12 Mar 2024 08:50:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710233458; cv=none; b=bMm4eYorRAKv8drpXfxIJLrm+t+tVIAwra9At5Ado5qcHqyOQO7+ZTH6JPfQ1HVSAOrw8TaNfKfezxQR8AnQuS5+u9ZWYxQ/ZiVehohk6OBJTDHLyooYUA6wydcvmUpfSL1kmeKNwYCnn44O55gvaZxzz1ztpY1oyOCBjIX2zJ4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710233458; c=relaxed/simple; bh=UkEHwkFP0GJ42KgigzEfzH5VwwhLCveVEoSZfymiQ7Q=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=r59yekzAP2gr7C15HvzRvxvdq3+Ysx4YQGpAtEh89XpCXZrCtB0jxuwlimIfYEcTuxx43mL8S5pMEgx/iKpyRRfg7Lutb/h/v0Dd3eE6DoS28oyVtwc0aRkWgPKMU395o1I0B/E1/MHkYp2LHUWIwxWCmqbe5K5aD9L0z32Lvmc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=GkTfJF0x; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id AEC3EC433C7; Tue, 12 Mar 2024 08:50:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1710233457; bh=UkEHwkFP0GJ42KgigzEfzH5VwwhLCveVEoSZfymiQ7Q=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=GkTfJF0x5UxRgfSyApu4CDiDhrydZ3Zrc4DOd5q55HaVgK7X6kzKBcCWgc/oGyF80 OwBnxAh/BNFL52qSaDo5H6jvVtoTm7pNGMoW5IjEyBaGgvYz4zuTXkYwZiAbu60cR1 Oz2eZYI00wzaFViL+zuME5oxOv9bvtjPejiH6qAP3LBXtYibsYqG7pcYiZh8jd0lqR KHnrLnU1UavaZOvzTDiw3M7K1eR7RFML0kApzy32kIZW9SZ0dVO1PA/uTizKLyKRg9 rjC6sHtQphD5LTZ4PUp4zxxG4VwlFLyknhRX6owfpn0r/C3t+4u/CIbVNdTxLIyxm6 byTbLk3UW5xkQ== Date: Tue, 12 Mar 2024 09:50:46 +0100 From: Christian Brauner To: Jan Kara Cc: Miklos Szeredi , Luis Henriques , Theodore Ts'o , Andreas Dilger , Alexander Viro , Amir Goldstein , linux-ext4@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-unionfs@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 3/3] ovl: fix the parsing of empty string mount parameters Message-ID: <20240312-gaukeln-mehrpolig-8e8fb77f221d@brauner> References: <20240307160225.23841-1-lhenriques@suse.de> <20240307160225.23841-4-lhenriques@suse.de> <87le6p6oqe.fsf@suse.de> <20240311-weltmeere-gesiegt-798c4201c3f8@brauner> <20240311180127.4qdr6ln2xf6vviu3@quack3> Precedence: bulk X-Mailing-List: linux-ext4@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20240311180127.4qdr6ln2xf6vviu3@quack3> On Mon, Mar 11, 2024 at 07:01:27PM +0100, Jan Kara wrote: > On Mon 11-03-24 15:39:39, Miklos Szeredi wrote: > > On Mon, 11 Mar 2024 at 14:25, Christian Brauner wrote: > > > > > Yeah, so with that I do agree. But have you read my reply to the other > > > thread? I'd like to hear your thoughs on that. The problem is that > > > mount(8) currently does: > > > > > > fsconfig(3, FSCONFIG_SET_FLAG, "usrjquota", NULL, 0) = -1 EINVAL (Invalid argument) > > > > > > for both -o usrjquota and -o usrjquota= > > > > For "-o usrjquota" this seems right. > > > > For "-o usrjquota=" it doesn't. Flags should never have that "=", so > > this seems buggy in more than one ways. > > > > > So we need a clear contract with userspace or the in-kernel solution > > > proposed here. I see the following options: > > > > > > (1) Userspace must know that mount options such as "usrjquota" that can > > > have no value must be specified as "usrjquota=" when passed to > > > mount(8). This in turn means we need to tell Karel to update > > > mount(8) to recognize this and infer from "usrjquota=" that it must > > > be passed as FSCONFIG_SET_STRING. > > > > Yes, this is what I'm thinking. Of course this only works if there > > are no backward compatibility issues, if "-o usrjquota" worked in the > > past and some systems out there relied on this, then this is not > > sufficient. > > No, "-o usrjquota" never worked and I'm inclined to keep refusing this > variant as IMHO it is confusing. Tbh, I'm not too sure that having empty string options was a good idea even though it can be useful. I think it would've been better if we had used a specific phantom value to signify this. But yes, I just filed an issue on util-linux to get this fixed. I think we should also util-linux and Karel's up for handling this. > > > > In any case, we need to document what we want: > > > > > > https://github.com/brauner/man-pages-md/blob/main/fsconfig.md > > > > What's the plan with these? It would be good if "man fsconfig" would > > finally work. > > Yes, merging these into official manpages would be nice. I'll try to get around to it.