summaryrefslogtreecommitdiffstats
path: root/net/core/sock_diag.c
Commit message (Collapse)AuthorAgeFilesLines
* net: sock_diag_handler structs can be constShan Wei2012-04-251-6/+6
| | | | | | | | read only, so change it to const. Signed-off-by: Shan Wei <davidshan@tencent.com> Acked-by: Pavel Emelyanov <xemul@parallels.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* sock_diag: Introduce the meminfo nla core (v2)Pavel Emelyanov2011-12-301-0/+23
| | | | | | | | | | | | Add a routine that dumps memory-related values of a socket. It's made as an array to make it possible to add more stuff here later without breaking compatibility. Since v1: The SK_MEMINFO_ constants are in userspace visible part of sock_diag.h, the rest is under __KERNEL__. Signed-off-by: Pavel Emelyanov <xemul@parallels.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* sock_diag: Generalize requests cookies managementsPavel Emelyanov2011-12-161-0/+19
| | | | | | | | | The sk address is used as a cookie between dump/get_exact calls. It will be required for unix socket sdumping, so move it from inet_diag to sock_diag. Signed-off-by: Pavel Emelyanov <xemul@parallels.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* sock_diag: Fix module netlink aliasesPavel Emelyanov2011-12-161-2/+2
| | | | | | | | | | | | | | I've made a mistake when fixing the sock_/inet_diag aliases :( 1. The sock_diag layer should request the family-based alias, not just the IPPROTO_IP one; 2. The inet_diag layer should request for AF_INET+protocol alias, not just the protocol one. Thus fix this. Signed-off-by: Pavel Emelyanov <xemul@parallels.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* sock_diag: off by one checksDan Carpenter2011-12-081-2/+2
| | | | | | | | | These tests are off by one because sock_diag_handlers[] only has AF_MAX elements. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Acked-by: Pavel Emelyanov <xemul@parallels.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* sock_diag: Move the sock_ code to net/core/Pavel Emelyanov2011-12-061-0/+150
This patch moves the sock_ code from inet_diag.c to generic sock_diag.c file and provides necessary request_module-s calls and a pointer on inet_diag_compat dumping routine. Signed-off-by: Pavel Emelyanov <xemul@parallels.com> Signed-off-by: David S. Miller <davem@davemloft.net>