Commit cb9d97de authored by Heiner Kallweit's avatar Heiner Kallweit Committed by David S. Miller
Browse files

r8169: improve rtl_coalesce_choose_scale



The time limit provided by userspace is multiplied with 1000,
what could result in an overflow. Therefore change the time limit
parameter unit from ns to us, and avoid the problematic operation.
If there's no matching scale because provided time limit is too big,
return ERANGE instead of EINVAL to provide a hint to the user what's
wrong.

Signed-off-by: default avatarHeiner Kallweit <hkallweit1@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 6cf96dd4
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment