On Thu, 31 Oct 2024 09:36:28 +0000 Daniel Machon wrote: > > For a followup for both drivers -- you're mixing irqsave and bare > > spin_lock() here. The _irqsave/_irqrestore is not necessary, let's > > drop it. > > > > > + spin_lock(&sparx5->ptp_ts_id_lock); > > Hi Jakub, > > I agree it seems wrong to mix these. > > I just talked to Horatiu, and he mentioned posting a similar fix for the > lan966x driver some time ago [1]. Only this fix added > _irqsave/_irqrestore to the ptp_ts_id_lock - so basically the opposite > of what you are suggesting. Why do you think that the > _irqsave/_irqrestore is not necessary? Oh, I thought this is a real IRQ handler, not a threaded one. I haven't read the code to figure out whether ptp_ts_id_lock needs to be IRQ-safe, but in other places you lock if _irqsave so yes, let's irqsave here, too.