[prev in list] [next in list] [prev in thread] [next in thread]
List: fwts-devel
Subject: ACK: [PATCH 3/4] uefi: uefibootpath: add test for BluetoothLE device path
From: Colin Ian King <colin.king () canonical ! com>
Date: 2017-10-26 10:15:36
Message-ID: c2029c39-4417-4a82-a274-c0a0a8589f26 () canonical ! com
[Download RAW message or body]
On 26/10/17 11:42, Ivan Hu wrote:
> BluetoothLE device path is defined in UEFI spec version 2.7
>
> Signed-off-by: Ivan Hu <ivan.hu@canonical.com>
> ---
> src/uefi/uefibootpath/uefibootpath.c | 19 +++++++++++++++++++
> 1 file changed, 19 insertions(+)
>
> diff --git a/src/uefi/uefibootpath/uefibootpath.c b/src/uefi/uefibootpath/uefibootpath.c
> index e2e3bfe..5a18297 100644
> --- a/src/uefi/uefibootpath/uefibootpath.c
> +++ b/src/uefi/uefibootpath/uefibootpath.c
> @@ -622,6 +622,25 @@ static int uefibootpath_check_dev_path(fwts_framework *fw, fwts_uefi_dev_path *d
> errors++;
> }
> break;
> + case FWTS_UEFI_BLUETOOTHLE_DEVICE_PATH_SUBTYPE:
> + if (len != sizeof(fwts_uefi_bluetoothle_dev_path)) {
> + fwts_failed(fw, LOG_LEVEL_MEDIUM, "UEFIBTLEDevPathLength",
> + "The length of BluetoothLE device path is %" PRIu16 " bytes "
> + "and differs from UEFI specification defined %" PRIu16 " bytes.",
> + len,
> + (uint16_t)sizeof(fwts_uefi_bluetoothle_dev_path));
> + errors++;
> + }
> +
> + fwts_uefi_bluetoothle_dev_path *b = (fwts_uefi_bluetoothle_dev_path *)dev_path;
> + if (b->addr_type > 1) {
> + fwts_failed(fw, LOG_LEVEL_MEDIUM, "UEFIBTLEDevPathTypeInvalid",
> + "The Address Type of BluetoothLE Device Path is %" PRIu8
> + " which is out of UEFI specification defined range 0 or 1.",
> + b->addr_type);
> + errors++;
> + }
> + break;
> default:
> fwts_log_info_verbatim(fw, "Unknown subtype of Messaging Device Path.");
> break;
>
Acked-by: Colin Ian King <colin.king@canonical.com>
--
fwts-devel mailing list
fwts-devel@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/fwts-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic