return 0;
}
-#ifndef CSS15
static int lm3554_g_flash_status_register(struct v4l2_subdev *sd, s32 *val)
{
struct lm3554 *flash = to_lm3554(sd);
*val = ret;
return 0;
}
-#endif
static int lm3554_s_ctrl(struct v4l2_ctrl *ctrl)
{
case V4L2_CID_FLASH_STATUS:
ret = lm3554_g_flash_status(&dev->sd, &ctrl->val);
break;
-#ifndef CSS15
case V4L2_CID_FLASH_STATUS_REGISTER:
ret = lm3554_g_flash_status_register(&dev->sd, &ctrl->val);
break;
-#endif
default:
ret = -EINVAL;
}
.def = ATOMISP_FLASH_STATUS_OK,
.flags = 0,
},
-#ifndef CSS15
{
.ops = &ctrl_ops,
.id = V4L2_CID_FLASH_STATUS_REGISTER,
.def = 0,
.flags = 0,
},
-#endif
};
/* -----------------------------------------------------------------------------
return 0;
}
-#ifndef CSS15
/*
* This function will return the sensor supported max exposure zone number.
* the sensor which supports max exposure zone number is 1.
return 0;
}
-#endif
static int mt9m114_g_bin_factor_x(struct v4l2_subdev *sd, s32 *val)
{
__func__, ctrl->val);
ret = mt9m114_t_hflip(&dev->sd, ctrl->val);
break;
-#ifndef CSS15
case V4L2_CID_EXPOSURE_METERING:
ret = mt9m114_s_exposure_metering(&dev->sd, ctrl->val);
break;
-#endif
case V4L2_CID_EXPOSURE:
ret = mt9m114_s_ev(&dev->sd, ctrl->val);
break;
case V4L2_CID_EXPOSURE_ABSOLUTE:
ret = mt9m114_g_exposure(&dev->sd, &ctrl->val);
break;
-#ifndef CSS15
case V4L2_CID_EXPOSURE_ZONE_NUM:
ret = mt9m114_g_exposure_zone_num(&dev->sd, &ctrl->val);
break;
-#endif
case V4L2_CID_BIN_FACTOR_HORZ:
ret = mt9m114_g_bin_factor_x(&dev->sd, &ctrl->val);
break;
.def = 0,
.flags = 0,
},
-#ifndef CSS15
{
.ops = &ctrl_ops,
.id = V4L2_CID_EXPOSURE_ZONE_NUM,
.def = 1,
.flags = 0,
},
-#endif
{
.ops = &ctrl_ops,
.id = V4L2_CID_BIN_FACTOR_HORZ,
.enum_frame_size = mt9m114_enum_frame_size,
.get_fmt = mt9m114_get_fmt,
.set_fmt = mt9m114_set_fmt,
-#ifndef CSS15
.set_selection = mt9m114_s_exposure_selection,
-#endif
};
static const struct v4l2_subdev_ops mt9m114_ops = {
*
*
*/
-#ifdef CSS15
-#include <linux/atomisp_css15.h>
-#else
#ifndef _ATOM_ISP_H
#define _ATOM_ISP_H
};
#endif /* _ATOM_ISP_H */
-#endif /* CSS15*/
#include "system_global.h"
-#ifdef __FIST__
-#define HRT_ADDRESS_WIDTH 32 /* Surprise, this is a local property and even differs per platform */
-#else
#define HRT_ADDRESS_WIDTH 64 /* Surprise, this is a local property */
-#endif
/* This interface is deprecated */
#include "hrt/hive_types.h"
#define _isp_ceil_div(a, b) (((a) + (b) - 1) / (b))
-#ifdef C_RUN
-#define ISP_VEC_ALIGN (_isp_ceil_div(ISP_VEC_WIDTH, 64) * 8)
-#else
#define ISP_VEC_ALIGN ISP_VMEM_ALIGN
-#endif
/* HRT specific vector support */
#define isp2401_mamoiada_vector_alignment ISP_VEC_ALIGN
#define HRT_HOST_TYPE(cell_type) HRTCAT(hrt_host_type_of_, cell_type)
#define HRT_INT_TYPE(type) HRTCAT(hrt_int_type_of_, type)
-#ifdef C_RUN
-
-#ifdef C_RUN_DYNAMIC_LINK_PROGRAMS
-void *csim_processor_get_crun_symbol(hive_proc_id p, const char *sym);
-#define _hrt_cell_get_crun_symbol(cell, sym) csim_processor_get_crun_symbol(cell, HRTSTR(sym))
-#define _hrt_cell_get_crun_indexed_symbol(cell, sym) csim_processor_get_crun_symbol(cell, HRTSTR(sym))
-#else
-#define _hrt_cell_get_crun_symbol(cell, sym) (&sym)
-#define _hrt_cell_get_crun_indexed_symbol(cell, sym) (sym)
-#endif // C_RUN_DYNAMIC_LINK_PROGRAMS
-
-#define hrt_scalar_store(cell, type, var, data) \
- ((*(HRT_HOST_TYPE(type) *)_hrt_cell_get_crun_symbol(cell, var)) = (data))
-#define hrt_scalar_load(cell, type, var) \
- ((*(HRT_HOST_TYPE(type) *)_hrt_cell_get_crun_symbol(cell, var)))
-
-#define hrt_indexed_store(cell, type, array, index, data) \
- ((((HRT_HOST_TYPE(type) *)_hrt_cell_get_crun_indexed_symbol(cell, array))[index]) = (data))
-#define hrt_indexed_load(cell, type, array, index) \
- (((HRT_HOST_TYPE(type) *)_hrt_cell_get_crun_indexed_symbol(cell, array))[index])
-
-#else /* C_RUN */
#define hrt_scalar_store(cell, type, var, data) \
HRTCAT(hrt_mem_store_, HRT_TYPE_BITS(cell, type))(\
HRTCAT(HIVE_MEM_, array), \
(HRTCAT(HIVE_ADDR_, array)) + ((index) * HRT_TYPE_BYTES(cell, type))))
-#endif /* C_RUN */
#endif /* _HRT_VAR_H */
#endif
#define _isp_ceil_div(a, b) (((a) + (b) - 1) / (b))
-#ifdef C_RUN
-#define ISP_VEC_ALIGN (_isp_ceil_div(ISP_VEC_WIDTH, 64) * 8)
-#else
#define ISP_VEC_ALIGN ISP_VMEM_ALIGN
-#endif
/* HRT specific vector support */
#define isp2401_mamoiada_vector_alignment ISP_VEC_ALIGN
#define HRT_HOST_TYPE(cell_type) HRTCAT(hrt_host_type_of_, cell_type)
#define HRT_INT_TYPE(type) HRTCAT(hrt_int_type_of_, type)
-#ifdef C_RUN
-
-#ifdef C_RUN_DYNAMIC_LINK_PROGRAMS
-void *csim_processor_get_crun_symbol(hive_proc_id p, const char *sym);
-#define _hrt_cell_get_crun_symbol(cell, sym) csim_processor_get_crun_symbol(cell, HRTSTR(sym))
-#define _hrt_cell_get_crun_indexed_symbol(cell, sym) csim_processor_get_crun_symbol(cell, HRTSTR(sym))
-#else
-#define _hrt_cell_get_crun_symbol(cell, sym) (&sym)
-#define _hrt_cell_get_crun_indexed_symbol(cell, sym) (sym)
-#endif // C_RUN_DYNAMIC_LINK_PROGRAMS
-
-#define hrt_scalar_store(cell, type, var, data) \
- ((*(HRT_HOST_TYPE(type) *)_hrt_cell_get_crun_symbol(cell, var)) = (data))
-#define hrt_scalar_load(cell, type, var) \
- ((*(HRT_HOST_TYPE(type) *)_hrt_cell_get_crun_symbol(cell, var)))
-
-#define hrt_indexed_store(cell, type, array, index, data) \
- ((((HRT_HOST_TYPE(type) *)_hrt_cell_get_crun_indexed_symbol(cell, array))[index]) = (data))
-#define hrt_indexed_load(cell, type, array, index) \
- (((HRT_HOST_TYPE(type) *)_hrt_cell_get_crun_indexed_symbol(cell, array))[index])
-
-#else /* C_RUN */
#define hrt_scalar_store(cell, type, var, data) \
HRTCAT(hrt_mem_store_, HRT_TYPE_BITS(cell, type))(\
HRTCAT(HIVE_MEM_, array), \
(HRTCAT(HIVE_ADDR_, array)) + ((index) * HRT_TYPE_BYTES(cell, type))))
-#endif /* C_RUN */
#endif /* _HRT_VAR_H */
#endif
#include "system_global.h"
-#ifdef __FIST__
-#define HRT_ADDRESS_WIDTH 32 /* Surprise, this is a local property and even differs per platform */
-#else
/* HRT assumes 32 by default (see Linux/include/hrt/hive_types.h), overrule it in case it is different */
#undef HRT_ADDRESS_WIDTH
#define HRT_ADDRESS_WIDTH 64 /* Surprise, this is a local property */
-#endif
/* This interface is deprecated */
#include "hrt/hive_types.h"
#define CT_ASSERT(cnd) ((void)sizeof(char[(cnd) ? 1 : -1]))
#endif /* CT_ASSERT */
-#ifdef NDEBUG
-
-#define assert(cnd) ((void)0)
-
-#else
-
-#if defined(_MSC_VER)
-#ifdef _KERNEL_MODE
-/* Windows kernel mode compilation */
-#include <wdm.h>
-#define assert(cnd) ASSERT(cnd)
-#else
-/* Windows usermode compilation */
-#include <assert.h>
-#endif
-
-#elif defined(__KERNEL__)
#include <linux/bug.h>
/* TODO: it would be cleaner to use this:
BUG(); \
} while (0)
-#elif defined(__FIST__) || defined(__GNUC__)
-
-/* enable assert for crun */
-#include "assert.h"
-
-#else /* default for unknown environments */
-#define assert(cnd) ((void)0)
-#endif
-
-#endif /* NDEBUG */
-
#ifndef PIPE_GENERATION
/* Deprecated OP___assert, this is still used in ~1000 places
* in the code. This will be removed over time.
#ifndef __ERROR_SUPPORT_H_INCLUDED__
#define __ERROR_SUPPORT_H_INCLUDED__
-#if defined(_MSC_VER)
-#include <errno.h>
-/*
- * Put here everything _MSC_VER specific not covered in
- * "errno.h"
- */
-#define EINVAL 22
-#define EBADE 52
-#define ENODATA 61
-#define ENOTCONN 107
-#define ENOTSUP 252
-#define ENOBUFS 233
-
-#elif defined(__KERNEL__)
#include <linux/errno.h>
/*
* Put here everything __KERNEL__ specific not covered in
*/
#define ENOTSUP 252
-#elif defined(__GNUC__)
-#include <errno.h>
-/*
- * Put here everything __GNUC__ specific not covered in
- * "errno.h"
- */
-
-#else /* default is for the FIST environment */
-#include <errno.h>
-/*
- * Put here everything FIST specific not covered in
- * "errno.h"
- */
-
-#endif
-
#define verifexit(cond, error_tag) \
do { \
if (!(cond)) { \
#include <linux/kernel.h> /* Override the definition of max/min from linux kernel*/
-#if defined(_MSC_VER)
-#include <stdlib.h> /* Override the definition of max/min from stdlib.h*/
-#endif /* _MSC_VER */
/* in case we have min/max/MIN/MAX macro's undefine them */
#ifdef min
#define CSS_ALIGN(d, a) d __attribute__((aligned(a)))
-/*
- * Put here everything __KERNEL__ specific not covered in
- * "assert_support.h", "math_support.h", etc
- */
-
#endif /* __PLATFORM_SUPPORT_H_INCLUDED__ */
#include <platform_support.h>
#include <type_support.h>
-#if !defined(_MSC_VER)
/*
* For all non microsoft cases, we need the following functions
*/
return 0;
}
-#endif /*!defined(_MSC_VER)*/
#endif /* __STRING_SUPPORT_H_INCLUDED__ */
#define XNR_BLENDING_SCALE_FACTOR BIT(XNR_BLENDING_SCALE_LOG2)
/* XNR3 filter size. Must be 11x11, 9x9 or 5x5. */
-#ifdef FLT_KERNEL_9x9
-#define XNR_FILTER_SIZE 9
-#else
-#ifdef FLT_KERNEL_11x11
-#define XNR_FILTER_SIZE 11
-#else
#define XNR_FILTER_SIZE 5
-#endif
-#endif
/* XNR3 alpha (1/sigma) parameters on the ISP, expressed as a base (0) value
* for dark areas, and a scaled diff towards the value for bright areas. */
#define NUM_TNR_FRAMES_PER_REF_BUF_SET (2)
/* In luma-only mode alternate illuminated frames are supported, that requires two double buffers */
-#ifdef ENABLE_LUMA_ONLY
-#define NUM_TNR_REF_BUF_SETS (2)
-#else
#define NUM_TNR_REF_BUF_SETS (1)
-#endif
#define NUM_TNR_FRAMES (NUM_TNR_FRAMES_PER_REF_BUF_SET * NUM_TNR_REF_BUF_SETS)
#define SH_CSS_SP_INTERNAL_SERVICE_THREAD 1
-#ifdef __DISABLE_UNUSED_THREAD__
-#define SH_CSS_MAX_SP_THREADS 0
-#else
#define SH_CSS_MAX_SP_THREADS 5
-#endif
#define SH_CSS_MAX_SP_INTERNAL_THREADS (\
SH_CSS_SP_INTERNAL_SERVICE_THREAD +\