Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751818AbZL3L3Z (ORCPT ); Wed, 30 Dec 2009 06:29:25 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751631AbZL3L3Y (ORCPT ); Wed, 30 Dec 2009 06:29:24 -0500 Received: from mgw1.diku.dk ([130.225.96.91]:45382 "EHLO mgw1.diku.dk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751605AbZL3L3X (ORCPT ); Wed, 30 Dec 2009 06:29:23 -0500 Date: Wed, 30 Dec 2009 12:29:20 +0100 (CET) From: Julia Lawall To: Joe Perches Cc: Rolf Eike Beer , James.Bottomley@suse.de, linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: Re: [PATCH 3/5] drivers/scsi : Correct the size argument to kmalloc In-Reply-To: <1262121796.1888.190.camel@Joe-Laptop.home> Message-ID: References: <200912292102.43373.eike-kernel@sf-tec.de> <1262121796.1888.190.camel@Joe-Laptop.home> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1086 Lines: 27 On Tue, 29 Dec 2009, Joe Perches wrote: > On Tue, 2009-12-29 at 21:04 +0100, Julia Lawall wrote: > > On Tue, 29 Dec 2009, Rolf Eike Beer wrote: > > > Julia Lawall wrote: > > > > From: Julia Lawall > > > > In each case, the destination of the allocation has type struct **, so the > > > > elements of the array should have pointer type, not structure type. > > > Maybe they should even by kcalloc'ed? > > I thought about that, but in response to another patch someone seemed to > > think kcalloc was not very useful. But I can certainly change it in this > > case. > > I think kcalloc is useful and should be used when the > allocated array of elements needs to be zeroed. > > It appears the uses in 1/5 and 3/5 don't need it but > maybe patch 2/5 and 4/5 should use kcalloc. I will look into changing them too. julia -- 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/