From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753860AbcEZMgJ (ORCPT ); Thu, 26 May 2016 08:36:09 -0400 Received: from lists.s-osg.org ([54.187.51.154]:48869 "EHLO lists.s-osg.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753262AbcEZMgG (ORCPT ); Thu, 26 May 2016 08:36:06 -0400 Message-ID: <5746EDAF.7010902@osg.samsung.com> Date: Thu, 26 May 2016 13:35:59 +0100 From: Luis de Bethencourt User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.8.0 MIME-Version: 1.0 To: Shubham Bansal , gregkh@linuxfoundation.org, arve@android.com, riandrews@android.com, labbott@redhat.com, rohit.kr@samsung.com, gioh.kim@lge.com, daniel.vetter@ffwll.ch, kirill.shutemov@linux.intel.com, shawn.lin@rock-chips.com, dy@drexel.edu, neilzhang1123@hotmail.com, eun.taik.lee@samsung.com, sriram@marirs.net.in, tiago.vignatti@intel.com CC: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] Staging: android: ion: fixed a kzalloc coding style issue. References: <1464249674-7812-1-git-send-email-illusionist.neo@gmail.com> In-Reply-To: <1464249674-7812-1-git-send-email-illusionist.neo@gmail.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 26/05/16 09:01, Shubham Bansal wrote: > Fixed a coding style issue. Issue reported by checkpatch.pl. > > Signed-off-by: Shubham Bansal > --- > drivers/staging/android/ion/ion.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c > index 8536567..2217ccb 100644 > --- a/drivers/staging/android/ion/ion.c > +++ b/drivers/staging/android/ion/ion.c > @@ -184,7 +184,7 @@ static struct ion_buffer *ion_buffer_create(struct ion_heap *heap, > struct scatterlist *sg; > int i, ret; > > - buffer = kzalloc(sizeof(struct ion_buffer), GFP_KERNEL); > + buffer = kzalloc(sizeof(*buffer), GFP_KERNEL); > if (!buffer) > return ERR_PTR(-ENOMEM); > > This patch looks good. It is not a big issue, but have it in mind for the future. When fixing issues reported by checkpatch, it is nice to paste the output warning of checkpatch in the commit message. Look at this example: https://git.kernel.org/cgit/linux/kernel/git/next/linux-next.git/commit/?id=e7a142aaa09fa5db015fd176d6943f888665829f Thanks, Luis