msm: camera: Enable IMEM clock for inline jpeg

This change enables IMEM clock so that VFE can put
frame in to IMEM and Gemini received frame from IMEM.

Change-Id: Ia7d12d7ec5bd433deef545d04e8a72256e19513c
Signed-off-by: Jignesh Mehta <jigneshm@codeaurora.org>
This commit is contained in:
Jignesh Mehta
2011-11-18 17:21:16 -08:00
committed by Linux Build Service Account
parent ed1e2dd6d8
commit 95dd6e161b
4 changed files with 72 additions and 1 deletions

View File

@@ -219,6 +219,18 @@ static struct msm_bus_vectors cam_init_vectors[] = {
.ab = 0, .ab = 0,
.ib = 0, .ib = 0,
}, },
{
.src = MSM_BUS_MASTER_JPEG_ENC,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 0,
.ib = 0,
},
{
.src = MSM_BUS_MASTER_VFE,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 0,
.ib = 0,
},
}; };
static struct msm_bus_vectors cam_preview_vectors[] = { static struct msm_bus_vectors cam_preview_vectors[] = {
@@ -240,6 +252,18 @@ static struct msm_bus_vectors cam_preview_vectors[] = {
.ab = 0, .ab = 0,
.ib = 0, .ib = 0,
}, },
{
.src = MSM_BUS_MASTER_JPEG_ENC,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 0,
.ib = 0,
},
{
.src = MSM_BUS_MASTER_VFE,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 0,
.ib = 0,
},
}; };
static struct msm_bus_vectors cam_video_vectors[] = { static struct msm_bus_vectors cam_video_vectors[] = {
@@ -261,6 +285,18 @@ static struct msm_bus_vectors cam_video_vectors[] = {
.ab = 0, .ab = 0,
.ib = 0, .ib = 0,
}, },
{
.src = MSM_BUS_MASTER_JPEG_ENC,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 0,
.ib = 0,
},
{
.src = MSM_BUS_MASTER_VFE,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 0,
.ib = 0,
},
}; };
static struct msm_bus_vectors cam_snapshot_vectors[] = { static struct msm_bus_vectors cam_snapshot_vectors[] = {
@@ -282,6 +318,18 @@ static struct msm_bus_vectors cam_snapshot_vectors[] = {
.ab = 540000000, .ab = 540000000,
.ib = 1350000000, .ib = 1350000000,
}, },
{
.src = MSM_BUS_MASTER_JPEG_ENC,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 43200000,
.ib = 69120000,
},
{
.src = MSM_BUS_MASTER_VFE,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 43200000,
.ib = 69120000,
},
}; };
static struct msm_bus_vectors cam_zsl_vectors[] = { static struct msm_bus_vectors cam_zsl_vectors[] = {
@@ -303,6 +351,18 @@ static struct msm_bus_vectors cam_zsl_vectors[] = {
.ab = 540000000, .ab = 540000000,
.ib = 1350000000, .ib = 1350000000,
}, },
{
.src = MSM_BUS_MASTER_JPEG_ENC,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 43200000,
.ib = 69120000,
},
{
.src = MSM_BUS_MASTER_VFE,
.dst = MSM_BUS_SLAVE_MM_IMEM,
.ab = 43200000,
.ib = 69120000,
},
}; };
static struct msm_bus_paths cam_bus_client_config[] = { static struct msm_bus_paths cam_bus_client_config[] = {

View File

@@ -5249,7 +5249,7 @@ static struct clk_lookup msm_clocks_8960[] = {
CLK_LOOKUP("core_clk", gfx3d_clk.c, "kgsl-3d0.0"), CLK_LOOKUP("core_clk", gfx3d_clk.c, "kgsl-3d0.0"),
CLK_LOOKUP("core_clk", gfx3d_clk.c, "footswitch-8x60.2"), CLK_LOOKUP("core_clk", gfx3d_clk.c, "footswitch-8x60.2"),
CLK_LOOKUP("bus_clk", ijpeg_axi_clk.c, "footswitch-8x60.3"), CLK_LOOKUP("bus_clk", ijpeg_axi_clk.c, "footswitch-8x60.3"),
CLK_LOOKUP("mem_clk", imem_axi_clk.c, ""), CLK_LOOKUP("imem_clk", imem_axi_clk.c, NULL),
CLK_LOOKUP("ijpeg_clk", ijpeg_clk.c, NULL), CLK_LOOKUP("ijpeg_clk", ijpeg_clk.c, NULL),
CLK_LOOKUP("core_clk", ijpeg_clk.c, "footswitch-8x60.3"), CLK_LOOKUP("core_clk", ijpeg_clk.c, "footswitch-8x60.3"),
CLK_LOOKUP("core_clk", jpegd_clk.c, ""), CLK_LOOKUP("core_clk", jpegd_clk.c, ""),

View File

@@ -577,6 +577,7 @@ enum msm_camio_clk_type {
CAMIO_CSI0_PHY_CLK, CAMIO_CSI0_PHY_CLK,
CAMIO_CSI1_PHY_CLK, CAMIO_CSI1_PHY_CLK,
CAMIO_CSIPHY_TIMER_SRC_CLK, CAMIO_CSIPHY_TIMER_SRC_CLK,
CAMIO_IMEM_CLK,
CAMIO_MAX_CLK CAMIO_MAX_CLK
}; };

View File

@@ -29,6 +29,7 @@
static struct clk *camio_jpeg_clk; static struct clk *camio_jpeg_clk;
static struct clk *camio_jpeg_pclk; static struct clk *camio_jpeg_pclk;
static struct clk *camio_imem_clk;
static struct regulator *fs_ijpeg; static struct regulator *fs_ijpeg;
static struct platform_device *camio_dev; static struct platform_device *camio_dev;
@@ -129,6 +130,11 @@ int msm_camio_clk_enable(enum msm_camio_clk_type clktype)
clk = clk_get(NULL, "ijpeg_pclk"); clk = clk_get(NULL, "ijpeg_pclk");
break; break;
case CAMIO_IMEM_CLK:
camio_imem_clk =
clk = clk_get(NULL, "imem_clk");
break;
default: default:
break; break;
} }
@@ -158,6 +164,10 @@ int msm_camio_clk_disable(enum msm_camio_clk_type clktype)
clk = camio_jpeg_pclk; clk = camio_jpeg_pclk;
break; break;
case CAMIO_IMEM_CLK:
clk = camio_imem_clk;
break;
default: default:
break; break;
} }