Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp3256787ybl; Mon, 19 Aug 2019 15:14:58 -0700 (PDT) X-Google-Smtp-Source: APXvYqwA2E7z0GMvoJpc2YsWyTANgOD3AKQfsPln20Ua4aMCHsCZmXbzrYn6rw83Wdw+3MKe8877 X-Received: by 2002:a17:902:e2:: with SMTP id a89mr25293244pla.210.1566252898516; Mon, 19 Aug 2019 15:14:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1566252898; cv=none; d=google.com; s=arc-20160816; b=IramnKqwP+nT4bFh+BAJ7m0bxbsrxHWA3X/Vua5LZyOT9qOXlZDjdAxn8Rz3eN1MVo qj+nlwF/aZURmAhqFYA2inkPjzGl0tEdha3D03gKpLlcaBGG0bR96gb3dphLSIFm5Zij zvI6mRyD3PPJEkTcTA5lRXtVsqepMNzNgcrdl0bkbKJkVNHeMaFudzWcNYIcdUzuxNrx /ZWgyYzMBx9+OIa5nOddbCtaX86XyHkpZb7Rld7FoJZ0pe3fd8oyIDLP7l48cozeTUWd q7psAIbi7s2wT4jFO+TPOSXswZzybAZgxTqLXhUeP0FFm0yayCRH69As4CnI7tN3FMcq qpEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=aEx2EZhaJyEiLRuv64vgtm7gLoBsbeUkesq3160bNyo=; b=cuvN67qABzIF7yTlg8CxgN/WnxHZDxPWivBclu2g7YvJucEFLpvj00vj/aCOwaEeoe wlgbow4HkN30jAFTw0Yfx6fTcpIVwCGZyX5Ka/MG2+kJ1KK3OnlFvKj2PKyowAiOuHZA Xhmlofz0U8Ymhq2M7aehrJK3Dbe/yDKb55EgUf7/Wc4Vi1F7KgLU/OI3PnKKwKJsTsHw xJSh7dz5zF88U5yT/lM7Xfu3VMwbQOv2DcdmAROHhFyLG+sTAKvn+xXpcp2tVmc7NANF ca1ilwzW+p0+U/B3dGUhZVkrbIpSu9vGT4g7p7qDLbC2ea5FGaZreHmff9MPHao8miyx zimA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=kI9kp010; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id bi7si10658068plb.284.2019.08.19.15.14.42; Mon, 19 Aug 2019 15:14:58 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=kI9kp010; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728545AbfHSWNt (ORCPT + 99 others); Mon, 19 Aug 2019 18:13:49 -0400 Received: from mail.kernel.org ([198.145.29.99]:33064 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728136AbfHSWNs (ORCPT ); Mon, 19 Aug 2019 18:13:48 -0400 Received: from akpm3.svl.corp.google.com (unknown [104.133.8.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id AF79C214DA; Mon, 19 Aug 2019 22:13:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1566252827; bh=4OL6nVB0qLhHMLV1A+Hg935diBRpXnS4haw7ngoM9j4=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=kI9kp010sbLvA9Ywre7pB5dBfmLhakbFcsuorxWOsdV6NmA+5vidwNG0D1bwcxfD5 EJ/hFdkoCAooP46shHMKoYGA4ahBsfgPgTI244f/fzMjmQ5//XKRM3TegfNa+TLMJ2 sdG4xBNmgNek2PkqFsbwyptx/+1k3hlw6wZ10qXE= Date: Mon, 19 Aug 2019 15:13:47 -0700 From: Andrew Morton To: Hugh Dickins Cc: David Howells , Al Viro , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: tmpfs: fixups to use of the new mount API Message-Id: <20190819151347.ecbd915060278a70ddeebc91@linux-foundation.org> In-Reply-To: References: X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.32; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 19 Aug 2019 15:09:14 -0700 (PDT) Hugh Dickins wrote: > Several fixups to shmem_parse_param() and tmpfs use of new mount API: > > mm/shmem.c manages filesystem named "tmpfs": revert "shmem" to "tmpfs" > in its mount error messages. > > /sys/kernel/mm/transparent_hugepage/shmem_enabled has valid options > "deny" and "force", but they are not valid as tmpfs "huge" options. > > The "size" param is an alternative to "nr_blocks", and needs to be > recognized as changing max_blocks. And where there's ambiguity, it's > better to mention "size" than "nr_blocks" in messages, since "size" is > the variant shown in /proc/mounts. > > shmem_apply_options() left ctx->mpol as the new mpol, so then it was > freed in shmem_free_fc(), and the filesystem went on to use-after-free. > > shmem_parse_param() issue "tmpfs: Bad value for '%s'" messages just > like fs_parse() would, instead of a different wording. Where config > disables "mpol" or "huge", say "tmpfs: Unsupported parameter '%s'". Is this Fixes: 144df3b288c41 ("vfs: Convert ramfs, shmem, tmpfs, devtmpfs, rootfs to use the new mount API")? and a Cc:stable is appropriate?