diff options
author | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2022-10-07 18:14:09 -0700 |
---|---|---|
committer | Luiz Augusto von Dentz <luiz.von.dentz@intel.com> | 2022-10-10 13:06:16 -0700 |
commit | c2bf15137410c92f346ff8031bdfaa756fb8b16e (patch) | |
tree | faa740c29c53594e04c60dd6946f4466d7a33b6a /emulator | |
parent | c94cdbc6d73ffd818d862975895d48dd01361234 (diff) | |
download | bluez-c2bf15137410c92f346ff8031bdfaa756fb8b16e.tar.gz |
vhci: Add function to interact with force_static_address
This adds functions that can be used to set debugfs
force_static_address.
Diffstat (limited to 'emulator')
-rw-r--r-- | emulator/vhci.c | 10 | ||||
-rw-r--r-- | emulator/vhci.h | 1 |
2 files changed, 11 insertions, 0 deletions
diff --git a/emulator/vhci.c b/emulator/vhci.c index 4295e30ef..a12b11e0f 100644 --- a/emulator/vhci.c +++ b/emulator/vhci.c @@ -257,3 +257,13 @@ int vhci_set_emu_opcode(struct vhci *vhci, uint16_t opcode) { return btdev_set_emu_opcode(vhci->btdev, opcode); } + +int vhci_set_force_static_address(struct vhci *vhci, bool enable) +{ + char val; + + val = (enable) ? 'Y' : 'N'; + + return vhci_debugfs_write(vhci, "force_static_address", &val, + sizeof(val)); +} diff --git a/emulator/vhci.h b/emulator/vhci.h index c42e8bde1..6da56cb58 100644 --- a/emulator/vhci.h +++ b/emulator/vhci.h @@ -28,3 +28,4 @@ int vhci_set_force_wakeup(struct vhci *vhci, bool enable); int vhci_set_msft_opcode(struct vhci *vhci, uint16_t opcode); int vhci_set_aosp_capable(struct vhci *vhci, bool enable); int vhci_set_emu_opcode(struct vhci *vhci, uint16_t opcode); +int vhci_set_force_static_address(struct vhci *vhci, bool enable); |