aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/rtl8712/rtl8712_io.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/staging/rtl8712/rtl8712_io.c')
-rw-r--r--drivers/staging/rtl8712/rtl8712_io.c15
1 files changed, 5 insertions, 10 deletions
diff --git a/drivers/staging/rtl8712/rtl8712_io.c b/drivers/staging/rtl8712/rtl8712_io.c
index c7346008def0..921fcffb3065 100644
--- a/drivers/staging/rtl8712/rtl8712_io.c
+++ b/drivers/staging/rtl8712/rtl8712_io.c
@@ -39,11 +39,9 @@ u8 r8712_read8(struct _adapter *adapter, u32 addr)
struct io_queue *pio_queue = (struct io_queue *)adapter->pio_queue;
struct intf_hdl *pintfhdl = &(pio_queue->intf);
u8 (*_read8)(struct intf_hdl *pintfhdl, u32 addr);
- u8 r_val;
_read8 = pintfhdl->io_ops._read8;
- r_val = _read8(pintfhdl, addr);
- return r_val;
+ return _read8(pintfhdl, addr);
}
u16 r8712_read16(struct _adapter *adapter, u32 addr)
@@ -51,11 +49,9 @@ u16 r8712_read16(struct _adapter *adapter, u32 addr)
struct io_queue *pio_queue = (struct io_queue *)adapter->pio_queue;
struct intf_hdl *pintfhdl = &(pio_queue->intf);
u16 (*_read16)(struct intf_hdl *pintfhdl, u32 addr);
- u16 r_val;
_read16 = pintfhdl->io_ops._read16;
- r_val = _read16(pintfhdl, addr);
- return r_val;
+ return _read16(pintfhdl, addr);
}
u32 r8712_read32(struct _adapter *adapter, u32 addr)
@@ -63,11 +59,9 @@ u32 r8712_read32(struct _adapter *adapter, u32 addr)
struct io_queue *pio_queue = (struct io_queue *)adapter->pio_queue;
struct intf_hdl *pintfhdl = &(pio_queue->intf);
u32 (*_read32)(struct intf_hdl *pintfhdl, u32 addr);
- u32 r_val;
_read32 = pintfhdl->io_ops._read32;
- r_val = _read32(pintfhdl, addr);
- return r_val;
+ return _read32(pintfhdl, addr);
}
void r8712_write8(struct _adapter *adapter, u32 addr, u8 val)
@@ -84,8 +78,8 @@ void r8712_write16(struct _adapter *adapter, u32 addr, u16 val)
{
struct io_queue *pio_queue = (struct io_queue *)adapter->pio_queue;
struct intf_hdl *pintfhdl = &(pio_queue->intf);
-
void (*_write16)(struct intf_hdl *pintfhdl, u32 addr, u16 val);
+
_write16 = pintfhdl->io_ops._write16;
_write16(pintfhdl, addr, val);
}
@@ -96,6 +90,7 @@ void r8712_write32(struct _adapter *adapter, u32 addr, u32 val)
struct intf_hdl *pintfhdl = (struct intf_hdl *)(&(pio_queue->intf));
void (*_write32)(struct intf_hdl *pintfhdl, u32 addr, u32 val);
+
_write32 = pintfhdl->io_ops._write32;
_write32(pintfhdl, addr, val);
}