On Wed, May 12, 2010 at 9:02 AM, Ivo Van Doorn <ivdoorn@xxxxxxxxx> wrote: > On Tue, May 11, 2010 at 11:51 PM, Gertjan van Wingerde > <gwingerde@xxxxxxxxx> wrote: >> For rt2800 reverse the calling order of rt2x00pci_write_data and >> rt2800pci_write_data. Currently rt2800pci_write_data calls rt2x00pci_write_data >> as there can be only 1 driver callback function specified by the driver. >> Reverse this calling order by introducing a new driver callback function, >> called add_tx_datadesc, which is called from the bus-specific write_tx_data >> functions. >> Preparation for futher cleanups in the skb data handling of rt2x00. >> >> Signed-off-by: Gertjan van Wingerde <gwingerde@xxxxxxxxx> >> --- >> drivers/net/wireless/rt2x00/rt2800pci.c | 15 ++++----------- >> drivers/net/wireless/rt2x00/rt2x00.h | 2 ++ >> drivers/net/wireless/rt2x00/rt2x00pci.c | 6 ++++++ >> drivers/net/wireless/rt2x00/rt2x00usb.c | 6 ++++++ >> 4 files changed, 18 insertions(+), 11 deletions(-) >> >> diff --git a/drivers/net/wireless/rt2x00/rt2800pci.c b/drivers/net/wireless/rt2x00/rt2800pci.c >> index fcca30c..bbd6481 100644 >> --- a/drivers/net/wireless/rt2x00/rt2800pci.c >> +++ b/drivers/net/wireless/rt2x00/rt2800pci.c >> @@ -614,18 +614,10 @@ static int rt2800pci_set_device_state(struct rt2x00_dev *rt2x00dev, >> /* >> * TX descriptor initialization >> */ >> -static int rt2800pci_write_tx_data(struct queue_entry* entry, >> - struct txentry_desc *txdesc) >> +static void rt2800pci_add_tx_datadesc(struct queue_entry* entry, >> + struct txentry_desc *txdesc) >> { >> - int ret; >> - >> - ret = rt2x00pci_write_tx_data(entry, txdesc); >> - if (ret) >> - return ret; >> - >> rt2800_write_txwi(entry->skb, txdesc); >> - >> - return 0; >> } >> >> >> @@ -1080,7 +1072,8 @@ static const struct rt2x00lib_ops rt2800pci_rt2x00_ops = { >> .reset_tuner = rt2800_reset_tuner, >> .link_tuner = rt2800_link_tuner, >> .write_tx_desc = rt2800pci_write_tx_desc, >> - .write_tx_data = rt2800pci_write_tx_data, >> + .write_tx_data = rt2x00pci_write_tx_data, >> + .add_tx_datadesc = rt2800pci_add_tx_datadesc, >> .write_beacon = rt2800pci_write_beacon, >> .kick_tx_queue = rt2800pci_kick_tx_queue, >> .kill_tx_queue = rt2800pci_kill_tx_queue, > > Doesn't the name write_tx_datadesc make more sense? > The names are equivalent to me. But if that name makes more sense to you then I have no problem with changing the name of the callback function. --- Gertjan -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html