From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Sandeen Subject: [PATCH 0/6] fs: fix up error handlers for insert_inode_locked Date: Tue, 06 Dec 2011 16:55:16 -0600 Message-ID: <4EDE9D54.1030506@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit To: "linux-fsdevel@vger.kernel.org" Return-path: Received: from mx1.redhat.com ([209.132.183.28]:61553 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751002Ab1LFWzS (ORCPT ); Tue, 6 Dec 2011 17:55:18 -0500 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id pB6MtHAV019626 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 6 Dec 2011 17:55:18 -0500 Received: from liberator.sandeen.net (ovpn01.gateway.prod.ext.phx2.redhat.com [10.5.9.1]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id pB6MtGqs030775 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Tue, 6 Dec 2011 17:55:17 -0500 Sender: linux-fsdevel-owner@vger.kernel.org List-ID: after 250df6ed274d767da844a5d9f05720b804240197 (fs: protect inode->i_state with inode->i_lock), insert_inode_locked() no longer returns the inode with I_NEW set. However, error handlers still call unlock_new_inode() on failure, which does a WARN_ON if I_NEW is not set, so any failure spews a lot of warnings. Patches follow to skip the call to unlock_new_inode() if insert_inode_locked() fails. -Eric