Received: by 2002:a05:6358:45e:b0:b5:b6eb:e1f9 with SMTP id 30csp2859884rwe; Mon, 29 Aug 2022 01:13:59 -0700 (PDT) X-Google-Smtp-Source: AA6agR6sMA8Ykk7Vasi1ybr5WpYoYrYSvhcNazL7kWDuBfyzuX26j8xLWF2SPzK6EAS6+TgHFYy9 X-Received: by 2002:a05:6402:3907:b0:431:6776:64e7 with SMTP id fe7-20020a056402390700b00431677664e7mr15482201edb.0.1661760839453; Mon, 29 Aug 2022 01:13:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661760839; cv=none; d=google.com; s=arc-20160816; b=hXrdvTxegoIObck1XsH2JgETlO4LJIkylgMCQipzx5U5i+uMW/KIlYbrcEcwUP7rO1 /7YipO8Ur5+WWvOblyPRPy8DoqAF5J0COhgrHsHMYJ2aFnjUMaK9mDQ1GvkC56dhJUAu HkaFdvjfUhRYx9cRvBvqXpleKqe4o6ZSgpX1LmnznTkzvCc9q1JeAWUYsgL7uzmkKdqw OkqMe8xjiuMvSnezKo9ZkVqocPxS5rk9E3cYbNzVlikKENKMGudFfR89vdPfTdffCLBG 0YMF8jOL0JTuMcOPV1r07mUgxblmHiuntZWkmfq8TJBk81SCILL0FbFfJry043cFPiRq vP4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=ex8m/LSkdQVtQF4zzdtn3rTtpg6npJNdaVzNBggz1cA=; b=xAnyoGfdpQ1rJMqUHlzJwHkfeFeBBFtBj2HxkwjIZUnrpRnoQ77sQmK6VAyG9kAtie qy39rFVrV5Y7twjvYtV8P1yVhrjyNfUq5g21vPmBMfhRqF9y1xWWK7G/EAdDYrcoqa2F SI6M/XcNjvmOXdQ7rLE2O9HzR2EhOqzMFbbksSFXkBxjhgNp12mHi3jNqfbkGTprR3RE vTDjUPIAyQM5U2tUtmDk1I4rJ3MOhfVI7pKePInsbcosHejZeC9JhS8HJTE+mZRbq0OC WaS70Ak49Xc0hqL5ELP5K85wgETVU7MKaSwjZSJDP0R2CeTS4fpXosgxiIXr/7YR0NB6 kjUQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=S7iMWIDW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id bt21-20020a170906b15500b0073d62f62c9csi5840605ejb.217.2022.08.29.01.13.34; Mon, 29 Aug 2022 01:13:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=S7iMWIDW; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229838AbiH2IGz (ORCPT + 99 others); Mon, 29 Aug 2022 04:06:55 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47950 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229776AbiH2IGs (ORCPT ); Mon, 29 Aug 2022 04:06:48 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AC9C252838; Mon, 29 Aug 2022 01:06:47 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id E8F3EB80D63; Mon, 29 Aug 2022 08:06:45 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8B999C43470; Mon, 29 Aug 2022 08:06:44 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1661760404; bh=vEVlgcvzHAGVREWl4JAo7TyUTWO2ajtrlaWpFndzrc0=; h=From:To:Cc:Subject:Date:From; b=S7iMWIDWo1Xza4W8WqTIfQiJg96PtyaAoQVcHlTa2Vf8jrMQssWnueb2urKUULkCA kvZoNKbnAEroXKk3hFkwAYeUkW36/RX327Z39MQ+1zKYWG2KEDY2N4m7pLJ2Ag9Awh 1U/JZG6ao/FYetkUx9/Pv4sBeH8Fu/YCzudUcwLjYCMTkEVb4X3RYaoGH6MFvbYYH8 D+0pkwF4K9lhrF/Yx6R2hrLbpIy8sUV/A2Xd3vPmeXQpIEGxV7YE4T6j5CNH/iYhOC glnZVwVG0tRqdAg+xQn5a5FqnTOfgiR+h8L1FN5nT3wdMaX8YmL3AFr9Kc3WiZWf0U Gw6ZKd2rgcELg== Received: from johan by xi.lan with local (Exim 4.94.2) (envelope-from ) id 1oSZnH-0007jS-V2; Mon, 29 Aug 2022 10:06:51 +0200 From: Johan Hovold To: Srinivas Kandagatla , Amol Maheshwari Cc: Greg Kroah-Hartman , Arnd Bergmann , Bjorn Andersson , Manivannan Sadhasivam , linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold Subject: [PATCH 0/3] misc: fastrpc: fix memory corruption Date: Mon, 29 Aug 2022 10:05:28 +0200 Message-Id: <20220829080531.29681-1-johan+linaro@kernel.org> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The fastrpc driver uses a fixed-sized array to store its sessions but missing and broken sanity checks could lead to memory beyond the array being corrupted. This specifically happens on SC8280XP platforms that use 14 sessions for the compute DSP. These are all needed for 6.0. Johan Johan Hovold (3): misc: fastrpc: fix memory corruption on probe misc: fastrpc: fix memory corruption on open misc: fastrpc: increase maximum session count drivers/misc/fastrpc.c | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) -- 2.35.1