Commit 81bdfa4f authored by Bryan O'Donoghue's avatar Bryan O'Donoghue Committed by Mauro Carvalho Chehab

media: camss: Set unused regulators to the empty set

If a CAMSS block has no regulator set the regulator array to the empty set
as opposed to setting the first element of the array to NULL.
Suggested-by: default avatarBjorn Andersson <bjorn.andersson@linaro.org>
Reviewed-by: default avatarRobert Foss <robert.foss@linaro.org>
Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
Signed-off-by: default avatarHans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@kernel.org>
parent 0d814017
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
static const struct resources csiphy_res_8x16[] = { static const struct resources csiphy_res_8x16[] = {
/* CSIPHY0 */ /* CSIPHY0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy0_timer" }, .clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy0_timer" },
.clock_rate = { { 0 }, .clock_rate = { { 0 },
{ 0 }, { 0 },
...@@ -46,7 +46,7 @@ static const struct resources csiphy_res_8x16[] = { ...@@ -46,7 +46,7 @@ static const struct resources csiphy_res_8x16[] = {
/* CSIPHY1 */ /* CSIPHY1 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy1_timer" }, .clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy1_timer" },
.clock_rate = { { 0 }, .clock_rate = { { 0 },
{ 0 }, { 0 },
...@@ -107,7 +107,7 @@ static const struct resources_ispif ispif_res_8x16 = { ...@@ -107,7 +107,7 @@ static const struct resources_ispif ispif_res_8x16 = {
static const struct resources vfe_res_8x16[] = { static const struct resources vfe_res_8x16[] = {
/* VFE0 */ /* VFE0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "vfe0", "csi_vfe0", .clock = { "top_ahb", "vfe0", "csi_vfe0",
"vfe_ahb", "vfe_axi", "ahb" }, "vfe_ahb", "vfe_axi", "ahb" },
.clock_rate = { { 0 }, .clock_rate = { { 0 },
...@@ -129,7 +129,7 @@ static const struct resources vfe_res_8x16[] = { ...@@ -129,7 +129,7 @@ static const struct resources vfe_res_8x16[] = {
static const struct resources csiphy_res_8x96[] = { static const struct resources csiphy_res_8x96[] = {
/* CSIPHY0 */ /* CSIPHY0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy0_timer" }, .clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy0_timer" },
.clock_rate = { { 0 }, .clock_rate = { { 0 },
{ 0 }, { 0 },
...@@ -141,7 +141,7 @@ static const struct resources csiphy_res_8x96[] = { ...@@ -141,7 +141,7 @@ static const struct resources csiphy_res_8x96[] = {
/* CSIPHY1 */ /* CSIPHY1 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy1_timer" }, .clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy1_timer" },
.clock_rate = { { 0 }, .clock_rate = { { 0 },
{ 0 }, { 0 },
...@@ -153,7 +153,7 @@ static const struct resources csiphy_res_8x96[] = { ...@@ -153,7 +153,7 @@ static const struct resources csiphy_res_8x96[] = {
/* CSIPHY2 */ /* CSIPHY2 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy2_timer" }, .clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy2_timer" },
.clock_rate = { { 0 }, .clock_rate = { { 0 },
{ 0 }, { 0 },
...@@ -249,7 +249,7 @@ static const struct resources_ispif ispif_res_8x96 = { ...@@ -249,7 +249,7 @@ static const struct resources_ispif ispif_res_8x96 = {
static const struct resources vfe_res_8x96[] = { static const struct resources vfe_res_8x96[] = {
/* VFE0 */ /* VFE0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ahb", "vfe0", "csi_vfe0", "vfe_ahb", .clock = { "top_ahb", "ahb", "vfe0", "csi_vfe0", "vfe_ahb",
"vfe0_ahb", "vfe_axi", "vfe0_stream"}, "vfe0_ahb", "vfe_axi", "vfe0_stream"},
.clock_rate = { { 0 }, .clock_rate = { { 0 },
...@@ -267,7 +267,7 @@ static const struct resources vfe_res_8x96[] = { ...@@ -267,7 +267,7 @@ static const struct resources vfe_res_8x96[] = {
/* VFE1 */ /* VFE1 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ahb", "vfe1", "csi_vfe1", "vfe_ahb", .clock = { "top_ahb", "ahb", "vfe1", "csi_vfe1", "vfe_ahb",
"vfe1_ahb", "vfe_axi", "vfe1_stream"}, "vfe1_ahb", "vfe_axi", "vfe1_stream"},
.clock_rate = { { 0 }, .clock_rate = { { 0 },
...@@ -287,7 +287,7 @@ static const struct resources vfe_res_8x96[] = { ...@@ -287,7 +287,7 @@ static const struct resources vfe_res_8x96[] = {
static const struct resources csiphy_res_660[] = { static const struct resources csiphy_res_660[] = {
/* CSIPHY0 */ /* CSIPHY0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy0_timer", .clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy0_timer",
"csi0_phy", "csiphy_ahb2crif" }, "csi0_phy", "csiphy_ahb2crif" },
.clock_rate = { { 0 }, .clock_rate = { { 0 },
...@@ -301,7 +301,7 @@ static const struct resources csiphy_res_660[] = { ...@@ -301,7 +301,7 @@ static const struct resources csiphy_res_660[] = {
/* CSIPHY1 */ /* CSIPHY1 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy1_timer", .clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy1_timer",
"csi1_phy", "csiphy_ahb2crif" }, "csi1_phy", "csiphy_ahb2crif" },
.clock_rate = { { 0 }, .clock_rate = { { 0 },
...@@ -315,7 +315,7 @@ static const struct resources csiphy_res_660[] = { ...@@ -315,7 +315,7 @@ static const struct resources csiphy_res_660[] = {
/* CSIPHY2 */ /* CSIPHY2 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy2_timer", .clock = { "top_ahb", "ispif_ahb", "ahb", "csiphy2_timer",
"csi2_phy", "csiphy_ahb2crif" }, "csi2_phy", "csiphy_ahb2crif" },
.clock_rate = { { 0 }, .clock_rate = { { 0 },
...@@ -425,7 +425,7 @@ static const struct resources_ispif ispif_res_660 = { ...@@ -425,7 +425,7 @@ static const struct resources_ispif ispif_res_660 = {
static const struct resources vfe_res_660[] = { static const struct resources vfe_res_660[] = {
/* VFE0 */ /* VFE0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "throttle_axi", "top_ahb", "ahb", "vfe0", .clock = { "throttle_axi", "top_ahb", "ahb", "vfe0",
"csi_vfe0", "vfe_ahb", "vfe0_ahb", "vfe_axi", "csi_vfe0", "vfe_ahb", "vfe0_ahb", "vfe_axi",
"vfe0_stream"}, "vfe0_stream"},
...@@ -446,7 +446,7 @@ static const struct resources vfe_res_660[] = { ...@@ -446,7 +446,7 @@ static const struct resources vfe_res_660[] = {
/* VFE1 */ /* VFE1 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "throttle_axi", "top_ahb", "ahb", "vfe1", .clock = { "throttle_axi", "top_ahb", "ahb", "vfe1",
"csi_vfe1", "vfe_ahb", "vfe1_ahb", "vfe_axi", "csi_vfe1", "vfe_ahb", "vfe1_ahb", "vfe_axi",
"vfe1_stream"}, "vfe1_stream"},
...@@ -469,7 +469,7 @@ static const struct resources vfe_res_660[] = { ...@@ -469,7 +469,7 @@ static const struct resources vfe_res_660[] = {
static const struct resources csiphy_res_845[] = { static const struct resources csiphy_res_845[] = {
/* CSIPHY0 */ /* CSIPHY0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi", "soc_ahb", "slow_ahb_src", .clock = { "camnoc_axi", "soc_ahb", "slow_ahb_src",
"cpas_ahb", "cphy_rx_src", "csiphy0", "cpas_ahb", "cphy_rx_src", "csiphy0",
"csiphy0_timer_src", "csiphy0_timer" }, "csiphy0_timer_src", "csiphy0_timer" },
...@@ -487,7 +487,7 @@ static const struct resources csiphy_res_845[] = { ...@@ -487,7 +487,7 @@ static const struct resources csiphy_res_845[] = {
/* CSIPHY1 */ /* CSIPHY1 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi", "soc_ahb", "slow_ahb_src", .clock = { "camnoc_axi", "soc_ahb", "slow_ahb_src",
"cpas_ahb", "cphy_rx_src", "csiphy1", "cpas_ahb", "cphy_rx_src", "csiphy1",
"csiphy1_timer_src", "csiphy1_timer" }, "csiphy1_timer_src", "csiphy1_timer" },
...@@ -505,7 +505,7 @@ static const struct resources csiphy_res_845[] = { ...@@ -505,7 +505,7 @@ static const struct resources csiphy_res_845[] = {
/* CSIPHY2 */ /* CSIPHY2 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi", "soc_ahb", "slow_ahb_src", .clock = { "camnoc_axi", "soc_ahb", "slow_ahb_src",
"cpas_ahb", "cphy_rx_src", "csiphy2", "cpas_ahb", "cphy_rx_src", "csiphy2",
"csiphy2_timer_src", "csiphy2_timer" }, "csiphy2_timer_src", "csiphy2_timer" },
...@@ -523,7 +523,7 @@ static const struct resources csiphy_res_845[] = { ...@@ -523,7 +523,7 @@ static const struct resources csiphy_res_845[] = {
/* CSIPHY3 */ /* CSIPHY3 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi", "soc_ahb", "slow_ahb_src", .clock = { "camnoc_axi", "soc_ahb", "slow_ahb_src",
"cpas_ahb", "cphy_rx_src", "csiphy3", "cpas_ahb", "cphy_rx_src", "csiphy3",
"csiphy3_timer_src", "csiphy3_timer" }, "csiphy3_timer_src", "csiphy3_timer" },
...@@ -605,7 +605,7 @@ static const struct resources csid_res_845[] = { ...@@ -605,7 +605,7 @@ static const struct resources csid_res_845[] = {
static const struct resources vfe_res_845[] = { static const struct resources vfe_res_845[] = {
/* VFE0 */ /* VFE0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi", "cpas_ahb", "slow_ahb_src", .clock = { "camnoc_axi", "cpas_ahb", "slow_ahb_src",
"soc_ahb", "vfe0", "vfe0_axi", "soc_ahb", "vfe0", "vfe0_axi",
"vfe0_src", "csi0", "vfe0_src", "csi0",
...@@ -625,7 +625,7 @@ static const struct resources vfe_res_845[] = { ...@@ -625,7 +625,7 @@ static const struct resources vfe_res_845[] = {
/* VFE1 */ /* VFE1 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi", "cpas_ahb", "slow_ahb_src", .clock = { "camnoc_axi", "cpas_ahb", "slow_ahb_src",
"soc_ahb", "vfe1", "vfe1_axi", "soc_ahb", "vfe1", "vfe1_axi",
"vfe1_src", "csi1", "vfe1_src", "csi1",
...@@ -645,7 +645,7 @@ static const struct resources vfe_res_845[] = { ...@@ -645,7 +645,7 @@ static const struct resources vfe_res_845[] = {
/* VFE-lite */ /* VFE-lite */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi", "cpas_ahb", "slow_ahb_src", .clock = { "camnoc_axi", "cpas_ahb", "slow_ahb_src",
"soc_ahb", "vfe_lite", "soc_ahb", "vfe_lite",
"vfe_lite_src", "csi2", "vfe_lite_src", "csi2",
...@@ -666,7 +666,7 @@ static const struct resources vfe_res_845[] = { ...@@ -666,7 +666,7 @@ static const struct resources vfe_res_845[] = {
static const struct resources csiphy_res_8250[] = { static const struct resources csiphy_res_8250[] = {
/* CSIPHY0 */ /* CSIPHY0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "csiphy0", "csiphy0_timer" }, .clock = { "csiphy0", "csiphy0_timer" },
.clock_rate = { { 400000000 }, .clock_rate = { { 400000000 },
{ 300000000 } }, { 300000000 } },
...@@ -675,7 +675,7 @@ static const struct resources csiphy_res_8250[] = { ...@@ -675,7 +675,7 @@ static const struct resources csiphy_res_8250[] = {
}, },
/* CSIPHY1 */ /* CSIPHY1 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "csiphy1", "csiphy1_timer" }, .clock = { "csiphy1", "csiphy1_timer" },
.clock_rate = { { 400000000 }, .clock_rate = { { 400000000 },
{ 300000000 } }, { 300000000 } },
...@@ -684,7 +684,7 @@ static const struct resources csiphy_res_8250[] = { ...@@ -684,7 +684,7 @@ static const struct resources csiphy_res_8250[] = {
}, },
/* CSIPHY2 */ /* CSIPHY2 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "csiphy2", "csiphy2_timer" }, .clock = { "csiphy2", "csiphy2_timer" },
.clock_rate = { { 400000000 }, .clock_rate = { { 400000000 },
{ 300000000 } }, { 300000000 } },
...@@ -693,7 +693,7 @@ static const struct resources csiphy_res_8250[] = { ...@@ -693,7 +693,7 @@ static const struct resources csiphy_res_8250[] = {
}, },
/* CSIPHY3 */ /* CSIPHY3 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "csiphy3", "csiphy3_timer" }, .clock = { "csiphy3", "csiphy3_timer" },
.clock_rate = { { 400000000 }, .clock_rate = { { 400000000 },
{ 300000000 } }, { 300000000 } },
...@@ -702,7 +702,7 @@ static const struct resources csiphy_res_8250[] = { ...@@ -702,7 +702,7 @@ static const struct resources csiphy_res_8250[] = {
}, },
/* CSIPHY4 */ /* CSIPHY4 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "csiphy4", "csiphy4_timer" }, .clock = { "csiphy4", "csiphy4_timer" },
.clock_rate = { { 400000000 }, .clock_rate = { { 400000000 },
{ 300000000 } }, { 300000000 } },
...@@ -711,7 +711,7 @@ static const struct resources csiphy_res_8250[] = { ...@@ -711,7 +711,7 @@ static const struct resources csiphy_res_8250[] = {
}, },
/* CSIPHY5 */ /* CSIPHY5 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "csiphy5", "csiphy5_timer" }, .clock = { "csiphy5", "csiphy5_timer" },
.clock_rate = { { 400000000 }, .clock_rate = { { 400000000 },
{ 300000000 } }, { 300000000 } },
...@@ -772,7 +772,7 @@ static const struct resources csid_res_8250[] = { ...@@ -772,7 +772,7 @@ static const struct resources csid_res_8250[] = {
static const struct resources vfe_res_8250[] = { static const struct resources vfe_res_8250[] = {
/* VFE0 */ /* VFE0 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi_src", "slow_ahb_src", "cpas_ahb", .clock = { "camnoc_axi_src", "slow_ahb_src", "cpas_ahb",
"camnoc_axi", "vfe0_ahb", "vfe0_areg", "vfe0", "camnoc_axi", "vfe0_ahb", "vfe0_areg", "vfe0",
"vfe0_axi", "cam_hf_axi" }, "vfe0_axi", "cam_hf_axi" },
...@@ -790,7 +790,7 @@ static const struct resources vfe_res_8250[] = { ...@@ -790,7 +790,7 @@ static const struct resources vfe_res_8250[] = {
}, },
/* VFE1 */ /* VFE1 */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi_src", "slow_ahb_src", "cpas_ahb", .clock = { "camnoc_axi_src", "slow_ahb_src", "cpas_ahb",
"camnoc_axi", "vfe1_ahb", "vfe1_areg", "vfe1", "camnoc_axi", "vfe1_ahb", "vfe1_areg", "vfe1",
"vfe1_axi", "cam_hf_axi" }, "vfe1_axi", "cam_hf_axi" },
...@@ -808,7 +808,7 @@ static const struct resources vfe_res_8250[] = { ...@@ -808,7 +808,7 @@ static const struct resources vfe_res_8250[] = {
}, },
/* VFE2 (lite) */ /* VFE2 (lite) */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi_src", "slow_ahb_src", "cpas_ahb", .clock = { "camnoc_axi_src", "slow_ahb_src", "cpas_ahb",
"camnoc_axi", "vfe_lite_ahb", "vfe_lite_axi", "camnoc_axi", "vfe_lite_ahb", "vfe_lite_axi",
"vfe_lite", "cam_hf_axi" }, "vfe_lite", "cam_hf_axi" },
...@@ -825,7 +825,7 @@ static const struct resources vfe_res_8250[] = { ...@@ -825,7 +825,7 @@ static const struct resources vfe_res_8250[] = {
}, },
/* VFE3 (lite) */ /* VFE3 (lite) */
{ {
.regulators = { NULL }, .regulators = {},
.clock = { "camnoc_axi_src", "slow_ahb_src", "cpas_ahb", .clock = { "camnoc_axi_src", "slow_ahb_src", "cpas_ahb",
"camnoc_axi", "vfe_lite_ahb", "vfe_lite_axi", "camnoc_axi", "vfe_lite_ahb", "vfe_lite_axi",
"vfe_lite", "cam_hf_axi" }, "vfe_lite", "cam_hf_axi" },
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment