14 Apr, 2008
1 commit
-
Paul Bolle wrote:
> http://bugzilla.kernel.org/show_bug.cgi?id=9923 would have been much easier to
> track down if eth_validate_addr() would somehow complain aloud if an address
> is invalid. Shouldn't it make at least some noise?I guess it should return -EADDRNOTAVAIL similar to eth_mac_addr()
when validation fails.Signed-off-by: Patrick McHardy
Signed-off-by: David S. Miller
29 Jan, 2008
1 commit
-
print_mac() used many most net drivers and format_addr() used by
net-sysfs.c are very similar and they can be intergrated.format_addr() is also identically redefined in the qla4xxx iscsi
driver.Export a new function sysfs_format_mac() to be used by net-sysfs,
qla4xxx and others in the future. Both print_mac() and
sysfs_format_mac() call _format_mac_addr() to do the formatting.Changed print_mac() to use unsigned char * to be consistent with
net_device struct's dev_addr. Added buffer length overrun checking
as suggested by Joe Perches.Signed-off-by: Michael Chan
Signed-off-by: David S. Miller
24 Oct, 2007
1 commit
-
Signed-off-by: Jeff Garzik
Signed-off-by: David S. Miller
11 Oct, 2007
5 commits
-
Since hardware header operations are part of the protocol class
not the device instance, make them into a separate object and
save memory.Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller -
Wrap the hard_header_parse function to simplify next step of
header_ops conversion.Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller -
Add inline for common usage of hardware header creation, and
fix bug in IPV6 mcast where the assumption about negative return is
an errno. Negative return from hard_header means not enough space
was available,(ie -N bytes).Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller -
This is nicer than the MAC_FMT stuff.
Signed-off-by: Joe Perches
Signed-off-by: David S. Miller -
The ethernet header management only needs to handle a fixed
size address (6 bytes). If the memcpy/memset are changed to
be passed a constant length, then compiler can optimize for
this case (and if it is smart eliminate string instructions).Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller
12 Jul, 2007
1 commit
-
Signed-off-by: Patrick McHardy
Signed-off-by: David S. Miller
11 Jul, 2007
1 commit
-
Add the multiqueue hardware device support API to the core network
stack. Allow drivers to allocate multiple queues and manage them at
the netdev level if they choose to do so.Added a new field to sk_buff, namely queue_mapping, for drivers to
know which tx_ring to select based on OS classification of the flow.Signed-off-by: Peter P Waskiewicz Jr
Signed-off-by: Patrick McHardy
Signed-off-by: David S. Miller
26 Apr, 2007
3 commits
-
For the common, open coded 'skb->mac.raw = skb->data' operation, so that we can
later turn skb->mac.raw into a offset, reducing the size of struct sk_buff in
64bit land while possibly keeping it as a pointer on 32bit.This one touches just the most simple case, next will handle the slightly more
"complex" cases.Signed-off-by: Arnaldo Carvalho de Melo
Signed-off-by: David S. Miller -
One less thing for drivers writers to worry about.
Signed-off-by: Arnaldo Carvalho de Melo
Signed-off-by: David S. Miller -
Signed-off-by: YOSHIFUJI Hideaki
Signed-off-by: David S. Miller
15 Feb, 2007
1 commit
-
After Al Viro (finally) succeeded in removing the sched.h #include in module.h
recently, it makes sense again to remove other superfluous sched.h includes.
There are quite a lot of files which include it but don't actually need
anything defined in there. Presumably these includes were once needed for
macros that used to live in sched.h, but moved to other header files in the
course of cleaning it up.To ease the pain, this time I did not fiddle with any header files and only
removed #includes from .c-files, which tend to cause less trouble.Compile tested against 2.6.20-rc2 and 2.6.20-rc2-mm2 (with offsets) on alpha,
arm, i386, ia64, mips, powerpc, and x86_64 with allnoconfig, defconfig,
allmodconfig, and allyesconfig as well as a few randconfigs on x86_64 and all
configs in arch/arm/configs on arm. I also checked that no new warnings were
introduced by the patch (actually, some warnings are removed that were emitted
by unnecessarily included header files).Signed-off-by: Tim Schmielau
Acked-by: Russell King
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
11 Feb, 2007
1 commit
-
Signed-off-by: YOSHIFUJI Hideaki
Signed-off-by: David S. Miller
03 Dec, 2006
1 commit
-
Signed-off-by: Al Viro
Signed-off-by: David S. Miller
29 Sep, 2006
1 commit
-
Signed-off-by: Al Viro
Signed-off-by: David S. Miller
23 Sep, 2006
2 commits
-
Run ethernet support through Lindent and fix up.
Applies after docbook comments patchSigned-off-by: Stephen Hemminger
Signed-off-by: David S. Miller -
Add docbook style comments to ethernet support.
Signed-off-by: Stephen Hemminger
Acked-by: Randy Dunlap
Signed-off-by: David S. Miller
01 Jul, 2006
1 commit
-
Signed-off-by: Jörn Engel
Signed-off-by: Adrian Bunk
06 Jun, 2006
1 commit
-
The /proc/sys/net/ethernet directory has been sitting empty for more than
10 years! Time to eliminate it!Signed-off-by: Jes Sorensen
Signed-off-by: Andrew Morton
Signed-off-by: David S. Miller
24 Feb, 2006
1 commit
-
When you turn off ARP on a netdevice then the first packet always goes
out with a dstMAC of all zeroes. This is because the first packet is
used to resolve ARP entries. Even though the ARP entry may be resolved
(I tried by setting a static ARP entry for a host i was pinging from),
it gets overwritten by virtue of having the netdevice disabling ARP.Subsequent packets go out fine with correct dstMAC address (which may
be why people have ignored reporting this issue).To cut the story short:
the culprit code is in net/ethernet/eth.c::eth_header()
----
/*
* Anyway, the loopback-device should never use this
function...
*/if (dev->flags & (IFF_LOOPBACK|IFF_NOARP))
{
memset(eth->h_dest, 0, dev->addr_len);
return ETH_HLEN;
}if(daddr)
{
memcpy(eth->h_dest,daddr,dev->addr_len);
return ETH_HLEN;
}----
Note how the h_dest is being reset when device has IFF_NOARP.
As a note:
All devices including loopback pass a daddr. loopback in fact passes
a 0 all the time ;->
This means i can delete the check totaly or i can remove the IFF_NOARPAlexey says:
--------------------
I think, it was me who did this crap. It was so long ago I do not remember
why it was made.I remember some troubles with dummy device. It tried to resolve
addresses, apparently, without success and generated errors instead of
blackholing. I think the problem was eventually solved at neighbour
level.After some thinking I suspect the deletion of this chunk could change
behaviour of some parts which do not use neighbour cache f.e. packet
socket.I think safer approach would be to move this chunk after if (daddr).
And the possibility to remove this completely could be analyzed later.
--------------------Patch updated with Alexey's safer suggestions.
Signed-off-by: Jamal Hadi Salim
Acked-by: Alexey Kuznetsov
Signed-off-by: David S. Miller
07 Jan, 2006
1 commit
-
This uses is_multicast_ether_addr() because it has recently been
changed to do the same thing these seperate tests are doing.Signed-off-by: Kris Katterjohn
Signed-off-by: David S. Miller
06 Jan, 2006
1 commit
-
These patches add the header linux/if_ether.h and change 1500 to
ETH_DATA_LEN in some files.Signed-off-by: Kris Katterjohn
Signed-off-by: David S. Miller
09 Nov, 2005
1 commit
-
From: Jesper Juhl
This is the net/ part of the big kfree cleanup patch.
Remove pointless checks for NULL prior to calling kfree() in net/.
Signed-off-by: Jesper Juhl
Cc: "David S. Miller"
Cc: Arnaldo Carvalho de Melo
Acked-by: Marcel Holtmann
Acked-by: YOSHIFUJI Hideaki
Signed-off-by: Andrew Morton
29 Oct, 2005
1 commit
-
Expose faster ether compare for use by protocols and other
driver. And change name to be more consistent with other ether
address manipulation routines in same fileSigned-off-by: Stephen Hemminger
Signed-off-by: Arnaldo Carvalho de Melo
29 Sep, 2005
1 commit
-
I got the second compare_eth_addr() test reversed, oops.
Signed-off-by: David S. Miller
28 Sep, 2005
1 commit
-
We know the thing is at least 2-byte aligned, so take
advantage of that instead of invoking memcmp() which
results in truly horrifically inefficient code because
it can't assume anything about alignment.Signed-off-by: David S. Miller
30 Aug, 2005
2 commits
-
Of this type, mostly:
CHECK net/ipv6/netfilter.c
net/ipv6/netfilter.c:96:12: warning: symbol 'ipv6_netfilter_init' was not declared. Should it be static?
net/ipv6/netfilter.c:101:6: warning: symbol 'ipv6_netfilter_fini' was not declared. Should it be static?Signed-off-by: Arnaldo Carvalho de Melo
Signed-off-by: David S. Miller -
Instead, set it in one place, namely the beginning of
netif_receive_skb().Based upon suggestions from Jamal Hadi Salim.
Signed-off-by: David S. Miller
13 Jul, 2005
1 commit
-
tr_type_trans(), hippi_type_trans() left as-is.
Signed-off-by: Alexey Dobriyan
Signed-off-by: David S. Miller
29 Jun, 2005
1 commit
-
Signed-off-by: Denis Vlasenko
Signed-off-by: David S. Miller
06 May, 2005
1 commit
-
Ross moved. Remove the bad email address so people will find the correct
one in ./CREDITS.Signed-off-by: Jesper Juhl
Signed-off-by: Andrew Morton
Signed-off-by: Linus Torvalds
17 Apr, 2005
1 commit
-
Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.Let it rip!