aboutsummaryrefslogtreecommitdiffstats
path: root/net/802
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2008-11-20 23:29:48 -0500
committerDavid S. Miller <davem@davemloft.net>2008-11-20 23:29:48 -0500
commit145186a39570244aead77dc2efc559e5cac90548 (patch)
treefbb9797afeccbc27578d43fcc51737e273f10027 /net/802
parent007c3838d9fdcc8fdaea87e4879ec3759f016ed5 (diff)
fddi: convert to new network device ops
Similar to ethernet. Convert infrastructure and the one lone FDDI driver (for the one lone user of that hardware??). Compile tested only. Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/802')
-rw-r--r--net/802/fddi.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/net/802/fddi.c b/net/802/fddi.c
index 0549317b9356..f1611a1e06a7 100644
--- a/net/802/fddi.c
+++ b/net/802/fddi.c
@@ -167,23 +167,27 @@ __be16 fddi_type_trans(struct sk_buff *skb, struct net_device *dev)
167 167
168EXPORT_SYMBOL(fddi_type_trans); 168EXPORT_SYMBOL(fddi_type_trans);
169 169
170static int fddi_change_mtu(struct net_device *dev, int new_mtu) 170int fddi_change_mtu(struct net_device *dev, int new_mtu)
171{ 171{
172 if ((new_mtu < FDDI_K_SNAP_HLEN) || (new_mtu > FDDI_K_SNAP_DLEN)) 172 if ((new_mtu < FDDI_K_SNAP_HLEN) || (new_mtu > FDDI_K_SNAP_DLEN))
173 return(-EINVAL); 173 return(-EINVAL);
174 dev->mtu = new_mtu; 174 dev->mtu = new_mtu;
175 return(0); 175 return(0);
176} 176}
177EXPORT_SYMBOL(fddi_change_mtu);
177 178
178static const struct header_ops fddi_header_ops = { 179static const struct header_ops fddi_header_ops = {
179 .create = fddi_header, 180 .create = fddi_header,
180 .rebuild = fddi_rebuild_header, 181 .rebuild = fddi_rebuild_header,
181}; 182};
182 183
184
183static void fddi_setup(struct net_device *dev) 185static void fddi_setup(struct net_device *dev)
184{ 186{
185 dev->change_mtu = fddi_change_mtu;
186 dev->header_ops = &fddi_header_ops; 187 dev->header_ops = &fddi_header_ops;
188#ifdef CONFIG_COMPAT_NET_DEV_OPS
189 dev->change_mtu = fddi_change_mtu,
190#endif
187 191
188 dev->type = ARPHRD_FDDI; 192 dev->type = ARPHRD_FDDI;
189 dev->hard_header_len = FDDI_K_SNAP_HLEN+3; /* Assume 802.2 SNAP hdr len + 3 pad bytes */ 193 dev->hard_header_len = FDDI_K_SNAP_HLEN+3; /* Assume 802.2 SNAP hdr len + 3 pad bytes */