Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1163321AbbKTTtG (ORCPT ); Fri, 20 Nov 2015 14:49:06 -0500 Received: from shards.monkeyblade.net ([149.20.54.216]:34256 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1161920AbbKTTtD (ORCPT ); Fri, 20 Nov 2015 14:49:03 -0500 Date: Fri, 20 Nov 2015 14:48:59 -0500 (EST) Message-Id: <20151120.144859.248502507361985820.davem@davemloft.net> To: linux@rainbow-software.org Cc: netdev@vger.kernel.org, romieu@fr.zoreil.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/3 v2] dl2k: Handle memory allocation errors in alloc_list From: David Miller In-Reply-To: <1447960386-3049-1-git-send-email-linux@rainbow-software.org> References: <1447960386-3049-1-git-send-email-linux@rainbow-software.org> X-Mailer: Mew version 6.7 on Emacs 24.5 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Fri, 20 Nov 2015 11:49:03 -0800 (PST) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 633 Lines: 15 From: Ondrej Zary Date: Thu, 19 Nov 2015 20:13:04 +0100 > If memory allocation fails in alloc_list(), free the already allocated > memory and return -ENOMEM. In rio_open(), call alloc_list() first and > abort if it fails. Move HW access (set RFDListPtr) out ot alloc_list(). > > Signed-off-by: Ondrej Zary Applied to net-next. -- 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/