From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S936367AbdJRIjd (ORCPT ); Wed, 18 Oct 2017 04:39:33 -0400 Received: from mail-wr0-f195.google.com ([209.85.128.195]:50762 "EHLO mail-wr0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S936335AbdJRIjb (ORCPT ); Wed, 18 Oct 2017 04:39:31 -0400 X-Google-Smtp-Source: ABhQp+Qf3HPhdEJ4lKpku2t7YJsiSzlYipGz0uXNYxDbqT20fd2XV2E0Yyt+mlq8cYU13FEueRzt1g== Date: Wed, 18 Oct 2017 10:39:29 +0200 From: Jiri Pirko To: Arnd Bergmann Cc: Jamal Hadi Salim , Cong Wang , "David S. Miller" , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH net-next] net: sched: cls_u32: use hash_ptr() for tc_u_hash Message-ID: <20171018083929.GE2028@nanopsycho> References: <20171018083403.3236142-1-arnd@arndb.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171018083403.3236142-1-arnd@arndb.de> User-Agent: Mutt/1.8.3 (2017-05-23) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Wed, Oct 18, 2017 at 10:33:37AM CEST, arnd@arndb.de wrote: >After the change to the tp hash, we now get a build warning >on 32-bit architectures: > >net/sched/cls_u32.c: In function 'tc_u_hash': >net/sched/cls_u32.c:338:17: error: cast from pointer to integer of different size [-Werror=pointer-to-int-cast] > return hash_64((u64) tp->chain->block, U32_HASH_SHIFT); > >Using hash_ptr() instead of hash_64() lets us drop the cast >and fixes the warning while still resulting in the same hash >value. > >Fixes: 7fa9d974f3c2 ("net: sched: cls_u32: use block instead of q in tc_u_common") >Signed-off-by: Arnd Bergmann Acked-by: Jiri Pirko Thanks.