From patchwork Thu Mar 22 10:02:20 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 7401 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 4345A23DEA for ; Thu, 22 Mar 2012 10:02:20 +0000 (UTC) Received: from mail-iy0-f180.google.com (mail-iy0-f180.google.com [209.85.210.180]) by fiordland.canonical.com (Postfix) with ESMTP id DD636A183F0 for ; Thu, 22 Mar 2012 10:02:19 +0000 (UTC) Received: by iage36 with SMTP id e36so3827723iag.11 for ; Thu, 22 Mar 2012 03:02:19 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to :date:message-id:x-mailer:in-reply-to:references:cc:subject :x-beenthere:x-mailman-version:precedence:list-id:list-unsubscribe :list-archive:list-post:list-help:list-subscribe:mime-version :content-type:content-transfer-encoding:sender:errors-to :x-gm-message-state; bh=j/rQrYcz7mldWYdMMGuIkW6iHmwnvmI73WjXAv3wCxw=; b=Sr3d5qtK1DsCvLoy8q3IxTh9Inw6Lunp4o3/JB4nxG0vE0A8icy/AL8uKjw2Q7WQKx mHJffvkUR2y+gaGJuri2WHzg/JHBMqPj8WiqdMOtKt0IDahWLK2RJ44cm4GyIRqVxqIF 88cPM8xqbq2BsxoW9lSPYAZ8BFvWBMa0Bkxc8Tf48Zz6XUMtReXFncSUtnmvYUErQTkP mLjZsbGUZ2t/3yJb+P0hlmzUNDE8/QoRqRZ9ayji2uTft7G+8NFxojTkb34W/JxVXru7 JpjCrwisAQj/5kBhfSlDKq0wqnI+GSGcD0PYy/RviSWfL4Tasb2l4YRdxRJvA/MxyGXV QTrg== Received: by 10.42.72.130 with SMTP id o2mr4859620icj.8.1332410539289; Thu, 22 Mar 2012 03:02:19 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.231.203.79 with SMTP id fh15csp43648ibb; Thu, 22 Mar 2012 03:02:18 -0700 (PDT) Received: by 10.180.95.34 with SMTP id dh2mr3624989wib.15.1332410532512; Thu, 22 Mar 2012 03:02:12 -0700 (PDT) Received: from mombin.canonical.com (mombin.canonical.com. [91.189.95.16]) by mx.google.com with ESMTP id f6si1481239wie.18.2012.03.22.03.02.11; Thu, 22 Mar 2012 03:02:12 -0700 (PDT) Received-SPF: neutral (google.com: 91.189.95.16 is neither permitted nor denied by best guess record for domain of linaro-mm-sig-bounces@lists.linaro.org) client-ip=91.189.95.16; Authentication-Results: mx.google.com; spf=neutral (google.com: 91.189.95.16 is neither permitted nor denied by best guess record for domain of linaro-mm-sig-bounces@lists.linaro.org) smtp.mail=linaro-mm-sig-bounces@lists.linaro.org Received: from localhost ([127.0.0.1] helo=mombin.canonical.com) by mombin.canonical.com with esmtp (Exim 4.71) (envelope-from ) id 1SAeqP-00071c-Ao; Thu, 22 Mar 2012 10:02:09 +0000 Received: from perceval.ideasonboard.com ([95.142.166.194]) by mombin.canonical.com with esmtp (Exim 4.71) (envelope-from ) id 1SAeqN-0006za-DQ for linaro-mm-sig@lists.linaro.org; Thu, 22 Mar 2012 10:02:07 +0000 Received: from localhost.localdomain (ptr-91-87-217-68.mobistar.be [91.87.217.68]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id B54B7362BA; Thu, 22 Mar 2012 11:02:02 +0100 (CET) From: Laurent Pinchart To: Tomasz Stanislawski Date: Thu, 22 Mar 2012 11:02:20 +0100 Message-Id: <1332410543-14433-1-git-send-email-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 1.7.3.4 In-Reply-To: <5187420.ORugDzE4Gp@avalon> References: <5187420.ORugDzE4Gp@avalon> Cc: sumit.semwal@ti.com, robdclark@gmail.com, dri-devel@lists.freedesktop.org, linaro-mm-sig@lists.linaro.org, kyungmin.park@samsung.com, sakari.ailus@iki.fi, Andrzej Pietrasiewicz , airlied@redhat.com, Kamil Debski Subject: [Linaro-mm-sig] [RFCv2 PATCH 2/9 - 1/4] v4l: vb2-dma-contig: Shorten vb2_dma_contig prefix to vb2_dc X-BeenThere: linaro-mm-sig@lists.linaro.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Unified memory management interest group." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linaro-mm-sig-bounces@lists.linaro.org Errors-To: linaro-mm-sig-bounces@lists.linaro.org X-Gm-Message-State: ALoCoQmFpTEQ4zJFL2hz7Mg6SHCitHPwxk2JM4FXBmG7w9o4aqUYyFLSqBDhZy28EnCQ58v1wKya Signed-off-by: Laurent Pinchart --- drivers/media/video/videobuf2-dma-contig.c | 36 ++++++++++++++-------------- 1 files changed, 18 insertions(+), 18 deletions(-) Needless to say, feel free to modify authorship information for these patches based on the original authors. diff --git a/drivers/media/video/videobuf2-dma-contig.c b/drivers/media/video/videobuf2-dma-contig.c index f17ad98..5207eb1 100644 --- a/drivers/media/video/videobuf2-dma-contig.c +++ b/drivers/media/video/videobuf2-dma-contig.c @@ -31,9 +31,9 @@ struct vb2_dc_buf { struct vb2_vmarea_handler handler; }; -static void vb2_dma_contig_put(void *buf_priv); +static void vb2_dc_put(void *buf_priv); -static void *vb2_dma_contig_alloc(void *alloc_ctx, unsigned long size) +static void *vb2_dc_alloc(void *alloc_ctx, unsigned long size) { struct vb2_dc_conf *conf = alloc_ctx; struct vb2_dc_buf *buf; @@ -55,7 +55,7 @@ static void *vb2_dma_contig_alloc(void *alloc_ctx, unsigned long size) buf->size = size; buf->handler.refcount = &buf->refcount; - buf->handler.put = vb2_dma_contig_put; + buf->handler.put = vb2_dc_put; buf->handler.arg = buf; atomic_inc(&buf->refcount); @@ -63,7 +63,7 @@ static void *vb2_dma_contig_alloc(void *alloc_ctx, unsigned long size) return buf; } -static void vb2_dma_contig_put(void *buf_priv) +static void vb2_dc_put(void *buf_priv) { struct vb2_dc_buf *buf = buf_priv; @@ -74,14 +74,14 @@ static void vb2_dma_contig_put(void *buf_priv) } } -static void *vb2_dma_contig_cookie(void *buf_priv) +static void *vb2_dc_cookie(void *buf_priv) { struct vb2_dc_buf *buf = buf_priv; return &buf->dma_addr; } -static void *vb2_dma_contig_vaddr(void *buf_priv) +static void *vb2_dc_vaddr(void *buf_priv) { struct vb2_dc_buf *buf = buf_priv; if (!buf) @@ -90,14 +90,14 @@ static void *vb2_dma_contig_vaddr(void *buf_priv) return buf->vaddr; } -static unsigned int vb2_dma_contig_num_users(void *buf_priv) +static unsigned int vb2_dc_num_users(void *buf_priv) { struct vb2_dc_buf *buf = buf_priv; return atomic_read(&buf->refcount); } -static int vb2_dma_contig_mmap(void *buf_priv, struct vm_area_struct *vma) +static int vb2_dc_mmap(void *buf_priv, struct vm_area_struct *vma) { struct vb2_dc_buf *buf = buf_priv; @@ -110,7 +110,7 @@ static int vb2_dma_contig_mmap(void *buf_priv, struct vm_area_struct *vma) &vb2_common_vm_ops, &buf->handler); } -static void *vb2_dma_contig_get_userptr(void *alloc_ctx, unsigned long vaddr, +static void *vb2_dc_get_userptr(void *alloc_ctx, unsigned long vaddr, unsigned long size, int write) { struct vb2_dc_buf *buf; @@ -137,7 +137,7 @@ static void *vb2_dma_contig_get_userptr(void *alloc_ctx, unsigned long vaddr, return buf; } -static void vb2_dma_contig_put_userptr(void *mem_priv) +static void vb2_dc_put_userptr(void *mem_priv) { struct vb2_dc_buf *buf = mem_priv; @@ -149,14 +149,14 @@ static void vb2_dma_contig_put_userptr(void *mem_priv) } const struct vb2_mem_ops vb2_dma_contig_memops = { - .alloc = vb2_dma_contig_alloc, - .put = vb2_dma_contig_put, - .cookie = vb2_dma_contig_cookie, - .vaddr = vb2_dma_contig_vaddr, - .mmap = vb2_dma_contig_mmap, - .get_userptr = vb2_dma_contig_get_userptr, - .put_userptr = vb2_dma_contig_put_userptr, - .num_users = vb2_dma_contig_num_users, + .alloc = vb2_dc_alloc, + .put = vb2_dc_put, + .cookie = vb2_dc_cookie, + .vaddr = vb2_dc_vaddr, + .mmap = vb2_dc_mmap, + .get_userptr = vb2_dc_get_userptr, + .put_userptr = vb2_dc_put_userptr, + .num_users = vb2_dc_num_users, }; EXPORT_SYMBOL_GPL(vb2_dma_contig_memops);