From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932527AbcAHVsv (ORCPT ); Fri, 8 Jan 2016 16:48:51 -0500 Received: from mail-pa0-f47.google.com ([209.85.220.47]:35230 "EHLO mail-pa0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756653AbcAHVst (ORCPT ); Fri, 8 Jan 2016 16:48:49 -0500 From: tim.gardner@canonical.com To: dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Tim Gardner , Vinod Koul , Dan Williams , Dave Jiang , Prarit Bhargava , Nicholas Mc Guire , Jarkko Nikula Subject: [PATCH v4.4-rc8 v4] dmaengine: ioatdma: Squelch framesize warnings Date: Fri, 8 Jan 2016 14:48:17 -0700 Message-Id: <1452289697-1737-1-git-send-email-tim.gardner@canonical.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1452283126.3983.41.camel@intel.com> References: <1452283126.3983.41.camel@intel.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Tim Gardner CC [M] drivers/dma/ioat/prep.o drivers/dma/ioat/prep.c: In function 'ioat_prep_pqxor': drivers/dma/ioat/prep.c:682:1: warning: the frame size of 1048 bytes is larger than 1024 bytes [-Wframe-larger-than=] } ^ drivers/dma/ioat/prep.c: In function 'ioat_prep_pqxor_val': drivers/dma/ioat/prep.c:714:1: warning: the frame size of 1048 bytes is larger than 1024 bytes [-Wframe-larger-than=] } gcc version 5.3.1 20151219 (Ubuntu 5.3.1-4ubuntu1) Cc: Vinod Koul Cc: Dan Williams Cc: Dave Jiang Cc: Prarit Bhargava Cc: Nicholas Mc Guire Cc: Jarkko Nikula Signed-off-by: Tim Gardner --- v2 - use per CPU static buffers instead of dynamically allocating memory. v3 - Use get_cpu_var/put_cpu_var which implicitly control preeemption. Drop the wrapper function that no longer serves any purpose. v4 - According to discussion between Dan Williams and Dave Jiang, MAX_SCF really only needs to be 256. That is certainly a simpler patch then previous efforts. Quoting from an email regarding v3: Dan said, "Looks good to me... but now that I think about it, why is MAX_SCF set to 1024 in the first place? Certainly it can't be bigger than the maximum number of sources in a single operation which is 8 to 16. Even md raid can only support up to 256 devices in an array. So I think that contstant is bogus. If we set it to 16 we may not even need the percpu change. Dave?" Dave responded, "You are right. It was an arbitrary number I threw in there to address sparse warning. It can be reduced. 256 seems reasonable. " drivers/dma/ioat/prep.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dma/ioat/prep.c b/drivers/dma/ioat/prep.c index 6bb4a13..243421a 100644 --- a/drivers/dma/ioat/prep.c +++ b/drivers/dma/ioat/prep.c @@ -26,7 +26,7 @@ #include "hw.h" #include "dma.h" -#define MAX_SCF 1024 +#define MAX_SCF 256 /* provide a lookup table for setting the source address in the base or * extended descriptor of an xor or pq descriptor -- 2.6.4