Skip to content
  • Florian Grandel's avatar
    Bluetooth: mgmt: multi adv for clear_adv_instances() · 847818d9
    Florian Grandel authored
    
    
    The clear_adv_instance() function could not clean up multiple
    advertising instances previously. It is being changed to provide both, a
    means to clean up a single instance and cleaning up all instances at
    once.
    
    An additional instance parameter is being introduced to achieve this.
    Passing in 0x00 to this parameter signifies that all instances should be
    cleaned up. This semantics has been chosen similarly to the semantics of
    the instance parameter in the remove_advertising() function.
    
    When removing a single instance the method also ensures that another
    instance will be scheduled if available. When the currently advertising
    method is being removed, it will be canceled immediately.
    
    Signed-off-by: default avatarFlorian Grandel <fgrandel@gmail.com>
    Signed-off-by: default avatarMarcel Holtmann <marcel@holtmann.org>
    847818d9