From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932272AbbLNLAU (ORCPT ); Mon, 14 Dec 2015 06:00:20 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:19336 "EHLO aserp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932121AbbLNLAT (ORCPT ); Mon, 14 Dec 2015 06:00:19 -0500 Date: Mon, 14 Dec 2015 14:00:03 +0300 From: Dan Carpenter To: SF Markus Elfring Cc: Andreas Dilger , Greg Kroah-Hartman , Oleg Drokin , lustre-devel@lists.lustre.org, devel@driverdev.osuosl.org, Julia Lawall , kernel-janitors@vger.kernel.org, LKML Subject: Re: [PATCH 5/7] staging: lustre: Less checks in mgc_process_recover_log() after error detection Message-ID: <20151214110003.GV5284@mwanda> References: <566ABCD9.1060404@users.sourceforge.net> <566D7733.1030102@users.sourceforge.net> <566D7952.7090401@users.sourceforge.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <566D7952.7090401@users.sourceforge.net> User-Agent: Mutt/1.5.21 (2010-09-15) X-Source-IP: userv0022.oracle.com [156.151.31.74] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Dec 13, 2015 at 02:57:38PM +0100, SF Markus Elfring wrote: > From: Markus Elfring > Date: Sun, 13 Dec 2015 12:21:17 +0100 > > A few checks would be performed by the mgc_process_recover_log() function > even if it is known already that the passed variable "pages" contained > a null pointer. > > * Let us return directly if a call of the kcalloc() function failed. > > * Move assignments for the variables "eof" and "req" behind > this memory allocation. Why? Then in the next patch it moves again. It's like cup shuffle to read these patches sometimes. regards, dan carpenter