mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-11 15:11:48 -04:00
Merge "Bluetooth: Fix bluetooth enable failure for sdxlemur"
This commit is contained in:
commit
c55f30b9e1
1 changed files with 12 additions and 8 deletions
|
|
@ -257,11 +257,13 @@ static int bt_clk_enable(struct bt_power_clk_data *clk)
|
|||
|
||||
pr_debug("%s: %s\n", __func__, clk->name);
|
||||
|
||||
/* Get the clock handle for vreg */
|
||||
if (!clk->clk || clk->is_enabled) {
|
||||
pr_err("%s: error - node: %p, clk->is_enabled:%d\n",
|
||||
__func__, clk->clk, clk->is_enabled);
|
||||
if (!clk->clk)
|
||||
return -EINVAL;
|
||||
/* Get the clock handle for vreg */
|
||||
if (clk->is_enabled) {
|
||||
pr_warning("%s: node: %p, clk->is_enabled:%d\n",
|
||||
__func__, clk->clk, clk->is_enabled);
|
||||
return 0;
|
||||
}
|
||||
|
||||
rc = clk_prepare_enable(clk->clk);
|
||||
|
|
@ -281,11 +283,13 @@ static int bt_clk_disable(struct bt_power_clk_data *clk)
|
|||
|
||||
pr_debug("%s: %s\n", __func__, clk->name);
|
||||
|
||||
/* Get the clock handle for vreg */
|
||||
if (!clk->clk || !clk->is_enabled) {
|
||||
pr_err("%s: error - node: %p, clk->is_enabled:%d\n",
|
||||
__func__, clk->clk, clk->is_enabled);
|
||||
if (!clk->clk)
|
||||
return -EINVAL;
|
||||
/* Get the clock handle for vreg */
|
||||
if (!clk->is_enabled) {
|
||||
pr_warning("%s: node: %p, clk->is_enabled:%d\n",
|
||||
__func__, clk->clk, clk->is_enabled);
|
||||
return 0;
|
||||
}
|
||||
clk_disable_unprepare(clk->clk);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue