From: Greg KH <greg@kroah.com>
To: linux-hotplug@vger.kernel.org
Subject: Re: Finding sysfs mount point
Date: Fri, 29 Apr 2005 04:48:46 +0000 [thread overview]
Message-ID: <20050429044846.GA27385@kroah.com> (raw)
In-Reply-To: <d4rmhh$vjk$1@sea.gmane.org>
On Thu, Apr 28, 2005 at 05:08:02PM -0500, Ian Pilcher wrote:
> I'm trying to write a script (invoked via a PROGRAM key) to find the
> interface number of a USB serial port. (See my post in the "udev: rules
> using multiple sysfs directories" thread for the reason why.)
>
> To do this I need to look as sysfs. What's the best way to figure out
> where it's mounted?
cat /proc/mounts | grep sysfs | cut -f 2 -d " "
works for me. I think there's a glibc function to retrieve this too.
> Also, is it safe to rely on the contents of DEVPATH to find a symbolic
> link to the device?
Yes, that's what it is there for :)
thanks,
greg k-h
-------------------------------------------------------
SF.Net email is sponsored by: Tell us your software development plans!
Take this survey and enter to win a one-year sub to SourceForge.net
Plus IDC's 2005 look-ahead and a copy of this survey
Click here to start! http://www.idcswdc.com/cgi-bin/survey?id\x105hix
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
Linux-hotplug-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
next prev parent reply other threads:[~2005-04-29 4:48 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-04-28 22:08 Finding sysfs mount point Ian Pilcher
2005-04-29 4:48 ` Greg KH [this message]
2005-04-29 7:09 ` Christian Bornträger
2005-05-04 17:51 ` Nico -telmich- Schottelius
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=20050429044846.GA27385@kroah.com \
--to=greg@kroah.com \
--cc=linux-hotplug@vger.kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).