Skip to content

Commit fad47cc

Browse files
jannaumarcan
authored andcommitted
fixup! media: apple: isp: t8112 fixes...
temporal-filter setting is platform dependent so move it to DT. Signed-off-by: Janne Grunau <[email protected]>
1 parent 9fc6019 commit fad47cc

3 files changed

Lines changed: 8 additions & 7 deletions

File tree

drivers/media/platform/apple/isp/isp-cam.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ static int isp_ch_configure_capture(struct apple_isp *isp, u32 ch)
403403
if (err)
404404
return err;
405405

406-
err = isp_cmd_apple_ch_temporal_filter_start(isp, ch, isp->hw->temporal_filter);
406+
err = isp_cmd_apple_ch_temporal_filter_start(isp, ch, isp->temporal_filter);
407407
if (err)
408408
return err;
409409

@@ -443,7 +443,7 @@ static int isp_ch_configure_capture(struct apple_isp *isp, u32 ch)
443443
if (err)
444444
return err;
445445

446-
err = isp_cmd_apple_ch_temporal_filter_start(isp, ch, isp->hw->temporal_filter);
446+
err = isp_cmd_apple_ch_temporal_filter_start(isp, ch, isp->temporal_filter);
447447
if (err)
448448
return err;
449449

drivers/media/platform/apple/isp/isp-drv.c

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -322,6 +322,11 @@ static int apple_isp_probe(struct platform_device *pdev)
322322
return err;
323323
}
324324

325+
err = of_property_read_u32(dev->of_node, "apple,temporal-filter",
326+
&isp->temporal_filter);
327+
if (err)
328+
isp->temporal_filter = 0;
329+
325330
err = apple_isp_init_presets(isp);
326331
if (err) {
327332
dev_err(dev, "failed to initialize presets\n");
@@ -462,7 +467,6 @@ static const struct apple_isp_hw apple_isp_hw_t8103 = {
462467

463468
.scl1 = false,
464469
.lpdp = false,
465-
.temporal_filter = 0,
466470
.meta_size = ISP_META_SIZE_T8103,
467471
};
468472

@@ -491,7 +495,6 @@ static const struct apple_isp_hw apple_isp_hw_t6000 = {
491495

492496
.scl1 = false,
493497
.lpdp = false,
494-
.temporal_filter = 0,
495498
.meta_size = ISP_META_SIZE_T8103,
496499
};
497500

@@ -514,7 +517,6 @@ static const struct apple_isp_hw apple_isp_hw_t8112 = {
514517

515518
.scl1 = false,
516519
.lpdp = false,
517-
.temporal_filter = 1,
518520
.meta_size = ISP_META_SIZE_T8112,
519521
};
520522

@@ -537,7 +539,6 @@ static const struct apple_isp_hw apple_isp_hw_t6020 = {
537539

538540
.scl1 = true,
539541
.lpdp = true,
540-
.temporal_filter = 0,
541542
.meta_size = ISP_META_SIZE_T8112,
542543
};
543544

drivers/media/platform/apple/isp/isp-drv.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,6 @@ struct apple_isp_hw {
121121
u32 meta_size;
122122
bool scl1;
123123
bool lpdp;
124-
u32 temporal_filter;
125124
};
126125

127126
enum isp_sensor_id {
@@ -190,6 +189,7 @@ struct apple_isp {
190189
const struct apple_isp_hw *hw;
191190
enum isp_firmware_version fw_compat;
192191
u32 platform_id;
192+
u32 temporal_filter;
193193
struct isp_preset *presets;
194194
int num_presets;
195195

0 commit comments

Comments
 (0)