diff options
author | Hans de Goede <hdegoede@redhat.com> | 2023-05-12 20:31:21 +0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@kernel.org> | 2023-06-09 16:53:23 +0300 |
commit | ae39964d2c01cb1805fcaa6f0ad0b7b4e8568106 (patch) | |
tree | 2a71780c32a8495ed567e2f6087beb1ef7c3f546 /drivers/staging/media/atomisp/pci/atomisp_cmd.c | |
parent | 1180d072e05cb40fdd65725b9235e23c008411f9 (diff) | |
download | linux-ae39964d2c01cb1805fcaa6f0ad0b7b4e8568106.tar.xz |
media: atomisp: Remove in_reset argument from atomisp_css_start()
The in_reset argument to atomisp_css_start() is only ever true
in atomisp_assert_recovery_work(), drop the argument and move
the special reset handlig to atomisp_assert_recovery_work().
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Diffstat (limited to 'drivers/staging/media/atomisp/pci/atomisp_cmd.c')
-rw-r--r-- | drivers/staging/media/atomisp/pci/atomisp_cmd.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/staging/media/atomisp/pci/atomisp_cmd.c b/drivers/staging/media/atomisp/pci/atomisp_cmd.c index d9139e67c94f..9c44ffba2828 100644 --- a/drivers/staging/media/atomisp/pci/atomisp_cmd.c +++ b/drivers/staging/media/atomisp/pci/atomisp_cmd.c @@ -974,7 +974,13 @@ void atomisp_assert_recovery_work(struct work_struct *work) atomisp_css_input_set_mode(&isp->asd, IA_CSS_INPUT_MODE_BUFFERED_SENSOR); - if (atomisp_css_start(&isp->asd, true)) { + /* Recreate streams destroyed by atomisp_css_stop() */ + atomisp_create_pipes_stream(&isp->asd); + + /* Invalidate caches. FIXME: should flush only necessary buffers */ + wbinvd(); + + if (atomisp_css_start(&isp->asd)) { dev_warn(isp->dev, "start SP failed, so do not set streaming to be enable!\n"); } else { spin_lock_irqsave(&isp->lock, flags); |