Hi Vishal, On Wed, Apr 04, 2012, vishal agarwal wrote: > > Firstly, did you verify that this fixes your test case? You still > > didn't tell us what test case this is, btw. What about the above? > > Since setting the flag is outside of mgmt.c I think the removal should > > also be. That way you also avoid an extra call to > > hci_conn_hash_lookup_ba. I.e. please put the removal in > > hci_disconn_complete_evt. > > > > I'd also still like to hear your opinion of the second option I > > proposed. If you had a reference to struct link_key in hci_conn then > > you'd just need to call list_del() and nothing else to remove it (i.e. > > no iteration of hdev->link_keys necessary. > > If I implement it this way then there will be two new variables added, > one in hci_conn to store the reference of key and other one is inside > link_key structure to store if key is temporary or not. > or you want me to store reference of key to hci_conn only when the key > is temporary? > in this case also code might become complicated to handle cases if key > is re generated and new key is not temporary but the older one was. > > So in my opinion after the changes you suggested (moving code in > hci_disconn_complete_evt), this is also OK. lesser and clearer code. Ok, fair enough. The hci_disconn_complete_evt change should be enough then. Johan -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html