feat(desktop): taskbar wifi quick card - scan list / password / connect via net api

- taskbar.c: wifi popup card anchored above tray net icon; net api slots read
  via kernel_api+0x48 hard offsets (UTSM net.h layout, connect@0x48)
- flow: icon click -> scan_start -> per-frame scan_count/result pull -> SSID
  list (security tag + rssi bars) -> open net direct connect / secured net
  password textbox (scan set 1 -> ascii, enter=connect) -> net_api.connect
- no wireless device in QEMU: graceful "not detected" status, no panic (by
  design: wireless dev absence is attest-exempt, not a stub)
- shell.c: handle_key routes to wifi_key when card open (modal)
- sdk kernel_api.h: mirror UTSM dkm_net_api layout (append connect/disconnect
  before device_stats, fixes slot offset mismatch)
- QEMU verified: card opens, renders, graceful no-device path (serial
  "[wifi] no wireless device")
This commit is contained in:
Linehu
2026-10-06 13:51:00 +08:00
parent bd098f51ec
commit b780a6b868
4 changed files with 360 additions and 3 deletions
+5
View File
@@ -93,6 +93,11 @@ typedef struct dkm_net_api {
int (*scan_count)(u32 index);
int (*scan_result)(u32 index, u32 n, dkm_net_scan_result *out);
int (*is_wireless)(u32 index);
/* 无线关联(dispatch 到 wlan 驱动回调;尾部追加,ABI 兼容。
* 槽位布局必须与 UTSM include/utsm/net.h 镜像一致:
* connect @0x48, disconnect @0x50, device_stats @0x58)。 */
int (*connect)(u32 index, const char *ssid, const char *password);
int (*disconnect)(u32 index);
int (*device_stats)(u32 index, dkm_net_stats *out);
} dkm_net_api;