linux/include/net
Chuck Lever 35c448a8a3 include/net/sock.h: squelch compiler warning in sk_rmem_schedule()
This warning:

  In file included from linux/include/linux/tcp.h:227:0,
                   from linux/include/linux/ipv6.h:221,
                   from linux/include/net/ipv6.h:16,
                   from linux/include/linux/sunrpc/clnt.h:26,
                   from linux/net/sunrpc/stats.c:22:
  linux/include/net/sock.h: In function `sk_rmem_schedule':
  linux/nfs-2.6/include/net/sock.h:1339:13: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]

is seen with gcc (GCC) 4.6.3 20120306 (Red Hat 4.6.3-2) using the
-Wextra option.

Commit c76562b670 ("netvm: prevent a stream-specific deadlock")
accidentally replaced the "size" parameter of sk_rmem_schedule() with an
unsigned int.  This changes the semantics of the comparison in the
return statement.

In sk_wmem_schedule we have syntactically the same comparison, but
"size" is a signed integer.  In addition, __sk_mem_schedule() takes a
signed integer for its "size" parameter, so there is an implicit type
conversion in sk_rmem_schedule() anyway.

Revert the "size" parameter back to a signed integer so that the
semantics of the expressions in both sk_[rw]mem_schedule() are exactly
the same.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Mel Gorman <mgorman@suse.de>
Cc: David Miller <davem@davemloft.net>
Cc: Joonsoo Kim <js1304@gmail.com>
Cc: David Rientjes <rientjes@google.com>
Cc: Pekka Enberg <penberg@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-09-17 15:00:38 -07:00
..
9p
bluetooth Bluetooth: Change signature of smp_conn_security() 2012-08-27 08:07:18 -07:00
caif
irda
iucv
netfilter netfilter: nf_conntrack: fix racy timer handling with reliable events 2012-08-31 15:50:28 +02:00
netns ipv4: remove rt_cache_rebuild_count 2012-07-30 14:53:22 -07:00
nfc
phonet
sctp
tc_act
act_api.h
addrconf.h
af_ieee802154.h
af_rxrpc.h
af_unix.h
ah.h
arp.h
atmclip.h
ax25.h
ax88796.h
cfg80211-wext.h
cfg80211.h cfg80211: add channel flag to prohibit OFDM operation 2012-08-02 15:30:49 +02:00
checksum.h
cipso_ipv4.h
cls_cgroup.h
codel.h codel: refine one condition to avoid a nul rec_inv_sqrt 2012-08-10 16:52:54 -07:00
compat.h
datalink.h
dcbevent.h
dcbnl.h
dn.h
dn_dev.h
dn_fib.h
dn_neigh.h
dn_nsp.h
dn_route.h
dsa.h
dsfield.h
dst.h net: force dst_default_metrics to const section 2012-08-08 16:00:28 -07:00
dst_ops.h
esp.h
ethoc.h
fib_rules.h
flow.h
flow_keys.h
garp.h
gen_stats.h
genetlink.h
gre.h
icmp.h
ieee80211_radiotap.h
ieee802154.h
ieee802154_netdev.h
if_inet6.h
inet6_connection_sock.h
inet6_hashtables.h ipv6: Early TCP socket demux 2012-07-26 15:50:39 -07:00
inet_common.h
inet_connection_sock.h net: ipv6: fix TCP early demux 2012-08-06 13:33:21 -07:00
inet_ecn.h
inet_frag.h
inet_hashtables.h
inet_sock.h net: ipv6: fix TCP early demux 2012-08-06 13:33:21 -07:00
inet_timewait_sock.h
inetpeer.h
ip.h ipv4: fix ip_send_skb() 2012-08-10 14:08:57 -07:00
ip6_checksum.h
ip6_fib.h
ip6_route.h
ip6_tunnel.h
ip_fib.h ipv4: Cache routes in nexthop exception entries. 2012-07-31 15:02:02 -07:00
ip_vs.h
ipcomp.h
ipconfig.h
ipip.h
ipv6.h
ipx.h
iw_handler.h
lapb.h
lib80211.h
llc.h llc2: Fix silent failure of llc_station_init() 2012-08-14 16:51:18 -07:00
llc_c_ac.h
llc_c_ev.h
llc_c_st.h
llc_conn.h
llc_if.h
llc_pdu.h
llc_s_ac.h
llc_s_ev.h
llc_s_st.h
llc_sap.h
mac80211.h
mac802154.h
mip6.h
mld.h
ndisc.h
neighbour.h
net_namespace.h
net_ratelimit.h
netdma.h
netevent.h
netlabel.h
netlink.h
netprio_cgroup.h
netrom.h
nexthop.h
nl802154.h
p8022.h
ping.h
pkt_cls.h
pkt_sched.h
protocol.h ipv6: Early TCP socket demux 2012-07-26 15:50:39 -07:00
psnap.h
raw.h
rawv6.h
red.h
regulatory.h
request_sock.h
rose.h
route.h ipv4: Properly purge netdev references on uncached routes. 2012-07-31 15:06:50 -07:00
rtnetlink.h
sch_generic.h
scm.h af_netlink: force credentials passing [CVE-2012-3520] 2012-08-21 14:53:01 -07:00
secure_seq.h
slhc_vj.h
snmp.h
sock.h include/net/sock.h: squelch compiler warning in sk_rmem_schedule() 2012-09-17 15:00:38 -07:00
stp.h
tcp.h net: tcp: ipv6_mapped needs sk_rx_dst_set method 2012-08-09 20:56:09 -07:00
tcp_memcontrol.h
tcp_states.h
timewait_sock.h
transp_v6.h
udp.h
udplite.h
wext.h
wimax.h
wpan-phy.h
x25.h
x25device.h
xfrm.h xfrm: Workaround incompatibility of ESN and async crypto 2012-09-04 14:09:45 -04:00