mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
rds: Fix endianness annotation for RDS_MPATH_HASH
[ Upstream commit 77907a068717fbefb25faf01fecca553aca6ccaa ] jhash_1word accepts host endian inputs while rs_bound_port is a be16 value (sockaddr_in6.sin6_port). Use ntohs() for consistency. Flagged by Sparse. Signed-off-by: Ujwal Kundur <[email protected]> Reviewed-by: Allison Henderson <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Jakub Kicinski <[email protected]> Signed-off-by: Sasha Levin <[email protected]>
This commit is contained in:
parent
ce179e2434
commit
23eebe1c1c
1 changed files with 1 additions and 1 deletions
|
|
@ -94,7 +94,7 @@ enum {
|
|||
|
||||
/* Max number of multipaths per RDS connection. Must be a power of 2 */
|
||||
#define RDS_MPATH_WORKERS 8
|
||||
#define RDS_MPATH_HASH(rs, n) (jhash_1word((rs)->rs_bound_port, \
|
||||
#define RDS_MPATH_HASH(rs, n) (jhash_1word(ntohs((rs)->rs_bound_port), \
|
||||
(rs)->rs_hash_initval) & ((n) - 1))
|
||||
|
||||
#define IS_CANONICAL(laddr, faddr) (htonl(laddr) < htonl(faddr))
|
||||
|
|
|
|||
Loading…
Reference in a new issue