ACK: [PATCH 2/3] acpi: pcc: fwts_mmap failure is FWTS_MAP_FAILED and not NULL
Alex Hung
alex.hung at canonical.com
Wed Dec 23 03:40:30 UTC 2015
On 2015-12-23 09:42 AM, Colin King wrote:
> From: Colin Ian King <colin.king at canonical.com>
>
> Should be checking for FWTS_MAP_FAILED on a failed fwts_mmap and not
> a NULL
>
> Signed-off-by: Colin Ian King <colin.king at canonical.com>
> ---
> src/acpi/pcc/pcc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/acpi/pcc/pcc.c b/src/acpi/pcc/pcc.c
> index da66aec..799e773 100644
> --- a/src/acpi/pcc/pcc.c
> +++ b/src/acpi/pcc/pcc.c
> @@ -110,7 +110,7 @@ static void pcc_check_pcc_header(
> fwts_pcc_header *hdr;
>
> hdr = (fwts_pcc_header *)fwts_mmap((off_t)addr, (size_t)length);
> - if (hdr == NULL) {
> + if (hdr == FWTS_MAP_FAILED) {
> fwts_log_info(fw, "Failed to memory map PCC header 0x%" PRIx64
> "..0x%" PRIx64 ".", addr, addr + length);
> return;
>
Acked-by: Alex Hung <alex.hung at canonical.com>
More information about the fwts-devel
mailing list