Re: [PATCH 2/3] [media] s5p-mfc: Core support to add v8 decoder
Hi Arun, On 23 April 2014 18:27, Arun Kumar K arun...@samsung.com wrote: From: Kiran AVND avnd.ki...@samsung.com This patch adds variant data and core support for V8 decoder. This patch also adds the register definition file for new firmware version v8 for MFC. Signed-off-by: Kiran AVND avnd.ki...@samsung.com Signed-off-by: Pawel Osciak posc...@chromium.org Signed-off-by: Arun Kumar K arun...@samsung.com --- ... + +/* Returned value register for specific setting */ +#define S5P_FIMV_D_RET_PICTURE_TAG_TOP_V8 0xf674 +#define S5P_FIMV_D_RET_PICTURE_TAG_BOT_V8 0xf678 +#define S5P_FIMV_D_MVC_VIEW_ID_V8 0xf6d8 + +/* SEI related information */ +#define S5P_FIMV_D_FRAME_PACK_SEI_AVAIL_V8 0xf6dc + +/* MFCv8 Context buffer sizes */ +#define MFC_CTX_BUF_SIZE_V8(30 * SZ_1K)/* 30KB */ Please include header file for size macros. ... }; diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h index 48a14b5..f0e63f5 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h @@ -23,8 +23,7 @@ #include media/v4l2-ioctl.h #include media/videobuf2-core.h #include regs-mfc.h -#include regs-mfc-v6.h -#include regs-mfc-v7.h +#include regs-mfc-v8.h /* Definitions related to MFC memory */ @@ -705,5 +704,6 @@ void set_work_bit_irqsave(struct s5p_mfc_ctx *ctx); #define IS_TWOPORT(dev)(dev-variant-port_num == 2 ? 1 : 0) #define IS_MFCV6_PLUS(dev) (dev-variant-version = 0x60 ? 1 : 0) #define IS_MFCV7(dev) (dev-variant-version = 0x70 ? 1 : 0) Is MFC v8 superset of MFC v7? +#define IS_MFCV8(dev) (dev-variant-version = 0x80 ? 1 : 0) -- With warm regards, Sachin -- To unsubscribe from this list: send the line unsubscribe linux-media in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH 2/3] [media] s5p-mfc: Core support to add v8 decoder
Hi Sachin, Thank you for the review. On 04/29/14 22:45, Sachin Kamat wrote: Hi Arun, On 23 April 2014 18:27, Arun Kumar K arun...@samsung.com wrote: From: Kiran AVND avnd.ki...@samsung.com This patch adds variant data and core support for V8 decoder. This patch also adds the register definition file for new firmware version v8 for MFC. Signed-off-by: Kiran AVND avnd.ki...@samsung.com Signed-off-by: Pawel Osciak posc...@chromium.org Signed-off-by: Arun Kumar K arun...@samsung.com --- ... + +/* Returned value register for specific setting */ +#define S5P_FIMV_D_RET_PICTURE_TAG_TOP_V8 0xf674 +#define S5P_FIMV_D_RET_PICTURE_TAG_BOT_V8 0xf678 +#define S5P_FIMV_D_MVC_VIEW_ID_V8 0xf6d8 + +/* SEI related information */ +#define S5P_FIMV_D_FRAME_PACK_SEI_AVAIL_V8 0xf6dc + +/* MFCv8 Context buffer sizes */ +#define MFC_CTX_BUF_SIZE_V8(30 * SZ_1K)/* 30KB */ Please include header file for size macros. The file linux/sizes.h is included in regs-mfc-v6.h which inturn gets included in this file. Isnt that fine? ... }; diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h index 48a14b5..f0e63f5 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h @@ -23,8 +23,7 @@ #include media/v4l2-ioctl.h #include media/videobuf2-core.h #include regs-mfc.h -#include regs-mfc-v6.h -#include regs-mfc-v7.h +#include regs-mfc-v8.h /* Definitions related to MFC memory */ @@ -705,5 +704,6 @@ void set_work_bit_irqsave(struct s5p_mfc_ctx *ctx); #define IS_TWOPORT(dev)(dev-variant-port_num == 2 ? 1 : 0) #define IS_MFCV6_PLUS(dev) (dev-variant-version = 0x60 ? 1 : 0) #define IS_MFCV7(dev) (dev-variant-version = 0x70 ? 1 : 0) Is MFC v8 superset of MFC v7? Yes it is a superset. So the last patch in this series renames IS_MFCV7 to IS_MFCV7_PLUS. Regards Arun +#define IS_MFCV8(dev) (dev-variant-version = 0x80 ? 1 : 0) -- To unsubscribe from this list: send the line unsubscribe linux-media in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH 2/3] [media] s5p-mfc: Core support to add v8 decoder
Hi Arun, On 30 April 2014 11:15, Arun Kumar K arunkk.sams...@gmail.com wrote: Hi Sachin, Thank you for the review. On 04/29/14 22:45, Sachin Kamat wrote: Hi Arun, On 23 April 2014 18:27, Arun Kumar K arun...@samsung.com wrote: From: Kiran AVND avnd.ki...@samsung.com This patch adds variant data and core support for V8 decoder. This patch also adds the register definition file for new firmware version v8 for MFC. Signed-off-by: Kiran AVND avnd.ki...@samsung.com Signed-off-by: Pawel Osciak posc...@chromium.org Signed-off-by: Arun Kumar K arun...@samsung.com --- ... + +/* Returned value register for specific setting */ +#define S5P_FIMV_D_RET_PICTURE_TAG_TOP_V8 0xf674 +#define S5P_FIMV_D_RET_PICTURE_TAG_BOT_V8 0xf678 +#define S5P_FIMV_D_MVC_VIEW_ID_V8 0xf6d8 + +/* SEI related information */ +#define S5P_FIMV_D_FRAME_PACK_SEI_AVAIL_V8 0xf6dc + +/* MFCv8 Context buffer sizes */ +#define MFC_CTX_BUF_SIZE_V8(30 * SZ_1K)/* 30KB */ Please include header file for size macros. The file linux/sizes.h is included in regs-mfc-v6.h which inturn gets included in this file. Isnt that fine? Direct inclusions are encouraged. Please add it in this file. ... }; diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h index 48a14b5..f0e63f5 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h @@ -23,8 +23,7 @@ #include media/v4l2-ioctl.h #include media/videobuf2-core.h #include regs-mfc.h -#include regs-mfc-v6.h -#include regs-mfc-v7.h +#include regs-mfc-v8.h /* Definitions related to MFC memory */ @@ -705,5 +704,6 @@ void set_work_bit_irqsave(struct s5p_mfc_ctx *ctx); #define IS_TWOPORT(dev)(dev-variant-port_num == 2 ? 1 : 0) #define IS_MFCV6_PLUS(dev) (dev-variant-version = 0x60 ? 1 : 0) #define IS_MFCV7(dev) (dev-variant-version = 0x70 ? 1 : 0) Is MFC v8 superset of MFC v7? Yes it is a superset. So the last patch in this series renames IS_MFCV7 to IS_MFCV7_PLUS. Shouldn't that be done first in that case? -- With warm regards, Sachin -- To unsubscribe from this list: send the line unsubscribe linux-media in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH 2/3] [media] s5p-mfc: Core support to add v8 decoder
Hi Sachin, On Wed, Apr 30, 2014 at 11:19 AM, Sachin Kamat sachin.ka...@linaro.org wrote: Hi Arun, On 30 April 2014 11:15, Arun Kumar K arunkk.sams...@gmail.com wrote: Hi Sachin, Thank you for the review. On 04/29/14 22:45, Sachin Kamat wrote: Hi Arun, On 23 April 2014 18:27, Arun Kumar K arun...@samsung.com wrote: From: Kiran AVND avnd.ki...@samsung.com This patch adds variant data and core support for V8 decoder. This patch also adds the register definition file for new firmware version v8 for MFC. Signed-off-by: Kiran AVND avnd.ki...@samsung.com Signed-off-by: Pawel Osciak posc...@chromium.org Signed-off-by: Arun Kumar K arun...@samsung.com --- ... + +/* Returned value register for specific setting */ +#define S5P_FIMV_D_RET_PICTURE_TAG_TOP_V8 0xf674 +#define S5P_FIMV_D_RET_PICTURE_TAG_BOT_V8 0xf678 +#define S5P_FIMV_D_MVC_VIEW_ID_V8 0xf6d8 + +/* SEI related information */ +#define S5P_FIMV_D_FRAME_PACK_SEI_AVAIL_V8 0xf6dc + +/* MFCv8 Context buffer sizes */ +#define MFC_CTX_BUF_SIZE_V8(30 * SZ_1K)/* 30KB */ Please include header file for size macros. The file linux/sizes.h is included in regs-mfc-v6.h which inturn gets included in this file. Isnt that fine? Direct inclusions are encouraged. Please add it in this file. Ok will add it. ... }; diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h index 48a14b5..f0e63f5 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_common.h +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_common.h @@ -23,8 +23,7 @@ #include media/v4l2-ioctl.h #include media/videobuf2-core.h #include regs-mfc.h -#include regs-mfc-v6.h -#include regs-mfc-v7.h +#include regs-mfc-v8.h /* Definitions related to MFC memory */ @@ -705,5 +704,6 @@ void set_work_bit_irqsave(struct s5p_mfc_ctx *ctx); #define IS_TWOPORT(dev)(dev-variant-port_num == 2 ? 1 : 0) #define IS_MFCV6_PLUS(dev) (dev-variant-version = 0x60 ? 1 : 0) #define IS_MFCV7(dev) (dev-variant-version = 0x70 ? 1 : 0) Is MFC v8 superset of MFC v7? Yes it is a superset. So the last patch in this series renames IS_MFCV7 to IS_MFCV7_PLUS. Shouldn't that be done first in that case? Adding variants to access MFC registers patch actually removes lot of such IS_MFCV7 checks from opr_v6.c file. Thats why I put that patch as the last in the series to have minimal changes as possible. Regards Arun -- To unsubscribe from this list: send the line unsubscribe linux-media in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH 2/3] [media] s5p-mfc: Core support to add v8 decoder
From: Kiran AVND avnd.ki...@samsung.com This patch adds variant data and core support for V8 decoder. This patch also adds the register definition file for new firmware version v8 for MFC. Signed-off-by: Kiran AVND avnd.ki...@samsung.com Signed-off-by: Pawel Osciak posc...@chromium.org Signed-off-by: Arun Kumar K arun...@samsung.com --- .../devicetree/bindings/media/s5p-mfc.txt |3 +- drivers/media/platform/s5p-mfc/regs-mfc-v8.h | 93 drivers/media/platform/s5p-mfc/s5p_mfc.c | 30 +++ drivers/media/platform/s5p-mfc/s5p_mfc_common.h|4 +- drivers/media/platform/s5p-mfc/s5p_mfc_dec.c |4 + drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c| 85 -- 6 files changed, 209 insertions(+), 10 deletions(-) create mode 100644 drivers/media/platform/s5p-mfc/regs-mfc-v8.h diff --git a/Documentation/devicetree/bindings/media/s5p-mfc.txt b/Documentation/devicetree/bindings/media/s5p-mfc.txt index f418168..3e3c5f3 100644 --- a/Documentation/devicetree/bindings/media/s5p-mfc.txt +++ b/Documentation/devicetree/bindings/media/s5p-mfc.txt @@ -10,7 +10,8 @@ Required properties: - compatible : value should be either one among the following (a) samsung,mfc-v5 for MFC v5 present in Exynos4 SoCs (b) samsung,mfc-v6 for MFC v6 present in Exynos5 SoCs - (b) samsung,mfc-v7 for MFC v7 present in Exynos5420 SoC + (c) samsung,mfc-v7 for MFC v7 present in Exynos5420 SoC + (d) samsung,mfc-v8 for MFC v8 present in Exynos5800 SoC - reg : Physical base address of the IP registers and length of memory mapped region. diff --git a/drivers/media/platform/s5p-mfc/regs-mfc-v8.h b/drivers/media/platform/s5p-mfc/regs-mfc-v8.h new file mode 100644 index 000..747907c --- /dev/null +++ b/drivers/media/platform/s5p-mfc/regs-mfc-v8.h @@ -0,0 +1,93 @@ +/* + * Register definition file for Samsung MFC V8.x Interface (FIMV) driver + * + * Copyright (c) 2014 Samsung Electronics Co., Ltd. + * http://www.samsung.com/ + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + */ + +#ifndef _REGS_MFC_V8_H +#define _REGS_MFC_V8_H + +#include regs-mfc-v7.h + +/* Additional registers for v8 */ +#define S5P_FIMV_D_MVC_NUM_VIEWS_V80xf104 +#define S5P_FIMV_D_FIRST_PLANE_DPB_SIZE_V8 0xf144 +#define S5P_FIMV_D_SECOND_PLANE_DPB_SIZE_V80xf148 +#define S5P_FIMV_D_MV_BUFFER_SIZE_V8 0xf150 + +#define S5P_FIMV_D_FIRST_PLANE_DPB_STRIDE_SIZE_V8 0xf138 +#define S5P_FIMV_D_SECOND_PLANE_DPB_STRIDE_SIZE_V8 0xf13c + +#define S5P_FIMV_D_FIRST_PLANE_DPB_V8 0xf160 +#define S5P_FIMV_D_SECOND_PLANE_DPB_V8 0xf260 +#define S5P_FIMV_D_MV_BUFFER_V80xf460 + +#define S5P_FIMV_D_NUM_MV_V8 0xf134 +#define S5P_FIMV_D_INIT_BUFFER_OPTIONS_V8 0xf154 + +#define S5P_FIMV_D_SCRATCH_BUFFER_ADDR_V8 0xf560 +#define S5P_FIMV_D_SCRATCH_BUFFER_SIZE_V8 0xf564 + +#define S5P_FIMV_D_CPB_BUFFER_ADDR_V8 0xf5b0 +#define S5P_FIMV_D_CPB_BUFFER_SIZE_V8 0xf5b4 +#define S5P_FIMV_D_AVAILABLE_DPB_FLAG_LOWER_V8 0xf5bc +#define S5P_FIMV_D_CPB_BUFFER_OFFSET_V80xf5c0 +#define S5P_FIMV_D_SLICE_IF_ENABLE_V8 0xf5c4 +#define S5P_FIMV_D_STREAM_DATA_SIZE_V8 0xf5d0 + +/* Display information register */ +#define S5P_FIMV_D_DISPLAY_FRAME_WIDTH_V8 0xf600 +#define S5P_FIMV_D_DISPLAY_FRAME_HEIGHT_V8 0xf604 + +/* Display status */ +#define S5P_FIMV_D_DISPLAY_STATUS_V8 0xf608 + +#define S5P_FIMV_D_DISPLAY_FIRST_PLANE_ADDR_V8 0xf60c +#define S5P_FIMV_D_DISPLAY_SECOND_PLANE_ADDR_V80xf610 + +#define S5P_FIMV_D_DISPLAY_FRAME_TYPE_V8 0xf618 +#define S5P_FIMV_D_DISPLAY_CROP_INFO1_V8 0xf61c +#define S5P_FIMV_D_DISPLAY_CROP_INFO2_V8 0xf620 +#define S5P_FIMV_D_DISPLAY_PICTURE_PROFILE_V8 0xf624 + +/* Decoded picture information register */ +#define S5P_FIMV_D_DECODED_STATUS_V8 0xf644 +#define S5P_FIMV_D_DECODED_FIRST_PLANE_ADDR_V8 0xf648 +#define S5P_FIMV_D_DECODED_SECOND_PLANE_ADDR_V80xf64c +#define S5P_FIMV_D_DECODED_THIRD_PLANE_ADDR_V8 0xf650 +#define S5P_FIMV_D_DECODED_FRAME_TYPE_V8 0xf654 +#define S5P_FIMV_D_DECODED_NAL_SIZE_V8 0xf664 + +/* Returned value register for specific setting */ +#define S5P_FIMV_D_RET_PICTURE_TAG_TOP_V8 0xf674 +#define S5P_FIMV_D_RET_PICTURE_TAG_BOT_V8 0xf678 +#define S5P_FIMV_D_MVC_VIEW_ID_V8 0xf6d8 + +/* SEI related information */ +#define S5P_FIMV_D_FRAME_PACK_SEI_AVAIL_V8 0xf6dc + +/* MFCv8 Context buffer sizes */ +#define MFC_CTX_BUF_SIZE_V8(30 * SZ_1K)/* 30KB */ +#define MFC_H264_DEC_CTX_BUF_SIZE_V8 (2 * SZ_1M) /* 2MB */ +#define MFC_OTHER_DEC_CTX_BUF_SIZE_V8 (20 * SZ_1K)/* 20KB */ + +/* Buffer size defines */