[PATCH v4 1/5] ntdll: Return BIOS info from NtQuerySystemInformation on Linux

Huw Davies huw at codeweavers.com
Thu Jun 14 03:07:19 CDT 2018


On Wed, Jun 13, 2018 at 09:41:15PM -0600, Alex Henrie wrote:
> Signed-off-by: Alex Henrie <alexhenrie24 at gmail.com>
> ---
>  dlls/ntdll/nt.c | 169 ++++++++++++++++++++++++++++++++++++++++++++++++
>  1 file changed, 169 insertions(+)
> 
> diff --git a/dlls/ntdll/nt.c b/dlls/ntdll/nt.c
> index dc0ce04f42..72ae381813 100644
> --- a/dlls/ntdll/nt.c
> +++ b/dlls/ntdll/nt.c
> @@ -66,6 +66,50 @@
>  
>  WINE_DEFAULT_DEBUG_CHANNEL(ntdll);
>  
> +#include "pshpack1.h"
> +
> +typedef enum _SYSTEM_FIRMWARE_TABLE_ACTION
> +{
> +    SystemFirmwareTable_Enumerate = 0,
> +    SystemFirmwareTable_Get = 1
> +} SYSTEM_FIRMWARE_TABLE_ACTION;
> +
> +typedef struct _SYSTEM_FIRMWARE_TABLE_INFORMATION
> +{
> +    ULONG ProviderSignature;
> +    SYSTEM_FIRMWARE_TABLE_ACTION Action;
> +    ULONG TableID;
> +    ULONG TableBufferLength;
> +    UCHAR TableBuffer[1];
> +} SYSTEM_FIRMWARE_TABLE_INFORMATION;

These two at least should be in winternl.h

It fails to build on macOS
nt.c:2454:27: error: label at end of compound statement: expected statement
                case RSMB:

I suspect you may want to move the main body of the implementation into
a helper function, to avoid adding even more bloat to the main switch.

Also, some tests would be nice, both for the ntdll (free feel to just
tidy up mine) and kernel32 functions.

Note, that these went to wine-patches rather than wine-devel.

Huw.



More information about the wine-devel mailing list