Linux-Rockchip Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Heiko Stuebner <heiko@sntech.de>
To: dafna.hirschfeld@collabora.com, helen.koike@collabora.com,
	linux-media@vger.kernel.org, mchehab@kernel.org,
	Laurent.pinchart@ideasonboard.com, hverkuil@xs4all.nl
Cc: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>,
	linux-rockchip@lists.infradead.org, ezequiel@collabora.com,
	heiko@sntech.de, christoph.muellner@theobroma-systems.com
Subject: [PATCH 2/2] media: rockchip: rkisp1: extend uapi array sizes
Date: Tue, 12 Jan 2021 00:40:11 +0100	[thread overview]
Message-ID: <20210111234011.3642481-3-heiko@sntech.de> (raw)
In-Reply-To: <20210111234011.3642481-1-heiko@sntech.de>

From: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>

Later variants of the rkisp1 block use more entries in some arrays:

RKISP1_CIF_ISP_AE_MEAN_MAX                 25 -> 81
RKISP1_CIF_ISP_HIST_BIN_N_MAX              16 -> 32
RKISP1_CIF_ISP_GAMMA_OUT_MAX_SAMPLES       17 -> 34
RKISP1_CIF_ISP_HISTOGRAM_WEIGHT_GRIDS_SIZE 28 -> 81

and we can still extend the uapi during the 5.11-rc cycle, so do that
now to be on the safe side.

V10 and V11 only need the smaller sizes, while V12 and V13 needed
the larger sizes.

Signed-off-by: Heiko Stuebner <heiko.stuebner@theobroma-systems.com>
---
changes since rfc:
- introduce constants for versions and make max use the biggest

 include/uapi/linux/rkisp1-config.h | 18 ++++++++++++++----
 1 file changed, 14 insertions(+), 4 deletions(-)

diff --git a/include/uapi/linux/rkisp1-config.h b/include/uapi/linux/rkisp1-config.h
index bad46aadf838..20d24656a8b7 100644
--- a/include/uapi/linux/rkisp1-config.h
+++ b/include/uapi/linux/rkisp1-config.h
@@ -49,8 +49,14 @@
 #define RKISP1_CIF_ISP_CTK_COEFF_MAX            0x100
 #define RKISP1_CIF_ISP_CTK_OFFSET_MAX           0x800
 
-#define RKISP1_CIF_ISP_AE_MEAN_MAX              25
-#define RKISP1_CIF_ISP_HIST_BIN_N_MAX           16
+#define RKISP1_CIF_ISP_AE_MEAN_MAX_V10		25
+#define RKISP1_CIF_ISP_AE_MEAN_MAX_V12		81
+#define RKISP1_CIF_ISP_AE_MEAN_MAX		RKISP1_CIF_ISP_AE_MEAN_MAX_V12
+
+#define RKISP1_CIF_ISP_HIST_BIN_N_MAX_V10	16
+#define RKISP1_CIF_ISP_HIST_BIN_N_MAX_V12	32
+#define RKISP1_CIF_ISP_HIST_BIN_N_MAX		RKISP1_CIF_ISP_HIST_BIN_N_MAX_V12
+
 #define RKISP1_CIF_ISP_AFM_MAX_WINDOWS          3
 #define RKISP1_CIF_ISP_DEGAMMA_CURVE_SIZE       17
 
@@ -86,7 +92,9 @@
  * Gamma out
  */
 /* Maximum number of color samples supported */
-#define RKISP1_CIF_ISP_GAMMA_OUT_MAX_SAMPLES       17
+#define RKISP1_CIF_ISP_GAMMA_OUT_MAX_SAMPLES_V10   17
+#define RKISP1_CIF_ISP_GAMMA_OUT_MAX_SAMPLES_V12   34
+#define RKISP1_CIF_ISP_GAMMA_OUT_MAX_SAMPLES       RKISP1_CIF_ISP_GAMMA_OUT_MAX_SAMPLES_V12
 
 /*
  * Lens shade correction
@@ -103,7 +111,9 @@
  * Histogram calculation
  */
 /* Last 3 values unused. */
-#define RKISP1_CIF_ISP_HISTOGRAM_WEIGHT_GRIDS_SIZE 28
+#define RKISP1_CIF_ISP_HISTOGRAM_WEIGHT_GRIDS_SIZE_V10 28
+#define RKISP1_CIF_ISP_HISTOGRAM_WEIGHT_GRIDS_SIZE_V12 81
+#define RKISP1_CIF_ISP_HISTOGRAM_WEIGHT_GRIDS_SIZE     RKISP1_CIF_ISP_HISTOGRAM_WEIGHT_GRIDS_SIZE_V12
 
 /*
  * Defect Pixel Cluster Correction
-- 
2.29.2


_______________________________________________
Linux-rockchip mailing list
Linux-rockchip@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-rockchip

  parent reply	other threads:[~2021-01-11 23:41 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-11 23:40 [PATCH 0/2] Fix the rkisp1 userspace API for later IP versions Heiko Stuebner
2021-01-11 23:40 ` [PATCH 1/2] media: rockchip: rkisp1: carry ip version information Heiko Stuebner
2021-01-12  8:32   ` Hans Verkuil
2021-01-12 10:47     ` Dafna Hirschfeld
2021-01-14 22:50       ` Heiko Stübner
2022-02-11 14:04   ` Laurent Pinchart
2021-01-11 23:40 ` Heiko Stuebner [this message]
2021-01-12  8:39   ` [PATCH 2/2] media: rockchip: rkisp1: extend uapi array sizes Hans Verkuil
2022-03-04 17:21 ` [PATCH 0/2] Fix the rkisp1 userspace API for later IP versions Laurent Pinchart
  -- strict thread matches above, loose matches on Subject: below --
2021-01-14 23:33 [PATCH v2 " Heiko Stuebner
2021-01-14 23:33 ` [PATCH 2/2] media: rockchip: rkisp1: extend uapi array sizes Heiko Stuebner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210111234011.3642481-3-heiko@sntech.de \
    --to=heiko@sntech.de \
    --cc=Laurent.pinchart@ideasonboard.com \
    --cc=christoph.muellner@theobroma-systems.com \
    --cc=dafna.hirschfeld@collabora.com \
    --cc=ezequiel@collabora.com \
    --cc=heiko.stuebner@theobroma-systems.com \
    --cc=helen.koike@collabora.com \
    --cc=hverkuil@xs4all.nl \
    --cc=linux-media@vger.kernel.org \
    --cc=linux-rockchip@lists.infradead.org \
    --cc=mchehab@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox