Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1485595 > unrolled thread
| Started by | Steve Longerbeam <slongerbeam@gmail.com> |
|---|---|
| First post | 2016-09-17 21:40 +0200 |
| Last post | 2016-09-19 09:40 +0200 |
| Articles | 3 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH v7 0/3] IPUv3 prep for i.MX5/6 v4l2 staging drivers, v7 Steve Longerbeam <slongerbeam@gmail.com> - 2016-09-17 21:40 +0200
[PATCH v7 2/3] gpu: ipu-v3: Add ipu_rot_mode_is_irt() Steve Longerbeam <slongerbeam@gmail.com> - 2016-09-17 21:40 +0200
Re: [PATCH v7 0/3] IPUv3 prep for i.MX5/6 v4l2 staging drivers, v7 Philipp Zabel <p.zabel@pengutronix.de> - 2016-09-19 09:40 +0200
| From | Steve Longerbeam <slongerbeam@gmail.com> |
|---|---|
| Date | 2016-09-17 21:40 +0200 |
| Subject | [PATCH v7 0/3] IPUv3 prep for i.MX5/6 v4l2 staging drivers, v7 |
| Message-ID | <sitCV-6z5-5@gated-at.bofh.it> |
Changes from v6: - renamed include/video/imx-image-convert.h to imx-ipu-image-convert.h. - changed MIN_W, MIN_H to absolute minimum allowed assuming conversions to/from planar pixel formats and with rotations (16x8). - removed setting defaults if given 0 widths/heights in ipu_image_convert_adjust(). Steve Longerbeam (3): gpu: ipu-v3: Add FSU channel linking support gpu: ipu-v3: Add ipu_rot_mode_is_irt() gpu: ipu-v3: Add queued image conversion support drivers/gpu/ipu-v3/Makefile | 3 +- drivers/gpu/ipu-v3/ipu-common.c | 140 +++ drivers/gpu/ipu-v3/ipu-ic.c | 2 +- drivers/gpu/ipu-v3/ipu-image-convert.c | 1709 ++++++++++++++++++++++++++++++++ drivers/gpu/ipu-v3/ipu-prv.h | 32 + include/video/imx-ipu-image-convert.h | 207 ++++ include/video/imx-ipu-v3.h | 35 +- 7 files changed, 2119 insertions(+), 9 deletions(-) create mode 100644 drivers/gpu/ipu-v3/ipu-image-convert.c create mode 100644 include/video/imx-ipu-image-convert.h -- 2.7.4
[toc] | [next] | [standalone]
| From | Steve Longerbeam <slongerbeam@gmail.com> |
|---|---|
| Date | 2016-09-17 21:40 +0200 |
| Subject | [PATCH v7 2/3] gpu: ipu-v3: Add ipu_rot_mode_is_irt() |
| Message-ID | <sitCV-6z5-9@gated-at.bofh.it> |
| In reply to | #1485595 |
Add a macro that returns boolean true if the given ipu_rotate_mode
requires the use of the Image Rotator.
Signed-off-by: Steve Longerbeam <steve_longerbeam@mentor.com>
---
drivers/gpu/ipu-v3/ipu-ic.c | 2 +-
include/video/imx-ipu-v3.h | 22 +++++++++++++++-------
2 files changed, 16 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/ipu-v3/ipu-ic.c b/drivers/gpu/ipu-v3/ipu-ic.c
index 1a37afc..321eb98 100644
--- a/drivers/gpu/ipu-v3/ipu-ic.c
+++ b/drivers/gpu/ipu-v3/ipu-ic.c
@@ -619,7 +619,7 @@ int ipu_ic_task_idma_init(struct ipu_ic *ic, struct ipuv3_channel *channel,
ipu_ic_write(ic, ic_idmac_2, IC_IDMAC_2);
ipu_ic_write(ic, ic_idmac_3, IC_IDMAC_3);
- if (rot >= IPU_ROTATE_90_RIGHT)
+ if (ipu_rot_mode_is_irt(rot))
ic->rotation = true;
unlock:
diff --git a/include/video/imx-ipu-v3.h b/include/video/imx-ipu-v3.h
index 49d5439..f39a3d6 100644
--- a/include/video/imx-ipu-v3.h
+++ b/include/video/imx-ipu-v3.h
@@ -63,17 +63,25 @@ enum ipu_csi_dest {
/*
* Enumeration of IPU rotation modes
*/
+#define IPU_ROT_BIT_VFLIP (1 << 0)
+#define IPU_ROT_BIT_HFLIP (1 << 1)
+#define IPU_ROT_BIT_90 (1 << 2)
+
enum ipu_rotate_mode {
IPU_ROTATE_NONE = 0,
- IPU_ROTATE_VERT_FLIP,
- IPU_ROTATE_HORIZ_FLIP,
- IPU_ROTATE_180,
- IPU_ROTATE_90_RIGHT,
- IPU_ROTATE_90_RIGHT_VFLIP,
- IPU_ROTATE_90_RIGHT_HFLIP,
- IPU_ROTATE_90_LEFT,
+ IPU_ROTATE_VERT_FLIP = IPU_ROT_BIT_VFLIP,
+ IPU_ROTATE_HORIZ_FLIP = IPU_ROT_BIT_HFLIP,
+ IPU_ROTATE_180 = (IPU_ROT_BIT_VFLIP | IPU_ROT_BIT_HFLIP),
+ IPU_ROTATE_90_RIGHT = IPU_ROT_BIT_90,
+ IPU_ROTATE_90_RIGHT_VFLIP = (IPU_ROT_BIT_90 | IPU_ROT_BIT_VFLIP),
+ IPU_ROTATE_90_RIGHT_HFLIP = (IPU_ROT_BIT_90 | IPU_ROT_BIT_HFLIP),
+ IPU_ROTATE_90_LEFT = (IPU_ROT_BIT_90 |
+ IPU_ROT_BIT_VFLIP | IPU_ROT_BIT_HFLIP),
};
+/* 90-degree rotations require the IRT unit */
+#define ipu_rot_mode_is_irt(m) (((m) & IPU_ROT_BIT_90) != 0)
+
enum ipu_color_space {
IPUV3_COLORSPACE_RGB,
IPUV3_COLORSPACE_YUV,
--
2.7.4
[toc] | [prev] | [next] | [standalone]
| From | Philipp Zabel <p.zabel@pengutronix.de> |
|---|---|
| Date | 2016-09-19 09:40 +0200 |
| Message-ID | <sj1lf-2uv-1@gated-at.bofh.it> |
| In reply to | #1485595 |
Hi Steve, Am Samstag, den 17.09.2016, 12:33 -0700 schrieb Steve Longerbeam: > Changes from v6: > > - renamed include/video/imx-image-convert.h to imx-ipu-image-convert.h. > - changed MIN_W, MIN_H to absolute minimum allowed assuming conversions > to/from planar pixel formats and with rotations (16x8). > - removed setting defaults if given 0 widths/heights in > ipu_image_convert_adjust(). > > Steve Longerbeam (3): > gpu: ipu-v3: Add FSU channel linking support > gpu: ipu-v3: Add ipu_rot_mode_is_irt() > gpu: ipu-v3: Add queued image conversion support > > drivers/gpu/ipu-v3/Makefile | 3 +- > drivers/gpu/ipu-v3/ipu-common.c | 140 +++ > drivers/gpu/ipu-v3/ipu-ic.c | 2 +- > drivers/gpu/ipu-v3/ipu-image-convert.c | 1709 ++++++++++++++++++++++++++++++++ > drivers/gpu/ipu-v3/ipu-prv.h | 32 + > include/video/imx-ipu-image-convert.h | 207 ++++ > include/video/imx-ipu-v3.h | 35 +- > 7 files changed, 2119 insertions(+), 9 deletions(-) > create mode 100644 drivers/gpu/ipu-v3/ipu-image-convert.c > create mode 100644 include/video/imx-ipu-image-convert.h thanks, I have updated to v7 and sent a pull request: https://lists.freedesktop.org/archives/dri-devel/2016-September/118572.html regards Philipp
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web