Selaa lähdekoodia

ipvs: Use ARRAY_SIZE()

Signed-off-by: Sven Wegener <sven.wegener@stealer.net>
Acked-by: Simon Horman <horms@verge.net.au>
Sven Wegener 17 vuotta sitten
vanhempi
commit
afdd614071
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      include/net/ip_vs.h

+ 1 - 1
include/net/ip_vs.h

@@ -440,7 +440,7 @@ struct ip_vs_app
  */
 extern const char *ip_vs_proto_name(unsigned proto);
 extern void ip_vs_init_hash_table(struct list_head *table, int rows);
-#define IP_VS_INIT_HASH_TABLE(t) ip_vs_init_hash_table(t, sizeof(t)/sizeof(t[0]))
+#define IP_VS_INIT_HASH_TABLE(t) ip_vs_init_hash_table((t), ARRAY_SIZE((t)))
 
 #define IP_VS_APP_TYPE_FTP	1