[v2,14/20] libcamera: ipa: Remove unused includes
diff mbox series

Message ID 20240830152721.1420313-15-mzamazal@redhat.com
State Accepted
Headers show
Series
  • Remove unused includes
Related show

Commit Message

Milan Zamazal Aug. 30, 2024, 3:27 p.m. UTC
The includes that are not used can be removed.

Signed-off-by: Milan Zamazal <mzamazal@redhat.com>
---
 include/libcamera/ipa/ipa_interface.h | 5 -----
 1 file changed, 5 deletions(-)

Comments

Laurent Pinchart Aug. 31, 2024, 12:20 a.m. UTC | #1
On Fri, Aug 30, 2024 at 05:27:11PM +0200, Milan Zamazal wrote:
> The includes that are not used can be removed.
> 
> Signed-off-by: Milan Zamazal <mzamazal@redhat.com>
> ---
>  include/libcamera/ipa/ipa_interface.h | 5 -----
>  1 file changed, 5 deletions(-)
> 
> diff --git a/include/libcamera/ipa/ipa_interface.h b/include/libcamera/ipa/ipa_interface.h
> index 7c835e98..2fdc085e 100644
> --- a/include/libcamera/ipa/ipa_interface.h
> +++ b/include/libcamera/ipa/ipa_interface.h
> @@ -7,11 +7,6 @@
>  
>  #pragma once
>  
> -#include <map>
> -#include <stddef.h>
> -#include <stdint.h>
> -#include <vector>
> -
>  #include <libcamera/base/flags.h>
>  #include <libcamera/base/signal.h>

I think all the other includes can be dropped too.

>
Milan Zamazal Sept. 2, 2024, 12:19 p.m. UTC | #2
Hi Laurent,

thank you for review.

Laurent Pinchart <laurent.pinchart@ideasonboard.com> writes:

> On Fri, Aug 30, 2024 at 05:27:11PM +0200, Milan Zamazal wrote:
>> The includes that are not used can be removed.
>> 
>
>> Signed-off-by: Milan Zamazal <mzamazal@redhat.com>
>> ---
>>  include/libcamera/ipa/ipa_interface.h | 5 -----
>>  1 file changed, 5 deletions(-)
>> 
>> diff --git a/include/libcamera/ipa/ipa_interface.h b/include/libcamera/ipa/ipa_interface.h
>> index 7c835e98..2fdc085e 100644
>> --- a/include/libcamera/ipa/ipa_interface.h
>> +++ b/include/libcamera/ipa/ipa_interface.h
>> @@ -7,11 +7,6 @@
>>  
>>  #pragma once
>>  
>> -#include <map>
>> -#include <stddef.h>
>> -#include <stdint.h>
>> -#include <vector>
>> -
>>  #include <libcamera/base/flags.h>
>>  #include <libcamera/base/signal.h>
>
> I think all the other includes can be dropped too.

I'm not sure.  ipa_interface.h is included in the generated files and
they rely on the includes (and what is worse, apparently on things
included through them).  Perhaps this should be fixed by including the
corresponding stuff at the right places but I'm worried by the fact that
LSP doesn't mark these includes as redundant (apparently for a reason).
I would rather not mess with the generated code in this patch series.
Laurent Pinchart Sept. 2, 2024, 12:35 p.m. UTC | #3
Hi Milan,

On Mon, Sep 02, 2024 at 02:19:27PM +0200, Milan Zamazal wrote:
> Laurent Pinchart writes:
> > On Fri, Aug 30, 2024 at 05:27:11PM +0200, Milan Zamazal wrote:
> >> The includes that are not used can be removed.
> >
> >> Signed-off-by: Milan Zamazal <mzamazal@redhat.com>
> >> ---
> >>  include/libcamera/ipa/ipa_interface.h | 5 -----
> >>  1 file changed, 5 deletions(-)
> >> 
> >> diff --git a/include/libcamera/ipa/ipa_interface.h b/include/libcamera/ipa/ipa_interface.h
> >> index 7c835e98..2fdc085e 100644
> >> --- a/include/libcamera/ipa/ipa_interface.h
> >> +++ b/include/libcamera/ipa/ipa_interface.h
> >> @@ -7,11 +7,6 @@
> >>  
> >>  #pragma once
> >>  
> >> -#include <map>
> >> -#include <stddef.h>
> >> -#include <stdint.h>
> >> -#include <vector>
> >> -
> >>  #include <libcamera/base/flags.h>
> >>  #include <libcamera/base/signal.h>
> >
> > I think all the other includes can be dropped too.
> 
> I'm not sure.  ipa_interface.h is included in the generated files and
> they rely on the includes (and what is worse, apparently on things
> included through them).  Perhaps this should be fixed by including the
> corresponding stuff at the right places but I'm worried by the fact that
> LSP doesn't mark these includes as redundant (apparently for a reason).
> I would rather not mess with the generated code in this patch series.

We can handle it in a separate series, but I think it should still be
fixed.

Patch
diff mbox series

diff --git a/include/libcamera/ipa/ipa_interface.h b/include/libcamera/ipa/ipa_interface.h
index 7c835e98..2fdc085e 100644
--- a/include/libcamera/ipa/ipa_interface.h
+++ b/include/libcamera/ipa/ipa_interface.h
@@ -7,11 +7,6 @@ 
 
 #pragma once
 
-#include <map>
-#include <stddef.h>
-#include <stdint.h>
-#include <vector>
-
 #include <libcamera/base/flags.h>
 #include <libcamera/base/signal.h>