From patchwork Sun Jan 12 19:06:00 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 1221841 X-Patchwork-Delegate: sjg@chromium.org Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.a=rsa-sha256 header.s=google header.b=OT85j+5d; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 47wmTZ2qNzz9s4Y for ; Mon, 13 Jan 2020 06:08:34 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 89A16817D9; Sun, 12 Jan 2020 20:07:20 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="OT85j+5d"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 047C181717; Sun, 12 Jan 2020 20:07:11 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-0.1 required=5.0 tests=DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_HELO_NONE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-io1-xd41.google.com (mail-io1-xd41.google.com [IPv6:2607:f8b0:4864:20::d41]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 9FF4F816DD for ; Sun, 12 Jan 2020 20:07:07 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd41.google.com with SMTP id b10so7246413iof.11 for ; Sun, 12 Jan 2020 11:07:07 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=vhQxKbIx3XV/TYh5FtASSZ89AJEsemf/7jXYZFa8boI=; b=OT85j+5dP7xzlUKQAv4Ls5NC3WRZCvl+4eESy5y1o5XDnUidRHXo+JT1azkasfFEdW TlC89MjxBpgovECZ/GMIGs4f7j+iQ8xMzH5UWqe0Yr0Cw8NdDt8WRH00VHxnkioBsohX A2HMAdDuzYZGfx+F9mGwosgm/uKBANaMIsuQw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=vhQxKbIx3XV/TYh5FtASSZ89AJEsemf/7jXYZFa8boI=; b=aGjk3FUArv0ZctnZR9JxOYzdkGWhu2mm5Hx3X42WwIcqa5sVDYFz3qB421WEoJLVdH Ham/PR6DmWyKarQejDZM6pqIcJrSwzIL3VTCPLehyB9e0Z2QV0lOCcYrqi4HXdoa1P7n URvD5rI8b+l+ZB++UvZ+oUH1Wia9KoCowELa87xOwOErupvN2Lh5KbmTUTq5qWwxKbK6 +YjvhfqEw7faXFD6mY8vjbnQGmupNPL9OxmohrlLn60O0mdvjaycJM0+Dqsg9TkojtNi 1jtakBZpbmgu/2o3ZLZ64ApwDRuCa9WZvlOCfma3r8TbkxsmG3OL621lzpadUbxAzd/f WJyg== X-Gm-Message-State: APjAAAXhnzR4EaLiTjRISX+H6kguMecvZMsPIgsGiVrfhtknkqPFmsek k1epBy/wfz+hPDuzgZIHCX4DIpiZe74= X-Google-Smtp-Source: APXvYqxKyBbb/0zzV5mw2SpMBd7xSNnVBtQl52JTgyju73lOflNeqQyAOoN/ZtTiS2YcjdI2IO0d7g== X-Received: by 2002:a5d:87d2:: with SMTP id q18mr10768836ios.224.1578856026420; Sun, 12 Jan 2020 11:07:06 -0800 (PST) Received: from kiwi.bld.corp.google.com ([2620:15c:183:0:8223:87c:a681:66aa]) by smtp.gmail.com with ESMTPSA id r22sm3039219ilb.25.2020.01.12.11.07.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 12 Jan 2020 11:07:06 -0800 (PST) From: Simon Glass To: U-Boot Mailing List Subject: [PATCH 09/33] dma: Rename free() to rfree() Date: Sun, 12 Jan 2020 12:06:00 -0700 Message-Id: <20200112120216.9.Ifb04203c2bf46c05eaf0015b1140a2ae4bb3e090@changeid> X-Mailer: git-send-email 2.25.0.rc1.283.g88dfdc4193-goog In-Reply-To: <20200112190624.79077-1-sjg@chromium.org> References: <20200112190624.79077-1-sjg@chromium.org> MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.26 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Peter Ujfalusi , Joe Hershberger Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.101.4 at phobos.denx.de X-Virus-Status: Clean This function name conflicts with our desire to #define free() to something else on sandbox. Since it deals with resources, rename it to rfree(). Signed-off-by: Simon Glass --- drivers/dma/dma-uclass.c | 4 ++-- drivers/dma/sandbox-dma-test.c | 2 +- drivers/dma/ti/k3-udma.c | 2 +- include/dma-uclass.h | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/dma/dma-uclass.c b/drivers/dma/dma-uclass.c index 5598bca21c..a0159d7888 100644 --- a/drivers/dma/dma-uclass.c +++ b/drivers/dma/dma-uclass.c @@ -122,10 +122,10 @@ int dma_free(struct dma *dma) debug("%s(dma=%p)\n", __func__, dma); - if (!ops->free) + if (!ops->rfree) return 0; - return ops->free(dma); + return ops->rfree(dma); } int dma_enable(struct dma *dma) diff --git a/drivers/dma/sandbox-dma-test.c b/drivers/dma/sandbox-dma-test.c index 8fcef1863e..5aa7838ff5 100644 --- a/drivers/dma/sandbox-dma-test.c +++ b/drivers/dma/sandbox-dma-test.c @@ -229,7 +229,7 @@ static const struct dma_ops sandbox_dma_ops = { .transfer = sandbox_dma_transfer, .of_xlate = sandbox_dma_of_xlate, .request = sandbox_dma_request, - .free = sandbox_dma_free, + .rfree = sandbox_dma_free, .enable = sandbox_dma_enable, .disable = sandbox_dma_disable, .send = sandbox_dma_send, diff --git a/drivers/dma/ti/k3-udma.c b/drivers/dma/ti/k3-udma.c index f7128610c5..23d6ed0697 100644 --- a/drivers/dma/ti/k3-udma.c +++ b/drivers/dma/ti/k3-udma.c @@ -1720,7 +1720,7 @@ static const struct dma_ops udma_ops = { .transfer = udma_transfer, .of_xlate = udma_of_xlate, .request = udma_request, - .free = udma_free, + .rfree = udma_free, .enable = udma_enable, .disable = udma_disable, .send = udma_send, diff --git a/include/dma-uclass.h b/include/dma-uclass.h index a1d9d26ac5..340437acc1 100644 --- a/include/dma-uclass.h +++ b/include/dma-uclass.h @@ -58,14 +58,14 @@ struct dma_ops { */ int (*request)(struct dma *dma); /** - * free - Free a previously requested dma. + * rfree - Free a previously requested dma. * * This is the implementation of the client dma_free() API. * * @dma: The DMA to free. * @return 0 if OK, or a negative error code. */ - int (*free)(struct dma *dma); + int (*rfree)(struct dma *dma); /** * enable() - Enable a DMA Channel. *