Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 330877
b: refs/heads/master
c: 1cb7cf2
h: refs/heads/master
i:
  330875: 1cf281e
v: v3
  • Loading branch information
Javier Martin authored and Mauro Carvalho Chehab committed Aug 15, 2012
1 parent 7e34b63 commit 11c0e2e
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 561d5d78cb03fe08519a166594820c5a70f3931c
refs/heads/master: 1cb7cf28c0690852cfe5800e037fa0db9fba2432
40 changes: 40 additions & 0 deletions trunk/drivers/media/platform/mx2_camera.c
Original file line number Diff line number Diff line change
Expand Up @@ -335,6 +335,34 @@ static struct mx2_fmt_cfg mx27_emma_prp_table[] = {
.csicr1 = 0,
}
},
{
.in_fmt = V4L2_MBUS_FMT_UYVY8_2X8,
.out_fmt = V4L2_PIX_FMT_YUYV,
.cfg = {
.channel = 1,
.in_fmt = PRP_CNTL_DATA_IN_YUV422,
.out_fmt = PRP_CNTL_CH1_OUT_YUV422,
.src_pixel = 0x22000888, /* YUV422 (YUYV) */
.ch1_pixel = 0x62000888, /* YUV422 (YUYV) */
.irq_flags = PRP_INTR_RDERR | PRP_INTR_CH1WERR |
PRP_INTR_CH1FC | PRP_INTR_LBOVF,
.csicr1 = CSICR1_SWAP16_EN,
}
},
{
.in_fmt = V4L2_MBUS_FMT_YUYV8_2X8,
.out_fmt = V4L2_PIX_FMT_YUYV,
.cfg = {
.channel = 1,
.in_fmt = PRP_CNTL_DATA_IN_YUV422,
.out_fmt = PRP_CNTL_CH1_OUT_YUV422,
.src_pixel = 0x22000888, /* YUV422 (YUYV) */
.ch1_pixel = 0x62000888, /* YUV422 (YUYV) */
.irq_flags = PRP_INTR_RDERR | PRP_INTR_CH1WERR |
PRP_INTR_CH1FC | PRP_INTR_LBOVF,
.csicr1 = CSICR1_PACK_DIR,
}
},
{
.in_fmt = V4L2_MBUS_FMT_YUYV8_2X8,
.out_fmt = V4L2_PIX_FMT_YUV420,
Expand Down Expand Up @@ -1142,6 +1170,18 @@ static int mx2_camera_get_formats(struct soc_camera_device *icd,
}
}

if (code == V4L2_MBUS_FMT_UYVY8_2X8) {
formats++;
if (xlate) {
xlate->host_fmt =
soc_mbus_get_fmtdesc(V4L2_MBUS_FMT_YUYV8_2X8);
xlate->code = code;
dev_dbg(dev, "Providing host format %s for sensor code %d\n",
xlate->host_fmt->name, code);
xlate++;
}
}

/* Generic pass-trough */
formats++;
if (xlate) {
Expand Down

0 comments on commit 11c0e2e

Please sign in to comment.