mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Robert Marko <robert.marko@sartura.hr>
Cc: daniel.machon@microchip.com, andrew@lunn.ch,
	hkallweit1@gmail.com, linux@armlinux.org.uk, davem@davemloft.net,
	edumazet@google.com, pabeni@redhat.com,
	vadim.fedorenko@linux.dev, horatiu.vultur@microchip.com,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	luka.perkov@sartura.hr
Subject: Re: [PATCH net] net: phy: micrel: always set shared->phydev for LAN8814
Date: Thu, 23 Oct 2025 07:12:59 -0700	[thread overview]
Message-ID: <20251023071259.77076fd4@kernel.org> (raw)
In-Reply-To: <20251021132034.983936-1-robert.marko@sartura.hr>

On Tue, 21 Oct 2025 15:20:26 +0200 Robert Marko wrote:
> Currently, during the LAN8814 PTP probe shared->phydev is only set if PTP
> clock gets actually set, otherwise the function will return before setting
> it.
> 
> This is an issue as shared->phydev is unconditionally being used when IRQ
> is being handled, especially in lan8814_gpio_process_cap and since it was
> not set it will cause a NULL pointer exception and crash the kernel.
> 
> So, simply always set shared->phydev to avoid the NULL pointer exception.
> 
> Fixes: b3f1a08fcf0d ("net: phy: micrel: Add support for PTP_PF_EXTTS for lan8814")
> Signed-off-by: Robert Marko <robert.marko@sartura.hr>

Hopefully I'm not misunderstanding the situation, but since we're
considering taking the other patchset via net-next I'll apply
already this to prevent crashes in net..

  parent reply	other threads:[~2025-10-23 14:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-21 13:20 Robert Marko
2025-10-21 13:32 ` Andrew Lunn
2025-10-22  7:19   ` Horatiu Vultur
2025-10-23 14:12 ` Jakub Kicinski [this message]
2025-10-23 14:16   ` Robert Marko
2025-10-23 14:30 ` patchwork-bot+netdevbpf

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=20251023071259.77076fd4@kernel.org \
    --to=kuba@kernel.org \
    --cc=andrew@lunn.ch \
    --cc=daniel.machon@microchip.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=hkallweit1@gmail.com \
    --cc=horatiu.vultur@microchip.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=luka.perkov@sartura.hr \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=robert.marko@sartura.hr \
    --cc=vadim.fedorenko@linux.dev \
    /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

Powered by JetHome