From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Google-Smtp-Source: AH8x225iNcf0amlvABLnjm8QvzBm6CGXl2nMuETLBuJ/NA69r/7jviBHEaEbCBmsMbQxhTcy+Ny3 ARC-Seal: i=1; a=rsa-sha256; t=1517262583; cv=none; d=google.com; s=arc-20160816; b=Q0DYR2ZcQEIqntuqHJqoEmzeInFR+Ud+g8wGFOLlYjV6GOa5NPQKBVRX+S/saR8z5F m/rXYGUiJq6QlHdFVK6UKKLfi+YLhg4KteKDJF953XApX18g5/Q+IaJFBPm9yjvOxvZy qBKBsi7lzLc07xCSZ6OzhItvUlCX9rmAZ1ED9ChDQAHIP79qxoRIO6ZF3FncG+peu/q7 /m9WmZ3uon3glmQMV8jmisIGLxRHyy4DAejj9J9BUCBn4kEymGigH/AhWKTG0SRR02zl JGNFl/WzgbuI/ClrAJgj1iMog2teO8kUsC1O5iJcEpT+i+337LMFT0t6NOf9kmTokDKx 8SDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:content-language:in-reply-to:mime-version :user-agent:date:message-id:from:references:cc:to:subject :dkim-signature:arc-authentication-results; bh=PjeAivmfbnkqVfVghm5GMOvmhJORWta5JHn1z6FMWMI=; b=udnO/MLlT5zYXbAly886EHfo6DzUOKR+mkSpPPUYTaDUOHr1DgWYsSH+VHpvXhgJtI aAhImLTX2/6ZhwA/sHCGVayX6mWWzO2hqI0M0mgXirncslidHWTUhbmOqcujPcRZKctB QUu/aFfZ+Qk1r3LxcjgUw5SJdbheTKM30C5XD+Ay/N+yrDKumAIu8WKYHoRuEy3vCWa1 IxnSsAhBQQV6glXVOmmSMYAK5sqahoT/YRLKABkH02C8fEaOWX1wocQhJv3TXMLJUYqg UIP5XF3akiXBT2IzoqnldauLD3dUhMHPQ4Q92uw9kjiXSKfZSdqU9kjgq0jxeqEhoVPr qI7A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20170209 header.b=beks53Ti; spf=pass (google.com: best guess record for domain of rdunlap@infradead.org designates 65.50.211.133 as permitted sender) smtp.mailfrom=rdunlap@infradead.org Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20170209 header.b=beks53Ti; spf=pass (google.com: best guess record for domain of rdunlap@infradead.org designates 65.50.211.133 as permitted sender) smtp.mailfrom=rdunlap@infradead.org Subject: Re: [PATCH v7 2/2] media: V3s: Add support for Allwinner CSI. To: Yong Deng , Maxime Ripard Cc: Mauro Carvalho Chehab , Rob Herring , Mark Rutland , Chen-Yu Tsai , "David S. Miller" , Greg Kroah-Hartman , Linus Walleij , Hans Verkuil , Stanimir Varbanov , Hugues Fruchet , Yannick Fertre , Philipp Zabel , Arnd Bergmann , Benjamin Gaignard , Ramesh Shanmugasundaram , Sakari Ailus , Rick Chang , linux-media@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-sunxi@googlegroups.com References: <1517217696-17816-1-git-send-email-yong.deng@magewell.com> From: Randy Dunlap Message-ID: Date: Mon, 29 Jan 2018 13:49:14 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <1517217696-17816-1-git-send-email-yong.deng@magewell.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: =?utf-8?q?1590918123212414894?= X-GMAIL-MSGID: =?utf-8?q?1590965130268564322?= X-Mailing-List: linux-kernel@vger.kernel.org List-ID: On 01/29/2018 01:21 AM, Yong Deng wrote: > Allwinner V3s SoC features two CSI module. CSI0 is used for MIPI CSI-2 > interface and CSI1 is used for parallel interface. This is not > documented in datasheet but by test and guess. > > This patch implement a v4l2 framework driver for it. > > Currently, the driver only support the parallel interface. MIPI-CSI2, > ISP's support are not included in this patch. > > Tested-by: Maxime Ripard > Signed-off-by: Yong Deng > --- A previous version (I think v6) had a build error with the use of PHYS_OFFSET, so Kconfig was modified to depend on ARM and ARCH_SUNXI (one of which seems to be overkill). As is here, the COMPILE_TEST piece is meaningless for all arches except ARM. If you care enough for COMPILE_TEST (and I would), then you could make COMPILE_TEST useful on any arch by removing the "depends on ARM" (the ARCH_SUNXI takes care of that) and by having an alternate value for PHYS_OFFSET, like so: +#if defined(CONFIG_COMPILE_TEST) && !defined(PHYS_OFFSET) +#define PHYS_OFFSET 0 +#endif With those 2 changes, the driver builds for me on x86_64. > diff --git a/drivers/media/platform/sunxi/sun6i-csi/Kconfig b/drivers/media/platform/sunxi/sun6i-csi/Kconfig > new file mode 100644 > index 0000000..f80c965 > --- /dev/null > +++ b/drivers/media/platform/sunxi/sun6i-csi/Kconfig > @@ -0,0 +1,10 @@ > +config VIDEO_SUN6I_CSI > + tristate "Allwinner V3s Camera Sensor Interface driver" > + depends on ARM > + depends on VIDEO_V4L2 && COMMON_CLK && VIDEO_V4L2_SUBDEV_API && HAS_DMA > + depends on ARCH_SUNXI || COMPILE_TEST > + select VIDEOBUF2_DMA_CONTIG > + select REGMAP_MMIO > + select V4L2_FWNODE > + ---help--- > + Support for the Allwinner Camera Sensor Interface Controller on V3s. thanks, -- ~Randy