From patchwork Wed Jul 27 07:37:06 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexey Dobriyan X-Patchwork-Id: 9249391 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 4268660757 for ; Wed, 27 Jul 2016 07:37:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 36528237A5 for ; Wed, 27 Jul 2016 07:37:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 2AEBD26538; Wed, 27 Jul 2016 07:37:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C7ABA237A5 for ; Wed, 27 Jul 2016 07:37:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753229AbcG0HhM (ORCPT ); Wed, 27 Jul 2016 03:37:12 -0400 Received: from mail-lf0-f65.google.com ([209.85.215.65]:34513 "EHLO mail-lf0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753144AbcG0HhL (ORCPT ); Wed, 27 Jul 2016 03:37:11 -0400 Received: by mail-lf0-f65.google.com with SMTP id l69so1583971lfg.1 for ; Wed, 27 Jul 2016 00:37:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:mime-version:content-disposition :user-agent; bh=ilcOULoSsO0LJVp+8Znq97SDJMsr6+A85p+oZIhkQGA=; b=mfmSVowM9bNbYTmUeeZwNP6IO7/AonguUFQq+Qh/Lbao9azZNS1gjqCw4zXEKqUxld rxy0G7mTsAchpeXJbaq6a8YAOMwQ7AQ8XGf4HuPGtet6CuBVdWlY4TvYWEV3uv/oRPsx m8ho0JYqh5tk8+iiaRWF6UVbVmtJ3vCXP8/B7wsAqmDftVq3do34xifEAdm7aPKS0yfO hw94jPtDxoKyzwOj+QZJDvIBF74M2cxgzjbd7bNCAn1JU8iQhhNUi+1Jqmv44TrHOUF8 NfjCt0M2zYtnN9FpSkJqPwny3/+2hTSs+L0Zj3tn9hQ7rbMiz+ID0KMCzxTEotfsUmAV lMbQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:mime-version :content-disposition:user-agent; bh=ilcOULoSsO0LJVp+8Znq97SDJMsr6+A85p+oZIhkQGA=; b=RmwB3lmtv9Be83spkAIHqUAWvlgLiGBlpFLuX0KjPfRf40yEsfQBs8e1vSB8DbhvyO od7YA+D/38sKWd02ofzW7NAU256iEwoz39YlFHbSEueRg7dic6MW5NPN4o5BxwKjt7j5 rEpppCwJWTN+dBkFV5fCLQNEjFNXcDduSodeED3v5jpQ9lq6P69NNat3j2kMOKy9J7mV Jo0hPV/QS26a0/79+0hI3FpUJtcb2Wt72svqgBal8FgKkEAgnP1NOwluo4ytaGhS4M56 FuqQo3AFLBA/1L+q5gaDdfbht4Ffzbrj371jJvAs4eM5HP5Lu//Spu3r0TrPwHT1KHVv IJjQ== X-Gm-Message-State: AEkoous76gBiELPBiAbUYHC/yPnUCIEFNbhcu8T8JOk4nTD0OtOWtpbpJdAq09ogAWuXuQ== X-Received: by 10.25.22.152 with SMTP id 24mr11259493lfw.180.1469605029933; Wed, 27 Jul 2016 00:37:09 -0700 (PDT) Received: from p183.telecom.by (nat5-minsk-pool-46-53-216-214.telecom.by. [46.53.216.214]) by smtp.gmail.com with ESMTPSA id l19sm738724lfi.24.2016.07.27.00.37.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 27 Jul 2016 00:37:09 -0700 (PDT) Date: Wed, 27 Jul 2016 10:37:06 +0300 From: Alexey Dobriyan To: m.szyprowski@samsung.com, s.nawrocki@samsung.com, mchehab@s-opensource.com Cc: linux-media@vger.kernel.org Subject: media: vb2-dma-contig: fix sizeof(pointer) allocation Message-ID: <20160727073706.GA15733@p183.telecom.by> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Alexey Dobriyan --- drivers/media/v4l2-core/videobuf2-dma-contig.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- a/drivers/media/v4l2-core/videobuf2-dma-contig.c +++ b/drivers/media/v4l2-core/videobuf2-dma-contig.c @@ -749,7 +749,7 @@ EXPORT_SYMBOL_GPL(vb2_dma_contig_memops); int vb2_dma_contig_set_max_seg_size(struct device *dev, unsigned int size) { if (!dev->dma_parms) { - dev->dma_parms = kzalloc(sizeof(dev->dma_parms), GFP_KERNEL); + dev->dma_parms = kzalloc(sizeof(*dev->dma_parms), GFP_KERNEL); if (!dev->dma_parms) return -ENOMEM; }