From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DA8AAC00144 for ; Mon, 1 Aug 2022 17:58:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233956AbiHAR6l (ORCPT ); Mon, 1 Aug 2022 13:58:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35754 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233721AbiHAR6F (ORCPT ); Mon, 1 Aug 2022 13:58:05 -0400 Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1914A2980E for ; Mon, 1 Aug 2022 10:57:49 -0700 (PDT) Received: by verein.lst.de (Postfix, from userid 2407) id 27E2768AA6; Mon, 1 Aug 2022 19:57:45 +0200 (CEST) Date: Mon, 1 Aug 2022 19:57:44 +0200 From: Christoph Hellwig To: yf.wang@mediatek.com Cc: Christoph Hellwig , Robin Murphy , Marek Szyprowski , Matthias Brugger , "open list:DMA MAPPING HELPERS" , open list , "moderated list:ARM/Mediatek SoC support" , "moderated list:ARM/Mediatek SoC support" , wsd_upstream@mediatek.com, Libo Kang , Ning Li , Yong Wu , Miles Chen , jianjiao zeng Subject: Re: [PATCH] dma-debug: Fix overflow issue in bucket_find_contain Message-ID: <20220801175744.GA17256@lst.de> References: <20220730114146.32669-1-yf.wang@mediatek.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220730114146.32669-1-yf.wang@mediatek.com> User-Agent: Mutt/1.5.17 (2007-11-01) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > + unsigned int shift = (1 << HASH_FN_SHIFT); Please just add a constant for that right nxt to the HASH_FN_SHIFT definition.