]> git.baikalelectronics.ru Git - kernel.git/commit
net: netcp: Fixes error in oversized memory allocation for statistics storage
authorWingMan Kwok <w-kwok2@ti.com>
Thu, 23 Jul 2015 19:57:21 +0000 (15:57 -0400)
committerDavid S. Miller <davem@davemloft.net>
Mon, 27 Jul 2015 07:18:39 +0000 (00:18 -0700)
commit2594bbcf463b3a01ef06f3db0544f5f5f48f5f06
tree370a67426a9b29dcedef2d2b1a7ecd71dd30228f
parent75f6ff22feeea8f3493092adb365d84c5c68f7a9
net: netcp: Fixes error in oversized memory allocation for statistics storage

The CPSW driver keeps internally some, but not all, of
the statistics available in the hw statistics modules.  Furthermore,
some of the locations in the hw statistics modules are reserved and
contain no useful information.  Prior to this patch, the driver
allocates memory of the size of the the whole hw statistics modules,
instead of the size of statistics-entries-interested-in (i.e. et_stats),
for internal storage.  This patch fixes that.

Signed-off-by: WingMan Kwok <w-kwok2@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/ti/netcp_ethss.c