From patchwork Tue Dec 11 17:24:21 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jan Kara X-Patchwork-Id: 10724275 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id BA4B41759 for ; Tue, 11 Dec 2018 17:24:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9BCF92A253 for ; Tue, 11 Dec 2018 17:24:32 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 901142B553; Tue, 11 Dec 2018 17:24:32 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 516902B567 for ; Tue, 11 Dec 2018 17:24:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726864AbeLKRYb (ORCPT ); Tue, 11 Dec 2018 12:24:31 -0500 Received: from mx2.suse.de ([195.135.220.15]:55364 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726402AbeLKRYa (ORCPT ); Tue, 11 Dec 2018 12:24:30 -0500 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 30AF1AD75; Tue, 11 Dec 2018 17:24:29 +0000 (UTC) Received: by quack2.suse.cz (Postfix, from userid 1000) id DF9CD1E13F8; Tue, 11 Dec 2018 18:24:28 +0100 (CET) From: Jan Kara To: Al Viro Cc: , Jan Kara Subject: [PATCH 0/2 RESEND] vfs: Fix crashes when reading /proc/mounts Date: Tue, 11 Dec 2018 18:24:21 +0100 Message-Id: <20181211172423.7709-1-jack@suse.cz> X-Mailer: git-send-email 2.16.4 Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Hello, resending this patch series since I got no reply for almost two months. This patch series aims at fixing possible races between functions formatting output for /proc/mounts and friends and remount. Especially ->show_options functions of filesystems are not counting with the fact that options can change under them and thus races can result in bogus output or outright crashes (like was the case with ext4 handling of quota mount option, or udf could crash when printing charset name, or xfs when printing log device name etc.). Admittedly the patch 2/2 is somewhat ugly because namespace_sem ranks below sb->s_umount semaphore but I think it is bearable. Al, what do you think? Honza