blob: 39d452d878e71795d7bba918707bcfe3c69e6f2f [file] [log] [blame]
Akinobu Mita850576c2016-04-15 00:11:30 +09001/*
2 * Ethernet driver for the WIZnet W5100 chip.
3 *
4 * Copyright (C) 2006-2008 WIZnet Co.,Ltd.
5 * Copyright (C) 2012 Mike Sinkovsky <msink@permonline.ru>
6 *
7 * Licensed under the GPL-2 or later.
8 */
9
10struct w5100_ops {
11 int (*read)(struct net_device *ndev, u16 addr);
12 int (*write)(struct net_device *ndev, u16 addr, u8 data);
13 int (*read16)(struct net_device *ndev, u16 addr);
14 int (*write16)(struct net_device *ndev, u16 addr, u16 data);
15 int (*readbulk)(struct net_device *ndev, u16 addr, u8 *buf, int len);
16 int (*writebulk)(struct net_device *ndev, u16 addr, const u8 *buf,
17 int len);
18 int (*reset)(struct net_device *ndev);
19 int (*init)(struct net_device *ndev);
20};
21
22void *w5100_ops_priv(const struct net_device *ndev);
23
24int w5100_probe(struct device *dev, const struct w5100_ops *ops,
25 int sizeof_ops_priv, u8 *mac_addr, int irq, int link_gpio);
26int w5100_remove(struct device *dev);
27
28extern const struct dev_pm_ops w5100_pm_ops;