[Intel-wired-lan] [PATCH V2 3/5] ixgbe: Correct length check for round up

Bowers, AndrewX andrewx.bowers at intel.com
Mon Mar 21 21:16:59 UTC 2016


> -----Original Message-----
> From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On
> Behalf Of Mark D Rustad
> Sent: Monday, March 14, 2016 11:06 AM
> To: intel-wired-lan at lists.osuosl.org
> Subject: [Intel-wired-lan] [PATCH V2 3/5] ixgbe: Correct length check for
> round up
> 
> The function ixgbe_host_interface_command actually uses a multiple of
> word sized buffer to do its business, but only checks against the actual length
> passed in. This means that on read operations it could be possible to modify
> locations beyond the length passed in.
> Change the check to round up in the same way, just to avoid any possible
> hazard.
> 
> Signed-off-by: Mark Rustad <mark.d.rustad at intel.com>
> ---
> Changes in V2:
> - Use round_up function instead of an open-coded one
> ---
>  drivers/net/ethernet/intel/ixgbe/ixgbe_common.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Tested-by: Andrew Bowers <andrewx.bowers at intel.com>
Code changes correctly applied.


More information about the Intel-wired-lan mailing list