** On Apr 10, Alexander Viro scribbled:
> > down(&info_mutex);
> > card =3D snd_info_find_card(dentry->d_inode->i_ino);
> > if (card =3D=3D NULL || card->proc_dir =3D=3D NULL) {
> > up(&info_mutex);
> > return NULL;
>=20
> ... which is (and was) totally broken. Just what is intended here?
> And BTW, what, it's YAFS?
ALSA uses /proc/asound/ directory for publishing its information. A bit less
strange idea than /dev/sndstat...=20
> > }
> > strcpy(tmp, card->id);
> > up(&info_mutex);
> > return lookup_dentry(tmp, base, follow);
> > }
>=20
> _That_ one is easy -
> static int snd_info_card_followlink(struct dentry *dentry, struct nameida=
ta *nd)
> {
> [same stuff, modulo the bug above]
> return vfs_follow_link(tmp, nd);
> }
To stay more in sync with the actual code, it should be:
return lookup_dentry(tmp, follow) - works, tested.
marek
--KsGdsel6WgEHnImy
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.1 (GNU/Linux)
Comment: For info see http://www.gnupg.org
iEYEARECAAYFAjjy6IsACgkQq3909GIf5ur5nQCffLmkUJsq6ILTXUh4lC7Yoj+p
EWcAn049Y2GuSV3QxfCrHDKcFLkR06Ee
=3OCs
-----END PGP SIGNATURE-----
--KsGdsel6WgEHnImy--
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/