chameleond: fix bluetooth grpc server init process

The kernel updates the Class of Device (COD) when SetDiscoverable is
called and reads the COD value from an internal cache.
Using the hciconfig tool to change the COD does not update this kernel
cache. Consequently, the next time SetDiscoverable is called, the
kernel will use the stale COD value from its cache, overwriting any
changes made via hciconfig. To modify the COD correctly and ensure the
kernel's cache is updated, use the control socket interface instead.

BUG=b:445279971
TEST=Bluetooth suspend and resume tests

Change-Id: I395cd85e7dd45beb9197e02a114f9839955e654f
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/chameleon/+/6975427
Commit-Queue: ChromeOS Auto Runner <[email protected]>
Tested-by: John Lai <[email protected]>
Reviewed-by: Yun-hao Chung <[email protected]>
Commit-Queue: John Lai <[email protected]>
Auto-Submit: John Lai <[email protected]>
2 files changed