Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753170AbZJ2P54 (ORCPT ); Thu, 29 Oct 2009 11:57:56 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752651AbZJ2P54 (ORCPT ); Thu, 29 Oct 2009 11:57:56 -0400 Received: from cantor.suse.de ([195.135.220.2]:38184 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752285AbZJ2P5z (ORCPT ); Thu, 29 Oct 2009 11:57:55 -0400 Message-ID: <4AE9BBC6.3070304@suse.de> Date: Thu, 29 Oct 2009 16:59:02 +0100 From: Tejun Heo User-Agent: Thunderbird 2.0.0.23 (X11/20090817) MIME-Version: 1.0 To: Matthew Wilcox Cc: Greg Kroah-Hartman , linux-kernel@vger.kernel.org, Jesse Barnes , linux-pci@vger.kernel.org Subject: Re: [PATCH 1/3] Fix updating of named attribute groups References: <20091020054740.GC29158@parisc-linux.org> <20091020054946.GD29158@parisc-linux.org> In-Reply-To: <20091020054946.GD29158@parisc-linux.org> X-Enigmail-Version: 0.95.7 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 616 Lines: 24 Matthew Wilcox wrote: > + if (update) { > + sd = sysfs_get_dirent(kobj->sd, grp->name); > + if (!sd) > + return -ENOENT; > + } else { > + error = sysfs_create_subdir(kobj, grp->name, &sd); > + if (error) > + return error; > + sysfs_get(sd); > + } > + } else { > + sd = sysfs_get(kobj->sd); > + } nitpick: the last braces aren't necessary. -- tejun -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/