From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753045AbdBJPhb (ORCPT ); Fri, 10 Feb 2017 10:37:31 -0500 Received: from mail-pg0-f68.google.com ([74.125.83.68]:36449 "EHLO mail-pg0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752030AbdBJPh1 (ORCPT ); Fri, 10 Feb 2017 10:37:27 -0500 From: "Youngdo, Lee" To: gregkh@linuxfoundation.org, labbott@redhat.com, sumit.semwal@linaro.org, arve@android.com, riandrews@android.com Cc: devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org, "Youngdo, Lee" Subject: [PATCH] staging: android: ion: fix coding style issue Date: Sat, 11 Feb 2017 00:29:15 +0900 Message-Id: <1486740555-4605-1-git-send-email-oss.ydlee@gmail.com> X-Mailer: git-send-email 1.9.1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Replaced sizeof(struct foo) into sizeof(*ptr), found by checkpatch.pl. Signed-off-by: Youngdo, Lee --- drivers/staging/android/ion/ion_cma_heap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/staging/android/ion/ion_cma_heap.c b/drivers/staging/android/ion/ion_cma_heap.c index 22b9582..6c40685 100644 --- a/drivers/staging/android/ion/ion_cma_heap.c +++ b/drivers/staging/android/ion/ion_cma_heap.c @@ -55,7 +55,7 @@ static int ion_cma_allocate(struct ion_heap *heap, struct ion_buffer *buffer, if (align > PAGE_SIZE) return -EINVAL; - info = kzalloc(sizeof(struct ion_cma_buffer_info), GFP_KERNEL); + info = kzalloc(sizeof(*info), GFP_KERNEL); if (!info) return -ENOMEM; @@ -67,7 +67,7 @@ static int ion_cma_allocate(struct ion_heap *heap, struct ion_buffer *buffer, goto err; } - info->table = kmalloc(sizeof(struct sg_table), GFP_KERNEL); + info->table = kmalloc(sizeof(*info->table), GFP_KERNEL); if (!info->table) goto free_mem; @@ -140,7 +140,7 @@ struct ion_heap *ion_cma_heap_create(struct ion_platform_heap *data) { struct ion_cma_heap *cma_heap; - cma_heap = kzalloc(sizeof(struct ion_cma_heap), GFP_KERNEL); + cma_heap = kzalloc(sizeof(*cma_heap), GFP_KERNEL); if (!cma_heap) return ERR_PTR(-ENOMEM); -- 1.9.1