提交 77d7d7a3 编写于 作者: F Felipe Balbi 提交者: Luciano Coelho

net: wl12xx: care for optional operations

->init and ->reset are optional - at least
sdio.c doesn't implement them - so allow those
pointers to be NULL.
Signed-off-by: NFelipe Balbi <balbi@ti.com>
Signed-off-by: NLuciano Coelho <coelho@ti.com>
上级 6bdaf796
......@@ -128,12 +128,14 @@ EXPORT_SYMBOL_GPL(wl1271_set_partition);
void wl1271_io_reset(struct wl1271 *wl)
{
wl->if_ops->reset(wl);
if (wl->if_ops->reset)
wl->if_ops->reset(wl);
}
void wl1271_io_init(struct wl1271 *wl)
{
wl->if_ops->init(wl);
if (wl->if_ops->init)
wl->if_ops->init(wl);
}
void wl1271_top_reg_write(struct wl1271 *wl, int addr, u16 val)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册