mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-08-05 16:54:27 +00:00
irda/sa1100_ir: convert to net_device_ops
Signed-off-by: Alexander Beregalov <a.beregalov@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
c76ccd6a25
commit
a1de966682
1 changed files with 12 additions and 5 deletions
|
@ -875,6 +875,16 @@ static int sa1100_irda_init_iobuf(iobuff_t *io, int size)
|
||||||
return io->head ? 0 : -ENOMEM;
|
return io->head ? 0 : -ENOMEM;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static const struct net_device_ops sa1100_irda_netdev_ops = {
|
||||||
|
.ndo_open = sa1100_irda_start,
|
||||||
|
.ndo_stop = sa1100_irda_stop,
|
||||||
|
.ndo_start_xmit = sa1100_irda_hard_xmit,
|
||||||
|
.ndo_do_ioctl = sa1100_irda_ioctl,
|
||||||
|
.ndo_change_mtu = eth_change_mtu,
|
||||||
|
.ndo_validate_addr = eth_validate_addr,
|
||||||
|
.ndo_set_mac_address = eth_mac_addr,
|
||||||
|
};
|
||||||
|
|
||||||
static int sa1100_irda_probe(struct platform_device *pdev)
|
static int sa1100_irda_probe(struct platform_device *pdev)
|
||||||
{
|
{
|
||||||
struct net_device *dev;
|
struct net_device *dev;
|
||||||
|
@ -913,11 +923,8 @@ static int sa1100_irda_probe(struct platform_device *pdev)
|
||||||
if (err)
|
if (err)
|
||||||
goto err_mem_5;
|
goto err_mem_5;
|
||||||
|
|
||||||
dev->hard_start_xmit = sa1100_irda_hard_xmit;
|
dev->netdev_ops = &sa1100_irda_netdev_ops;
|
||||||
dev->open = sa1100_irda_start;
|
dev->ir = IRQ_Ser2ICP;
|
||||||
dev->stop = sa1100_irda_stop;
|
|
||||||
dev->do_ioctl = sa1100_irda_ioctl;
|
|
||||||
dev->irq = IRQ_Ser2ICP;
|
|
||||||
|
|
||||||
irda_init_max_qos_capabilies(&si->qos);
|
irda_init_max_qos_capabilies(&si->qos);
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue