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]
Date:	Tue, 23 Jan 2007 07:42:15 -0800
From:	David Brownell <david-b@...bell.net>
To:	Atsushi Nemoto <anemo@....ocn.ne.jp>
Cc:	linux-kernel@...r.kernel.org, hcegtvedt@...el.com, akpm@...l.org
Subject: Re: [PATCH 2.6.20-rc5] SPI: alternative fix for spi_busnum_to_master

On Monday 22 January 2007 5:10 pm, Atsushi Nemoto wrote:
> On Mon, 22 Jan 2007 14:12:02 -0800, David Brownell <david-b@...bell.net> wrote:
> > > Here is a revised version.  The children list of spi_master_class
> > > contains only spi_master class so we can just compare bus_num member
> > > instead of class_id string.
> > 
> > Looks just a bit iffy ... though, thanks for helping to finally
> > sort this out!
> 
> Well, so previous patch (which was checking class_id string) would be
> preferred?

No, with this rename support lurking, checking names becomes risky.


> > > +		cdev = class_device_get(cdev);
> > > +		if (!cdev)
> > > +			continue;
> > 
> > That "continue" case doesn't seem like it should be possible... but
> > at any rate, the "get" can be deferred until the relevent class
> > device is known, since that _valid_ handle can't disappear so long
> > as that semaphore is held.  And if you find the right device but
> > can't get a reference ... no point in continuing!
> > 
> > Something like a class_find_device() would be the best way to solve
> > this sort of problem, IMO.  But we don't have one of those.  :(
> 
> Indeed the check can be omitted.  Should I send a new patch just
> moving class_device_get() into "if (master->bus_num == bus_num)"
> block?

Yes, please.

 
> The crashing with udev is 2.6.20 regression so I wish this fixed very
> soon.  Thank you for review.

Agreed.

- Dave


 
> ---
> Atsushi Nemoto
> 
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ