diff mbox series

[v3,2/4] block: check for sys/disk.h

Message ID 20210315180341.31638-3-j@getutm.app
State New
Headers show
Series Disable unsupported features on iOS hosts | expand

Commit Message

Joelle van Dyne March 15, 2021, 6:03 p.m. UTC
Some BSD platforms do not have this header.

Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Joelle van Dyne <j@getutm.app>
---
 meson.build | 1 +
 block.c     | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

Comments

Joelle van Dyne April 1, 2021, 5:08 a.m. UTC | #1
On Mon, Mar 15, 2021 at 11:03 AM Joelle van Dyne <j@getutm.app> wrote:
>
> Some BSD platforms do not have this header.
>
> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
> Signed-off-by: Joelle van Dyne <j@getutm.app>

Please bear with me as I am still new to this, but what happens to the
three patches that are reviewed if the last patch does not get
reviewed? Do the reviewed patches still get to make it into 6.0? I am
willing to drop the unreviewed patch if there are issues. Thanks.

-j
Philippe Mathieu-Daudé April 1, 2021, 8:03 a.m. UTC | #2
On 4/1/21 7:08 AM, Joelle van Dyne wrote:
> On Mon, Mar 15, 2021 at 11:03 AM Joelle van Dyne <j@getutm.app> wrote:
>>
>> Some BSD platforms do not have this header.
>>
>> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
>> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
>> Signed-off-by: Joelle van Dyne <j@getutm.app>
> 
> Please bear with me as I am still new to this, but what happens to the
> three patches that are reviewed if the last patch does not get
> reviewed? Do the reviewed patches still get to make it into 6.0? I am
> willing to drop the unreviewed patch if there are issues. Thanks.

I guess this is bad timing, as this time in year various maintainers
are on vacations. Cc'ing Paolo as he sometimes take generic/block
patches.

Regards,

Phil.
Paolo Bonzini April 1, 2021, 8:58 a.m. UTC | #3
On 01/04/21 10:03, Philippe Mathieu-Daudé wrote:
> On 4/1/21 7:08 AM, Joelle van Dyne wrote:
>> On Mon, Mar 15, 2021 at 11:03 AM Joelle van Dyne <j@getutm.app> wrote:
>>>
>>> Some BSD platforms do not have this header.
>>>
>>> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
>>> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
>>> Signed-off-by: Joelle van Dyne <j@getutm.app>
>>
>> Please bear with me as I am still new to this, but what happens to the
>> three patches that are reviewed if the last patch does not get
>> reviewed? Do the reviewed patches still get to make it into 6.0? I am
>> willing to drop the unreviewed patch if there are issues. Thanks.
> 
> I guess this is bad timing, as this time in year various maintainers
> are on vacations. Cc'ing Paolo as he sometimes take generic/block
> patches.

I didn't notice this series before, and it was posted a bit late (one 
day before feature freeze).  I have queued it, so Joelle need not do 
anything else, but I won't include it in my pull request for 6.0.

Paolo
diff mbox series

Patch

diff --git a/meson.build b/meson.build
index 59c7c56366..2c01e2494c 100644
--- a/meson.build
+++ b/meson.build
@@ -1153,6 +1153,7 @@  config_host_data.set('HAVE_SYS_IOCCOM_H', cc.has_header('sys/ioccom.h'))
 config_host_data.set('HAVE_SYS_KCOV_H', cc.has_header('sys/kcov.h'))
 config_host_data.set('HAVE_SYSTEM_FUNCTION', cc.has_function('system', prefix: '#include <stdlib.h>'))
 config_host_data.set('HAVE_HOST_BLOCK_DEVICE', have_host_block_device)
+config_host_data.set('HAVE_SYS_DISK_H', cc.has_header('sys/disk.h'))
 
 config_host_data.set('CONFIG_PREADV', cc.has_function('preadv', prefix: '#include <sys/uio.h>'))
 
diff --git a/block.c b/block.c
index f377158c42..c9729bdf21 100644
--- a/block.c
+++ b/block.c
@@ -54,7 +54,7 @@ 
 #ifdef CONFIG_BSD
 #include <sys/ioctl.h>
 #include <sys/queue.h>
-#ifndef __DragonFly__
+#if defined(HAVE_SYS_DISK_H)
 #include <sys/disk.h>
 #endif
 #endif