Skip to contentSkip to conversation

ARM: davinci: some dm646x related fixes

PATCH New Sekhar Nori 1 participant 5 messages May 11, 2018 – May 15, 2018

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

cover ARM: davinci: some dm646x related fixes

Hi,

Here are some DM646x related fixes for issues I found while testing the platform.

Sekhar Nori (3):
ARM: davinci: dm646x: fix timer interrupt generation
ARM: davinci: board-dm646x-evm: pass correct I2C adapter id for VPIF
ARM: davinci: board-dm646x-evm: set VPIF capture card name

 arch/arm/mach-davinci/board-dm646x-evm.c | 5 ++++-
 arch/arm/mach-davinci/dm646x.c           | 3 ++-
 2 files changed, 6 insertions(+), 2 deletions(-)
Signature · 1 line
2.16.2
#1 lore raw

PATCH 1/3 ARM: davinci: dm646x: fix timer interrupt generation

commit b38434145b34 ("ARM: davinci: irqs: Correct McASP1 TX interrupt definition for DM646x") inadvertently removed setting for priority for timer0_12 (bottom half of timer0). This timer is used as clockevent.

When INTPRIn register setting for an interrupt is left at 0, it is mapped to FIQ by the AINTC causing the timer interrupt to not get generated.

Fix it by including an entry for timer0_12 in interrupt priority map array. While at it, move the clockevent comment to the right place.

Fixes b38434145b34 ("ARM: davinci: irqs: Correct McASP1 TX interrupt definition for DM646x")
---
 arch/arm/mach-davinci/dm646x.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
arch/arm/mach-davinci/dm646x.c +2 -1
index 54a4299030de..6bd2ed069d0d 100644
@@ -178,7 +178,8 @@ static u8 dm646x_default_priorities[DAVINCI_N_AINTC_IRQ] = {
 	[IRQ_DM646X_MCASP0TXINT]        = 7,
 	[IRQ_DM646X_MCASP0RXINT]        = 7,
 	[IRQ_DM646X_RESERVED_3]         = 7,
-	[IRQ_DM646X_MCASP1TXINT]        = 7,    /* clockevent */
+	[IRQ_DM646X_MCASP1TXINT]        = 7,
+	[IRQ_TINT0_TINT12]              = 7,    /* clockevent */
 	[IRQ_TINT0_TINT34]              = 7,    /* clocksource */
 	[IRQ_TINT1_TINT12]              = 7,    /* DSP timer */
 	[IRQ_TINT1_TINT34]              = 7,    /* system tick */
Signature · 1 line
2.16.2
#2 lore raw

PATCH 2/3 ARM: davinci: board-dm646x-evm: pass correct I2C adapter id for VPIF

In reply to Sekhar Nori

commit a16cb91ad9c4 ("[media] media: vpif: use a configurable i2c_adapter_id for vpif display") removed hardcoded I2C adaptor setting in VPIF driver, but missed updating platform data passed from DM646x board.

Fix it.

Fixes a16cb91ad9c4 ("[media] media: vpif: use a configurable i2c_adapter_id for vpif display")
---
 arch/arm/mach-davinci/board-dm646x-evm.c | 2 ++
 1 file changed, 2 insertions(+)
arch/arm/mach-davinci/board-dm646x-evm.c +2 -0
index 37c9e0ee4dcc..bf6f85048d17 100644
@@ -533,6 +533,7 @@ static struct vpif_display_config dm646x_vpif_display_config = {
 	.set_clock	= set_vpif_clock,
 	.subdevinfo	= dm646x_vpif_subdev,
 	.subdev_count	= ARRAY_SIZE(dm646x_vpif_subdev),
+	.i2c_adapter_id = 1,
 	.chan_config[0] = {
 		.outputs = dm6467_ch0_outputs,
 		.output_count = ARRAY_SIZE(dm6467_ch0_outputs),
@@ -675,6 +676,7 @@ static struct vpif_capture_config dm646x_vpif_capture_cfg = {
 	.setup_input_channel_mode = setup_vpif_input_channel_mode,
 	.subdev_info = vpif_capture_sdev_info,
 	.subdev_count = ARRAY_SIZE(vpif_capture_sdev_info),
+	.i2c_adapter_id = 1,
 	.chan_config[0] = {
 		.inputs = dm6467_ch0_inputs,
 		.input_count = ARRAY_SIZE(dm6467_ch0_inputs),
Signature · 1 line
2.16.2
#3 lore raw

PATCH 3/3 ARM: davinci: board-dm646x-evm: set VPIF capture card name

In reply to Sekhar Nori

VPIF capture driver expects card name to be set since it uses it without checking for NULL. The commit which introduced VPIF display and capture support added card name only for display, not for capture.

Set it in platform data to probe driver successfully.

While at it, also fix the display card name to something more appropriate.

Fixes 85609c1ccda6 ("DaVinci: DM646x - platform changes for vpif capture and display drivers")
---
 arch/arm/mach-davinci/board-dm646x-evm.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
arch/arm/mach-davinci/board-dm646x-evm.c +2 -1
index bf6f85048d17..867ab2fa6cfd 100644
@@ -538,7 +538,7 @@ static struct vpif_display_config dm646x_vpif_display_config = {
 		.outputs = dm6467_ch0_outputs,
 		.output_count = ARRAY_SIZE(dm6467_ch0_outputs),
 	},
-	.card_name	= "DM646x EVM",
+	.card_name	= "DM646x EVM Video Display",
 };
 
 /**
@@ -697,6 +697,7 @@ static struct vpif_capture_config dm646x_vpif_capture_cfg = {
 			.fid_pol = 0,
 		},
 	},
+	.card_name = "DM646x EVM Video Capture",
 };
 
 static void __init evm_init_video(void)
Signature · 1 line
2.16.2
#4 lore raw

cover ARM: davinci: some dm646x related fixes

In reply to Sekhar Nori
Quoted 4 lines · Sekhar Nori

Hi,

Here are some DM646x related fixes for issues I found while testing the platform.

Applied and pull request to ARM-SoC maintainers sent.

Thanks,
Sekhar