Commit 05fa5ec2 authored by navin patidar's avatar navin patidar Committed by Greg Kroah-Hartman

staging: rtl8188eu: Remove function _rtw_write_port()

_rtw_write_port() is a wrapper function, being used to call usb_write_port().
Call usb_write_port() directly and drop _rtw_write_port().
Signed-off-by: default avatarnavin patidar <navin.patidar@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e81ffd89
......@@ -126,22 +126,6 @@ int _rtw_write32(struct adapter *adapter, u32 addr, u32 val)
return RTW_STATUS_CODE(ret);
}
u32 _rtw_write_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem)
{
u32 (*_write_port)(struct adapter *pintfhdl, u32 addr, u32 cnt, u8 *pmem);
struct io_priv *pio_priv = &adapter->iopriv;
struct intf_hdl *pintfhdl = &(pio_priv->intf);
u32 ret = _SUCCESS;
_write_port = pintfhdl->io_ops._write_port;
ret = _write_port(adapter, addr, cnt, pmem);
return ret;
}
void _rtw_write_port_cancel(struct adapter *adapter)
{
void (*_write_port_cancel)(struct adapter *pintfhdl);
......
......@@ -397,7 +397,7 @@ static s32 rtw_dump_xframe(struct adapter *adapt, struct xmit_frame *pxmitframe)
}
ff_hwaddr = rtw_get_ff_hwaddr(pxmitframe);
inner_ret = rtw_write_port(adapt, ff_hwaddr, w_sz, (unsigned char *)pxmitbuf);
inner_ret = usb_write_port(adapt, ff_hwaddr, w_sz, (unsigned char *)pxmitbuf);
rtw_count_tx_stats(adapt, pxmitframe, sz);
......@@ -608,7 +608,7 @@ s32 rtl8188eu_xmitframe_complete(struct adapter *adapt, struct xmit_priv *pxmitp
/* 3 4. write xmit buffer to USB FIFO */
ff_hwaddr = rtw_get_ff_hwaddr(pfirstframe);
rtw_write_port(adapt, ff_hwaddr, pbuf_tail, (u8 *)pxmitbuf);
usb_write_port(adapt, ff_hwaddr, pbuf_tail, (u8 *)pxmitbuf);
/* 3 5. update statisitc */
pbuf_tail -= (pfirstframe->agg_num * TXDESC_SIZE);
......
......@@ -672,6 +672,5 @@ void rtl8188eu_set_intf_ops(struct _io_ops *pops)
pops->_write8 = &usb_write8;
pops->_write16 = &usb_write16;
pops->_write32 = &usb_write32;
pops->_write_port = &usb_write_port;
pops->_write_port_cancel = &usb_write_port_cancel;
}
......@@ -50,8 +50,6 @@ struct _io_ops {
int (*_write8)(struct adapter *pintfhdl, u32 addr, u8 val);
int (*_write16)(struct adapter *pintfhdl, u32 addr, u16 val);
int (*_write32)(struct adapter *pintfhdl, u32 addr, u32 val);
u32 (*_write_port)(struct adapter *pintfhdl, u32 addr, u32 cnt,
u8 *pmem);
void (*_write_port_cancel)(struct adapter *pintfhdl);
};
......@@ -95,7 +93,7 @@ int _rtw_write16(struct adapter *adapter, u32 addr, u16 val);
int _rtw_write32(struct adapter *adapter, u32 addr, u32 val);
int usb_writeN(struct adapter *adapter, u32 addr, u32 length, u8 *pdata);
u32 _rtw_write_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
u32 usb_write_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem);
void _rtw_write_port_cancel(struct adapter *adapter);
#define rtw_read8(adapter, addr) _rtw_read8((adapter), (addr))
......@@ -108,8 +106,6 @@ void _rtw_write_port_cancel(struct adapter *adapter);
_rtw_write16((adapter), (addr), (val))
#define rtw_write32(adapter, addr, val) \
_rtw_write32((adapter), (addr), (val))
#define rtw_write_port(adapter, addr, cnt, mem) \
_rtw_write_port((adapter), (addr), (cnt), (mem))
#define rtw_write_port_cancel(adapter) _rtw_write_port_cancel((adapter))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment