[PATCH 2/2] lib: fwts_smbios: fix build error with non-Intel architectures

IvanHu ivan.hu at canonical.com
Thu Dec 13 09:57:48 UTC 2012


On 12/07/2012 05:05 PM, Colin King wrote:
> From: Colin Ian King <colin.king at canonical.com>
>
> The dummy no-op fwts_smbios_find_entry() for non-Intel builds
> is causing build failures because of the -Wextra flag.  Clean
> this up and make it return empty dummy values.
>
> Signed-off-by: Colin Ian King <colin.king at canonical.com>
> ---
>   src/lib/src/fwts_smbios.c | 7 +++++++
>   1 file changed, 7 insertions(+)
>
> diff --git a/src/lib/src/fwts_smbios.c b/src/lib/src/fwts_smbios.c
> index b9c4540..705f02b 100644
> --- a/src/lib/src/fwts_smbios.c
> +++ b/src/lib/src/fwts_smbios.c
> @@ -132,6 +132,13 @@ void *fwts_smbios_find_entry(fwts_framework *fw,
>   	fwts_smbios_type  *type,
>   	uint16_t	  *version)
>   {
> +	FWTS_UNUSED(fw);
> +
> +	/* Return a dummy values */
> +	memset(entry, 0, sizeof(fwts_smbios_entry));
> +	*type = FWTS_SMBIOS_UNKNOWN;
> +	*version = 0;
> +
>   	return NULL;
>   }
>   #endif
>
Acked-by: Ivan Hu <ivan.hu at canonical.com>



More information about the fwts-devel mailing list