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 42A1FCDB465 for ; Mon, 16 Oct 2023 11:41:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233003AbjJPLlO (ORCPT ); Mon, 16 Oct 2023 07:41:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33670 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233134AbjJPLlJ (ORCPT ); Mon, 16 Oct 2023 07:41:09 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D7565DC; Mon, 16 Oct 2023 04:41:07 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 510BDC433C8; Mon, 16 Oct 2023 11:41:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1697456466; bh=Y58rCXuF/l5eSXkcjq2QOHO2o9mynnSscDqicFlbC74=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=bzj10yoU16IONm22GE6uQ4TJX7JU2wL8tAmfHBHqpKSsrPERv3w/IoQQm2x+1xOzi wjdl5dyndgqfIeo5fj1Sfmh5Q9MW7DNTgfgXCf3GXnksOpz3ZtU9yg3p+gLghSR99R yxZsbbpKuzcBDt1fee7kqrwycAunZ0/tHLIp0vCf9u4HPaQ11bKtOX2+JdqrQU1sz4 1p50qvGFjti2HRLlvjYibJWMoS6Uun8VrCtKe8rHO70LIGVfYAMrFj9NoUUx5jT23g TtXA6lKdKanO1dcEmZjlpzHefmHxpRmSdgqVovZHQq+yKZ4Fj00lTHo78KAv9VW/Ke xtWCdlkq62DDw== MIME-Version: 1.0 Date: Mon, 16 Oct 2023 13:41:01 +0200 From: Michael Walle To: =?UTF-8?Q?Alexis_Lothor=C3=A9?= Cc: Claudiu Beznea , Kalle Valo , linux-wireless@vger.kernel.org, linux-kernel@vger.kernel.org, Thomas Petazzoni , Ajay Singh , stable@vger.kernel.org Subject: Re: [PATCH v2] wifi: wilc1000: use vmm_table as array in wilc struct In-Reply-To: <20231016-wilc1000_tx_oops-v2-1-8d1982a29ef1@bootlin.com> References: <20231016-wilc1000_tx_oops-v2-1-8d1982a29ef1@bootlin.com> Message-ID: X-Sender: mwalle@kernel.org Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Am 2023-10-16 10:29, schrieb Alexis Lothoré: > From: Ajay Singh > > Enabling KASAN and running some iperf tests raises some memory issues > with > vmm_table: > > BUG: KASAN: slab-out-of-bounds in wilc_wlan_handle_txq+0x6ac/0xdb4 > Write of size 4 at addr c3a61540 by task wlan0-tx/95 > > KASAN detects that we are writing data beyond range allocated to > vmm_table. > There is indeed a mismatch between the size passed to allocator in > wilc_wlan_init, and the range of possible indexes used later: > allocation > size is missing a multiplication by sizeof(u32) > > Fixes: 40b717bfcefa ("wifi: wilc1000: fix DMA on stack objects") > Cc: stable@vger.kernel.org > Signed-off-by: Ajay Singh > Signed-off-by: Alexis Lothoré Reviewed-by: Michael Walle -michael