Bluetooth: Constify bt_register_starage parameters

There is no need for struct bt_storage being modified by stack.

Change-Id: I732cf94983a29de40d692e802d6a71b8986708df
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
This commit is contained in:
Szymon Janc 2016-05-30 14:05:28 +02:00 committed by Johan Hedberg
parent bd3043dc00
commit 31912bcb23
3 changed files with 4 additions and 4 deletions

View file

@ -43,7 +43,7 @@ static bt_le_scan_cb_t *scan_dev_found_cb;
struct nble nble;
static struct bt_storage *storage;
static const struct bt_storage *storage;
#define BT_SMP_IO_DISPLAY_ONLY 0x00
#define BT_SMP_IO_DISPLAY_YESNO 0x01
@ -552,7 +552,7 @@ void on_nble_up(void)
send_dm_config();
}
void bt_storage_register(struct bt_storage *bt_storage)
void bt_storage_register(const struct bt_storage *bt_storage)
{
storage = bt_storage;
}

View file

@ -80,7 +80,7 @@ struct bt_storage {
};
void bt_storage_register(struct bt_storage *storage);
void bt_storage_register(const struct bt_storage *storage);
/** Clear all storage keys for a specific address
*

View file

@ -3724,7 +3724,7 @@ int bt_br_set_discoverable(bool enable)
}
#endif /* CONFIG_BLUETOOTH_BREDR */
void bt_storage_register(struct bt_storage *storage)
void bt_storage_register(const struct bt_storage *storage)
{
bt_storage = storage;
}