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=-3.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_PASS,USER_AGENT_NEOMUTT autolearn=ham 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 94295C10F06 for ; Sat, 6 Apr 2019 11:01:46 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 6465A213A2 for ; Sat, 6 Apr 2019 11:01:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726524AbfDFLBp (ORCPT ); Sat, 6 Apr 2019 07:01:45 -0400 Received: from mga05.intel.com ([192.55.52.43]:50076 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726387AbfDFLBo (ORCPT ); Sat, 6 Apr 2019 07:01:44 -0400 X-Amp-Result: UNKNOWN X-Amp-Original-Verdict: FILE UNKNOWN X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga105.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 06 Apr 2019 04:01:43 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.60,316,1549958400"; d="scan'208";a="140481503" Received: from muelleca-mobl7.ger.corp.intel.com (HELO kekkonen.fi.intel.com) ([10.249.47.132]) by orsmga003.jf.intel.com with ESMTP; 06 Apr 2019 04:01:38 -0700 Received: by kekkonen.fi.intel.com (Postfix, from userid 1000) id DB0DD21D09; Sat, 6 Apr 2019 14:01:35 +0300 (EEST) Date: Sat, 6 Apr 2019 14:01:35 +0300 From: Sakari Ailus To: Mickael GUENE Cc: "linux-media@vger.kernel.org" , Hugues FRUCHET , Mauro Carvalho Chehab , Matt Ranostay , Petr Cvek , Akinobu Mita , "linux-kernel@vger.kernel.org" , "David S. Miller" , Ben Kao , Nicolas Ferre , Todor Tomov , Rui Miguel Silva , Greg Kroah-Hartman , Hans Verkuil , Ricardo Ribalda Delgado , Jacopo Mondi , Tianshu Qiu , Bingbu Cao Subject: Re: [PATCH v3 2/2] media:st-mipid02: MIPID02 CSI-2 to PARALLEL bridge driver Message-ID: <20190406110135.7l2m6hkmvwr33d7s@kekkonen.localdomain> References: <1552373045-134493-1-git-send-email-mickael.guene@st.com> <1553594620-88280-1-git-send-email-mickael.guene@st.com> <1553594620-88280-3-git-send-email-mickael.guene@st.com> <20190326113308.mp5hqdw3ktbpcawu@paasikivi.fi.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Mar 26, 2019 at 02:36:41PM +0000, Mickael GUENE wrote: > Sakari, > > >> +static int bpp_from_code(__u32 code) > >> +{ > >> + switch (code) { > >> + case MEDIA_BUS_FMT_SBGGR8_1X8: > >> + case MEDIA_BUS_FMT_SGBRG8_1X8: > >> + case MEDIA_BUS_FMT_SGRBG8_1X8: > >> + case MEDIA_BUS_FMT_SRGGB8_1X8: > >> + return 8; > >> + case MEDIA_BUS_FMT_SBGGR10_1X10: > >> + case MEDIA_BUS_FMT_SGBRG10_1X10: > >> + case MEDIA_BUS_FMT_SGRBG10_1X10: > >> + case MEDIA_BUS_FMT_SRGGB10_1X10: > >> + return 10; > >> + case MEDIA_BUS_FMT_SBGGR12_1X12: > >> + case MEDIA_BUS_FMT_SGBRG12_1X12: > >> + case MEDIA_BUS_FMT_SGRBG12_1X12: > >> + case MEDIA_BUS_FMT_SRGGB12_1X12: > >> + return 12; > >> + case MEDIA_BUS_FMT_UYVY8_2X8: > > > > This is good for the parallel bus, but on CSI-2 side you should have > > MEDIA_BUS_FMT_UYVY8_1X16 instead. This isn't technically correct for a > > serial bus, but the custom is to use the one sample / pixel formats on the > > serial busses. > > > Should MEDIA_BUS_FMT_BGR888_1X24 be something like > MEDIA_BUS_FMT_BGR888_3X8 for parallel output bus ? Good point. Yes. Could you add that format to Documentation/media/uapi/v4l/subdev-formats.rst, please, in a separate patch? -- Regards, Sakari Ailus sakari.ailus@linux.intel.com