summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorYOSHIFUJI Hideaki / 吉藤英明 <yoshfuji@linux-ipv6.org>2013-01-24 01:44:23 +0100
committerDavid S. Miller <davem@davemloft.net>2013-01-29 05:17:51 +0100
commit08433eff2d041b263c68306f6a6ccb4e1f75e196 (patch)
treea983dd9edfdb434076751c50f3952c744f64e17f /arch
parentnet: avoid to hang up on sending due to sysctl configuration overflow. (diff)
downloadlinux-08433eff2d041b263c68306f6a6ccb4e1f75e196.tar.xz
linux-08433eff2d041b263c68306f6a6ccb4e1f75e196.zip
net neigh: Optimize neighbor entry size calculation.
When allocating memory for neighbour cache entry, if tbl->entry_size is not set, we always calculate sizeof(struct neighbour) + tbl->key_len, which is common in the same table. With this change, set tbl->entry_size during the table initialization phase, if it was not set, and use it in neigh_alloc() and neighbour_priv(). This change also allow us to have both of protocol private data and device priate data at tha same time. Note that the only user of prototcol private is DECnet and the only user of device private is ATM CLIP. Since those are exclusive, we have not been facing issues here. Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch')
0 files changed, 0 insertions, 0 deletions