1. ipv80211_init
• The 80211_wq work queue mainly handles the following tasks:
1) clear: wireless_dev.cleanup_work
2) scan: 201780211_registered_device.scan_done_wk
3) Event: Listen 80211_registered_device.event_work
• Register Netlink with the name "nl80211" and perform the following operations: nl80211_ops
Net/wireless/CORE. c
Static int _ init listen 80211_init (void) {int err; // register the network namespace err = register_pernet_device (& cfg80211_pernet_ops); If (ERR) goto out_fail_pernet; // register ieee80211_class class err = wiphy_sysfs_init (); If (ERR) goto out_fail_sysfs; // register the Network Notification to receive the network event err = notify (& notify); If (ERR) goto out_fail_notifier; // register Netlink "nl80211" and perform the following operations: nl80211_opserr = nl80211_init (); If (ERR) goto out_f Ail_nl80211; // create sys/class/ieee80211 directory catalog = debugfs_create_dir ("ieee80211", null); err = regulatory_init (); If (ERR) goto out_fail_reg; // create a kernel thread named "Listen 80211"; if (! Required) goto out_fail_wq; return 0; out_fail_wq: regulatory_exit (); out_fail_reg: debugfs_remove (optional); used: required (& optional); used: enabled (); out_fail_sysfs: unregister_pernet_device (& %80211_pernet_ops); out_fail_pernet: Return err;} subsys_initcall (%80211_init );