Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
Kernel
提交
46f16c49
K
Kernel
项目概览
openeuler
/
Kernel
1 年多 前同步成功
通知
8
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
K
Kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
46f16c49
编写于
8月 16, 2011
作者:
S
Stanislaw Gruszka
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
iwlegacy: remove DEBUG_IO
Nothing useful at present. Signed-off-by:
N
Stanislaw Gruszka
<
sgruszka@redhat.com
>
上级
d2ddf621
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
3 addition
and
197 deletion
+3
-197
drivers/net/wireless/iwlegacy/iwl-4965-eeprom.c
drivers/net/wireless/iwlegacy/iwl-4965-eeprom.c
+1
-5
drivers/net/wireless/iwlegacy/iwl-debug.h
drivers/net/wireless/iwlegacy/iwl-debug.h
+0
-2
drivers/net/wireless/iwlegacy/iwl-io.h
drivers/net/wireless/iwlegacy/iwl-io.h
+2
-190
未找到文件。
drivers/net/wireless/iwlegacy/iwl-4965-eeprom.c
浏览文件 @
46f16c49
...
...
@@ -102,12 +102,8 @@ int il4965_eeprom_acquire_semaphore(struct il_priv *il)
CSR_HW_IF_CONFIG_REG_BIT_EEPROM_OWN_SEM
,
CSR_HW_IF_CONFIG_REG_BIT_EEPROM_OWN_SEM
,
EEPROM_SEM_TIMEOUT
);
if
(
ret
>=
0
)
{
IL_DEBUG_IO
(
il
,
"Acquired semaphore after %d tries.
\n
"
,
count
+
1
);
if
(
ret
>=
0
)
return
ret
;
}
}
return
ret
;
...
...
drivers/net/wireless/iwlegacy/iwl-debug.h
浏览文件 @
46f16c49
...
...
@@ -146,7 +146,6 @@ static inline void il_dbgfs_unregister(struct il_priv *il)
#define IL_DL_RX (1 << 24)
#define IL_DL_ISR (1 << 25)
#define IL_DL_HT (1 << 26)
#define IL_DL_IO (1 << 27)
/* 0xF0000000 - 0x10000000 */
#define IL_DL_11H (1 << 28)
#define IL_DL_STATS (1 << 29)
...
...
@@ -174,7 +173,6 @@ static inline void il_dbgfs_unregister(struct il_priv *il)
IL_DEBUG_LIMIT(p, IL_DL_DROP, f, ## a)
#define IL_DEBUG_AP(p, f, a...) IL_DEBUG(p, IL_DL_AP, f, ## a)
#define IL_DEBUG_TXPOWER(p, f, a...) IL_DEBUG(p, IL_DL_TXPOWER, f, ## a)
#define IL_DEBUG_IO(p, f, a...) IL_DEBUG(p, IL_DL_IO, f, ## a)
#define IL_DEBUG_RATE(p, f, a...) IL_DEBUG(p, IL_DL_RATE, f, ## a)
#define IL_DEBUG_RATE_LIMIT(p, f, a...) \
IL_DEBUG_LIMIT(p, IL_DL_RATE, f, ## a)
...
...
drivers/net/wireless/iwlegacy/iwl-io.h
浏览文件 @
46f16c49
...
...
@@ -34,90 +34,24 @@
#include "iwl-dev.h"
#include "iwl-debug.h"
/*
* IO, register, and NIC memory access functions
*
* NOTE on naming convention and macro usage for these
*
* A single _ prefix before a an access function means that no state
* check or debug information is printed when that function is called.
*
* A double __ prefix before an access function means that state is checked
* and the current line number and caller function name are printed in addition
* to any other debug output.
*
* The non-prefixed name is the #define that maps the caller into a
* #define that provides the caller's name and __LINE__ to the double
* prefix version.
*
* If you wish to call the function without any debug or state checking,
* you should use the single _ prefix version (as is used by dependent IO
* routines, for example _il_read_direct32 calls the non-check version of
* _il_read32.)
*
* These declarations are *extremely* useful in quickly isolating code deltas
* which result in misconfiguration of the hardware I/O. In combination with
* git-bisect and the IO debug level you can quickly determine the specific
* commit which breaks the IO sequence to the hardware.
*
*/
static
inline
void
_il_write8
(
struct
il_priv
*
il
,
u32
ofs
,
u8
val
)
{
iowrite8
(
val
,
il
->
hw_base
+
ofs
);
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
void
__il_write8
(
const
char
*
f
,
u32
l
,
struct
il_priv
*
il
,
u32
ofs
,
u8
val
)
{
IL_DEBUG_IO
(
il
,
"write8(0x%08X, 0x%02X) - %s %d
\n
"
,
ofs
,
val
,
f
,
l
);
_il_write8
(
il
,
ofs
,
val
);
}
#define il_write8(il, ofs, val) \
__il_write8(__FILE__, __LINE__, il, ofs, val)
#else
#define il_write8(il, ofs, val) _il_write8(il, ofs, val)
#endif
static
inline
void
_il_write32
(
struct
il_priv
*
il
,
u32
ofs
,
u32
val
)
{
iowrite32
(
val
,
il
->
hw_base
+
ofs
);
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
void
__il_write32
(
const
char
*
f
,
u32
l
,
struct
il_priv
*
il
,
u32
ofs
,
u32
val
)
{
IL_DEBUG_IO
(
il
,
"write32(0x%08X, 0x%08X) - %s %d
\n
"
,
ofs
,
val
,
f
,
l
);
_il_write32
(
il
,
ofs
,
val
);
}
#define il_write32(il, ofs, val) \
__il_write32(__FILE__, __LINE__, il, ofs, val)
#else
#define il_write32(il, ofs, val) _il_write32(il, ofs, val)
#endif
static
inline
u32
_il_read32
(
struct
il_priv
*
il
,
u32
ofs
)
{
u32
val
=
ioread32
(
il
->
hw_base
+
ofs
);
return
val
;
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
u32
__il_read32
(
char
*
f
,
u32
l
,
struct
il_priv
*
il
,
u32
ofs
)
{
IL_DEBUG_IO
(
il
,
"read_direct32(0x%08X) - %s %d
\n
"
,
ofs
,
f
,
l
);
return
_il_read32
(
il
,
ofs
);
}
#define il_read32(il, ofs) __il_read32(__FILE__, __LINE__, il, ofs)
#else
#define il_read32(p, o) _il_read32(p, o)
#endif
#define IL_POLL_INTERVAL 10
/* microseconds */
static
inline
int
...
...
@@ -135,46 +69,13 @@ _il_poll_bit(struct il_priv *il, u32 addr,
return
-
ETIMEDOUT
;
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
int
__il_poll_bit
(
const
char
*
f
,
u32
l
,
struct
il_priv
*
il
,
u32
addr
,
u32
bits
,
u32
mask
,
int
timeout
)
{
int
ret
=
_il_poll_bit
(
il
,
addr
,
bits
,
mask
,
timeout
);
IL_DEBUG_IO
(
il
,
"poll_bit(0x%08X, 0x%08X, 0x%08X) - %s- %s %d
\n
"
,
addr
,
bits
,
mask
,
unlikely
(
ret
==
-
ETIMEDOUT
)
?
"timeout"
:
""
,
f
,
l
);
return
ret
;
}
#define il_poll_bit(il, addr, bits, mask, timeout) \
__il_poll_bit(__FILE__, __LINE__, il, addr, \
bits, mask, timeout)
#else
#define il_poll_bit(p, a, b, m, t) _il_poll_bit(p, a, b, m, t)
#endif
static
inline
void
_il_set_bit
(
struct
il_priv
*
il
,
u32
reg
,
u32
mask
)
{
_il_write32
(
il
,
reg
,
_il_read32
(
il
,
reg
)
|
mask
);
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
void
__il_set_bit
(
const
char
*
f
,
u32
l
,
struct
il_priv
*
il
,
u32
reg
,
u32
mask
)
{
u32
val
=
_il_read32
(
il
,
reg
)
|
mask
;
IL_DEBUG_IO
(
il
,
"set_bit(0x%08X, 0x%08X) = 0x%08X
\n
"
,
reg
,
mask
,
val
);
_il_write32
(
il
,
reg
,
val
);
}
static
inline
void
il_set_bit
(
struct
il_priv
*
p
,
u32
r
,
u32
m
)
{
unsigned
long
reg_flags
;
spin_lock_irqsave
(
&
p
->
reg_lock
,
reg_flags
);
__il_set_bit
(
__FILE__
,
__LINE__
,
p
,
r
,
m
);
spin_unlock_irqrestore
(
&
p
->
reg_lock
,
reg_flags
);
}
#else
static
inline
void
il_set_bit
(
struct
il_priv
*
p
,
u32
r
,
u32
m
)
{
unsigned
long
reg_flags
;
...
...
@@ -183,31 +84,13 @@ static inline void il_set_bit(struct il_priv *p, u32 r, u32 m)
_il_set_bit
(
p
,
r
,
m
);
spin_unlock_irqrestore
(
&
p
->
reg_lock
,
reg_flags
);
}
#endif
static
inline
void
_il_clear_bit
(
struct
il_priv
*
il
,
u32
reg
,
u32
mask
)
{
_il_write32
(
il
,
reg
,
_il_read32
(
il
,
reg
)
&
~
mask
);
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
void
__il_clear_bit
(
const
char
*
f
,
u32
l
,
struct
il_priv
*
il
,
u32
reg
,
u32
mask
)
{
u32
val
=
_il_read32
(
il
,
reg
)
&
~
mask
;
IL_DEBUG_IO
(
il
,
"clear_bit(0x%08X, 0x%08X) = 0x%08X
\n
"
,
reg
,
mask
,
val
);
_il_write32
(
il
,
reg
,
val
);
}
static
inline
void
il_clear_bit
(
struct
il_priv
*
p
,
u32
r
,
u32
m
)
{
unsigned
long
reg_flags
;
spin_lock_irqsave
(
&
p
->
reg_lock
,
reg_flags
);
__il_clear_bit
(
__FILE__
,
__LINE__
,
p
,
r
,
m
);
spin_unlock_irqrestore
(
&
p
->
reg_lock
,
reg_flags
);
}
#else
static
inline
void
il_clear_bit
(
struct
il_priv
*
p
,
u32
r
,
u32
m
)
{
unsigned
long
reg_flags
;
...
...
@@ -216,7 +99,6 @@ static inline void il_clear_bit(struct il_priv *p, u32 r, u32 m)
_il_clear_bit
(
p
,
r
,
m
);
spin_unlock_irqrestore
(
&
p
->
reg_lock
,
reg_flags
);
}
#endif
static
inline
int
_il_grab_nic_access
(
struct
il_priv
*
il
)
{
...
...
@@ -259,69 +141,20 @@ static inline int _il_grab_nic_access(struct il_priv *il)
return
0
;
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
int
__il_grab_nic_access
(
const
char
*
f
,
u32
l
,
struct
il_priv
*
il
)
{
IL_DEBUG_IO
(
il
,
"grabbing nic access - %s %d
\n
"
,
f
,
l
);
return
_il_grab_nic_access
(
il
);
}
#define il_grab_nic_access(il) \
__il_grab_nic_access(__FILE__, __LINE__, il)
#else
#define il_grab_nic_access(il) \
_il_grab_nic_access(il)
#endif
#define il_grab_nic_access(il) _il_grab_nic_access(il)
static
inline
void
_il_release_nic_access
(
struct
il_priv
*
il
)
{
_il_clear_bit
(
il
,
CSR_GP_CNTRL
,
CSR_GP_CNTRL_REG_FLAG_MAC_ACCESS_REQ
);
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
void
__il_release_nic_access
(
const
char
*
f
,
u32
l
,
struct
il_priv
*
il
)
{
IL_DEBUG_IO
(
il
,
"releasing nic access - %s %d
\n
"
,
f
,
l
);
_il_release_nic_access
(
il
);
}
#define il_release_nic_access(il) \
__il_release_nic_access(__FILE__, __LINE__, il)
#else
#define il_release_nic_access(il) \
_il_release_nic_access(il)
#endif
#define il_release_nic_access(il) _il_release_nic_access(il)
static
inline
u32
_il_read_direct32
(
struct
il_priv
*
il
,
u32
reg
)
{
return
_il_read32
(
il
,
reg
);
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
u32
__il_read_direct32
(
const
char
*
f
,
u32
l
,
struct
il_priv
*
il
,
u32
reg
)
{
u32
value
=
_il_read_direct32
(
il
,
reg
);
IL_DEBUG_IO
(
il
,
"read_direct32(0x%4X) = 0x%08x - %s %d
\n
"
,
reg
,
value
,
f
,
l
);
return
value
;
}
static
inline
u32
il_read_direct32
(
struct
il_priv
*
il
,
u32
reg
)
{
u32
value
;
unsigned
long
reg_flags
;
spin_lock_irqsave
(
&
il
->
reg_lock
,
reg_flags
);
il_grab_nic_access
(
il
);
value
=
__il_read_direct32
(
__FILE__
,
__LINE__
,
il
,
reg
);
il_release_nic_access
(
il
);
spin_unlock_irqrestore
(
&
il
->
reg_lock
,
reg_flags
);
return
value
;
}
#else
static
inline
u32
il_read_direct32
(
struct
il_priv
*
il
,
u32
reg
)
{
u32
value
;
...
...
@@ -335,7 +168,6 @@ static inline u32 il_read_direct32(struct il_priv *il, u32 reg)
return
value
;
}
#endif
static
inline
void
_il_write_direct32
(
struct
il_priv
*
il
,
u32
reg
,
u32
value
)
...
...
@@ -380,27 +212,7 @@ static inline int _il_poll_direct_bit(struct il_priv *il, u32 addr,
return
-
ETIMEDOUT
;
}
#ifdef CONFIG_IWLWIFI_LEGACY_DEBUG
static
inline
int
__il_poll_direct_bit
(
const
char
*
f
,
u32
l
,
struct
il_priv
*
il
,
u32
addr
,
u32
mask
,
int
timeout
)
{
int
ret
=
_il_poll_direct_bit
(
il
,
addr
,
mask
,
timeout
);
if
(
unlikely
(
ret
==
-
ETIMEDOUT
))
IL_DEBUG_IO
(
il
,
"poll_direct_bit(0x%08X, 0x%08X) - "
"timedout - %s %d
\n
"
,
addr
,
mask
,
f
,
l
);
else
IL_DEBUG_IO
(
il
,
"poll_direct_bit(0x%08X, 0x%08X) = 0x%08X "
"- %s %d
\n
"
,
addr
,
mask
,
ret
,
f
,
l
);
return
ret
;
}
#define il_poll_direct_bit(il, addr, mask, timeout) \
__il_poll_direct_bit(__FILE__, __LINE__, il, addr, mask, timeout)
#else
#define il_poll_direct_bit _il_poll_direct_bit
#endif
static
inline
u32
_il_read_prph
(
struct
il_priv
*
il
,
u32
reg
)
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录