Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
236c52ca
cloud-kernel
项目概览
openanolis
/
cloud-kernel
1 年多 前同步成功
通知
160
Star
36
Fork
7
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
10
列表
看板
标记
里程碑
合并请求
2
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
cloud-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
10
Issue
10
列表
看板
标记
里程碑
合并请求
2
合并请求
2
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
236c52ca
编写于
1月 07, 2016
作者:
K
Kalle Valo
浏览文件
操作
浏览文件
下载
差异文件
Merge ath-next from ath.git
No major changes to list.
上级
7683fe01
9d5db23e
变更
14
显示空白变更内容
内联
并排
Showing
14 changed file
with
129 addition
and
57 deletion
+129
-57
drivers/net/wireless/ath/ath10k/mac.c
drivers/net/wireless/ath/ath10k/mac.c
+2
-1
drivers/net/wireless/ath/ath10k/pci.c
drivers/net/wireless/ath/ath10k/pci.c
+17
-21
drivers/net/wireless/ath/ath9k/eeprom.c
drivers/net/wireless/ath/ath9k/eeprom.c
+1
-1
drivers/net/wireless/ath/ath9k/htc_drv_main.c
drivers/net/wireless/ath/ath9k/htc_drv_main.c
+1
-1
drivers/net/wireless/ath/ath9k/init.c
drivers/net/wireless/ath/ath9k/init.c
+1
-0
drivers/net/wireless/ath/wcn36xx/dxe.c
drivers/net/wireless/ath/wcn36xx/dxe.c
+22
-21
drivers/net/wireless/ath/wil6210/interrupt.c
drivers/net/wireless/ath/wil6210/interrupt.c
+6
-2
drivers/net/wireless/ath/wil6210/main.c
drivers/net/wireless/ath/wil6210/main.c
+1
-1
drivers/net/wireless/ath/wil6210/pcie_bus.c
drivers/net/wireless/ath/wil6210/pcie_bus.c
+28
-2
drivers/net/wireless/ath/wil6210/rx_reorder.c
drivers/net/wireless/ath/wil6210/rx_reorder.c
+11
-1
drivers/net/wireless/ath/wil6210/wil6210.h
drivers/net/wireless/ath/wil6210/wil6210.h
+1
-0
drivers/net/wireless/ath/wil6210/wil_crash_dump.c
drivers/net/wireless/ath/wil6210/wil_crash_dump.c
+1
-2
drivers/net/wireless/ath/wil6210/wil_platform.c
drivers/net/wireless/ath/wil6210/wil_platform.c
+2
-1
drivers/net/wireless/ath/wil6210/wil_platform.h
drivers/net/wireless/ath/wil6210/wil_platform.h
+35
-3
未找到文件。
drivers/net/wireless/ath/ath10k/mac.c
浏览文件 @
236c52ca
...
@@ -3860,7 +3860,8 @@ static struct ieee80211_sta_ht_cap ath10k_get_ht_cap(struct ath10k *ar)
...
@@ -3860,7 +3860,8 @@ static struct ieee80211_sta_ht_cap ath10k_get_ht_cap(struct ath10k *ar)
ht_cap
.
ampdu_density
=
IEEE80211_HT_MPDU_DENSITY_8
;
ht_cap
.
ampdu_density
=
IEEE80211_HT_MPDU_DENSITY_8
;
ht_cap
.
cap
|=
IEEE80211_HT_CAP_SUP_WIDTH_20_40
;
ht_cap
.
cap
|=
IEEE80211_HT_CAP_SUP_WIDTH_20_40
;
ht_cap
.
cap
|=
IEEE80211_HT_CAP_DSSSCCK40
;
ht_cap
.
cap
|=
IEEE80211_HT_CAP_DSSSCCK40
;
ht_cap
.
cap
|=
WLAN_HT_CAP_SM_PS_STATIC
<<
IEEE80211_HT_CAP_SM_PS_SHIFT
;
ht_cap
.
cap
|=
WLAN_HT_CAP_SM_PS_DISABLED
<<
IEEE80211_HT_CAP_SM_PS_SHIFT
;
if
(
ar
->
ht_cap_info
&
WMI_HT_CAP_HT20_SGI
)
if
(
ar
->
ht_cap_info
&
WMI_HT_CAP_HT20_SGI
)
ht_cap
.
cap
|=
IEEE80211_HT_CAP_SGI_20
;
ht_cap
.
cap
|=
IEEE80211_HT_CAP_SGI_20
;
...
...
drivers/net/wireless/ath/ath10k/pci.c
浏览文件 @
236c52ca
...
@@ -487,6 +487,9 @@ static int ath10k_pci_force_wake(struct ath10k *ar)
...
@@ -487,6 +487,9 @@ static int ath10k_pci_force_wake(struct ath10k *ar)
unsigned
long
flags
;
unsigned
long
flags
;
int
ret
=
0
;
int
ret
=
0
;
if
(
ar_pci
->
pci_ps
)
return
ret
;
spin_lock_irqsave
(
&
ar_pci
->
ps_lock
,
flags
);
spin_lock_irqsave
(
&
ar_pci
->
ps_lock
,
flags
);
if
(
!
ar_pci
->
ps_awake
)
{
if
(
!
ar_pci
->
ps_awake
)
{
...
@@ -2480,13 +2483,11 @@ static int ath10k_pci_hif_resume(struct ath10k *ar)
...
@@ -2480,13 +2483,11 @@ static int ath10k_pci_hif_resume(struct ath10k *ar)
u32
val
;
u32
val
;
int
ret
=
0
;
int
ret
=
0
;
if
(
ar_pci
->
pci_ps
==
0
)
{
ret
=
ath10k_pci_force_wake
(
ar
);
ret
=
ath10k_pci_force_wake
(
ar
);
if
(
ret
)
{
if
(
ret
)
{
ath10k_err
(
ar
,
"failed to wake up target: %d
\n
"
,
ret
);
ath10k_err
(
ar
,
"failed to wake up target: %d
\n
"
,
ret
);
return
ret
;
return
ret
;
}
}
}
/* Suspend/Resume resets the PCI configuration space, so we have to
/* Suspend/Resume resets the PCI configuration space, so we have to
* re-disable the RETRY_TIMEOUT register (0x41) to keep PCI Tx retries
* re-disable the RETRY_TIMEOUT register (0x41) to keep PCI Tx retries
...
@@ -2592,14 +2593,11 @@ static irqreturn_t ath10k_pci_interrupt_handler(int irq, void *arg)
...
@@ -2592,14 +2593,11 @@ static irqreturn_t ath10k_pci_interrupt_handler(int irq, void *arg)
struct
ath10k_pci
*
ar_pci
=
ath10k_pci_priv
(
ar
);
struct
ath10k_pci
*
ar_pci
=
ath10k_pci_priv
(
ar
);
int
ret
;
int
ret
;
if
(
ar_pci
->
pci_ps
==
0
)
{
ret
=
ath10k_pci_force_wake
(
ar
);
ret
=
ath10k_pci_force_wake
(
ar
);
if
(
ret
)
{
if
(
ret
)
{
ath10k_warn
(
ar
,
"failed to wake device up on irq: %d
\n
"
,
ath10k_warn
(
ar
,
"failed to wake device up on irq: %d
\n
"
,
ret
);
ret
);
return
IRQ_NONE
;
return
IRQ_NONE
;
}
}
}
if
(
ar_pci
->
num_msi_intrs
==
0
)
{
if
(
ar_pci
->
num_msi_intrs
==
0
)
{
if
(
!
ath10k_pci_irq_pending
(
ar
))
if
(
!
ath10k_pci_irq_pending
(
ar
))
...
@@ -3071,16 +3069,14 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
...
@@ -3071,16 +3069,14 @@ static int ath10k_pci_probe(struct pci_dev *pdev,
goto
err_sleep
;
goto
err_sleep
;
}
}
ath10k_pci_ce_deinit
(
ar
);
ath10k_pci_irq_disable
(
ar
);
if
(
ar_pci
->
pci_ps
==
0
)
{
ret
=
ath10k_pci_force_wake
(
ar
);
ret
=
ath10k_pci_force_wake
(
ar
);
if
(
ret
)
{
if
(
ret
)
{
ath10k_warn
(
ar
,
"failed to wake up device : %d
\n
"
,
ret
);
ath10k_warn
(
ar
,
"failed to wake up device : %d
\n
"
,
ret
);
goto
err_free_pipes
;
goto
err_free_pipes
;
}
}
}
ath10k_pci_ce_deinit
(
ar
);
ath10k_pci_irq_disable
(
ar
);
ret
=
ath10k_pci_init_irq
(
ar
);
ret
=
ath10k_pci_init_irq
(
ar
);
if
(
ret
)
{
if
(
ret
)
{
...
...
drivers/net/wireless/ath/ath9k/eeprom.c
浏览文件 @
236c52ca
...
@@ -206,7 +206,7 @@ bool ath9k_hw_nvram_check_version(struct ath_hw *ah, int version, int minrev)
...
@@ -206,7 +206,7 @@ bool ath9k_hw_nvram_check_version(struct ath_hw *ah, int version, int minrev)
ath_err
(
common
,
"Bad EEPROM VER 0x%04x or REV 0x%04x
\n
"
,
ath_err
(
common
,
"Bad EEPROM VER 0x%04x or REV 0x%04x
\n
"
,
ah
->
eep_ops
->
get_eeprom_ver
(
ah
),
ah
->
eep_ops
->
get_eeprom_ver
(
ah
),
ah
->
eep_ops
->
get_eeprom_rev
(
ah
));
ah
->
eep_ops
->
get_eeprom_rev
(
ah
));
return
-
EINVAL
;
return
false
;
}
}
return
true
;
return
true
;
...
...
drivers/net/wireless/ath/ath9k/htc_drv_main.c
浏览文件 @
236c52ca
...
@@ -834,7 +834,7 @@ void ath9k_htc_ani_work(struct work_struct *work)
...
@@ -834,7 +834,7 @@ void ath9k_htc_ani_work(struct work_struct *work)
if
(
longcal
||
shortcal
)
if
(
longcal
||
shortcal
)
common
->
ani
.
caldone
=
common
->
ani
.
caldone
=
ath9k_hw_calibrate
(
ah
,
ah
->
curchan
,
ath9k_hw_calibrate
(
ah
,
ah
->
curchan
,
ah
->
rxchainmask
,
longcal
)
;
ah
->
rxchainmask
,
longcal
)
>
0
;
ath9k_htc_ps_restore
(
priv
);
ath9k_htc_ps_restore
(
priv
);
}
}
...
...
drivers/net/wireless/ath/ath9k/init.c
浏览文件 @
236c52ca
...
@@ -828,6 +828,7 @@ static void ath9k_set_hw_capab(struct ath_softc *sc, struct ieee80211_hw *hw)
...
@@ -828,6 +828,7 @@ static void ath9k_set_hw_capab(struct ath_softc *sc, struct ieee80211_hw *hw)
ieee80211_hw_set
(
hw
,
RX_INCLUDES_FCS
);
ieee80211_hw_set
(
hw
,
RX_INCLUDES_FCS
);
ieee80211_hw_set
(
hw
,
HOST_BROADCAST_PS_BUFFERING
);
ieee80211_hw_set
(
hw
,
HOST_BROADCAST_PS_BUFFERING
);
ieee80211_hw_set
(
hw
,
SUPPORT_FAST_XMIT
);
ieee80211_hw_set
(
hw
,
SUPPORT_FAST_XMIT
);
ieee80211_hw_set
(
hw
,
SUPPORTS_CLONED_SKBS
);
if
(
ath9k_ps_enable
)
if
(
ath9k_ps_enable
)
ieee80211_hw_set
(
hw
,
SUPPORTS_PS
);
ieee80211_hw_set
(
hw
,
SUPPORTS_PS
);
...
...
drivers/net/wireless/ath/wcn36xx/dxe.c
浏览文件 @
236c52ca
...
@@ -474,36 +474,37 @@ static int wcn36xx_rx_handle_packets(struct wcn36xx *wcn,
...
@@ -474,36 +474,37 @@ static int wcn36xx_rx_handle_packets(struct wcn36xx *wcn,
struct
wcn36xx_dxe_desc
*
dxe
=
ctl
->
desc
;
struct
wcn36xx_dxe_desc
*
dxe
=
ctl
->
desc
;
dma_addr_t
dma_addr
;
dma_addr_t
dma_addr
;
struct
sk_buff
*
skb
;
struct
sk_buff
*
skb
;
int
ret
=
0
,
int_mask
;
u32
value
;
if
(
ch
->
ch_type
==
WCN36XX_DXE_CH_RX_L
)
{
value
=
WCN36XX_DXE_CTRL_RX_L
;
int_mask
=
WCN36XX_DXE_INT_CH1_MASK
;
}
else
{
value
=
WCN36XX_DXE_CTRL_RX_H
;
int_mask
=
WCN36XX_DXE_INT_CH3_MASK
;
}
while
(
!
(
dxe
->
ctrl
&
WCN36XX_DXE_CTRL_VALID_MASK
))
{
while
(
!
(
dxe
->
ctrl
&
WCN36XX_DXE_CTRL_VALID_MASK
))
{
skb
=
ctl
->
skb
;
skb
=
ctl
->
skb
;
dma_addr
=
dxe
->
dst_addr_l
;
dma_addr
=
dxe
->
dst_addr_l
;
wcn36xx_dxe_fill_skb
(
wcn
->
dev
,
ctl
);
ret
=
wcn36xx_dxe_fill_skb
(
wcn
->
dev
,
ctl
);
if
(
0
==
ret
)
{
switch
(
ch
->
ch_type
)
{
/* new skb allocation ok. Use the new one and queue
case
WCN36XX_DXE_CH_RX_L
:
* the old one to network system.
dxe
->
ctrl
=
WCN36XX_DXE_CTRL_RX_L
;
*/
wcn36xx_dxe_write_register
(
wcn
,
WCN36XX_DXE_ENCH_ADDR
,
WCN36XX_DXE_INT_CH1_MASK
);
break
;
case
WCN36XX_DXE_CH_RX_H
:
dxe
->
ctrl
=
WCN36XX_DXE_CTRL_RX_H
;
wcn36xx_dxe_write_register
(
wcn
,
WCN36XX_DXE_ENCH_ADDR
,
WCN36XX_DXE_INT_CH3_MASK
);
break
;
default:
wcn36xx_warn
(
"Unknown channel
\n
"
);
}
dma_unmap_single
(
wcn
->
dev
,
dma_addr
,
WCN36XX_PKT_SIZE
,
dma_unmap_single
(
wcn
->
dev
,
dma_addr
,
WCN36XX_PKT_SIZE
,
DMA_FROM_DEVICE
);
DMA_FROM_DEVICE
);
wcn36xx_rx_skb
(
wcn
,
skb
);
wcn36xx_rx_skb
(
wcn
,
skb
);
}
/* else keep old skb not submitted and use it for rx DMA */
dxe
->
ctrl
=
value
;
ctl
=
ctl
->
next
;
ctl
=
ctl
->
next
;
dxe
=
ctl
->
desc
;
dxe
=
ctl
->
desc
;
}
}
wcn36xx_dxe_write_register
(
wcn
,
WCN36XX_DXE_ENCH_ADDR
,
int_mask
);
ch
->
head_blk_ctl
=
ctl
;
ch
->
head_blk_ctl
=
ctl
;
return
0
;
return
0
;
}
}
...
...
drivers/net/wireless/ath/wil6210/interrupt.c
浏览文件 @
236c52ca
...
@@ -394,9 +394,13 @@ static irqreturn_t wil6210_irq_misc_thread(int irq, void *cookie)
...
@@ -394,9 +394,13 @@ static irqreturn_t wil6210_irq_misc_thread(int irq, void *cookie)
wil_fw_core_dump
(
wil
);
wil_fw_core_dump
(
wil
);
wil_notify_fw_error
(
wil
);
wil_notify_fw_error
(
wil
);
isr
&=
~
ISR_MISC_FW_ERROR
;
isr
&=
~
ISR_MISC_FW_ERROR
;
if
(
wil
->
platform_ops
.
notify_crash
)
{
wil_err
(
wil
,
"notify platform driver about FW crash"
);
wil
->
platform_ops
.
notify_crash
(
wil
->
platform_handle
);
}
else
{
wil_fw_error_recovery
(
wil
);
wil_fw_error_recovery
(
wil
);
}
}
}
if
(
isr
&
ISR_MISC_MBOX_EVT
)
{
if
(
isr
&
ISR_MISC_MBOX_EVT
)
{
wil_dbg_irq
(
wil
,
"MBOX event
\n
"
);
wil_dbg_irq
(
wil
,
"MBOX event
\n
"
);
wmi_recv_cmd
(
wil
);
wmi_recv_cmd
(
wil
);
...
...
drivers/net/wireless/ath/wil6210/main.c
浏览文件 @
236c52ca
...
@@ -987,7 +987,7 @@ int __wil_down(struct wil6210_priv *wil)
...
@@ -987,7 +987,7 @@ int __wil_down(struct wil6210_priv *wil)
}
}
mutex_lock
(
&
wil
->
mutex
);
mutex_lock
(
&
wil
->
mutex
);
if
(
!
iter
)
if
(
iter
<
0
)
wil_err
(
wil
,
"timeout waiting for idle FW/HW
\n
"
);
wil_err
(
wil
,
"timeout waiting for idle FW/HW
\n
"
);
wil_reset
(
wil
,
false
);
wil_reset
(
wil
,
false
);
...
...
drivers/net/wireless/ath/wil6210/pcie_bus.c
浏览文件 @
236c52ca
/*
/*
* Copyright (c) 2012-201
4
Qualcomm Atheros, Inc.
* Copyright (c) 2012-201
5
Qualcomm Atheros, Inc.
*
*
* Permission to use, copy, modify, and/or distribute this software for any
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* purpose with or without fee is hereby granted, provided that the above
...
@@ -125,11 +125,37 @@ static int wil_if_pcie_disable(struct wil6210_priv *wil)
...
@@ -125,11 +125,37 @@ static int wil_if_pcie_disable(struct wil6210_priv *wil)
return
0
;
return
0
;
}
}
static
int
wil_platform_rop_ramdump
(
void
*
wil_handle
,
void
*
buf
,
uint32_t
size
)
{
struct
wil6210_priv
*
wil
=
wil_handle
;
if
(
!
wil
)
return
-
EINVAL
;
return
wil_fw_copy_crash_dump
(
wil
,
buf
,
size
);
}
static
int
wil_platform_rop_fw_recovery
(
void
*
wil_handle
)
{
struct
wil6210_priv
*
wil
=
wil_handle
;
if
(
!
wil
)
return
-
EINVAL
;
wil_fw_error_recovery
(
wil
);
return
0
;
}
static
int
wil_pcie_probe
(
struct
pci_dev
*
pdev
,
const
struct
pci_device_id
*
id
)
static
int
wil_pcie_probe
(
struct
pci_dev
*
pdev
,
const
struct
pci_device_id
*
id
)
{
{
struct
wil6210_priv
*
wil
;
struct
wil6210_priv
*
wil
;
struct
device
*
dev
=
&
pdev
->
dev
;
struct
device
*
dev
=
&
pdev
->
dev
;
int
rc
;
int
rc
;
const
struct
wil_platform_rops
rops
=
{
.
ramdump
=
wil_platform_rop_ramdump
,
.
fw_recovery
=
wil_platform_rop_fw_recovery
,
};
/* check HW */
/* check HW */
dev_info
(
&
pdev
->
dev
,
WIL_NAME
dev_info
(
&
pdev
->
dev
,
WIL_NAME
...
@@ -154,7 +180,7 @@ static int wil_pcie_probe(struct pci_dev *pdev, const struct pci_device_id *id)
...
@@ -154,7 +180,7 @@ static int wil_pcie_probe(struct pci_dev *pdev, const struct pci_device_id *id)
/* rollback to if_free */
/* rollback to if_free */
wil
->
platform_handle
=
wil
->
platform_handle
=
wil_platform_init
(
&
pdev
->
dev
,
&
wil
->
platform_ops
);
wil_platform_init
(
&
pdev
->
dev
,
&
wil
->
platform_ops
,
&
rops
,
wil
);
if
(
!
wil
->
platform_handle
)
{
if
(
!
wil
->
platform_handle
)
{
rc
=
-
ENODEV
;
rc
=
-
ENODEV
;
wil_err
(
wil
,
"wil_platform_init failed
\n
"
);
wil_err
(
wil
,
"wil_platform_init failed
\n
"
);
...
...
drivers/net/wireless/ath/wil6210/rx_reorder.c
浏览文件 @
236c52ca
...
@@ -261,9 +261,19 @@ struct wil_tid_ampdu_rx *wil_tid_ampdu_rx_alloc(struct wil6210_priv *wil,
...
@@ -261,9 +261,19 @@ struct wil_tid_ampdu_rx *wil_tid_ampdu_rx_alloc(struct wil6210_priv *wil,
void
wil_tid_ampdu_rx_free
(
struct
wil6210_priv
*
wil
,
void
wil_tid_ampdu_rx_free
(
struct
wil6210_priv
*
wil
,
struct
wil_tid_ampdu_rx
*
r
)
struct
wil_tid_ampdu_rx
*
r
)
{
{
int
i
;
if
(
!
r
)
if
(
!
r
)
return
;
return
;
wil_release_reorder_frames
(
wil
,
r
,
r
->
head_seq_num
+
r
->
buf_size
);
/* Do not pass remaining frames to the network stack - it may be
* not expecting to get any more Rx. Rx from here may lead to
* kernel OOPS since some per-socket accounting info was already
* released.
*/
for
(
i
=
0
;
i
<
r
->
buf_size
;
i
++
)
kfree_skb
(
r
->
reorder_buf
[
i
]);
kfree
(
r
->
reorder_buf
);
kfree
(
r
->
reorder_buf
);
kfree
(
r
->
reorder_time
);
kfree
(
r
->
reorder_time
);
kfree
(
r
);
kfree
(
r
);
...
...
drivers/net/wireless/ath/wil6210/wil6210.h
浏览文件 @
236c52ca
...
@@ -828,6 +828,7 @@ int wil_can_suspend(struct wil6210_priv *wil, bool is_runtime);
...
@@ -828,6 +828,7 @@ int wil_can_suspend(struct wil6210_priv *wil, bool is_runtime);
int
wil_suspend
(
struct
wil6210_priv
*
wil
,
bool
is_runtime
);
int
wil_suspend
(
struct
wil6210_priv
*
wil
,
bool
is_runtime
);
int
wil_resume
(
struct
wil6210_priv
*
wil
,
bool
is_runtime
);
int
wil_resume
(
struct
wil6210_priv
*
wil
,
bool
is_runtime
);
int
wil_fw_copy_crash_dump
(
struct
wil6210_priv
*
wil
,
void
*
dest
,
u32
size
);
void
wil_fw_core_dump
(
struct
wil6210_priv
*
wil
);
void
wil_fw_core_dump
(
struct
wil6210_priv
*
wil
);
#endif
/* __WIL6210_H__ */
#endif
/* __WIL6210_H__ */
drivers/net/wireless/ath/wil6210/wil_crash_dump.c
浏览文件 @
236c52ca
...
@@ -51,8 +51,7 @@ static int wil_fw_get_crash_dump_bounds(struct wil6210_priv *wil,
...
@@ -51,8 +51,7 @@ static int wil_fw_get_crash_dump_bounds(struct wil6210_priv *wil,
return
0
;
return
0
;
}
}
static
int
wil_fw_copy_crash_dump
(
struct
wil6210_priv
*
wil
,
void
*
dest
,
int
wil_fw_copy_crash_dump
(
struct
wil6210_priv
*
wil
,
void
*
dest
,
u32
size
)
u32
size
)
{
{
int
i
;
int
i
;
const
struct
fw_map
*
map
;
const
struct
fw_map
*
map
;
...
...
drivers/net/wireless/ath/wil6210/wil_platform.c
浏览文件 @
236c52ca
...
@@ -33,7 +33,8 @@ void wil_platform_modexit(void)
...
@@ -33,7 +33,8 @@ void wil_platform_modexit(void)
* It returns a handle which is used with the rest of the API
* It returns a handle which is used with the rest of the API
*
*
*/
*/
void
*
wil_platform_init
(
struct
device
*
dev
,
struct
wil_platform_ops
*
ops
)
void
*
wil_platform_init
(
struct
device
*
dev
,
struct
wil_platform_ops
*
ops
,
const
struct
wil_platform_rops
*
rops
,
void
*
wil_handle
)
{
{
void
*
handle
=
ops
;
/* to return some non-NULL for 'void' impl. */
void
*
handle
=
ops
;
/* to return some non-NULL for 'void' impl. */
...
...
drivers/net/wireless/ath/wil6210/wil_platform.h
浏览文件 @
236c52ca
/*
/*
* Copyright (c) 2014 Qualcomm Atheros, Inc.
* Copyright (c) 2014
-2015
Qualcomm Atheros, Inc.
*
*
* Permission to use, copy, modify, and/or distribute this software for any
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* purpose with or without fee is hereby granted, provided that the above
...
@@ -20,16 +20,48 @@
...
@@ -20,16 +20,48 @@
struct
device
;
struct
device
;
/**
/**
* struct wil_platform_ops - wil platform module callbacks
* struct wil_platform_ops - wil platform module calls from this
* driver to platform driver
*/
*/
struct
wil_platform_ops
{
struct
wil_platform_ops
{
int
(
*
bus_request
)(
void
*
handle
,
uint32_t
kbps
/* KBytes/Sec */
);
int
(
*
bus_request
)(
void
*
handle
,
uint32_t
kbps
/* KBytes/Sec */
);
int
(
*
suspend
)(
void
*
handle
);
int
(
*
suspend
)(
void
*
handle
);
int
(
*
resume
)(
void
*
handle
);
int
(
*
resume
)(
void
*
handle
);
void
(
*
uninit
)(
void
*
handle
);
void
(
*
uninit
)(
void
*
handle
);
int
(
*
notify_crash
)(
void
*
handle
);
};
};
void
*
wil_platform_init
(
struct
device
*
dev
,
struct
wil_platform_ops
*
ops
);
/**
* struct wil_platform_rops - wil platform module callbacks from
* platform driver to this driver
* @ramdump: store a ramdump from the wil firmware. The platform
* driver may add additional data to the ramdump to
* generate the final crash dump.
* @fw_recovery: start a firmware recovery process. Called as
* part of a crash recovery process which may include other
* related platform subsystems.
*/
struct
wil_platform_rops
{
int
(
*
ramdump
)(
void
*
wil_handle
,
void
*
buf
,
uint32_t
size
);
int
(
*
fw_recovery
)(
void
*
wil_handle
);
};
/**
* wil_platform_init - initialize the platform driver
*
* @dev - pointer to the wil6210 device
* @ops - structure with platform driver operations. Platform
* driver will fill this structure with function pointers.
* @rops - structure with callbacks from platform driver to
* this driver. The platform driver copies the structure to
* its own storage. Can be NULL if this driver does not
* support crash recovery.
* @wil_handle - context for this driver that will be passed
* when platform driver invokes one of the callbacks in
* rops. May be NULL if rops is NULL.
*/
void
*
wil_platform_init
(
struct
device
*
dev
,
struct
wil_platform_ops
*
ops
,
const
struct
wil_platform_rops
*
rops
,
void
*
wil_handle
);
int
__init
wil_platform_modinit
(
void
);
int
__init
wil_platform_modinit
(
void
);
void
wil_platform_modexit
(
void
);
void
wil_platform_modexit
(
void
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录