Jump to content

How to turn off Wi-Fi and Bluetooth devices?


SES

Recommended Posts

Here is how I did it with my Orange Pi 3 LTS running the latest Armbian Ubuntu:

 

# systemctl disable --now wpa_supplicant.service

# systemctl mask wpa_supplicant.service

# systemctl disable --now aw859a-bluetooth.service

# sed -i '' '/sprdwl_ng/d' /etc/modules

 

My typical load went from ~1 to ~0.01 to 0.1. 

Link to comment
Share on other sites

Or temporarily patch the driver until a better solution presents its self.

 

diff --git a/drivers/net/wireless/uwe5622/unisocwifi/tx_msg.c b/drivers/net/wireless/uwe5622/unisocwifi/tx_msg.c
index 40d51a7130d9..f1c356306c80 100644
--- a/drivers/net/wireless/uwe5622/unisocwifi/tx_msg.c
+++ b/drivers/net/wireless/uwe5622/unisocwifi/tx_msg.c
@@ -317,7 +317,15 @@ void sprdwl_dequeue_data_list(struct mbuf_t *head, int num)
 /* seam for tx_thread */
 void tx_down(struct sprdwl_tx_msg *tx_msg)
 {
-	wait_for_completion(&tx_msg->tx_completed);
+	int ret;
+	while (1) {
+		ret = wait_for_completion_interruptible(&tx_msg->tx_completed);
+		if (ret == -ERESTARTSYS) {
+			continue;
+		}
+
+		return;
+	}
 }
 
 void tx_up(struct sprdwl_tx_msg *tx_msg)
-- 
2.39.2

 

https://github.com/orangepi-xunlong/linux-orangepi/issues/57

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines