From: Johan Hedberg Date: Fri, 5 Dec 2014 11:36:04 +0000 (+0200) Subject: Bluetooth: Convert Pair Device to use cmd_complete callback X-Git-Tag: omap-for-v3.20/drop-legacy-3517~122^2~28^2~5^2~16 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=04ab2749ea96a79f5eba3ca26d46f4283b5509a6;p=pandora-kernel.git Bluetooth: Convert Pair Device to use cmd_complete callback This patch converts the Pair Device mgmt command to use the new cmd_complete callback for pending mgmt commands. The already existing pairing_complete() function is exactly what's needed and doesn't need changing. In addition to getting the return parameters always right this patch actually fixes a reference counting bug and memory leak with the hci_conn that's attached to the pending mgmt command - something that would occur when powering off or unplugging the adapter while pairing is in progress. Signed-off-by: Johan Hedberg Signed-off-by: Marcel Holtmann --- Reading git-diff-tree failed