Linux on Apple ARM platform development
 help / color / mirror / Atom feed
From: Mark Kettenis <mark.kettenis@xs4all.nl>
To: Janne Grunau <j@jannau.net>
Cc: u-boot@lists.u-boot-project.org, asahi@lists.linux.dev,
	kettenis@openbsd.org, sven@kernel.org, neil.armstrong@linaro.org,
	bmeng.cn@gmail.com, trini@konsulko.com, fberder@outlook.fr,
	j@jannau.net
Subject: Re: [PATCH 4/4] nvme: apple: Drop the PRP null check chicken bit
Date: Mon, 07 Sep 2026 23:24:04 +0200	[thread overview]
Message-ID: <87pkyosqkr.fsf@bloch.sibelius.xs4all.nl> (raw)
In-Reply-To: <20260904-apple-nvme-fwabi-v1-4-f7ede661c469@jannau.net> (message from Janne Grunau on Fri, 04 Sep 2026 21:22:42 +0200)

> From: Janne Grunau <j@jannau.net>
> Date: Fri, 04 Sep 2026 21:22:42 +0200
> 
> Now that we program the DMA direction correctly the NULL check that used
> to make commands fail passes. Another side effect of this bit was that
> non-align buffers on the admin queue were silently allowed and that's
> been fixed now as well and we this don't need this chicken bit anymore.
> More importantly, starting with the firmware installed with macOS 15,
> which is required for M4 but can also be installed on the previous SoCs,
> the controller no longer exposes this control register and any access
> SErrors instead. Just drop the write entirely.
> 
> Based on Linux kernel commit 8ce883fd068b ("nvme-apple: Drop the PRP
> null check chicken bit").

Reviewed-by: Mark Kettenis <kettenis@openbsd.org>

> Link: https://lore.kernel.org/asahi/20260806-b4-nvme-fwabi-v1-6-bde19ce8db04@kernel.org/
> Fixes: 50333c94f2de ("nvme: apple: Add driver for Apple NVMe storage controller")
> Signed-off-by: Janne Grunau <j@jannau.net>
> ---
>  drivers/nvme/nvme_apple.c | 5 -----
>  1 file changed, 5 deletions(-)
> 
> diff --git a/drivers/nvme/nvme_apple.c b/drivers/nvme/nvme_apple.c
> index 54821f80c81..948a56e518b 100644
> --- a/drivers/nvme/nvme_apple.c
> +++ b/drivers/nvme/nvme_apple.c
> @@ -26,8 +26,6 @@
>  #define ANS_BOOT_STATUS		0x01300
>  #define  ANS_BOOT_STATUS_OK	0xde71ce55
>  #define ANS_MODESEL		0x01304
> -#define ANS_UNKNOWN_CTRL	0x24008
> -#define  ANS_PRP_NULL_CHECK	(1 << 11)
>  #define ANS_LINEAR_SQ_CTRL	0x24908
>  #define  ANS_LINEAR_SQ_CTRL_EN	(1 << 0)
>  #define ANS_ASQ_DB		0x2490c
> @@ -257,9 +255,6 @@ static int apple_nvme_probe(struct udevice *dev)
>  	writel(((ANS_MAX_QUEUE_DEPTH << 16) | ANS_MAX_QUEUE_DEPTH),
>  	       priv->base + ANS_MAX_PEND_CMDS_CTRL);
>  
> -	writel(readl(priv->base + ANS_UNKNOWN_CTRL) & ~ANS_PRP_NULL_CHECK,
> -	       priv->base + ANS_UNKNOWN_CTRL);
> -
>  	strcpy(priv->ndev.vendor, "Apple");
>  
>  	writel((ANS_NVMMU_TCB_SIZE / ANS_NVMMU_TCB_PITCH) - 1,
> 
> -- 
> 2.55.0
> 
> 

  reply	other threads:[~2026-09-07 21:24 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-04 19:22 [PATCH 0/4] Apple NVMe fixes for macOS 15+ firmware / M4 support Janne Grunau
2026-09-04 19:22 ` [PATCH 1/4] nvme: apple: Don't set a DMA direction for commands without a data transfer Janne Grunau
2026-09-07 21:21   ` Mark Kettenis
2026-09-04 19:22 ` [PATCH 2/4] nvme: apple: Never set the opcode in the NVMMU TCB Janne Grunau
2026-09-07 21:21   ` Mark Kettenis
2026-09-04 19:22 ` [PATCH 3/4] nvme: apple: Add WARN_ON_ONCE for non page-aligned admin queue buffers Janne Grunau
2026-09-07 21:23   ` Mark Kettenis
2026-09-04 19:22 ` [PATCH 4/4] nvme: apple: Drop the PRP null check chicken bit Janne Grunau
2026-09-07 21:24   ` Mark Kettenis [this message]
2026-09-10 12:44 ` [PATCH 0/4] Apple NVMe fixes for macOS 15+ firmware / M4 support Neil Armstrong
2026-09-10 13:11   ` Mark Kettenis
2026-09-10 13:14 ` Neil Armstrong

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87pkyosqkr.fsf@bloch.sibelius.xs4all.nl \
    --to=mark.kettenis@xs4all.nl \
    --cc=asahi@lists.linux.dev \
    --cc=bmeng.cn@gmail.com \
    --cc=fberder@outlook.fr \
    --cc=j@jannau.net \
    --cc=kettenis@openbsd.org \
    --cc=neil.armstrong@linaro.org \
    --cc=sven@kernel.org \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.u-boot-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox