From patchwork Fri Mar 23 15:49:17 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sumit Semwal X-Patchwork-Id: 7434 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 A243D23E01 for ; Fri, 23 Mar 2012 15:50:29 +0000 (UTC) Received: from mail-yw0-f52.google.com (mail-yw0-f52.google.com [209.85.213.52]) by fiordland.canonical.com (Postfix) with ESMTP id 55702A18CE6 for ; Fri, 23 Mar 2012 15:50:29 +0000 (UTC) Received: by yhpp61 with SMTP id p61so3594744yhp.11 for ; Fri, 23 Mar 2012 08:50:28 -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:mime-version:cc:subject:x-beenthere :x-mailman-version:precedence:list-id:list-unsubscribe:list-archive :list-post:list-help:list-subscribe:content-type :content-transfer-encoding:sender:errors-to:x-gm-message-state; bh=k9E2lwGE4lGU/HpA9u5a1B4KG8awtSWS1xsfwkAWyuo=; b=W8WxqU1D66DiJNhudkBStOv07yLUvHoXc+x3RJ615JXlnfblq25Z7T+HM0GBs/+5Sx W4bzBCAaWVEcjseevTgZDk+P+O3V6FXLGmSO4dV3ldKFlsCuFQzfD5bvh0kpbSSP0Jmj QdttiVTG1vZeJW51wqkiq+NeqTty0QVbaRdjulkke7embMqUca8Pxp0rdLYhLxx4CwsR j24siS7Pr5v2zjgqivd5DJrGzdHD/eSJf6PYwMPh6v8ymm4f9G/bfalAKoQUibQkhiOU O5Xx8kxIKehBNpOpw3soKKA24GkMiw6WfaSF7kMuRi3PBH1MSU8uZ6teyDi00AePx2hk Fkcw== Received: by 10.50.155.229 with SMTP id vz5mr2531092igb.12.1332517828665; Fri, 23 Mar 2012 08:50:28 -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 fh15csp27159ibb; Fri, 23 Mar 2012 08:50:27 -0700 (PDT) Received: by 10.216.137.232 with SMTP id y82mr7205203wei.82.1332517821935; Fri, 23 Mar 2012 08:50:21 -0700 (PDT) Received: from mombin.canonical.com (mombin.canonical.com. [91.189.95.16]) by mx.google.com with ESMTP id s15si8960908wec.105.2012.03.23.08.49.50; Fri, 23 Mar 2012 08:50:21 -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 1SB6kM-0001KT-Oa; Fri, 23 Mar 2012 15:49:47 +0000 Received: from comal.ext.ti.com ([198.47.26.152]) by mombin.canonical.com with esmtp (Exim 4.71) (envelope-from ) id 1SB6kK-0001Iu-HY for linaro-mm-sig@lists.linaro.org; Fri, 23 Mar 2012 15:49:44 +0000 Received: from dlep26.itg.ti.com ([157.170.170.121]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id q2NFndc1019006; Fri, 23 Mar 2012 10:49:39 -0500 Received: from DLEE74.ent.ti.com (localhost [127.0.0.1]) by dlep26.itg.ti.com (8.13.8/8.13.8) with ESMTP id q2NFndCM014280; Fri, 23 Mar 2012 10:49:39 -0500 (CDT) Received: from dlelxv24.itg.ti.com (172.17.1.199) by DLEE74.ent.ti.com (157.170.170.8) with Microsoft SMTP Server id 14.1.323.3; Fri, 23 Mar 2012 10:49:39 -0500 Received: from legion.dal.design.ti.com (legion.dal.design.ti.com [128.247.22.53]) by dlelxv24.itg.ti.com (8.13.8/8.13.8) with ESMTP id q2NFndsR011004; Fri, 23 Mar 2012 10:49:39 -0500 Received: from localhost (h16-126.vpn.ti.com [172.24.16.126]) by legion.dal.design.ti.com (8.11.7p1+Sun/8.11.7) with ESMTP id q2NFnaW21418; Fri, 23 Mar 2012 10:49:36 -0500 (CDT) From: Sumit Semwal To: Date: Fri, 23 Mar 2012 21:19:17 +0530 Message-ID: <1332517757-25532-1-git-send-email-sumit.semwal@ti.com> X-Mailer: git-send-email 1.7.5.4 MIME-Version: 1.0 Cc: linaro-mm-sig@lists.linaro.org, Sumit Semwal , dri-devel@lists.freedesktop.org, linux-media@vger.kernel.org Subject: [Linaro-mm-sig] [PATCH] dma-buf: Correct dummy function declarations. 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: , Sender: linaro-mm-sig-bounces@lists.linaro.org Errors-To: linaro-mm-sig-bounces@lists.linaro.org X-Gm-Message-State: ALoCoQkyq4cDc+Byeugtdo/VoeIkRTUyY9drOrGtQuO6jyXi5sEscIfffJx6t4TvhVOfxG78mnLx While testing, I found that we need to correct some of the dummy declarations. When I send my pull request to Linus, I wish to squash these changes into the original patches from Daniel. Could you please review? Best regards, ~Sumit Acked-by: Daniel Vetter ========= Dummy functions for the newly added cpu access ops are needed for compilation when dma-buf framework is not compiled-in. Also, the introduction of flags in dma_buf_fd needs to be added to dummy functions as well. Signed-off-by: Sumit Semwal --- include/linux/dma-buf.h | 26 +++++++++++++------------- 1 files changed, 13 insertions(+), 13 deletions(-) diff --git a/include/linux/dma-buf.h b/include/linux/dma-buf.h index f08028e..779aaf9 100644 --- a/include/linux/dma-buf.h +++ b/include/linux/dma-buf.h @@ -189,7 +189,7 @@ static inline struct dma_buf *dma_buf_export(void *priv, return ERR_PTR(-ENODEV); } -static inline int dma_buf_fd(struct dma_buf *dmabuf) +static inline int dma_buf_fd(struct dma_buf *dmabuf, int flags) { return -ENODEV; } @@ -216,36 +216,36 @@ static inline void dma_buf_unmap_attachment(struct dma_buf_attachment *attach, return; } -static inline int dma_buf_begin_cpu_access(struct dma_buf *, - size_t, size_t, - enum dma_data_direction) +static inline int dma_buf_begin_cpu_access(struct dma_buf *dmabuf, + size_t start, size_t len, + enum dma_data_direction dir) { return -ENODEV; } -static inline void dma_buf_end_cpu_access(struct dma_buf *, - size_t, size_t, - enum dma_data_direction) +static inline void dma_buf_end_cpu_access(struct dma_buf *dmabuf, + size_t start, size_t len, + enum dma_data_direction dir) { } -static inline void *dma_buf_kmap_atomic(struct dma_buf *, unsigned long) +static inline void *dma_buf_kmap_atomic(struct dma_buf *db, unsigned long pnum) { return NULL; } -static inline void dma_buf_kunmap_atomic(struct dma_buf *, unsigned long, - void *) +static inline void dma_buf_kunmap_atomic(struct dma_buf *db, unsigned long pnum, + void *vaddr) { } -static inline void *dma_buf_kmap(struct dma_buf *, unsigned long) +static inline void *dma_buf_kmap(struct dma_buf *db, unsigned long pnum) { return NULL; } -static inline void dma_buf_kunmap(struct dma_buf *, unsigned long, - void *) +static inline void dma_buf_kunmap(struct dma_buf *db, unsigned long pnum, + void *vaddr) { } #endif /* CONFIG_DMA_SHARED_BUFFER */