lkml.org 
[lkml]   [2008]   [Sep]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: UIO device name
On Wed, Sep 24, 2008 at 11:21:33AM +0200, Joakim Tjernlund wrote:
> As far as I can see there isn't a way to name the /dev/uio%d device file
> to something more useful, is that so?
> I would like to name the device file from within the kernel so I can
> find the correct device from userspace.
> The very least is to control the minor(%d) number.
>
You have a couple of options for this:

- the 'name' sysfs entry for each of the uio devices, which
corresponds to the uio device name.
- extracting the relevant data from things like 'lsuio'.
- hooking in the pretty mame through udev to create an alias.

All of the information you need is available for userspace to play with,
and you want to be relying on the device name itself, not the minor
number (where you have no gaurantee of the ordering).

Documentation/DocBook/uio-howto.tmpl also has some more information on
what sort of information is exposed.


\
 
 \ /
  Last update: 2008-09-24 11:39    [W:1.084 / U:0.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site