diff options
author | Timo Wilken | 2024-03-26 11:48:22 -0500 |
---|---|---|
committer | Timo Wilken | 2024-03-26 11:48:22 -0500 |
commit | 96665c7bcf472f647d7ce119b79873afa59a5f65 (patch) | |
tree | 045c610337659cad0eeeda59c0254f77d4663aad /tw | |
parent | 393e59ffece0d799c40b27d10c459a194cc69f14 (diff) |
Trust NetworkManager to set Wi-Fi regulatory domain
Diffstat (limited to 'tw')
-rw-r--r-- | tw/system.scm | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/tw/system.scm b/tw/system.scm index e62ad095..58703e99 100644 --- a/tw/system.scm +++ b/tw/system.scm @@ -121,7 +121,7 @@ (define set-timezone-script ;; Every time we connect to a network, get our timezone from network geolocation. ;; https://wiki.archlinux.org/title/System_time - ;; https://wiki.archlinux.org/title/Network_configuration/Wireless#Respecting_the_regulatory_domain + ;; Wi-Fi regulatory domain is set automatically by NetworkManager when it connects to a network. (with-extensions (list guile-json-4 guile-gnutls) ; guile-gnutls needed by (web client) #~(begin (use-modules ((srfi srfi-11) #:select (let-values)) @@ -144,13 +144,6 @@ (when (assoc-ref json "error") (error "Got error response to request:" (assoc-ref json "reason") (assoc-ref json "message"))) - ;; Set WiFi regulatory domain to use the correct channels. - (let* ((regdb-country (assoc-ref json "country_code")) - (error-code - (system* #$(file-append iw "/sbin/iw") "reg" "set" regdb-country))) - (format (current-error-port) "Updated WiFi regdomain to ~a: ~a~%" - regdb-country (if (status:exit-val error-code) "success" - (format #f "error ~d" error-code)))) ;; Set local timezone. (let* ((timezone (assoc-ref json "timezone")) (zonefile (string-append #$tzdata "/share/zoneinfo/" timezone))) |