Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752375AbdGGLz6 (ORCPT ); Fri, 7 Jul 2017 07:55:58 -0400 Received: from mga11.intel.com ([192.55.52.93]:36094 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750848AbdGGLz4 (ORCPT ); Fri, 7 Jul 2017 07:55:56 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.40,322,1496127600"; d="scan'208";a="124422213" Message-ID: <1499428551.5590.15.camel@linux.intel.com> Subject: Re: [PATCH] staging: atomisp: replace kmalloc & memcpy with kmemdup From: Alan Cox To: Hari Prasath , mchehab@kernel.org Cc: gregkh@linuxfoundation.org, rvarsha016@gmail.com, julia.lawall@lip6.fr, singhalsimran0@gmail.com, linux-media@vger.kernel.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Date: Fri, 07 Jul 2017 12:55:51 +0100 In-Reply-To: <20170707115044.21744-1-gehariprasath@gmail.com> References: <20170707115044.21744-1-gehariprasath@gmail.com> Organization: Intel Corporation Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.20.5 (3.20.5-1.fc24) Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 222 Lines: 7 On Fri, 2017-07-07 at 17:20 +0530, Hari Prasath wrote: > kmemdup can be used to replace kmalloc followed by a memcpy.This was > pointed out by the coccinelle tool. And kstrdup could do the job even better I think ? Alan