Received: by 10.192.165.148 with SMTP id m20csp2458295imm; Sun, 22 Apr 2018 07:27:58 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+a5JlOHJqLWQgSFN60Y0QG8H6YLf+9Yg9P3B1EVub5bBgOcg7RYi0JrKFoeIzNkr1LPReG X-Received: by 2002:a17:902:2c83:: with SMTP id n3-v6mr17835336plb.317.1524407278188; Sun, 22 Apr 2018 07:27:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524407278; cv=none; d=google.com; s=arc-20160816; b=H0K1lDZKrXjYT5JMoO39+gO7XJsQUuPHSlNurtdZvNnG9Gx9skzWugMtFxUrgmlDAp 7gpXMBfkkfA1zm2wh8oHAoVMHqJXc7oLCqNZKYhsyccQFBKoChFn17iKuaPU5ekuIQFf 6MkccA0etptY5sRYr/q7u9g+xG3/HOwlLd9KKIjykfnLIPTd4DCC5vF1TtO+95kudr+R CconUxB8Btu/pCxeQL9b7L4zKx3xEve3Ir5SoAIgdVtNiVrkoY7RSO2xU3DOAp+5Omcv ycusdVX8Jy2oearDyaBLENb16vRy4IXCt1jk3WUO+xKYd9w1nVFjS8W5As88F8XXmIzD eQcQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=a/8OH5sWdgySRpzqDrCaGicZkblPrBqirTLHKU2vRMY=; b=py9t9M28FSfftjK+52yQl6RbWErzvCdSOxVh+zEUlADO8JOkLrVayUvtX9knnlj1FM OVPeaoW6cjN4YRzqjFw8C+AO3mvaXP/vF97F4tf2qec3kxcQjzA9OO2BoqIPKjZXSr04 ynHj1IPyu/E7Y81Ftpf3W/70362fX/9J5Gs1S2B0j9S7p6WpGOAIbPz0XGYUZoUlm+sU euOutBKLdDKSoqLWOa3htpzzvoK5rMyYtz3SYdi40jxi5FuyKtBiELm8bvrcMftzshM+ ogAteoG0aVNYQ0Ex/e/Z4vPf2D0xl5SJSVlQARu1baml6kKQTUSoR3XNina0vxC4/0S8 NX6w== ARC-Authentication-Results: i=1; mx.google.com; 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 k1-v6si9585125pld.267.2018.04.22.07.27.21; Sun, 22 Apr 2018 07:27: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; 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 S1757851AbeDVOZi (ORCPT + 99 others); Sun, 22 Apr 2018 10:25:38 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:33066 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757607AbeDVOVs (ORCPT ); Sun, 22 Apr 2018 10:21:48 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id AC151CEB; Sun, 22 Apr 2018 14:21:47 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Al Viro Subject: [PATCH 3.18 48/52] hypfs_kill_super(): deal with failed allocations Date: Sun, 22 Apr 2018 15:54:21 +0200 Message-Id: <20180422135317.558902601@linuxfoundation.org> X-Mailer: git-send-email 2.17.0 In-Reply-To: <20180422135315.254787616@linuxfoundation.org> References: <20180422135315.254787616@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 3.18-stable review patch. If anyone has any objections, please let me know. ------------------ From: Al Viro commit a24cd490739586a7d2da3549a1844e1d7c4f4fc4 upstream. hypfs_fill_super() might fail to allocate sbi; hypfs_kill_super() should not oops on that. Cc: stable@vger.kernel.org Signed-off-by: Al Viro Signed-off-by: Greg Kroah-Hartman --- arch/s390/hypfs/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/arch/s390/hypfs/inode.c +++ b/arch/s390/hypfs/inode.c @@ -326,7 +326,7 @@ static void hypfs_kill_super(struct supe if (sb->s_root) hypfs_delete_tree(sb->s_root); - if (sb_info->update_file) + if (sb_info && sb_info->update_file) hypfs_remove(sb_info->update_file); kfree(sb->s_fs_info); sb->s_fs_info = NULL;