lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Z9fSkxv_-mJnnXo4@black.fi.intel.com>
Date: Mon, 17 Mar 2025 09:43:15 +0200
From: Raag Jadav <raag.jadav@...el.com>
To: Greg KH <gregkh@...uxfoundation.org>
Cc: giometti@...eenne.com, andriy.shevchenko@...ux.intel.com,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1] pps: generators: tio: fix platform_set_drvdata()

On Mon, Mar 17, 2025 at 08:32:29AM +0100, Greg KH wrote:
> On Sat, Mar 15, 2025 at 07:01:40PM +0530, Raag Jadav wrote:
> > Set driver_data correctly and fix illegal memory access on driver reload.
> > 
> > Fixes: c89755d1111f ("pps: generators: Add PPS Generator TIO Driver")
> > Signed-off-by: Raag Jadav <raag.jadav@...el.com>
> > ---
> >  drivers/pps/generators/pps_gen_tio.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/drivers/pps/generators/pps_gen_tio.c b/drivers/pps/generators/pps_gen_tio.c
> > index 6c46b46c66cd..6e4a383957d9 100644
> > --- a/drivers/pps/generators/pps_gen_tio.c
> > +++ b/drivers/pps/generators/pps_gen_tio.c
> > @@ -230,7 +230,7 @@ static int pps_gen_tio_probe(struct platform_device *pdev)
> >  	hrtimer_init(&tio->timer, CLOCK_REALTIME, HRTIMER_MODE_ABS);
> >  	tio->timer.function = hrtimer_callback;
> >  	spin_lock_init(&tio->lock);
> > -	platform_set_drvdata(pdev, &tio);
> > +	platform_set_drvdata(pdev, tio);
> 
> What does reload have to do with this?  Either the data pointer is set
> to the expected type or not, so that it can work properly, which has
> nothing to do with when the device is unbound and then rebound (which is
> what I think you mean by reload?)

->remove() is the only user of driver_data here.

> So I think your changelog needs a lot of work here, as it's not really
> explaining what is happening properly.

Sure, will update.

Raag

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ