Bluetooth: GATT: Rework Service Changed indications
Bluetooth: GATT: Rework Service Changed indications

There could be situations where many services are changed in a row which
would cause k_sem_take to block on the second change, but if the calling
thread is actually the RX thread then this will deadlock since the RX
thread is the one processing the confirmations of indications and it is
blocked k_sem_give is never called.

To solve this the services changes are now offloaded to the system wq
and the code will attempt to consolidate the range being changed so only
one indication is send. If for some reason another changes is caused
while confirmation is pending we just reschedule it to run later to
avoid blocking the system wq in the same way.

Signed-off-by: Luiz Augusto von Dentz <8530c5ea66a1bdbc08f98bfcf183c8be901b5990@intel.com>

kraj/zephyr,zephyriot/zephyr,ldts/zephyr,punitvara/zephyr,punitvara/zephyr,nashif/zephyr,punitvara/zephyr,runchip/zephyr-cc3220,galak/zephyr,nashif/zephyr,Vudentz/zephyr,explora26/zephyr,punitvara/zephyr,fbsder/zephyr,Vudentz/zephyr,mbolivar/zephyr,kraj/zephyr,ldts/zephyr,kraj/zephyr,zephyriot/zephyr,runchip/zephyr-cc3220,rsalveti/zephyr,zephyriot/zephyr,GiulianoFranchetto/zephyr,runchip/zephyr-cc3220,finikorg/zephyr,galak/zephyr,Vudentz/zephyr,aceofall/zephyr-iotos,mbolivar/zephyr,nashif/zephyr,GiulianoFranchetto/zephyr,kraj/zephyr,galak/zephyr,zephyrproject-rtos/zephyr,galak/zephyr,fbsder/zephyr,fbsder/zephyr,holtmann/zephyr,aceofall/zephyr-iotos,aceofall/zephyr-iotos,ldts/zephyr,holtmann/zephyr,explora26/zephyr,mbolivar/zephyr,rsalveti/zephyr,explora26/zephyr,nashif/zephyr,aceofall/zephyr-iotos,GiulianoFranchetto/zephyr,zephyrproject-rtos/zephyr,finikorg/zephyr,punitvara/zephyr,holtmann/zephyr,zephyrproject-rtos/zephyr,finikorg/zephyr,explora26/zephyr,zephyrproject-rtos/zephyr,rsalveti/zephyr,rsalveti/zephyr,runchip/zephyr-cc3220,nashif/zephyr,ldts/zephyr,mbolivar/zephyr,GiulianoFranchetto/zephyr,aceofall/zephyr-iotos,fbsder/zephyr,zephyrproject-rtos/zephyr,finikorg/zephyr,GiulianoFranchetto/zephyr,Vudentz/zephyr,finikorg/zephyr,explora26/zephyr,zephyriot/zephyr,runchip/zephyr-cc3220,ldts/zephyr,galak/zephyr,mbolivar/zephyr,Vudentz/zephyr,kraj/zephyr,fbsder/zephyr,holtmann/zephyr,holtmann/zephyr,Vudentz/zephyr,rsalveti/zephyr,zephyriot/zephyr