Message ID | 20230511141146.30465-1-me@dylanvanassche.be |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:6358:3046:b0:115:7a1d:dabb with SMTP id p6csp4471903rwl; Thu, 11 May 2023 07:18:24 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4cgIudzySPuHCG2VftlVpvSSj5eZJ0e51/HgRW2PWU5TRnyuQHA+Nqr54JhEOr+drtlMRh X-Received: by 2002:a17:90a:fd8e:b0:250:2922:1f3c with SMTP id cx14-20020a17090afd8e00b0025029221f3cmr22446269pjb.33.1683814704638; Thu, 11 May 2023 07:18:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683814704; cv=none; d=google.com; s=arc-20160816; b=JqaylngRKkV2VmK3uebnaFZu2SNN/YdBCyWfAX2QH3dGXorwU7l67Mi0g4ihGijg0G uarUlYf/NyYWAdl2yy4nOu7rUowdTd+UtA5KJeDETVjicdLR4xVZeJDGaPdswAgdjecZ 3N+CHGyxYvQt22b/X00xwtGJEoJWUGI51gDJ+g/bNFPU1jAIZRkTOogFbgbnt3fVdnky yticmub88+vuHIZXUmwmeD+pHHBVSIBtKOG+nJUGHAiObNTtH7iMEs7Kp1XNl0grwO7/ n/bgxgb5xniOerupJb5K3Xchz1tiRrUZ+iGgALOnu2gUBYLGTFWdpcJVLq5gLYdF8fDc s07A== 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=sd6dUDVlduWJM+HnYeES6xBRaZitnQSV9AIx4FVcTS4=; b=ywoZ0JAA6nImzBCJHpOXOs+UAOR4TIwscyldPFlK2Fu9J87NwQfk/fi2xfQ2EXtGMc nySKHvRIvK3px6M5iQw/meaJqkoi90cfo2gN/MHnWrH9H6dFFcKums9f9naGZ+zXnhkS WwjTqjxKHBV9CPf83OYV+7YsM+OdDMwLHgK2yTbDDTDEqPDUnsY/O5K13drevYcesycl 1eQS7lJ5VMBtzqeHCacy0CGpCyL0j5DPPSqP/3pgajXHfXfjkh8eo4q+IkGx/fDRAtoX Mz2DJ+7yvGv4yqBeX5oU51Bvy5bFygaWNNJHP14uzyEuqcCnX6436WK1DfzKb0VlYPRw +hFg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@dylanvanassche.be header.s=MBO0001 header.b=enBGY9cN; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=dylanvanassche.be Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o9-20020a170902d4c900b001ac4027fa28si7298683plg.618.2023.05.11.07.18.11; Thu, 11 May 2023 07:18:24 -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=@dylanvanassche.be header.s=MBO0001 header.b=enBGY9cN; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=dylanvanassche.be Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238248AbjEKONk (ORCPT <rfc822;peekingduck44@gmail.com> + 99 others); Thu, 11 May 2023 10:13:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58360 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238164AbjEKONe (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 11 May 2023 10:13:34 -0400 Received: from mout-p-202.mailbox.org (mout-p-202.mailbox.org [80.241.56.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 77B521BC1; Thu, 11 May 2023 07:12:54 -0700 (PDT) Received: from smtp202.mailbox.org (smtp202.mailbox.org [IPv6:2001:67c:2050:b231:465::202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-202.mailbox.org (Postfix) with ESMTPS id 4QHDNW34ZCz9spr; Thu, 11 May 2023 16:11:55 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dylanvanassche.be; s=MBO0001; t=1683814315; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=sd6dUDVlduWJM+HnYeES6xBRaZitnQSV9AIx4FVcTS4=; b=enBGY9cNK1pl7ZE79ErAPB18bUZq92u1aUO0RZcFogDASNVKiSz0Nbn+hhZkVJx63kAbtb C/m3YuFDkhxXc+zgX9HxU+Jdt4EulWMM6uHtJm0b6qsm3HKw1oY5mKLi3Kr71UYp8uHAh3 37GzsKo+04lmYP0darIL52Co5egARFDiLjdCrTWaU66aMaJWDVleApSFt6UQBdFZxocFPt X1UMVwUdnhnZ6KGWBZZ7fwJwjkgTCWc0BjhC7EwaN2VaQ4UTOtehwzYPbH18RXHAb2Y+9I KOTPW03yjHUrxr0UE+t0fEsUUK3bkwnGDHB999vU60BKHbIa1kNrES2j9RONBw== From: Dylan Van Assche <me@dylanvanassche.be> To: srinivas.kandagatla@linaro.org, amahesh@qti.qualcomm.com, arnd@arndb.de, gregkh@linuxfoundation.org Cc: linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht, phone-devel@vger.kernel.org, dan.carpenter@linaro.org, Dylan Van Assche <me@dylanvanassche.be> Subject: [PATCH v4 0/2] misc: fastrpc: FastRPC reserved memory assignment for SDM845 SLPI Date: Thu, 11 May 2023 16:11:44 +0200 Message-Id: <20230511141146.30465-1-me@dylanvanassche.be> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 4QHDNW34ZCz9spr X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1765607687308855970?= X-GMAIL-MSGID: =?utf-8?q?1765607687308855970?= |
Series |
misc: fastrpc: FastRPC reserved memory assignment for SDM845 SLPI
|
|
Message
Dylan Van Assche
May 11, 2023, 2:11 p.m. UTC
* About * The Qualcomm SDM845 SoC has a separate SLPI (Sensor Low Power Island) DSP for sensors connected to the SoC which is responsible for exposing sensors to userspace, power saving, and other features. While sensors are connected to GPIOs of the SoC, they cannot be used because the hypervisor blocks direct access to the sensors, thus the DSP must be used to access any sensor on this SoC. The SLPI DSP uses a GLink edge (dsps) to communicate with the host and has a FastRPC interface to load files from the host filesystem such as sensor configuration files. The FastRPC interface does not use regular FastRPC Compute Banks but instead uses an allocated CMA region through which communication happens. * Changes * This patchseries add support to the FastRPC for assigning a coherent memory region to a DSP via the hypervisor with the correct permissions. This is necessary to support the SLPI found in the Qualcomm SDM845 SoC which does not have dedicated FastRPC Compute Banks, in contrast to newer SoCs, but uses a memory region instead when allocating buffers. * Related patches * 1. Remoteproc changes to support the SLPI DSP in SDM845 (v3), needs to be applied: https://lore.kernel.org/linux-remoteproc/20230330164633.117335-1-me@dylanvanassche.be 2. DTS changes (v5), already applied: https://lore.kernel.org/linux-devicetree/20230406173148.28309-1-me@dylanvanassche.be This serie does not depend on any serie, but all of them are necessary to enable the feature in the end. * Changelog * Changes in v4: - Fixed possible memory leak when driver encounters an error during probing. Changes in v3: - Dropped debug prints. - Added Reviewed-By tags from v2. Changes in v2: - Removed double blank lines - Dropped dt-bindings property as it is not needed for driver behavior - Add additional patch to allocate buffers via CMA memory for DSPs without dedicated FastRPC Compute Banks. Dylan Van Assche (2): misc: fastrpc: support complete DMA pool access to the DSP misc: fastrpc: use coherent pool for untranslated Compute Banks drivers/misc/fastrpc.c | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-)