static DECLARE_WAIT_QUEUE_HEAD(res_waitq);
static atomic_t req_cnt;
static int major;
+static int max_ipu_no;
static int thread_id;
static atomic_t frame_no;
static struct class *ipu_class;
}
}
- for (i = 0; i < MXC_IPU_MAX_NUM; i++) {
+ for (i = 0; i < max_ipu_no; i++) {
ipu = ipu_get_soc(i);
if (IS_ERR(ipu))
BUG();
if (found_ipu)
goto next;
- for (i = 0; i < MXC_IPU_MAX_NUM; i++) {
+ for (i = 0; i < max_ipu_no; i++) {
ipu = ipu_get_soc(i);
if (IS_ERR(ipu))
BUG();
return -EINVAL;
else if (param.band_mode)
param.band_lines = (1 << t->set.band_lines);
- for (i = 0; i < MXC_IPU_MAX_NUM; i++) {
+ for (i = 0; i < max_ipu_no; i++) {
ipu_idx = ipu_get_soc(i);
if (!IS_ERR(ipu_idx) && ipu_idx == ipu)
break;
if (t->set.task & VDOA_ONLY)
/* dummy, didn't need ipu res */
i = 0;
- if (MXC_IPU_MAX_NUM == i) {
+ if (max_ipu_no == i) {
dev_err(t->dev, "ERR:[0x%p] get ipu num\n", t);
return -EINVAL;
}
out:
if (ret == -ETIMEDOUT) {
/* debug */
- for (k = 0; k < MXC_IPU_MAX_NUM; k++) {
+ for (k = 0; k < max_ipu_no; k++) {
ipu = ipu_get_soc(k);
if (IS_ERR(ipu)) {
BUG();
mutex_init(&ipu_ch_tbl.lock);
}
+ max_ipu_no = ++id;
ipu->rot_dma[0].size = 0;
ipu->rot_dma[1].size = 0;