From patchwork Tue Nov 6 05:01:31 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 150240 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3457896ljp; Mon, 5 Nov 2018 21:02:05 -0800 (PST) X-Google-Smtp-Source: AJdET5eOezlyfLDdolIvMwmWHL87b/9nXH9k99GZZhpq7RTTSqDvxzfv8wM0w8f0LqLndU0RmX4U X-Received: by 2002:a62:4586:: with SMTP id n6-v6mr24395587pfi.3.1541480524907; Mon, 05 Nov 2018 21:02:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541480524; cv=none; d=google.com; s=arc-20160816; b=BUsmy+uNrZ4MAJiLdtq60GOB5bekZZ+EkyfG45x2cJMI1c/2ERataGDSx40hZlsfg+ MU5gTsz1r1pd7L3KBySeflZ8ruiLPHEGAREXU4IQKZPO6cZg7KP3/9/oNdohkgFonwtS 4Pr/FOf20hwKoC1H9oj5nKgf8Q8wmmCwN7SaHaeXFggta8MSlZSaGpClJiuJYElQAV4V ZR01jUF1aC9WJ9be3KB/l6kIarRNp/J/ERpXlb4lM4LEaoV1+Pct6SqfpQbNsfjhtDmD W0m/tjQ1pqbDc0wlqsIMEFj2dcF0aWeNHxOCNf72MZf/Jyg87FvY3nElzj0Y+ITzfLU9 FxLA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=ESGwK71J9MVIx0LSTHlmPcydTEacdFoGT0gjQtbEMzs=; b=Nds4s2fIbRESctl5fW79yAveHT4waRNnVW9a5B0wIOrcNSg+bQqygxbcDfwx4jyoGR U1M65ZR/WHhMbxEF9QOZaxXSSIlPrIqqWdwxAYIZOlixIpui+UM/iFOVc19dvfz1fI5B HVNxB0bkAFS0VSZc4rhW/cpymHWShScmhJ7s3a+KukNaBg4+odA3VYz/8E1ryL+f2omY gjEmiYkq6bJazxeOS/b942atmcJLUX1rHoB7ZZ2g4HLRQVQGpLgv+MCTJ4jPbCtwlxiH c6lihBrrZ89fwK1LcYIDxsv10LxZhVwFRg1dE/y9kNCdc7paJD0akWNqkhC2TvxzVGwL F7IA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dLTJjwlO; spf=pass (google.com: best guess record for domain of dmaengine-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=dmaengine-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b13-v6si45251820pgj.154.2018.11.05.21.02.04; Mon, 05 Nov 2018 21:02:04 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of dmaengine-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=dLTJjwlO; spf=pass (google.com: best guess record for domain of dmaengine-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=dmaengine-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729641AbeKFOZZ (ORCPT + 3 others); Tue, 6 Nov 2018 09:25:25 -0500 Received: from mail-pg1-f195.google.com ([209.85.215.195]:35109 "EHLO mail-pg1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729608AbeKFOZZ (ORCPT ); Tue, 6 Nov 2018 09:25:25 -0500 Received: by mail-pg1-f195.google.com with SMTP id 32-v6so5274182pgu.2 for ; Mon, 05 Nov 2018 21:02:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=ESGwK71J9MVIx0LSTHlmPcydTEacdFoGT0gjQtbEMzs=; b=dLTJjwlOqus4VJ2X2QZZEpyQjNlSulx0Gim1Vh811QxB/LzDqpG0UGiybmROP/KVdw 8X1yq/fkyF0Z53QDOdJH29pW3/vgj2YiBaUzHQEAWX9/puxZIYliQk5AdnsdHYZ1ITfM 3vDygDEQvRkyzkYmHAtH8Jw7mL70zqXv6oXRc= 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:in-reply-to:references; bh=ESGwK71J9MVIx0LSTHlmPcydTEacdFoGT0gjQtbEMzs=; b=STRbNx72aw3TpIn4k+bZJiJZPzhGvWaQBHG7PkaHflv0jHZ2VnZx9mPdTEVW+coYGr yUolsuhflCujvFU0Bb1mCh2szCH58fJfRV97WXnUmKwnYcQfz5EVgZnFzOd2mFU5rl5A ricdeQ7Maj/94HrMdZRsibwCMgKF/scaHThWQ3qHYNuLe63QVGUtt+bvvRU7gQTYV91f EBwjPTVkpJJ9GwKxtiqZctZg/VmlZdRhh1fbnXtyyj+dJtWyJG2ibcsyOGqU1jogtaqJ XFrDbxW/jW+HAxOTKIMqxTF0qDDSwdV98HWbnTS3/FeczZqZ0Xm3T2mF/++9O3rKaiL/ lYTQ== X-Gm-Message-State: AGRZ1gKq1XI5OYle7xBZHdUgFT/k01GkKWp9j62o4AP0ZJGLdal27MLH GH8ttfxNcQ8UPXtSnroeQuO51g== X-Received: by 2002:a62:302:: with SMTP id 2-v6mr9584532pfd.135.1541480523186; Mon, 05 Nov 2018 21:02:03 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.102]) by smtp.gmail.com with ESMTPSA id o7-v6sm55735416pfb.23.2018.11.05.21.01.59 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 05 Nov 2018 21:02:02 -0800 (PST) From: Baolin Wang To: dan.j.williams@intel.com, vkoul@kernel.org, eric.long@unisoc.com Cc: broonie@kernel.org, baolin.wang@linaro.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RESEND PATCH 1/7] dmaengine: sprd: Remove direction usage from struct dma_slave_config Date: Tue, 6 Nov 2018 13:01:31 +0800 Message-Id: <0eb7556e7d0a29c7d88e8b67b6228d1ffb332ea9.1541480353.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: In-Reply-To: References: Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org The direction field of struct dma_slave_config was marked deprecated, thus remove the usage. Signed-off-by: Baolin Wang --- drivers/dma/sprd-dma.c | 3 --- 1 file changed, 3 deletions(-) -- 1.7.9.5 diff --git a/drivers/dma/sprd-dma.c b/drivers/dma/sprd-dma.c index 38d4e4f..c226dc93 100644 --- a/drivers/dma/sprd-dma.c +++ b/drivers/dma/sprd-dma.c @@ -847,9 +847,6 @@ static int sprd_dma_slave_config(struct dma_chan *chan, struct sprd_dma_chn *schan = to_sprd_dma_chan(chan); struct dma_slave_config *slave_cfg = &schan->slave_cfg; - if (!is_slave_direction(config->direction)) - return -EINVAL; - memcpy(slave_cfg, config, sizeof(*config)); return 0; } From patchwork Tue Nov 6 05:01:32 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 150241 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3458009ljp; Mon, 5 Nov 2018 21:02:13 -0800 (PST) X-Google-Smtp-Source: AJdET5eQB3hamD9z1xX4qcpwX4j1q3JW1bBbrr9ZT0T8FKIp1TqZVZgDuywr9frlYtKcDYJCOKMg X-Received: by 2002:a17:902:650f:: with SMTP id b15-v6mr24658866plk.2.1541480533736; Mon, 05 Nov 2018 21:02:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541480533; cv=none; d=google.com; s=arc-20160816; b=bSdjIuZCTsOnGKQUpWHEsa/LIA3jjPbKcEWZcaIss4RI0fRfHXJkd/0ZBtbS3nKqfs ygo1q8CycFFJjJ8exrQTXx4jQ5iWMSKmynrvNNxNPePk6nTi+YGQf+Lcz5LVUOdck444 SdAY7dDmyQxFX2q+6YRspHBSS0C1kWPiy7HI1/JOaqSBQpmUDvJM1ZEZDwc5NmphHdae FjJuT8PrabUsSROmujpi9ckerPHxKrefL9DoSKqDMleJGOOiHZ0BlnpWP76O8VSUMfVN ZTV8Vvk7VMlNxsgR69TIrS62uFIyDcLp8cVtGFScP5UOctlkbaXjyCNAEMqt6Gbz8CbI gVdQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=sy/AQFQMaVt4C0zh+b0IOP8wDwMdYLhdTc2K4kZ/W/E=; b=y/uOX5oU0e31x+oEa2eSLQp3g2kEd1zUq/dlDI66PuWVk8/kVPP6xYAZnCW8D0krcT z5zhBzuKth60/wznfbovHOQxihGahb473xKxKPfQoCjflMyVeJUaKUUqnTh+Wui64zsI vF44naOk7nvtfByNe0VlA44UaBlFVkxyGonnuEye8eMJ+hVOUAZ7i7MmcSEwPf2C2IBR Nr8yda0IxNPIyNLPb7PgnLPs++AOLBDrz7g4JYUql5ygBCwcbP7Pbvg+sYbbgzU9Hh3C vx1k3uQF2r4AjuKgyqQ+VWWDV3S89dF0RwonwKqj/x9BWCqEG8nbFH7ZVQd0yUvfumfr guxg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=S+YCR0Nn; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w7-v6si44787070pgh.131.2018.11.05.21.02.13; Mon, 05 Nov 2018 21:02:13 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=S+YCR0Nn; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729791AbeKFOZ2 (ORCPT + 32 others); Tue, 6 Nov 2018 09:25:28 -0500 Received: from mail-pf1-f195.google.com ([209.85.210.195]:36181 "EHLO mail-pf1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729724AbeKFOZ2 (ORCPT ); Tue, 6 Nov 2018 09:25:28 -0500 Received: by mail-pf1-f195.google.com with SMTP id j22-v6so5539152pfh.3 for ; Mon, 05 Nov 2018 21:02:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=sy/AQFQMaVt4C0zh+b0IOP8wDwMdYLhdTc2K4kZ/W/E=; b=S+YCR0NnfFkn0XSpoQbyn6N99EvfFcVtcsSNDeAqW3vUoxp81iTMd1XtpDF7USkANh fQM8DVG9Tye6T7w6cM1dn1glzsTnzrBFDQf+ScM5967tKT+c70ssVf0jjbR1WVrUvEUs CMboNPqZTUpwKgFrOPswpHOLTZL2fO2HKt2p0= 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:in-reply-to:references; bh=sy/AQFQMaVt4C0zh+b0IOP8wDwMdYLhdTc2K4kZ/W/E=; b=SArCUE3ThS5itLzAb36ySZjK9X2BoVz8ADkinUyDGK07vAYNvWkyjJwO7GWGMjjR9Y uiGOEwCyD1DIrCsKu6naowU3SFLY0/nI3sQEgL7Un4mcC6bvwJH8jK7NUavzVWWhxIkQ 1Hl+THPnKufb9AJrociuiNIzuPkT4wsUrkiy2uWaufB1znlU9/tdpALQE6hFx19M6QU6 aBfc56D4UNMkRC7xNC6XtIu9p1jRIvogwVLDvGRkQegX3X4r0d6hhKOsqgHXLRIWoVVa n7gAEIJ5gu7erGHb3FpoFUJtniBvQTvYzkfErq9H6LZwezJ8EXLEwCUCYFbud08/a2cY gDqw== X-Gm-Message-State: AGRZ1gIE2CbtGV8q4KuAnxe/vz2gTTNHixZpVxDUgSp8pdTKO4HhhccZ sdoNJ1r7Lu8xWQlK6q5YxLP3SA== X-Received: by 2002:a63:2e02:: with SMTP id u2mr2621110pgu.9.1541480525976; Mon, 05 Nov 2018 21:02:05 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.102]) by smtp.gmail.com with ESMTPSA id o7-v6sm55735416pfb.23.2018.11.05.21.02.03 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 05 Nov 2018 21:02:05 -0800 (PST) From: Baolin Wang To: dan.j.williams@intel.com, vkoul@kernel.org, eric.long@unisoc.com Cc: broonie@kernel.org, baolin.wang@linaro.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RESEND PATCH 2/7] dmaengine: sprd: Get transfer residue depending on the transfer direction Date: Tue, 6 Nov 2018 13:01:32 +0800 Message-Id: <2968b6dce6864608b97391e5b86ee3c47e3fb8e6.1541480353.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Eric Long Add one field to save the transfer direction for struct sprd_dma_desc, which is used to get correct transfer residue depending on the transfer direction. [Baolin Wang adds one field to present the transfer direction] Signed-off-by: Eric Long Signed-off-by: Baolin Wang --- drivers/dma/sprd-dma.c | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) -- 1.7.9.5 diff --git a/drivers/dma/sprd-dma.c b/drivers/dma/sprd-dma.c index c226dc93..4f3587b 100644 --- a/drivers/dma/sprd-dma.c +++ b/drivers/dma/sprd-dma.c @@ -159,6 +159,7 @@ struct sprd_dma_chn_hw { struct sprd_dma_desc { struct virt_dma_desc vd; struct sprd_dma_chn_hw chn_hw; + enum dma_transfer_direction dir; }; /* dma channel description */ @@ -331,6 +332,17 @@ static void sprd_dma_stop_and_disable(struct sprd_dma_chn *schan) sprd_dma_disable_chn(schan); } +static unsigned long sprd_dma_get_src_addr(struct sprd_dma_chn *schan) +{ + unsigned long addr, addr_high; + + addr = readl(schan->chn_base + SPRD_DMA_CHN_SRC_ADDR); + addr_high = readl(schan->chn_base + SPRD_DMA_CHN_WARP_PTR) & + SPRD_DMA_HIGH_ADDR_MASK; + + return addr | (addr_high << SPRD_DMA_HIGH_ADDR_OFFSET); +} + static unsigned long sprd_dma_get_dst_addr(struct sprd_dma_chn *schan) { unsigned long addr, addr_high; @@ -534,7 +546,12 @@ static enum dma_status sprd_dma_tx_status(struct dma_chan *chan, else pos = 0; } else if (schan->cur_desc && schan->cur_desc->vd.tx.cookie == cookie) { - pos = sprd_dma_get_dst_addr(schan); + struct sprd_dma_desc *sdesc = to_sprd_dma_desc(vd); + + if (sdesc->dir == DMA_DEV_TO_MEM) + pos = sprd_dma_get_dst_addr(schan); + else + pos = sprd_dma_get_src_addr(schan); } else { pos = 0; } @@ -804,6 +821,8 @@ static int sprd_dma_fill_linklist_desc(struct dma_chan *chan, if (!sdesc) return NULL; + sdesc->dir = dir; + for_each_sg(sgl, sg, sglen, i) { len = sg_dma_len(sg); From patchwork Tue Nov 6 05:01:33 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 150242 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3458015ljp; Mon, 5 Nov 2018 21:02:14 -0800 (PST) X-Google-Smtp-Source: AJdET5dWdWaD4ipUzjP+QdKyKDe13VHD1ci6ocOrU9TblxfnbPNKm7BiIBUDSCROvf08qs+aFCev X-Received: by 2002:a63:d441:: with SMTP id i1-v6mr3838726pgj.31.1541480534096; Mon, 05 Nov 2018 21:02:14 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541480534; cv=none; d=google.com; s=arc-20160816; b=Bir/OWzOSom0binpMc4lyUiBVk7J5C1UoVWs1Ihh0Io7cQXwLw961f5FAv1GA5Pn8U OTV6rn3YriWzEsia+0sBFunx8VHF9XYeTqc4+Ijcm2rIcPxbUFjMS0Dwet+EER76olQA SocKMBqQLsUNSh1j1DCrvdNBmAWidBE0CEqzinOWMHsE5NTNOaxUALKPk71fIOtUyL5f 8/P7RZK2nLbb6JqIKtc0CdrNcLzmJKORjkxAKJHr1rTvUkM5H5fS8rFzzTcInSgMlc2c rbGUP/2p0eUymS9Afka5ykJRc+ABLNry0640w5E1laOV5h62ux6On0yU9q76fQnfwmdn wjhw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=Ipu0OKiVTAGWTLE4fg/nM2ymSy+8y5EVSd0lvjhlhp8=; b=pA5Q+n2+haTzspPorBVLs74PdryJv0DJVFiobOb1UcsIidaNm2/tiP9EcWJ7bycyRh ytzSQ0QoeMrkfhMRXp4VwpV6Ew2hyk7OduSdaNeQPK3q1zJdtB7L+TSsdBd1As6yrDqx y71c/OMDVhYr6l7R88kAg0ksIhVD0KJaqGRTKuT8YfgK3WLmPLMJAe6mATwQQSSaT8mR sOJQP6azxcHVcjHoqmm1Evc4wgGHyQ04vILywx//ofuXnzcRVNrIwS+5fUcMl9dOGmdG jOZ8WrTk71TXMOT7XWnsG1AzbOzGv0ox0FzAGej6/odJe3JoZz6nIyLD55q1hnGs8gsc Riyw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gutae7G7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w7-v6si44787070pgh.131.2018.11.05.21.02.13; Mon, 05 Nov 2018 21:02:14 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gutae7G7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729852AbeKFOZb (ORCPT + 32 others); Tue, 6 Nov 2018 09:25:31 -0500 Received: from mail-pl1-f194.google.com ([209.85.214.194]:40509 "EHLO mail-pl1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729794AbeKFOZb (ORCPT ); Tue, 6 Nov 2018 09:25:31 -0500 Received: by mail-pl1-f194.google.com with SMTP id q19-v6so2579118pll.7 for ; Mon, 05 Nov 2018 21:02:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=Ipu0OKiVTAGWTLE4fg/nM2ymSy+8y5EVSd0lvjhlhp8=; b=gutae7G74a5xWjvogNtC3uF7yCVomb6SNDj4i/rOZwIqyQrrPMcLKpUVx0rsnX15Ju kE3KVj6sicYEePLve7JYvmafJCZsUduo0QgnTSQFHG2AvthQXdg3uIeN7/WCdzg61MOC MlSY9nCD6TpzzC31M86yCd7b1Xa81FTIzHdoM= 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:in-reply-to:references; bh=Ipu0OKiVTAGWTLE4fg/nM2ymSy+8y5EVSd0lvjhlhp8=; b=FHRu2RaHfNhOfxaoBm1wxElg6JRsBZ/GJ3Xn5ZCLGjlSwdTEY7nc0WwFIy0fD1LDeM xPANDb4IWwxoKoAE3Ychs2Dbfzv82g/lA6NOTpwMNT/ERgxKHqkovmCW6xinlAeAQNm8 O9A0Bss6K7AEx+Tf+aeCOfkK7Xv+gvIto6F8OSPK/LygSVDT1ElnVer07UBGBpE1aFjE shNVmAb9hOQuOTPgfN4WJ/fH9dpKIhlqHLrSUDBt5G6Y7cs29E+RGT4Hntq66q47vrZY 2hniYaX2E2jwbhaZIUUmdt50mcg3nctMYbsYWM2qQ+Z6g0lVn2kK+735embwbOiKonAc tANQ== X-Gm-Message-State: AGRZ1gIPAiTodEn1L5ukZko0qtJ7uPFFhUQFFKCAi/iQ3Vrl0QJ8Jh1z bNgzQZcK+3bmWKXFxuLt/I5kEQ== X-Received: by 2002:a17:902:4222:: with SMTP id g31-v6mr24679107pld.236.1541480528979; Mon, 05 Nov 2018 21:02:08 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.102]) by smtp.gmail.com with ESMTPSA id o7-v6sm55735416pfb.23.2018.11.05.21.02.06 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 05 Nov 2018 21:02:08 -0800 (PST) From: Baolin Wang To: dan.j.williams@intel.com, vkoul@kernel.org, eric.long@unisoc.com Cc: broonie@kernel.org, baolin.wang@linaro.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RESEND PATCH 3/7] dmaengine: sprd: Fix the last link-list configuration Date: Tue, 6 Nov 2018 13:01:33 +0800 Message-Id: <95cbea4b835bb2689036afe78ff0b2239a24f352.1541480353.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Eric Long We will pass sglen as 0 configure the last link-list configuration when filling the descriptor, which will cause the incorrect link-list configuration. Thus we should check if the sglen is 0 to configure the correct link-list configuration. Signed-off-by: Eric Long Signed-off-by: Baolin Wang --- drivers/dma/sprd-dma.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- 1.7.9.5 diff --git a/drivers/dma/sprd-dma.c b/drivers/dma/sprd-dma.c index 4f3587b..e6a74dc 100644 --- a/drivers/dma/sprd-dma.c +++ b/drivers/dma/sprd-dma.c @@ -697,7 +697,8 @@ static int sprd_dma_fill_desc(struct dma_chan *chan, hw->cfg |= SPRD_DMA_LINKLIST_EN; /* link-list index */ - temp = (sg_index + 1) % sglen; + temp = sglen ? (sg_index + 1) % sglen : 0; + /* Next link-list configuration's physical address offset */ temp = temp * sizeof(*hw) + SPRD_DMA_CHN_SRC_ADDR; /* From patchwork Tue Nov 6 05:01:34 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 150243 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3458040ljp; Mon, 5 Nov 2018 21:02:16 -0800 (PST) X-Google-Smtp-Source: AJdET5fXXMoKSRCRebK7eJn63kXSoCMgJghXxZyfLWzZCx25V4owv0K16dpET8QZAwk6cVMrZas0 X-Received: by 2002:a17:902:c01:: with SMTP id 1-v6mr24948236pls.15.1541480536582; Mon, 05 Nov 2018 21:02:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541480536; cv=none; d=google.com; s=arc-20160816; b=QXulqGNdmC30+AG8jpD9AyJp/Pou39SKMQU9viQvmvS9M3fTWTkp+ictr+XxNO00I0 3tz3/4XE1o7aH6+PpdxtYycC4YVvOvXyzyd2p+76ifYFv0w4H4bgXbg0CwI7PQzRa4t+ aWK4j24HTrIQkvXczFU8ni/BR5hZpuXi44zIuCtvMguB6a5MnGg4MNe/0JYLK9IhigEg QxBmqsRzi7MbLRTyUiHiCf2ML2DVnwwQlmpjFy6o8NRQEz7NipRa7BxUydRXQtvXMMtK iobu6oKkkqKAT07mOKqdsO8KSqHupPBCqZOVY6CI6KGK1C6STm1xMkXXCxS70LwykZmZ NCFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=VKu6Lyuuq1HCg2vjK0SKqBKedEZKBAaQkFejaBLFPf0=; b=GzzKDVlLfzeuPqga9roW/EijVshZ3oknwZYx6799Kdnkd6VjZiDFkmpBGskhc8LGK2 p+Q5FNzPS3ZUmS4Q2raQAAwpZkfZF1Bjdd0vGgsfaQh7BEZxmas0OF8Nz0enNOkSSfKA zUDUqnq4rDfckqmOU9AQeF1a63idWWMmwMvptbH9Q5dciJyJmUaliYsbZxWFL1frEpFn m3sDBWpoWQKzJfvZdPDqjN27Y8lbHpFEIgmPfjI4PbEZAqiqFNB90vwvfWzoYwfvomjh SRv7MQTIvDpyhRrk9xva9a94ZEG7I15U/NVzC+8z5BLQSpCCjlmFB3+ZK27SStGh7xoR /a1g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=P5pOzBEP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r7-v6si4317517plo.100.2018.11.05.21.02.16; Mon, 05 Nov 2018 21:02:16 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=P5pOzBEP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387441AbeKFOZe (ORCPT + 32 others); Tue, 6 Nov 2018 09:25:34 -0500 Received: from mail-pf1-f194.google.com ([209.85.210.194]:44711 "EHLO mail-pf1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729794AbeKFOZe (ORCPT ); Tue, 6 Nov 2018 09:25:34 -0500 Received: by mail-pf1-f194.google.com with SMTP id j13-v6so5515328pff.11 for ; Mon, 05 Nov 2018 21:02:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=VKu6Lyuuq1HCg2vjK0SKqBKedEZKBAaQkFejaBLFPf0=; b=P5pOzBEPVvT+v94DFEU22LAsgxhHRTt6Ea6meOS+GbP+YI+0kE5s7mOwEVDwpyE7GE xN8AUVPCtu0UPYvze/fOUyRJ8UmOOoHj2pvwkgho1DdT03DyfSEbj8aXIt9cpvE48ju9 mG0ZWl+bbahRA3mvPwY8FbjEg1MpxHMbhmdKM= 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:in-reply-to:references; bh=VKu6Lyuuq1HCg2vjK0SKqBKedEZKBAaQkFejaBLFPf0=; b=CLLGsDMe5OCExtzUP/C7ldcGmpi7c/RSisecPsf8ePZmVncCbmdv4pu9YjGfSYUy1F YON802WKSRvE04i3JQfsodnNTK15LfcWaqYMENCHauObDn0zKZX66IAQomYIQYYPGufc 5N1KsMUNN3UmAVQVzyDrMnxkjdf6TPja1/zMwbXFV3YfqzSz6OjnbKTjjPiT0LJPXEJ5 wNiczXju1pn5/rN3cNv5Pg1ZWdWQv+k4Xhi4aqU5qHJiW6mR+l8R0XUJgT67GWs3NHRd 3AlOKfZU1Zw1K9Xk2BFsqhZYMYEYabe5/kneuWlpeThv4uL7qYgElV9uh5l3q3R5hrbv b6Jw== X-Gm-Message-State: AGRZ1gJVzIZA4T7UQLSEmnJbONy65fyBumEPavNlSqszzLpfEfx+eajZ 5PY5EQuJivdgkZ6kuDO5Hx8c2w== X-Received: by 2002:a63:d655:: with SMTP id d21mr13363464pgj.280.1541480531978; Mon, 05 Nov 2018 21:02:11 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.102]) by smtp.gmail.com with ESMTPSA id o7-v6sm55735416pfb.23.2018.11.05.21.02.09 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 05 Nov 2018 21:02:11 -0800 (PST) From: Baolin Wang To: dan.j.williams@intel.com, vkoul@kernel.org, eric.long@unisoc.com Cc: broonie@kernel.org, baolin.wang@linaro.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RESEND PATCH 4/7] dmaengine: sprd: Set cur_desc as NULL when free or terminate one dma channel Date: Tue, 6 Nov 2018 13:01:34 +0800 Message-Id: <4b13aba73775582aa570212a1dccc6c511031de6.1541480353.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Eric Long It will be failed to start one new transfer if the channel started one none interrupt transfer before, since we will only set the schan->cur_desc as NULL depending on the transfer interrupt now. Thus we should set schan->cur_desc as NULL when free or terminate one dma channel to avoid this issue. Signed-off-by: Eric Long Signed-off-by: Baolin Wang --- drivers/dma/sprd-dma.c | 1 + 1 file changed, 1 insertion(+) -- 1.7.9.5 diff --git a/drivers/dma/sprd-dma.c b/drivers/dma/sprd-dma.c index e6a74dc..1b39661 100644 --- a/drivers/dma/sprd-dma.c +++ b/drivers/dma/sprd-dma.c @@ -439,6 +439,7 @@ static void sprd_dma_stop(struct sprd_dma_chn *schan) sprd_dma_stop_and_disable(schan); sprd_dma_unset_uid(schan); sprd_dma_clear_int(schan); + schan->cur_desc = NULL; } static bool sprd_dma_check_trans_done(struct sprd_dma_desc *sdesc, From patchwork Tue Nov 6 05:01:35 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 150244 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3458058ljp; Mon, 5 Nov 2018 21:02:18 -0800 (PST) X-Google-Smtp-Source: AJdET5dIx3IFGFhYVk1acVCchLGsjL8wd6Q8qEc6amGBY0bAx07SUeUgRfhLoWQX0k/lLxQ7gRQu X-Received: by 2002:a62:4784:: with SMTP id p4-v6mr24408320pfi.257.1541480538473; Mon, 05 Nov 2018 21:02:18 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541480538; cv=none; d=google.com; s=arc-20160816; b=VhUJIj9aPVAJMFqtx7bisdsx6NkywpQ3KpwNHDrAjL4bBrWPzrdAi4MAGlx/BzBmaf KBz5ZmGuRmJKRP3FccrjLn0zZClUbV9Dsw4DGC3IOWaGMgs+JfoEyWeOCR72JXan+rpk objD8m68iXqb8vqAfuAR70NacVKIaQfiORz3OMYlcAvKXXxwl0eaH5Up8JuxYQkq86Cy Mh3IsUEBJJGChilMDR19rQfvrLRnh7xuNwTDcph+TfbCGP1xKSEBZMzL3WLH24dmC2n+ p1ztMLRRn3NGisHTWzqCx9gjcRMoFbEqacPsrHkKu9sykOwz4mnqHSLKZhG9j0o5YTtz 4cEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=Ig1u0SVMDYDTOMNzrGMHK+hoBj16/oLyBxKtaJt37JU=; b=PHE6YmWO2I03SRHpEzS6nYZY/FDxXkflAIij04LAQn+z9lJ3Scm6NQ+mriZioyPv0/ hbf756B97dsZ9eC23oiFgI4mp1ZV1f8E/UkIsEVn1afICifLZwWOJNyRmGX1oBzEeWb7 iqEhJMXHWxADwu9P6PQapZShEJ/CQVmvSdzjuN0tQOOvTTRcr/ANbyuEXYUqbLvmq5ac CZSnj/Kw+BtzkaZDa9UMRkbUJYKFJa7ThoE4b7ZRjj0qk1ydzmVlgB7sIafwJfVGG0PN BpiRcueUthxmcTY9jvRYtAfOHomkiMUi8FyBfH8Cb0A963M2ES6UZkScXkDmqHcWVr68 1CtQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=An5a6era; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r2-v6si34917974pgk.137.2018.11.05.21.02.18; Mon, 05 Nov 2018 21:02:18 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=An5a6era; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387485AbeKFOZh (ORCPT + 32 others); Tue, 6 Nov 2018 09:25:37 -0500 Received: from mail-pf1-f196.google.com ([209.85.210.196]:44716 "EHLO mail-pf1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387444AbeKFOZh (ORCPT ); Tue, 6 Nov 2018 09:25:37 -0500 Received: by mail-pf1-f196.google.com with SMTP id j13-v6so5515382pff.11 for ; Mon, 05 Nov 2018 21:02:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=Ig1u0SVMDYDTOMNzrGMHK+hoBj16/oLyBxKtaJt37JU=; b=An5a6eraHBGxYnTEnYSGMSvJom+BfCzLpM/xs8uLYjgucl2r1i+avUxJxJy1IhaTCo dis9DzuoqlpgedC8n3Hl66n2OZHtyVZVec8W4yQsZK3iBJg804l4GYJnE8zQ/luHWuG+ cj/XqQjPHZrN7wrF9VErJP6wViuwoIvYgy3WI= 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:in-reply-to:references; bh=Ig1u0SVMDYDTOMNzrGMHK+hoBj16/oLyBxKtaJt37JU=; b=hWBzcNLcG24Si7ND3YgZxmdG9jD/CxzpqXxYrJQ/4C65dee/Tg+8lSQquWGc0vRZmF 8Hndh313d2z8+Eex9LB31X/1jD1ijPhm2z6bq+88krFVgKYEPnEJMzkFAB66CoCnH0c2 g0/W95Q9fel8LEFeLtyCaDTOUKCLYisVaTBqCJgg7+vm345A2ft0SUPjl1ajzyJcjRWn EKBu+F/CJ1SNBWSwwscbSBYGwCJrZxgskR03ojkAqrw7KON2K0+92Ph/+BwL9FPBC5zZ 3bYO/M2D3qDut7VqPBD1ZAUaOndQvZigexrtdYEKgqWL/WYt5UrDyt5Z17RN49vSaV5e lsnA== X-Gm-Message-State: AGRZ1gKp8bDxgp1hC2wZY75HWOGHJW+3DRryENJ8EMJaM+RmMdV2uquw +ml4m5BJk8k7yyZWDx8gZJoUvQ== X-Received: by 2002:a63:d157:: with SMTP id c23mr6593019pgj.170.1541480534703; Mon, 05 Nov 2018 21:02:14 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.102]) by smtp.gmail.com with ESMTPSA id o7-v6sm55735416pfb.23.2018.11.05.21.02.12 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 05 Nov 2018 21:02:14 -0800 (PST) From: Baolin Wang To: dan.j.williams@intel.com, vkoul@kernel.org, eric.long@unisoc.com Cc: broonie@kernel.org, baolin.wang@linaro.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RESEND PATCH 5/7] dmaengine: sprd: Support DMA link-list cyclic callback Date: Tue, 6 Nov 2018 13:01:35 +0800 Message-Id: X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Eric Long The Spreadtrum DMA link-list mode is always one cyclic transfer, so we should clear the SPRD_DMA_LLIST_END flag for the link-list configuration. Moreover add cyclic callback support for the cyclic transfer. Signed-off-by: Eric Long Signed-off-by: Baolin Wang --- drivers/dma/sprd-dma.c | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) -- 1.7.9.5 diff --git a/drivers/dma/sprd-dma.c b/drivers/dma/sprd-dma.c index 1b39661..cefe42f 100644 --- a/drivers/dma/sprd-dma.c +++ b/drivers/dma/sprd-dma.c @@ -463,7 +463,7 @@ static irqreturn_t dma_irq_handle(int irq, void *dev_id) struct sprd_dma_desc *sdesc; enum sprd_dma_req_mode req_type; enum sprd_dma_int_type int_type; - bool trans_done = false; + bool trans_done = false, cyclic = false; u32 i; while (irq_status) { @@ -478,13 +478,19 @@ static irqreturn_t dma_irq_handle(int irq, void *dev_id) sdesc = schan->cur_desc; - /* Check if the dma request descriptor is done. */ - trans_done = sprd_dma_check_trans_done(sdesc, int_type, - req_type); - if (trans_done == true) { - vchan_cookie_complete(&sdesc->vd); - schan->cur_desc = NULL; - sprd_dma_start(schan); + /* cyclic mode schedule callback */ + cyclic = schan->linklist.phy_addr ? true : false; + if (cyclic == true) { + vchan_cyclic_callback(&sdesc->vd); + } else { + /* Check if the dma request descriptor is done. */ + trans_done = sprd_dma_check_trans_done(sdesc, int_type, + req_type); + if (trans_done == true) { + vchan_cookie_complete(&sdesc->vd); + schan->cur_desc = NULL; + sprd_dma_start(schan); + } } spin_unlock(&schan->vc.lock); } @@ -692,9 +698,6 @@ static int sprd_dma_fill_desc(struct dma_chan *chan, /* link-list configuration */ if (schan->linklist.phy_addr) { - if (sg_index == sglen - 1) - hw->frg_len |= SPRD_DMA_LLIST_END; - hw->cfg |= SPRD_DMA_LINKLIST_EN; /* link-list index */ From patchwork Tue Nov 6 05:01:36 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 150245 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3458106ljp; Mon, 5 Nov 2018 21:02:22 -0800 (PST) X-Google-Smtp-Source: AJdET5d0wGNKS/RTYWvJDuwP30hkTYta6+9/IQuaIO+fSA0SebPW0yuNWKHeBZ16zZJmWmjh0H5A X-Received: by 2002:a62:5441:: with SMTP id i62-v6mr25073114pfb.155.1541480542046; Mon, 05 Nov 2018 21:02:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541480542; cv=none; d=google.com; s=arc-20160816; b=Xo5Q6yfXBM9tHX7b4mBH+XqUeyCSI9Cnm9+Kuol6bRjQJ5y8HFIjC3GEqeJopr9fGn TOm0O9T9VYvoDGGOycHAcSwMTYQO3A8btgSLJDfEKnBQfOtoBghUN+3bhO3IOR4+l+T7 EPvFatpgT7lvFDXhaLJUTE/ApeRSDeHHquTKaSKMpWrYOscU5g7jEgb0Zi0rUgJTivzV 5falqNwqWOiSw+sNoCmuD1wgBzzKyr+x2HwnTxaDBHs2bVRr1vMeRAC5fIT2TAeP3akJ QIPS4Z6ZhCbDsNIA3HQhs8U3VswwWezVE2PY6zVqzNxfHqc/+tErwyJa84Pd5Gm3+ng4 ZLNw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=iWr4gpxLtZb6+cJ6KwEXZgyRLa7YNF4Gx04rrpmRjF4=; b=e3Q7RY+nd7Bgy29+VRWkTZJo3NkLAh/tuy19JhFN/lnGt+p7UhhlYv8cv7WLJiXUKH 4NDCUFFhLdi2Ga0shuhlkVXVZvF6M8AwJ7lp1krrNzZ2RoUA1pE3l9s9F2Es+Dsary7e 5yq9qdION8eknm+rHH7/vaFqeO8udzWJ90uvJTR+izsRjMuX98MeolQt/9xdITrXp5N6 YNHcZTk0niq0iQbVICRADsQYGmRcCyAN+MKfz639Z3RKpCUNaoSRXWXB55OD675NpANO YD/1cFINXN81ktfMQmeOeVTbL1A3cQRIhEfNWBhkjn0DMtqQScCl8Io1Ye5IR0A/DCI1 tirQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="Sbs/+DtC"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e92-v6si45896167pld.45.2018.11.05.21.02.21; Mon, 05 Nov 2018 21:02:22 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="Sbs/+DtC"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729907AbeKFOZl (ORCPT + 32 others); Tue, 6 Nov 2018 09:25:41 -0500 Received: from mail-pg1-f195.google.com ([209.85.215.195]:44149 "EHLO mail-pg1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729160AbeKFOZk (ORCPT ); Tue, 6 Nov 2018 09:25:40 -0500 Received: by mail-pg1-f195.google.com with SMTP id w3-v6so5252734pgs.11 for ; Mon, 05 Nov 2018 21:02:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=iWr4gpxLtZb6+cJ6KwEXZgyRLa7YNF4Gx04rrpmRjF4=; b=Sbs/+DtCkaM2ZZHSu+MPuZuWAQm+/63ec/1c6BXpQRI4G9NqgHNgqt1Fbp25lg1thF JytDD4IoZc0xAKJqZP3fJnFHBHJsZzXvvd6GiYw54Wy1cJuwTKkjUmv+0PbZ8uSX3ob6 Fss1IFaAFELSnsh/U5WivAnSu2LdIhSPl7JIk= 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:in-reply-to:references; bh=iWr4gpxLtZb6+cJ6KwEXZgyRLa7YNF4Gx04rrpmRjF4=; b=eajAQhCAEPk1LfAW2xlPbqBIETnG81g+2HO1Wg5hm3vu2GrWfJoBzCwnwbV0PsEnsn if4nqvmd0Seti6+vlpCQpk+leVfjlXT1AGf4mLCovDVSYuANkgBkuAHqCDJXggK+2Eu/ /G3UtiG4tjFjozja1G0d/fxQwTExlKVO2rOC9uuGxmZKJA1DLZbB6fT3wRNEJcxCwdh6 bXCcKfH/TxvOq352GR4W5+8T/b8B9LMM57wIzDVRY0SOl2nTtk1MTf36OFwqyGKe2Z0N k4f0061V+BmVuhvrREFzTx4brlVBYpJ17R87T9Q/a8iFrIGLYSzAu1B7+wzchMoq+LBL f6gg== X-Gm-Message-State: AGRZ1gIprpbggo2t9CH0QNPgNdAYKKCLHapRn0bJD7PB4BDUTO/uMr0B hGmdAaeD0E6+sarTI4DqR/xOSQ== X-Received: by 2002:a62:34c5:: with SMTP id b188-v6mr25689007pfa.65.1541480537831; Mon, 05 Nov 2018 21:02:17 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.102]) by smtp.gmail.com with ESMTPSA id o7-v6sm55735416pfb.23.2018.11.05.21.02.14 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 05 Nov 2018 21:02:17 -0800 (PST) From: Baolin Wang To: dan.j.williams@intel.com, vkoul@kernel.org, eric.long@unisoc.com Cc: broonie@kernel.org, baolin.wang@linaro.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RESEND PATCH 6/7] dmaengine: sprd: Support DMA 2-stage transfer mode Date: Tue, 6 Nov 2018 13:01:36 +0800 Message-Id: <2cddbfd67b58c3f153ef0950eb4d1b88765afc16.1541480353.git.baolin.wang@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Eric Long The Spreadtrum DMA controller supports channel 2-stage tansfer mode, that means we can request 2 dma channels, one for source channel, and another one for destination channel. Once the source channel's transaction is done, it will trigger the destination channel's transaction automatically by hardware signal. Signed-off-by: Eric Long Signed-off-by: Baolin Wang --- drivers/dma/sprd-dma.c | 98 +++++++++++++++++++++++++++++++++++++++++- include/linux/dma/sprd-dma.h | 62 ++++++++++++++++++++++++-- 2 files changed, 156 insertions(+), 4 deletions(-) -- 1.7.9.5 diff --git a/drivers/dma/sprd-dma.c b/drivers/dma/sprd-dma.c index cefe42f..50d6569 100644 --- a/drivers/dma/sprd-dma.c +++ b/drivers/dma/sprd-dma.c @@ -36,6 +36,8 @@ #define SPRD_DMA_GLB_CHN_EN_STS 0x1c #define SPRD_DMA_GLB_DEBUG_STS 0x20 #define SPRD_DMA_GLB_ARB_SEL_STS 0x24 +#define SPRD_DMA_GLB_2STAGE_GRP1 0x28 +#define SPRD_DMA_GLB_2STAGE_GRP2 0x2c #define SPRD_DMA_GLB_REQ_UID(uid) (0x4 * ((uid) - 1)) #define SPRD_DMA_GLB_REQ_UID_OFFSET 0x2000 @@ -57,6 +59,18 @@ #define SPRD_DMA_CHN_SRC_BLK_STEP 0x38 #define SPRD_DMA_CHN_DES_BLK_STEP 0x3c +/* SPRD_DMA_GLB_2STAGE_GRP register definition */ +#define SPRD_DMA_GLB_2STAGE_EN BIT(24) +#define SPRD_DMA_GLB_CHN_INT_MASK GENMASK(23, 20) +#define SPRD_DMA_GLB_LIST_DONE_TRG BIT(19) +#define SPRD_DMA_GLB_TRANS_DONE_TRG BIT(18) +#define SPRD_DMA_GLB_BLOCK_DONE_TRG BIT(17) +#define SPRD_DMA_GLB_FRAG_DONE_TRG BIT(16) +#define SPRD_DMA_GLB_TRG_OFFSET 16 +#define SPRD_DMA_GLB_DEST_CHN_MASK GENMASK(13, 8) +#define SPRD_DMA_GLB_DEST_CHN_OFFSET 8 +#define SPRD_DMA_GLB_SRC_CHN_MASK GENMASK(5, 0) + /* SPRD_DMA_CHN_INTC register definition */ #define SPRD_DMA_INT_MASK GENMASK(4, 0) #define SPRD_DMA_INT_CLR_OFFSET 24 @@ -118,6 +132,10 @@ #define SPRD_DMA_SRC_TRSF_STEP_OFFSET 0 #define SPRD_DMA_TRSF_STEP_MASK GENMASK(15, 0) +/* define DMA channel mode & trigger mode mask */ +#define SPRD_DMA_CHN_MODE_MASK GENMASK(7, 0) +#define SPRD_DMA_TRG_MODE_MASK GENMASK(7, 0) + /* define the DMA transfer step type */ #define SPRD_DMA_NONE_STEP 0 #define SPRD_DMA_BYTE_STEP 1 @@ -170,6 +188,8 @@ struct sprd_dma_chn { struct dma_slave_config slave_cfg; u32 chn_num; u32 dev_id; + enum sprd_dma_chn_mode chn_mode; + enum sprd_dma_trg_mode trg_mode; struct sprd_dma_desc *cur_desc; }; @@ -206,6 +226,16 @@ static inline struct sprd_dma_desc *to_sprd_dma_desc(struct virt_dma_desc *vd) return container_of(vd, struct sprd_dma_desc, vd); } +static void sprd_dma_glb_update(struct sprd_dma_dev *sdev, u32 reg, + u32 mask, u32 val) +{ + u32 orig = readl(sdev->glb_base + reg); + u32 tmp; + + tmp = (orig & ~mask) | val; + writel(tmp, sdev->glb_base + reg); +} + static void sprd_dma_chn_update(struct sprd_dma_chn *schan, u32 reg, u32 mask, u32 val) { @@ -389,6 +419,49 @@ static enum sprd_dma_req_mode sprd_dma_get_req_type(struct sprd_dma_chn *schan) return (frag_reg >> SPRD_DMA_REQ_MODE_OFFSET) & SPRD_DMA_REQ_MODE_MASK; } +static int sprd_dma_set_2stage_config(struct sprd_dma_chn *schan) +{ + struct sprd_dma_dev *sdev = to_sprd_dma_dev(&schan->vc.chan); + u32 val, chn = schan->chn_num + 1; + + switch (schan->chn_mode) { + case SPRD_DMA_SRC_CHN0: + val = chn & SPRD_DMA_GLB_SRC_CHN_MASK; + val |= BIT(schan->trg_mode - 1) << SPRD_DMA_GLB_TRG_OFFSET; + val |= SPRD_DMA_GLB_2STAGE_EN; + sprd_dma_glb_update(sdev, SPRD_DMA_GLB_2STAGE_GRP1, val, val); + break; + + case SPRD_DMA_SRC_CHN1: + val = chn & SPRD_DMA_GLB_SRC_CHN_MASK; + val |= BIT(schan->trg_mode - 1) << SPRD_DMA_GLB_TRG_OFFSET; + val |= SPRD_DMA_GLB_2STAGE_EN; + sprd_dma_glb_update(sdev, SPRD_DMA_GLB_2STAGE_GRP2, val, val); + break; + + case SPRD_DMA_DST_CHN0: + val = (chn << SPRD_DMA_GLB_DEST_CHN_OFFSET) & + SPRD_DMA_GLB_DEST_CHN_MASK; + val |= SPRD_DMA_GLB_2STAGE_EN; + sprd_dma_glb_update(sdev, SPRD_DMA_GLB_2STAGE_GRP1, val, val); + break; + + case SPRD_DMA_DST_CHN1: + val = (chn << SPRD_DMA_GLB_DEST_CHN_OFFSET) & + SPRD_DMA_GLB_DEST_CHN_MASK; + val |= SPRD_DMA_GLB_2STAGE_EN; + sprd_dma_glb_update(sdev, SPRD_DMA_GLB_2STAGE_GRP2, val, val); + break; + + default: + dev_err(sdev->dma_dev.dev, "invalid channel mode setting %d\n", + schan->chn_mode); + return -EINVAL; + } + + return 0; +} + static void sprd_dma_set_chn_config(struct sprd_dma_chn *schan, struct sprd_dma_desc *sdesc) { @@ -423,6 +496,13 @@ static void sprd_dma_start(struct sprd_dma_chn *schan) schan->cur_desc = to_sprd_dma_desc(vd); /* + * Set 2-stage configuration if the channel starts one 2-stage + * transfer. + */ + if (schan->chn_mode && sprd_dma_set_2stage_config(schan)) + return; + + /* * Copy the DMA configuration from DMA descriptor to this hardware * channel. */ @@ -617,6 +697,7 @@ static int sprd_dma_fill_desc(struct dma_chan *chan, { struct sprd_dma_dev *sdev = to_sprd_dma_dev(chan); struct sprd_dma_chn *schan = to_sprd_dma_chan(chan); + enum sprd_dma_chn_mode chn_mode = schan->chn_mode; u32 req_mode = (flags >> SPRD_DMA_REQ_SHIFT) & SPRD_DMA_REQ_MODE_MASK; u32 int_mode = flags & SPRD_DMA_INT_MASK; int src_datawidth, dst_datawidth, src_step, dst_step; @@ -628,7 +709,16 @@ static int sprd_dma_fill_desc(struct dma_chan *chan, dev_err(sdev->dma_dev.dev, "invalid source step\n"); return src_step; } - dst_step = SPRD_DMA_NONE_STEP; + + /* + * For 2-stage transfer, destination channel step can not be 0, + * since destination device is AON IRAM. + */ + if (chn_mode == SPRD_DMA_DST_CHN0 || + chn_mode == SPRD_DMA_DST_CHN1) + dst_step = src_step; + else + dst_step = SPRD_DMA_NONE_STEP; } else { dst_step = sprd_dma_get_step(slave_cfg->dst_addr_width); if (dst_step < 0) { @@ -855,6 +945,12 @@ static int sprd_dma_fill_linklist_desc(struct dma_chan *chan, } } + /* Set channel mode and trigger mode for 2-stage transfer */ + schan->chn_mode = + (flags >> SPRD_DMA_CHN_MODE_SHIFT) & SPRD_DMA_CHN_MODE_MASK; + schan->trg_mode = + (flags >> SPRD_DMA_TRG_MODE_SHIFT) & SPRD_DMA_TRG_MODE_MASK; + ret = sprd_dma_fill_desc(chan, &sdesc->chn_hw, 0, 0, src, dst, len, dir, flags, slave_cfg); if (ret) { diff --git a/include/linux/dma/sprd-dma.h b/include/linux/dma/sprd-dma.h index b42b80e5..ab82df6 100644 --- a/include/linux/dma/sprd-dma.h +++ b/include/linux/dma/sprd-dma.h @@ -3,9 +3,65 @@ #ifndef _SPRD_DMA_H_ #define _SPRD_DMA_H_ -#define SPRD_DMA_REQ_SHIFT 16 -#define SPRD_DMA_FLAGS(req_mode, int_type) \ - ((req_mode) << SPRD_DMA_REQ_SHIFT | (int_type)) +#define SPRD_DMA_REQ_SHIFT 8 +#define SPRD_DMA_TRG_MODE_SHIFT 16 +#define SPRD_DMA_CHN_MODE_SHIFT 24 +#define SPRD_DMA_FLAGS(chn_mode, trg_mode, req_mode, int_type) \ + ((chn_mode) << SPRD_DMA_CHN_MODE_SHIFT | \ + (trg_mode) << SPRD_DMA_TRG_MODE_SHIFT | \ + (req_mode) << SPRD_DMA_REQ_SHIFT | (int_type)) + +/* + * The Spreadtrum DMA controller supports channel 2-stage tansfer, that means + * we can request 2 dma channels, one for source channel, and another one for + * destination channel. Each channel is independent, and has its own + * configurations. Once the source channel's transaction is done, it will + * trigger the destination channel's transaction automatically by hardware + * signal. + * + * To support 2-stage tansfer, we must configure the channel mode and trigger + * mode as below definition. + */ + +/* + * enum sprd_dma_chn_mode: define the DMA channel mode for 2-stage transfer + * @SPRD_DMA_CHN_MODE_NONE: No channel mode setting which means channel doesn't + * support the 2-stage transfer. + * @SPRD_DMA_SRC_CHN0: Channel used as source channel 0. + * @SPRD_DMA_SRC_CHN1: Channel used as source channel 1. + * @SPRD_DMA_DST_CHN0: Channel used as destination channel 0. + * @SPRD_DMA_DST_CHN1: Channel used as destination channel 1. + * + * Now the DMA controller can supports 2 groups 2-stage transfer. + */ +enum sprd_dma_chn_mode { + SPRD_DMA_CHN_MODE_NONE, + SPRD_DMA_SRC_CHN0, + SPRD_DMA_SRC_CHN1, + SPRD_DMA_DST_CHN0, + SPRD_DMA_DST_CHN1, +}; + +/* + * enum sprd_dma_trg_mode: define the DMA channel trigger mode for 2-stage + * transfer + * @SPRD_DMA_NO_TRG: No trigger setting. + * @SPRD_DMA_FRAG_DONE_TRG: Trigger the transaction of destination channel + * automatically once the source channel's fragment request is done. + * @SPRD_DMA_BLOCK_DONE_TRG: Trigger the transaction of destination channel + * automatically once the source channel's block request is done. + * @SPRD_DMA_TRANS_DONE_TRG: Trigger the transaction of destination channel + * automatically once the source channel's transfer request is done. + * @SPRD_DMA_LIST_DONE_TRG: Trigger the transaction of destination channel + * automatically once the source channel's link-list request is done. + */ +enum sprd_dma_trg_mode { + SPRD_DMA_NO_TRG, + SPRD_DMA_FRAG_DONE_TRG, + SPRD_DMA_BLOCK_DONE_TRG, + SPRD_DMA_TRANS_DONE_TRG, + SPRD_DMA_LIST_DONE_TRG, +}; /* * enum sprd_dma_req_mode: define the DMA request mode From patchwork Tue Nov 6 05:01:37 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "\(Exiting\) Baolin Wang" X-Patchwork-Id: 150246 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp3458139ljp; Mon, 5 Nov 2018 21:02:24 -0800 (PST) X-Google-Smtp-Source: AJdET5c4hOJsvvZpPBeW3bTqWwhh6Q8SMfGjJCtKLCFBCZnMzxDXF5sPeCyju9bnmDTv845VaLln X-Received: by 2002:a17:902:6948:: with SMTP id k8-v6mr25149013plt.22.1541480544453; Mon, 05 Nov 2018 21:02:24 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541480544; cv=none; d=google.com; s=arc-20160816; b=gwWiJlED3HFefxnlaUrkmRpsmExymwfzeYkZdWfmJWKSJVMShbwQfAbacRW4ZcKyuV 78GMZO2b4WFvD5UW23aznLpsB86X9xtIKVL+fQjSv/7+GIdFGKb6WuP/LrzXzk02NepF tIGWByEi+YNAoeW/KdxvMBQLwj8it3VOYnMSNKChKoxZ6QGcrrHf3VcUPLk7CKIxuWRH fjgZ2RODwp15fCVHMiTPuEeXiNsbbtwxno5zWrqk47YvWImzikLm4/T/iEkcFoGTog5v UCJKvQeGp2+wiATphtPICZcDr3PgRn4ImnBtqjVQA42z1Wojbyoqw/NCezgHTttSuynm GgPg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:references :in-reply-to:message-id:date:subject:cc:to:from:dkim-signature; bh=5xZvV9ure0B+Th/au/ie3rB7XqPr/svxvChRm0xoFwg=; b=ls7psKmxuxTl8I83XCM8WbhTzjIo1km/YbQij0r1Y/hO1Zf5fKPH2ktcgTpvFopjt6 k01MwdEM9xIvXVwDTB7i2RrQLiwfK353ABg1mQ8zXTRTsyVIxerrtUbsVYFTruSehNIw lBxwHLzopCnpcJZd1hmP1sYQehv+8c0DsLxBcSUPFT+jKoPGf0lWjs1o3osDr76Dv5En PRIlkfBikYbCAmLsUoUyjQ1jJgW9a19WLwZ+YWVdGC3ywJFJce+3jnrpr690lQFjOM+M QX/MiA5PNA+etX2wpVSr7IuKAlTMnbQFtJM70DCkw6LEC/rH+f4gdSedF5p3p+Vg9uBJ yWmA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ibtnOHLL; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e14-v6si44438562pgb.254.2018.11.05.21.02.24; Mon, 05 Nov 2018 21:02:24 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=ibtnOHLL; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729962AbeKFOZn (ORCPT + 32 others); Tue, 6 Nov 2018 09:25:43 -0500 Received: from mail-pf1-f194.google.com ([209.85.210.194]:38807 "EHLO mail-pf1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729160AbeKFOZm (ORCPT ); Tue, 6 Nov 2018 09:25:42 -0500 Received: by mail-pf1-f194.google.com with SMTP id b11-v6so5528838pfi.5 for ; Mon, 05 Nov 2018 21:02:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=5xZvV9ure0B+Th/au/ie3rB7XqPr/svxvChRm0xoFwg=; b=ibtnOHLLblZ1SlAZodKPh/TX2KVmtl3uaPRMacZpaeeiBkQzgOVYxdiVAeIS0Jdo0N 06W3hhRNRbHpipyhfbCJZjeWTT1SydCN+HskekJc5bEosR19R2B62RJhxrjPpXL/4qb+ ek/r7SvL5Yf/z9G8D/OGTEz68nGZ9lS7trkZM= 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:in-reply-to:references; bh=5xZvV9ure0B+Th/au/ie3rB7XqPr/svxvChRm0xoFwg=; b=c9VGTvwtonj47Gad0v8aZc9toRHml0ln2cZ0RqyZ7qz+Re1e18YRK2VZT+RD676pQa k2itICWRwhEHrYtkhPjQuURVrERZzNlkv/w4lFZPc+RhGFLWilo72q5MTqr7ZGByqy9f liGnNLSgcHqj2yP1ORa7HgaA7qnoaDEx6kvMfztxWPLeClz08IPHt0kl98QdQZV8mXL0 xcUcPPY/iuSK4uwcyFS4Loik1e7G6oOccQbtlKEEL/UPgaKYIHx8DhBFSE5/DoeZ98Ei ak3E/sH6Yv6H1CkFo6mfHNvf3gQ4xKQxxPMy5WjD+L7LFjogRLLCRiZ/hY3jk6RSoODy dljw== X-Gm-Message-State: AGRZ1gKHfFWJWRqvFNVbKbUb/2nLh8eD+qIY/jEri1UgK3JKHjujvNms ieQuw1f6M6uqRgJxvXs8oTcFSw== X-Received: by 2002:a63:4c4e:: with SMTP id m14-v6mr22781968pgl.173.1541480540758; Mon, 05 Nov 2018 21:02:20 -0800 (PST) Received: from baolinwangubtpc.spreadtrum.com ([117.18.48.102]) by smtp.gmail.com with ESMTPSA id o7-v6sm55735416pfb.23.2018.11.05.21.02.18 (version=TLS1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 05 Nov 2018 21:02:20 -0800 (PST) From: Baolin Wang To: dan.j.williams@intel.com, vkoul@kernel.org, eric.long@unisoc.com Cc: broonie@kernel.org, baolin.wang@linaro.org, dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [RESEND PATCH 7/7] dmaengine: sprd: Add me as one of the module authors Date: Tue, 6 Nov 2018 13:01:37 +0800 Message-Id: X-Mailer: git-send-email 1.7.9.5 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Eric Long Add me as one of the module authors. Signed-off-by: Eric Long Signed-off-by: Baolin Wang --- drivers/dma/sprd-dma.c | 1 + 1 file changed, 1 insertion(+) -- 1.7.9.5 diff --git a/drivers/dma/sprd-dma.c b/drivers/dma/sprd-dma.c index 50d6569..e2f0167 100644 --- a/drivers/dma/sprd-dma.c +++ b/drivers/dma/sprd-dma.c @@ -1226,4 +1226,5 @@ static int __maybe_unused sprd_dma_runtime_resume(struct device *dev) MODULE_LICENSE("GPL v2"); MODULE_DESCRIPTION("DMA driver for Spreadtrum"); MODULE_AUTHOR("Baolin Wang "); +MODULE_AUTHOR("Eric Long "); MODULE_ALIAS("platform:sprd-dma");