diff mbox

[v2,5/5] tools/blktap2/drivers: Remove non-existent sys/sysctl.h include

Message ID 1482263220-3233-6-git-send-email-alistair.francis@xilinx.com (mailing list archive)
State New, archived
Headers show

Commit Message

Alistair Francis Dec. 20, 2016, 7:47 p.m. UTC
To avoid build errors related to missing file 'sys/sysctl.h' by removing
the #include statement.

Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
---
 tools/blktap2/drivers/block-remus.c | 1 -
 1 file changed, 1 deletion(-)

Comments

Wei Liu Dec. 22, 2016, 10:54 a.m. UTC | #1
On Tue, Dec 20, 2016 at 11:47:00AM -0800, Alistair Francis wrote:
> To avoid build errors related to missing file 'sys/sysctl.h' by removing
> the #include statement.
> 
> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>

I can find this in Linux. Maybe this is also due to the libc you're
using?

On the flip side, if this header is unused anyway I think I'm fine with
taking this patch.

> ---
>  tools/blktap2/drivers/block-remus.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/tools/blktap2/drivers/block-remus.c b/tools/blktap2/drivers/block-remus.c
> index 079588d..7401800 100644
> --- a/tools/blktap2/drivers/block-remus.c
> +++ b/tools/blktap2/drivers/block-remus.c
> @@ -54,7 +54,6 @@
>  #include <netinet/in.h>
>  #include <arpa/inet.h>
>  #include <sys/param.h>
> -#include <sys/sysctl.h>
>  #include <unistd.h>
>  #include <sys/stat.h>
>  
> -- 
> 2.7.4
>
Alistair Francis Dec. 22, 2016, 3:44 p.m. UTC | #2
On Thu, Dec 22, 2016 at 2:54 AM, Wei Liu <wei.liu2@citrix.com> wrote:
> On Tue, Dec 20, 2016 at 11:47:00AM -0800, Alistair Francis wrote:
>> To avoid build errors related to missing file 'sys/sysctl.h' by removing
>> the #include statement.
>>
>> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
>
> I can find this in Linux. Maybe this is also due to the libc you're
> using?

Yes, I think you are right. I am using musl when I see the error.

>
> On the flip side, if this header is unused anyway I think I'm fine with
> taking this patch.

Thanks, that is what I was thinking too.

Thanks,

Alistair

>
>> ---
>>  tools/blktap2/drivers/block-remus.c | 1 -
>>  1 file changed, 1 deletion(-)
>>
>> diff --git a/tools/blktap2/drivers/block-remus.c b/tools/blktap2/drivers/block-remus.c
>> index 079588d..7401800 100644
>> --- a/tools/blktap2/drivers/block-remus.c
>> +++ b/tools/blktap2/drivers/block-remus.c
>> @@ -54,7 +54,6 @@
>>  #include <netinet/in.h>
>>  #include <arpa/inet.h>
>>  #include <sys/param.h>
>> -#include <sys/sysctl.h>
>>  #include <unistd.h>
>>  #include <sys/stat.h>
>>
>> --
>> 2.7.4
>>
Douglas Goldstein Dec. 22, 2016, 3:46 p.m. UTC | #3
On 12/20/16 1:47 PM, Alistair Francis wrote:
> To avoid build errors related to missing file 'sys/sysctl.h' by removing
> the #include statement.
> 
> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
> ---
>  tools/blktap2/drivers/block-remus.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/tools/blktap2/drivers/block-remus.c b/tools/blktap2/drivers/block-remus.c
> index 079588d..7401800 100644
> --- a/tools/blktap2/drivers/block-remus.c
> +++ b/tools/blktap2/drivers/block-remus.c
> @@ -54,7 +54,6 @@
>  #include <netinet/in.h>
>  #include <arpa/inet.h>
>  #include <sys/param.h>
> -#include <sys/sysctl.h>
>  #include <unistd.h>
>  #include <sys/stat.h>
>  
> 

A bit late to the party but I also confirmed the header was unused.

Reviewed-by: Doug Goldstein <cardoe@cardoe.com>
Wei Liu Dec. 23, 2016, 11:10 a.m. UTC | #4
On Thu, Dec 22, 2016 at 07:44:19AM -0800, Alistair Francis wrote:
> On Thu, Dec 22, 2016 at 2:54 AM, Wei Liu <wei.liu2@citrix.com> wrote:
> > On Tue, Dec 20, 2016 at 11:47:00AM -0800, Alistair Francis wrote:
> >> To avoid build errors related to missing file 'sys/sysctl.h' by removing
> >> the #include statement.
> >>
> >> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
> >
> > I can find this in Linux. Maybe this is also due to the libc you're
> > using?
> 
> Yes, I think you are right. I am using musl when I see the error.
> 
> >
> > On the flip side, if this header is unused anyway I think I'm fine with
> > taking this patch.
> 
> Thanks, that is what I was thinking too.
> 

OK. I think I will need to update the commit message to:

  tools/blktap2: remove unused inclusion of sys/sysctl.h
  
  That header file is not used. Removing it would avoid build error with
  musl libc, which doesn't have that header.

If you have no objection I can make the change while committing.

Wei.

> Thanks,
> 
> Alistair
> 
> >
> >> ---
> >>  tools/blktap2/drivers/block-remus.c | 1 -
> >>  1 file changed, 1 deletion(-)
> >>
> >> diff --git a/tools/blktap2/drivers/block-remus.c b/tools/blktap2/drivers/block-remus.c
> >> index 079588d..7401800 100644
> >> --- a/tools/blktap2/drivers/block-remus.c
> >> +++ b/tools/blktap2/drivers/block-remus.c
> >> @@ -54,7 +54,6 @@
> >>  #include <netinet/in.h>
> >>  #include <arpa/inet.h>
> >>  #include <sys/param.h>
> >> -#include <sys/sysctl.h>
> >>  #include <unistd.h>
> >>  #include <sys/stat.h>
> >>
> >> --
> >> 2.7.4
> >>
Alistair Francis Dec. 23, 2016, 10:09 p.m. UTC | #5
Hey Wei,

Sorry about the top post but I’m doing this from my phone.

That sounds good to me, you can use that commit message.

Thanks,

Alistair

From: Wei Liu
Sent: Friday, 23 December 2016 6:12 AM
To: Alistair Francis
Cc: Wei Liu; Doug Goldstein; ian.jackson@eu.citrix.com; imhy.yang@gmail.com; rshriram@cs.ubc.ca; xen-devel@lists.xenproject.org
Subject: Re: [Xen-devel] [PATCH v2 5/5] tools/blktap2/drivers: Removenon-existent sys/sysctl.h include

On Thu, Dec 22, 2016 at 07:44:19AM -0800, Alistair Francis wrote:
> On Thu, Dec 22, 2016 at 2:54 AM, Wei Liu <wei.liu2@citrix.com> wrote:
> > On Tue, Dec 20, 2016 at 11:47:00AM -0800, Alistair Francis wrote:
> >> To avoid build errors related to missing file 'sys/sysctl.h' by removing
> >> the #include statement.
> >>
> >> Signed-off-by: Alistair Francis <alistair.francis@xilinx.com>
> >
> > I can find this in Linux. Maybe this is also due to the libc you're
> > using?
> 
> Yes, I think you are right. I am using musl when I see the error.
> 
> >
> > On the flip side, if this header is unused anyway I think I'm fine with
> > taking this patch.
> 
> Thanks, that is what I was thinking too.
> 

OK. I think I will need to update the commit message to:

  tools/blktap2: remove unused inclusion of sys/sysctl.h
  
  That header file is not used. Removing it would avoid build error with
  musl libc, which doesn't have that header.

If you have no objection I can make the change while committing.

Wei.

> Thanks,
> 
> Alistair
> 
> >
> >> ---
> >>  tools/blktap2/drivers/block-remus.c | 1 -
> >>  1 file changed, 1 deletion(-)
> >>
> >> diff --git a/tools/blktap2/drivers/block-remus.c b/tools/blktap2/drivers/block-remus.c
> >> index 079588d..7401800 100644
> >> --- a/tools/blktap2/drivers/block-remus.c
> >> +++ b/tools/blktap2/drivers/block-remus.c
> >> @@ -54,7 +54,6 @@
> >>  #include <netinet/in.h>
> >>  #include <arpa/inet.h>
> >>  #include <sys/param.h>
> >> -#include <sys/sysctl.h>
> >>  #include <unistd.h>
> >>  #include <sys/stat.h>
> >>
> >> --
> >> 2.7.4
> >>
Wei Liu Dec. 25, 2016, 3:57 p.m. UTC | #6
On Fri, Dec 23, 2016 at 05:09:47PM -0500, alistair23@gmail.com wrote:
> Hey Wei,
> 
> Sorry about the top post but I’m doing this from my phone.
> 
> That sounds good to me, you can use that commit message.
> 

Thanks for confirming. 

Pushed to staging.
diff mbox

Patch

diff --git a/tools/blktap2/drivers/block-remus.c b/tools/blktap2/drivers/block-remus.c
index 079588d..7401800 100644
--- a/tools/blktap2/drivers/block-remus.c
+++ b/tools/blktap2/drivers/block-remus.c
@@ -54,7 +54,6 @@ 
 #include <netinet/in.h>
 #include <arpa/inet.h>
 #include <sys/param.h>
-#include <sys/sysctl.h>
 #include <unistd.h>
 #include <sys/stat.h>