err = btintel_enter_mfg(hdev); if (err) return err;
err = btintel_read_version(hdev, &ver); if (err) return err;
btintel_version_info(hdev, &ver);
/* The hardware platform number has a fixed value of 0x37 and * for now only accept this single value.
*/ if (ver.hw_platform != 0x37) {
bt_dev_err(hdev, "Unsupported Intel hardware platform: 0x%X",
ver.hw_platform); return -EINVAL;
}
/* Only the hardware variant iBT 2.1 (AG6XX) is supported by this * firmware setup method.
*/ if (ver.hw_variant != 0x0a) {
bt_dev_err(hdev, "Unsupported Intel hardware variant: 0x%x",
ver.hw_variant); return -EINVAL;
}
patch: /* If there is no applied patch, fw_patch_num is always 0x00. In other * cases, current firmware is already patched. No need to patch it.
*/ if (ver.fw_patch_num) {
bt_dev_info(hdev, "Device is already patched. patch num: %02x",
ver.fw_patch_num);
patched = true; goto complete;
}
/* PBN patch file contains a list of binary patches to be applied on top * of the embedded firmware. Each patch entry header contains the target * address and patch size. * * Patch entry: * | addr(le) | patch_len(le) | patch_data | * | 4 Bytes | 4 Bytes | n Bytes | * * PBN file is terminated by a patch entry whose address is 0xffffffff.
*/ while (fw->size > fw_ptr - fw->data) { struct pbn_entry *pbn = (void *)fw_ptr;
u32 addr, plen;
complete: /* Exit manufacturing mode and reset */
err = btintel_exit_mfg(hdev, true, patched); if (err) return err;
/* Set the event mask for Intel specific vendor events. This enables * a few extra events that are useful during general operation.
*/
btintel_set_event_mask_mfg(hdev, false);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.