From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 27C04C433E0 for ; Wed, 27 May 2020 13:46:38 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id DDD302078C for ; Wed, 27 May 2020 13:46:37 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="jvBlgxlS"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=ideasonboard.com header.i=@ideasonboard.com header.b="K8tyyqP2" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DDD302078C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ideasonboard.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-riscv-bounces+infradead-linux-riscv=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To: Content-Type:MIME-Version:References:Message-ID:Subject:To:From:Date:Reply-To :Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=lN3D/zpOK44MJL7V6ohgo8Ka3GBX/b5BVU/BTuo1RoY=; b=jvBlgxlSjL8N2AYsSArvqS+MD m1mn4rPxGKE1BbxAdXRrcHjhGG6mUF1P8W0YgnRHR6Qkmg6bJalt/r6DBTbgvulBgEZMJ/NpChTmi /qC2esbeCzQ7ltpFFVi54d0dHIdG91DOGi8+xuCHAIzq1WERWErUKbTZU2+qz4dltaLhsoPM/lV8p YgqQRDvzsheKNBENJuTk6Nx3MdSfdBAEhaE0yX2QbQ4R/Xy5kIdha2KlVd+eIWwNH0tOMqsncbOgO AtNUMYoTOcLfdg+tygxk+iWn7QuEmTFWIAGxtWl33w65ePRBIWJ8d4SsY873eAa+9EVxXkqCXgkkL UglBC/hVw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jdwO6-0001lO-2d; Wed, 27 May 2020 13:46:30 +0000 Received: from perceval.ideasonboard.com ([213.167.242.64]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jdwNL-00017s-4U; Wed, 27 May 2020 13:45:44 +0000 Received: from pendragon.ideasonboard.com (81-175-216-236.bb.dnainternet.fi [81.175.216.236]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 18CCF5B4; Wed, 27 May 2020 15:45:41 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1590587141; bh=FOT36A7X8Hk3Rh2sgJfgv1jk67oSyBWaXMLvby3ZVn0=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=K8tyyqP2+EBqMtHIXAixv68AVoyRavwX2+DntbLh2vrjNKUdhw1kPp5L8v8XcEQke 5hoxdGk3u1oikaekAvVN79PzMi7aqfwFJI9F8IdAk1sxTLb8aiHOOnYPs49h177hrO RBBxk1jZGiThAgDTQMwbMwsU3yghDgrHe9UIOuIk= Date: Wed, 27 May 2020 16:45:27 +0300 From: Laurent Pinchart To: Nathan Chancellor Subject: Re: [PATCH] media: omap3isp: Shuffle cacheflush.h and include mm.h Message-ID: <20200527134527.GD6171@pendragon.ideasonboard.com> References: <20200515143646.3857579-7-hch@lst.de> <20200527043426.3242439-1-natechancellor@gmail.com> <20200527081337.GA3506499@ubuntu-s3-xlarge-x86> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20200527081337.GA3506499@ubuntu-s3-xlarge-x86> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200527_064543_350369_817AD259 X-CRM114-Status: GOOD ( 27.67 ) X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "linux-ia64@vger.kernel.org" , Linux-sh list , Roman Zippel , Linux Kernel Mailing List , Linux MM , sparclinux , linux-riscv@lists.infradead.org, Christoph Hellwig , Linux-Arch , linux-c6x-dev@linux-c6x.org, "open list:QUALCOMM HEXAGON..." , the arch/x86 maintainers , Geert Uytterhoeven , linux-media@vger.kernel.org, "open list:TENSILICA XTENSA PORT \(xtensa\)" , Arnd Bergmann , Jessica Yu , linux-um , linux-m68k , Openrisc , Linux ARM , Michal Simek , "open list:BROADCOM NVRAM DRIVER" , Sakari Ailus , alpha , Linux FS Devel , Andrew Morton , linuxppc-dev Sender: "linux-riscv" Errors-To: linux-riscv-bounces+infradead-linux-riscv=archiver.kernel.org@lists.infradead.org Hi Nathan, (CC'ing Sakari Ailus and the linux-media mailing list) On Wed, May 27, 2020 at 01:13:37AM -0700, Nathan Chancellor wrote: > On Wed, May 27, 2020 at 09:02:51AM +0200, Geert Uytterhoeven wrote: > > On Wed, May 27, 2020 at 6:37 AM Nathan Chancellor wrote: > > > After mm.h was removed from the asm-generic version of cacheflush.h, > > > s390 allyesconfig shows several warnings of the following nature: > > > > > > In file included from ./arch/s390/include/generated/asm/cacheflush.h:1, > > > from drivers/media/platform/omap3isp/isp.c:42: > > > ./include/asm-generic/cacheflush.h:16:42: warning: 'struct mm_struct' > > > declared inside parameter list will not be visible outside of this > > > definition or declaration > > > > > > cacheflush.h does not include mm.h nor does it include any forward > > > declaration of these structures hence the warning. To avoid this, > > > include mm.h explicitly in this file and shuffle cacheflush.h below it. > > > > > > Fixes: 19c0054597a0 ("asm-generic: don't include in cacheflush.h") > > > Signed-off-by: Nathan Chancellor > > > > Thanks for your patch! > > > > > I am aware the fixes tag is kind of irrelevant because that SHA will > > > change in the next linux-next revision and this will probably get folded > > > into the original patch anyways but still. > > > > > > The other solution would be to add forward declarations of these structs > > > to the top of cacheflush.h, I just chose to do what Christoph did in the > > > original patch. I am happy to do that instead if you all feel that is > > > better. > > > > That actually looks like a better solution to me, as it would address the > > problem for all users. Headers should be self-contained, so that would be the best fix in my opinion. This being said, as cacheflush.h isn't needed in isp.c, I think we should also drop it. It seems to have been included there since the first driver version, and was likely a left-over from the out-of-tree development. Manual cache handling was part of drivers/media/platform/omap3isp/ispqueue.c and has been removed in commit fbac1400bd1a ("[media] omap3isp: Move to videobuf2"). cacheflush.h can also be dropped from ispvideo.c which suffers from the same issue. > > > drivers/media/platform/omap3isp/isp.c | 5 +++-- > > > 1 file changed, 3 insertions(+), 2 deletions(-) > > > > > > diff --git a/drivers/media/platform/omap3isp/isp.c b/drivers/media/platform/omap3isp/isp.c > > > index a4ee6b86663e..54106a768e54 100644 > > > --- a/drivers/media/platform/omap3isp/isp.c > > > +++ b/drivers/media/platform/omap3isp/isp.c > > > @@ -39,8 +39,6 @@ > > > * Troy Laramy > > > */ > > > > > > -#include > > > - > > > #include > > > #include > > > #include > > > @@ -49,6 +47,7 @@ > > > #include > > > #include > > > #include > > > +#include > > > #include > > > #include > > > #include > > > @@ -58,6 +57,8 @@ > > > #include > > > #include > > > > > > +#include > > > + > > > #ifdef CONFIG_ARM_DMA_USE_IOMMU > > > #include > > > #endif > > > > Why does this file need at all? > > It doesn't call any of the flush_*() functions, and seems to compile fine > > without (on arm32). > > > > Perhaps it was included at the top intentionally, to override the definitions > > of copy_{to,from}_user_page()? Fortunately that doesn't seem to be the > > case, from a quick look at the assembler output. > > > > So let's just remove the #include instead? > > Sounds good to me. I can send a patch if needed or I suppose Andrew can > just make a small fixup patch for it. Let me know what I should do. -- Regards, Laurent Pinchart