ethtool.h: define INT_MAX for userland
authorNicolas Dichtel <nicolas.dichtel@6wind.com>
Fri, 4 Mar 2016 10:52:19 +0000 (11:52 +0100)
committerDavid S. Miller <davem@davemloft.net>
Fri, 4 Mar 2016 21:10:37 +0000 (16:10 -0500)
commit14e2037902d65213842b4e40305ff54a64abbcb6
tree371ad0004ce8f8f0158b9c5e066d5765faec9011
parent166cc7136752192bb6e1f2be2e56614762292a00
ethtool.h: define INT_MAX for userland

INT_MAX needs limits.h in userland.
When ethtool.h is included by a userland app, we got the following error:

.../usr/include/linux/ethtool.h: In function 'ethtool_validate_speed':
.../usr/include/linux/ethtool.h:1471:18: error: 'INT_MAX' undeclared (first use in this function)
  return speed <= INT_MAX || speed == SPEED_UNKNOWN
                  ^

Fixes: e02564ee334a ("ethtool: make validate_speed accept all speeds between 0 and INT_MAX")
CC: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Signed-off-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Acked-by: Nikolay Aleksandrov <nikolay@cumulusnetworks.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/uapi/linux/ethtool.h
This page took 0.02503 seconds and 5 git commands to generate.