diff options
author | Jerry Ray <jerry.ray@microchip.com> | 2022-08-22 16:39:32 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-08-24 13:02:15 +0100 |
commit | fef5de753ff01887cfa50990532c3890fccb9338 (patch) | |
tree | 22cf982db5eb608e762caa256752a231f55e5e6a /drivers/net/ethernet/intel/ice/ice_tc_lib.c | |
parent | aacd467c0a576e5e44d2de4205855dc0fe43f6fb (diff) |
micrel: ksz8851: fixes struct pointer issue
Issue found during code review. This bug has no impact as long as the
ks8851_net structure is the first element of the ks8851_net_spi structure.
As long as the offset to the ks8851_net struct is zero, the container_of()
macro is subtracting 0 and therefore no damage done. But if the
ks8851_net_spi struct is ever modified such that the ks8851_net struct
within it is no longer the first element of the struct, then the bug would
manifest itself and cause problems.
struct ks8851_net is contained within ks8851_net_spi.
ks is contained within kss.
kss is the priv_data of the netdev structure.
Signed-off-by: Jerry Ray <jerry.ray@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/intel/ice/ice_tc_lib.c')
0 files changed, 0 insertions, 0 deletions