From: Alan Cox <alan@llwyncelyn.cymru>
To: mchehab@kernel.org, linux-media@vger.kernel.org
Subject: [PATCH 09/11] atomisp: Unify lut free logic
Date: Fri, 26 May 2017 16:29:25 +0100 [thread overview]
Message-ID: <149581256100.17585.7448530032630612515.stgit@builder> (raw)
In-Reply-To: <149581243155.17585.8164899156710160858.stgit@builder>
ISP2401 introduced a helper for this which we can use just as well on the
ISP2400 and remove some more noise differences.
Signed-off-by: Alan Cox <alan@linux.intel.com>
---
.../media/atomisp/pci/atomisp2/css2400/sh_css.c | 7 -------
.../atomisp/pci/atomisp2/css2400/sh_css_params.c | 14 --------------
2 files changed, 21 deletions(-)
diff --git a/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css.c b/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css.c
index 55d2a69..dfef219 100644
--- a/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css.c
+++ b/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css.c
@@ -2533,15 +2533,8 @@ ia_css_pipe_destroy(struct ia_css_pipe *pipe)
break;
}
-#ifndef ISP2401
- if (pipe->scaler_pp_lut != mmgr_NULL) {
- hmm_free(pipe->scaler_pp_lut);
- pipe->scaler_pp_lut = mmgr_NULL;
- }
-#else
sh_css_params_free_gdc_lut(pipe->scaler_pp_lut);
pipe->scaler_pp_lut = mmgr_NULL;
-#endif
my_css.active_pipes[ia_css_pipe_get_pipe_num(pipe)] = NULL;
sh_css_pipe_free_shading_table(pipe);
diff --git a/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_params.c b/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_params.c
index d8c22e8..4822437 100644
--- a/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_params.c
+++ b/drivers/staging/media/atomisp/pci/atomisp2/css2400/sh_css_params.c
@@ -3356,15 +3356,8 @@ enum ia_css_err ia_css_pipe_set_bci_scaler_lut(struct ia_css_pipe *pipe,
}
/* Free any existing tables. */
-#ifndef ISP2401
- if (pipe->scaler_pp_lut != mmgr_NULL) {
- hmm_free(pipe->scaler_pp_lut);
- pipe->scaler_pp_lut = mmgr_NULL;
- }
-#else
sh_css_params_free_gdc_lut(pipe->scaler_pp_lut);
pipe->scaler_pp_lut = mmgr_NULL;
-#endif
#ifndef ISP2401
if (store) {
@@ -3445,15 +3438,8 @@ void sh_css_params_free_default_gdc_lut(void)
{
IA_CSS_ENTER_PRIVATE("void");
-#ifndef ISP2401
- if (default_gdc_lut != mmgr_NULL) {
- hmm_free(default_gdc_lut);
- default_gdc_lut = mmgr_NULL;
- }
-#else
sh_css_params_free_gdc_lut(default_gdc_lut);
default_gdc_lut = mmgr_NULL;
-#endif
IA_CSS_LEAVE_PRIVATE("void");
next prev parent reply other threads:[~2017-05-26 15:29 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-26 15:27 [PATCHv2 01/11] atompisp: HAS_BL is never defined so lose it Alan Cox
2017-05-26 15:27 ` [PATCHv2 02/11] atomisp: remove NUM_OF_BLS Alan Cox
2017-05-26 15:27 ` [PATCHv2 03/11] atomisp2: remove HRT_UNSCHED Alan Cox
2017-05-26 15:27 ` [PATCHv2 04/11] atomisp2: tidy up confused ifdefs Alan Cox
2017-05-26 15:28 ` [PATCH 05/11] atomisp2: off by one in atomisp_s_input() Alan Cox
2017-05-26 15:28 ` [PATCHv2 06/11] atomisp: eliminate dead code under HAS_RES_MGR Alan Cox
2017-05-26 15:28 ` [PATCH 07/11] atomisp: unify sh_css_hmm_buffer_record_acquire Alan Cox
2017-05-26 15:29 ` [PATCH 08/11] atomisp: Unify load_preview_binaries for the most part Alan Cox
2017-05-26 15:29 ` Alan Cox [this message]
2017-05-26 15:29 ` [PATCH 10/11] atomisp: remove sh_css_irq - it contains nothing Alan Cox
2017-05-26 15:29 ` [PATCH 11/11] atomisp: de-duplicate sh_css_mmu_set_page_table_base_index Alan Cox
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=149581256100.17585.7448530032630612515.stgit@builder \
--to=alan@llwyncelyn.cymru \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox