From patchwork Fri Feb 24 06:49:44 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Asahi Lina X-Patchwork-Id: 61138 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:5915:0:0:0:0:0 with SMTP id v21csp748742wrd; Thu, 23 Feb 2023 23:06:55 -0800 (PST) X-Google-Smtp-Source: AK7set97lBIwhFyDrbW8Fcajbrx3o4l2vKCCLxe4K+qk+bzm+/OGW0Vxh/pVSOieGAIzXck3Ofkg X-Received: by 2002:a17:906:9bec:b0:8b2:fa6d:45e6 with SMTP id de44-20020a1709069bec00b008b2fa6d45e6mr23429055ejc.2.1677222414958; Thu, 23 Feb 2023 23:06:54 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1677222414; cv=none; d=google.com; s=arc-20160816; b=iCm+rH2t663ftqQqgJk0l98ub/IT2976J1KrKK0QpxF/mCpkeW5Eq1HsfMlxfHow6l GV30VrZDOABieHDhjpmCy76uhbnXTupSnjgvYAxjNoUyZfeo+OetioO1VKD+twWU6AQR AOL+AErgzKtDbT1HANMWdqJMKXwbq8kYJL2PdGJYaGawlsTsks7Fv+0stQg3KNMHd0RH 1a93irQwL41+22uV98yXMW4Nq3TFJ7GfG/R9j5vN9rv6330icGTOCDi3d5GNEl5DwJyA JpvN6fB5iPQE5wh92YAPF6q1FUaUXPy2PHKMDFZGGXhFqobRtB8h0Wb7wYBk9ouqpR+G ZMxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:message-id:content-transfer-encoding :mime-version:subject:date:from:dkim-signature; bh=Xd1Pq9LxQycZEB+rxNMoOXCym9xstA2tApx77gJv5vo=; b=YCW5AKS2xdVyTgVIaiEGQQhXd0+JJaGJTP9iGRaXl/RSN46LK9Z3cNRDM83m5V90WQ WMjvAztlrZ2GidBv9eVO+AgtwTDML4kqT+fuNdElFwBCDvHKULD8aCxZfa/x4V9Ji47O HzjMkhANNmjzRLfRTArLs+aUeQT67Y6OE6YuphN2BcEOFJ0zaWn+I20NU3Nu8hgh2RAI f+qeA1uj4D9oHJpPMO6ip4xdkM1CDvgsSobua7seny3vAuTsp5NUQWcZrud2fpFOKY/T W20Nq0EBxC/ojepw8M9kccg9wLJO+GBncpWRCmbWWvyLoPwo7+7001R0YpD//e9ZaSjA HmqQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@asahilina.net header.s=default header.b=RJNC2gX2; 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=asahilina.net Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id eq4-20020a170907290400b008dc76bf3a69si10351685ejc.735.2023.02.23.23.06.31; Thu, 23 Feb 2023 23:06:54 -0800 (PST) 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=@asahilina.net header.s=default header.b=RJNC2gX2; 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=asahilina.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229609AbjBXGuF (ORCPT + 99 others); Fri, 24 Feb 2023 01:50:05 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44758 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229562AbjBXGuD (ORCPT ); Fri, 24 Feb 2023 01:50:03 -0500 Received: from mail.marcansoft.com (marcansoft.com [212.63.210.85]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 27A912386B for ; Thu, 23 Feb 2023 22:50:01 -0800 (PST) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: linasend@asahilina.net) by mail.marcansoft.com (Postfix) with ESMTPSA id DDC724206F; Fri, 24 Feb 2023 06:49:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=asahilina.net; s=default; t=1677221398; bh=XEjX9AY/rxbyfPg1iE4VKDJGbOP+C/8aCuR0EDho4L0=; h=From:Date:Subject:To:Cc; b=RJNC2gX2MTkdFFrlC2XQ1+QOCIDwewtCU9rFAbNyqdbstuuKPcoGknHHgmWYl3JXT ffqH7j6PQz7v8fh0QNQS5odDEY+5+SfD71x5uba9eldJvea0aOhZPs9SwcktTGMOxh vM/wIgPK/23P4cGgWTS1wFSLG3/RHpvynTYQ3rK8kfS0EnbObYpKi0rOgqS3FDCzcB faLlt8QSxD+AZO+EfCkkjDNNYFU2UepDqpioFa1b563VtB5k3bLj1eMDGmtGqiKVUt laV1oK4GHQTxci+yRHsfsZwlVUyc67A2CNYb6Gx83CAv2zjRh2NwNKW08YBBQgjkVR nH/QMAotQYoGA== From: Asahi Lina Date: Fri, 24 Feb 2023 15:49:44 +0900 Subject: [PATCH] soc: apple: rtkit: Fix buffer address field width MIME-Version: 1.0 Message-Id: <20230224-gpu-up-rtkit-v1-1-671178cb2a5e@asahilina.net> X-B4-Tracking: v=1; b=H4sIAAde+GMC/x2NwQrCMBBEf6Xs2cU2Fgz+inhI4rZdhBh2k1II/ XcTj29mHlNBSZgUHkMFoZ2Vv7HBdBkgbC6uhPxuDGY0t9GYGddUsCSU/OGMy+zDZOlug3XQFO+ U0IuLYetS216laMae9z4JLXz8756v8/wBgXTYKH4AAAA= To: Hector Martin , Sven Peter , Alyssa Rosenzweig Cc: asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Asahi Lina X-Mailer: b4 0.12.0 X-Developer-Signature: v=1; a=ed25519-sha256; t=1677221396; l=994; i=lina@asahilina.net; s=20230221; h=from:subject:message-id; bh=XEjX9AY/rxbyfPg1iE4VKDJGbOP+C/8aCuR0EDho4L0=; b=2cGAkzXmm2kGa9fJLiypOR7qW7WO91eNDpFnITNoCLa72VF/iKWxb6QTZ6LDnRDpYw6LVm5hx +zxE9TPOBR0DEpl2fCyeB4hC+F6L8aBXAygukJSxy5swsiuQeGdX9qh X-Developer-Key: i=lina@asahilina.net; a=ed25519; pk=Qn8jZuOtR1m5GaiDfTrAoQ4NE1XoYVZ/wmt5YtXWFC4= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1758695170995279716?= X-GMAIL-MSGID: =?utf-8?q?1758695170995279716?= The buffer address field is missing two bits. This matters for the GPU, which uses upper-half 64-bit addresses on the ASC and those get sign extended from the mailbox message field, so the right number of high bits need to be set. Signed-off-by: Asahi Lina Reviewed-by: Sven Peter --- drivers/soc/apple/rtkit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- base-commit: 83f978b63fa7ad474ca22d7e2772c5988101c9bd change-id: 20230224-gpu-up-rtkit-f4bc18e78c8a Thank you, ~~ Lina diff --git a/drivers/soc/apple/rtkit.c b/drivers/soc/apple/rtkit.c index 35ec35aa500d..a02a44a745f6 100644 --- a/drivers/soc/apple/rtkit.c +++ b/drivers/soc/apple/rtkit.c @@ -55,7 +55,7 @@ enum { #define APPLE_RTKIT_BUFFER_REQUEST 1 #define APPLE_RTKIT_BUFFER_REQUEST_SIZE GENMASK_ULL(51, 44) -#define APPLE_RTKIT_BUFFER_REQUEST_IOVA GENMASK_ULL(41, 0) +#define APPLE_RTKIT_BUFFER_REQUEST_IOVA GENMASK_ULL(43, 0) #define APPLE_RTKIT_SYSLOG_TYPE GENMASK_ULL(59, 52)