diff options
author | Steve Longerbeam <slongerbeam@gmail.com> | 2014-06-25 18:05:51 -0700 |
---|---|---|
committer | Philipp Zabel <p.zabel@pengutronix.de> | 2014-09-02 14:55:54 +0200 |
commit | c42d37ca421aa222e8f27744d4129bce726a3724 (patch) | |
tree | 46d471309390667beb4bead6b7e6adabc488f502 /drivers/gpu/ipu-v3 | |
parent | 555f0e6690a41245518003c02a1ecb84e4a69281 (diff) | |
download | op-kernel-dev-c42d37ca421aa222e8f27744d4129bce726a3724.zip op-kernel-dev-c42d37ca421aa222e8f27744d4129bce726a3724.tar.gz |
gpu: ipu-cpmem: Add ipu_cpmem_set_rotation()
Adds ipu_cpmem_set_rotation().
Signed-off-by: Steve Longerbeam <steve_longerbeam@mentor.com>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Diffstat (limited to 'drivers/gpu/ipu-v3')
-rw-r--r-- | drivers/gpu/ipu-v3/ipu-cpmem.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/gpu/ipu-v3/ipu-cpmem.c b/drivers/gpu/ipu-v3/ipu-cpmem.c index 2d1b376..f52e4b4 100644 --- a/drivers/gpu/ipu-v3/ipu-cpmem.c +++ b/drivers/gpu/ipu-v3/ipu-cpmem.c @@ -64,6 +64,7 @@ struct ipu_cpmem { #define IPU_FIELD_BNDM IPU_CPMEM_WORD(0, 114, 3) #define IPU_FIELD_BM IPU_CPMEM_WORD(0, 117, 2) #define IPU_FIELD_ROT IPU_CPMEM_WORD(0, 119, 1) +#define IPU_FIELD_ROT_HF_VF IPU_CPMEM_WORD(0, 119, 3) #define IPU_FIELD_HF IPU_CPMEM_WORD(0, 120, 1) #define IPU_FIELD_VF IPU_CPMEM_WORD(0, 121, 1) #define IPU_FIELD_THE IPU_CPMEM_WORD(0, 122, 1) @@ -273,6 +274,15 @@ void ipu_cpmem_set_block_mode(struct ipuv3_channel *ch) } EXPORT_SYMBOL_GPL(ipu_cpmem_set_block_mode); +void ipu_cpmem_set_rotation(struct ipuv3_channel *ch, + enum ipu_rotate_mode rot) +{ + u32 temp_rot = bitrev8(rot) >> 5; + + ipu_ch_param_write_field(ch, IPU_FIELD_ROT_HF_VF, temp_rot); +} +EXPORT_SYMBOL_GPL(ipu_cpmem_set_rotation); + int ipu_cpmem_set_format_rgb(struct ipuv3_channel *ch, const struct ipu_rgb *rgb) { |