Loading drivers/net/wireless/cnss/cnss_common.c +1 −1 Original line number Diff line number Diff line Loading @@ -21,7 +21,7 @@ #include <linux/mutex.h> #include <linux/rwsem.h> #include <net/cnss.h> #include <net/cnss_common.h> #include "cnss_common.h" #include <net/cfg80211.h> enum cnss_dev_bus_type { Loading include/net/cnss_common.h→drivers/net/wireless/cnss/cnss_common.h +40 −0 Original line number Diff line number Diff line Loading @@ -13,61 +13,28 @@ #ifndef _NET_CNSS_COMMON_H_ #define _NET_CNSS_COMMON_H_ #ifdef CONFIG_CNSS #define MAX_FIRMWARE_SIZE (1 * 1024 * 1024) /* max 20mhz channel count */ #define CNSS_MAX_CH_NUM 45 extern int cnss_set_wlan_unsafe_channel(u16 *unsafe_ch_list, u16 ch_count); extern int cnss_get_wlan_unsafe_channel(u16 *unsafe_ch_list, u16 *ch_count, u16 buf_len); extern int cnss_wlan_set_dfs_nol(const void *info, u16 info_len); extern int cnss_wlan_get_dfs_nol(void *info, u16 info_len); extern void cnss_init_work(struct work_struct *work, work_func_t func); extern void cnss_flush_work(void *work); extern void cnss_flush_delayed_work(void *dwork); extern void cnss_pm_wake_lock_timeout(struct wakeup_source *ws, ulong msec); extern void cnss_pm_wake_lock_release(struct wakeup_source *ws); extern void cnss_pm_wake_lock_destroy(struct wakeup_source *ws); extern void cnss_get_monotonic_boottime(struct timespec *ts); extern void cnss_get_boottime(struct timespec *ts); extern void cnss_init_delayed_work(struct delayed_work *work, work_func_t func); extern int cnss_vendor_cmd_reply(struct sk_buff *skb); extern int cnss_set_cpus_allowed_ptr(struct task_struct *task, ulong cpu); extern void cnss_dump_stack(struct task_struct *task); int cnss_pci_request_bus_bandwidth(int bandwidth); int cnss_sdio_request_bus_bandwidth(int bandwidth); extern int cnss_common_request_bus_bandwidth(struct device *dev, int bandwidth); void cnss_sdio_device_crashed(void); void cnss_pci_device_crashed(void); extern void cnss_common_device_crashed(struct device *dev); void cnss_pci_device_self_recovery(void); void cnss_sdio_device_self_recovery(void); extern void cnss_common_device_self_recovery(struct device *dev); void *cnss_pci_get_virt_ramdump_mem(unsigned long *size); void *cnss_sdio_get_virt_ramdump_mem(unsigned long *size); extern void *cnss_common_get_virt_ramdump_mem(struct device *dev, unsigned long *size); void cnss_sdio_schedule_recovery_work(void); void cnss_pci_schedule_recovery_work(void); extern void cnss_common_schedule_recovery_work(struct device *dev); extern int cnss_pcie_set_wlan_mac_address(const u8 *in, uint32_t len); extern int cnss_sdio_set_wlan_mac_address(const u8 *in, uint32_t len); extern int cnss_common_set_wlan_mac_address(struct device *dev, const u8 *in, uint32_t len); int cnss_pcie_set_wlan_mac_address(const u8 *in, uint32_t len); int cnss_sdio_set_wlan_mac_address(const u8 *in, uint32_t len); u8 *cnss_pci_get_wlan_mac_address(uint32_t *num); u8 *cnss_sdio_get_wlan_mac_address(uint32_t *num); extern u8 *cnss_common_get_wlan_mac_address(struct device *dev, uint32_t *num); #endif #endif /* _NET_CNSS_COMMON_H_ */ drivers/net/wireless/cnss/cnss_pci.c +1 −3 Original line number Diff line number Diff line Loading @@ -48,7 +48,7 @@ #include <net/cfg80211.h> #include <soc/qcom/memory_dump.h> #include <net/cnss.h> #include <net/cnss_common.h> #include "cnss_common.h" #ifdef CONFIG_WCNSS_MEM_PRE_ALLOC #include <net/cnss_prealloc.h> Loading Loading @@ -2155,7 +2155,6 @@ end: *num = 0; return NULL; } EXPORT_SYMBOL(cnss_pci_get_wlan_mac_address); /** * cnss_get_wlan_mac_address() - API to return MAC addresses buffer Loading Loading @@ -2245,7 +2244,6 @@ int cnss_pcie_set_wlan_mac_address(const u8 *in, uint32_t len) } return 0; } EXPORT_SYMBOL(cnss_pcie_set_wlan_mac_address); int cnss_wlan_register_driver(struct cnss_wlan_driver *driver) { Loading drivers/net/wireless/cnss/cnss_sdio.c +1 −3 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ #include <soc/qcom/ramdump.h> #include <soc/qcom/memory_dump.h> #include <net/cnss.h> #include <net/cnss_common.h> #include "cnss_common.h" #include <linux/pm_qos.h> #include <linux/msm-bus.h> #include <linux/msm-bus-board.h> Loading Loading @@ -1161,14 +1161,12 @@ int cnss_sdio_set_wlan_mac_address(const u8 *in, uint32_t len) { return 0; } EXPORT_SYMBOL(cnss_sdio_set_wlan_mac_address); u8 *cnss_sdio_get_wlan_mac_address(uint32_t *num) { *num = 0; return NULL; } EXPORT_SYMBOL(cnss_sdio_get_wlan_mac_address); static const struct of_device_id cnss_sdio_dt_match[] = { {.compatible = "qcom,cnss_sdio"}, Loading include/net/cnss.h +31 −1 Original line number Diff line number Diff line Loading @@ -15,7 +15,6 @@ #include <linux/device.h> #include <linux/skbuff.h> #include <linux/pci.h> #include <net/cnss_common.h> #include <linux/mmc/sdio_func.h> #ifdef CONFIG_CNSS Loading Loading @@ -209,4 +208,35 @@ extern int cnss_wlan_query_oob_status(void); extern int cnss_wlan_register_oob_irq_handler(oob_irq_handler_t handler, void *pm_oob); extern int cnss_wlan_unregister_oob_irq_handler(void *pm_oob); extern void cnss_dump_stack(struct task_struct *task); extern u8 *cnss_common_get_wlan_mac_address(struct device *dev, uint32_t *num); extern void cnss_init_work(struct work_struct *work, work_func_t func); extern void cnss_flush_delayed_work(void *dwork); extern void cnss_flush_work(void *work); extern void cnss_pm_wake_lock_timeout(struct wakeup_source *ws, ulong msec); extern void cnss_pm_wake_lock_release(struct wakeup_source *ws); extern void cnss_pm_wake_lock_destroy(struct wakeup_source *ws); extern void cnss_get_monotonic_boottime(struct timespec *ts); extern void cnss_get_boottime(struct timespec *ts); extern void cnss_init_delayed_work(struct delayed_work *work, work_func_t func); extern int cnss_vendor_cmd_reply(struct sk_buff *skb); extern int cnss_set_cpus_allowed_ptr(struct task_struct *task, ulong cpu); extern int cnss_set_wlan_unsafe_channel(u16 *unsafe_ch_list, u16 ch_count); extern int cnss_get_wlan_unsafe_channel(u16 *unsafe_ch_list, u16 *ch_count, u16 buf_len); extern int cnss_wlan_set_dfs_nol(const void *info, u16 info_len); extern int cnss_wlan_get_dfs_nol(void *info, u16 info_len); extern int cnss_common_request_bus_bandwidth(struct device *dev, int bandwidth); extern void cnss_common_device_crashed(struct device *dev); extern void cnss_common_device_self_recovery(struct device *dev); extern void *cnss_common_get_virt_ramdump_mem(struct device *dev, unsigned long *size); extern void cnss_common_schedule_recovery_work(struct device *dev); extern int cnss_common_set_wlan_mac_address(struct device *dev, const u8 *in, uint32_t len); extern u8 *cnss_common_get_wlan_mac_address(struct device *dev, uint32_t *num); #endif /* _NET_CNSS_H_ */ Loading
drivers/net/wireless/cnss/cnss_common.c +1 −1 Original line number Diff line number Diff line Loading @@ -21,7 +21,7 @@ #include <linux/mutex.h> #include <linux/rwsem.h> #include <net/cnss.h> #include <net/cnss_common.h> #include "cnss_common.h" #include <net/cfg80211.h> enum cnss_dev_bus_type { Loading
include/net/cnss_common.h→drivers/net/wireless/cnss/cnss_common.h +40 −0 Original line number Diff line number Diff line Loading @@ -13,61 +13,28 @@ #ifndef _NET_CNSS_COMMON_H_ #define _NET_CNSS_COMMON_H_ #ifdef CONFIG_CNSS #define MAX_FIRMWARE_SIZE (1 * 1024 * 1024) /* max 20mhz channel count */ #define CNSS_MAX_CH_NUM 45 extern int cnss_set_wlan_unsafe_channel(u16 *unsafe_ch_list, u16 ch_count); extern int cnss_get_wlan_unsafe_channel(u16 *unsafe_ch_list, u16 *ch_count, u16 buf_len); extern int cnss_wlan_set_dfs_nol(const void *info, u16 info_len); extern int cnss_wlan_get_dfs_nol(void *info, u16 info_len); extern void cnss_init_work(struct work_struct *work, work_func_t func); extern void cnss_flush_work(void *work); extern void cnss_flush_delayed_work(void *dwork); extern void cnss_pm_wake_lock_timeout(struct wakeup_source *ws, ulong msec); extern void cnss_pm_wake_lock_release(struct wakeup_source *ws); extern void cnss_pm_wake_lock_destroy(struct wakeup_source *ws); extern void cnss_get_monotonic_boottime(struct timespec *ts); extern void cnss_get_boottime(struct timespec *ts); extern void cnss_init_delayed_work(struct delayed_work *work, work_func_t func); extern int cnss_vendor_cmd_reply(struct sk_buff *skb); extern int cnss_set_cpus_allowed_ptr(struct task_struct *task, ulong cpu); extern void cnss_dump_stack(struct task_struct *task); int cnss_pci_request_bus_bandwidth(int bandwidth); int cnss_sdio_request_bus_bandwidth(int bandwidth); extern int cnss_common_request_bus_bandwidth(struct device *dev, int bandwidth); void cnss_sdio_device_crashed(void); void cnss_pci_device_crashed(void); extern void cnss_common_device_crashed(struct device *dev); void cnss_pci_device_self_recovery(void); void cnss_sdio_device_self_recovery(void); extern void cnss_common_device_self_recovery(struct device *dev); void *cnss_pci_get_virt_ramdump_mem(unsigned long *size); void *cnss_sdio_get_virt_ramdump_mem(unsigned long *size); extern void *cnss_common_get_virt_ramdump_mem(struct device *dev, unsigned long *size); void cnss_sdio_schedule_recovery_work(void); void cnss_pci_schedule_recovery_work(void); extern void cnss_common_schedule_recovery_work(struct device *dev); extern int cnss_pcie_set_wlan_mac_address(const u8 *in, uint32_t len); extern int cnss_sdio_set_wlan_mac_address(const u8 *in, uint32_t len); extern int cnss_common_set_wlan_mac_address(struct device *dev, const u8 *in, uint32_t len); int cnss_pcie_set_wlan_mac_address(const u8 *in, uint32_t len); int cnss_sdio_set_wlan_mac_address(const u8 *in, uint32_t len); u8 *cnss_pci_get_wlan_mac_address(uint32_t *num); u8 *cnss_sdio_get_wlan_mac_address(uint32_t *num); extern u8 *cnss_common_get_wlan_mac_address(struct device *dev, uint32_t *num); #endif #endif /* _NET_CNSS_COMMON_H_ */
drivers/net/wireless/cnss/cnss_pci.c +1 −3 Original line number Diff line number Diff line Loading @@ -48,7 +48,7 @@ #include <net/cfg80211.h> #include <soc/qcom/memory_dump.h> #include <net/cnss.h> #include <net/cnss_common.h> #include "cnss_common.h" #ifdef CONFIG_WCNSS_MEM_PRE_ALLOC #include <net/cnss_prealloc.h> Loading Loading @@ -2155,7 +2155,6 @@ end: *num = 0; return NULL; } EXPORT_SYMBOL(cnss_pci_get_wlan_mac_address); /** * cnss_get_wlan_mac_address() - API to return MAC addresses buffer Loading Loading @@ -2245,7 +2244,6 @@ int cnss_pcie_set_wlan_mac_address(const u8 *in, uint32_t len) } return 0; } EXPORT_SYMBOL(cnss_pcie_set_wlan_mac_address); int cnss_wlan_register_driver(struct cnss_wlan_driver *driver) { Loading
drivers/net/wireless/cnss/cnss_sdio.c +1 −3 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ #include <soc/qcom/ramdump.h> #include <soc/qcom/memory_dump.h> #include <net/cnss.h> #include <net/cnss_common.h> #include "cnss_common.h" #include <linux/pm_qos.h> #include <linux/msm-bus.h> #include <linux/msm-bus-board.h> Loading Loading @@ -1161,14 +1161,12 @@ int cnss_sdio_set_wlan_mac_address(const u8 *in, uint32_t len) { return 0; } EXPORT_SYMBOL(cnss_sdio_set_wlan_mac_address); u8 *cnss_sdio_get_wlan_mac_address(uint32_t *num) { *num = 0; return NULL; } EXPORT_SYMBOL(cnss_sdio_get_wlan_mac_address); static const struct of_device_id cnss_sdio_dt_match[] = { {.compatible = "qcom,cnss_sdio"}, Loading
include/net/cnss.h +31 −1 Original line number Diff line number Diff line Loading @@ -15,7 +15,6 @@ #include <linux/device.h> #include <linux/skbuff.h> #include <linux/pci.h> #include <net/cnss_common.h> #include <linux/mmc/sdio_func.h> #ifdef CONFIG_CNSS Loading Loading @@ -209,4 +208,35 @@ extern int cnss_wlan_query_oob_status(void); extern int cnss_wlan_register_oob_irq_handler(oob_irq_handler_t handler, void *pm_oob); extern int cnss_wlan_unregister_oob_irq_handler(void *pm_oob); extern void cnss_dump_stack(struct task_struct *task); extern u8 *cnss_common_get_wlan_mac_address(struct device *dev, uint32_t *num); extern void cnss_init_work(struct work_struct *work, work_func_t func); extern void cnss_flush_delayed_work(void *dwork); extern void cnss_flush_work(void *work); extern void cnss_pm_wake_lock_timeout(struct wakeup_source *ws, ulong msec); extern void cnss_pm_wake_lock_release(struct wakeup_source *ws); extern void cnss_pm_wake_lock_destroy(struct wakeup_source *ws); extern void cnss_get_monotonic_boottime(struct timespec *ts); extern void cnss_get_boottime(struct timespec *ts); extern void cnss_init_delayed_work(struct delayed_work *work, work_func_t func); extern int cnss_vendor_cmd_reply(struct sk_buff *skb); extern int cnss_set_cpus_allowed_ptr(struct task_struct *task, ulong cpu); extern int cnss_set_wlan_unsafe_channel(u16 *unsafe_ch_list, u16 ch_count); extern int cnss_get_wlan_unsafe_channel(u16 *unsafe_ch_list, u16 *ch_count, u16 buf_len); extern int cnss_wlan_set_dfs_nol(const void *info, u16 info_len); extern int cnss_wlan_get_dfs_nol(void *info, u16 info_len); extern int cnss_common_request_bus_bandwidth(struct device *dev, int bandwidth); extern void cnss_common_device_crashed(struct device *dev); extern void cnss_common_device_self_recovery(struct device *dev); extern void *cnss_common_get_virt_ramdump_mem(struct device *dev, unsigned long *size); extern void cnss_common_schedule_recovery_work(struct device *dev); extern int cnss_common_set_wlan_mac_address(struct device *dev, const u8 *in, uint32_t len); extern u8 *cnss_common_get_wlan_mac_address(struct device *dev, uint32_t *num); #endif /* _NET_CNSS_H_ */