Re: >256 ptys (previous subject line was garbage)

david parsons (o.r.c@p.e.l.l.p.o.r.t.l.a.n.d.o.r.u.s)
8 Jun 1998 16:30:16 -0700


In article <linux.kernel.199806082137.RAA00400@rsts-11.mit.edu>,
<tytso@mit.edu> wrote:
>
> I am not familiar with the reasons for using major/minor-pair for
> locking so I don't know if another solution is feasable. Do you have
> any pointers for additional reading? :-)
>
>The problem is things like /dev/modem being a symlink (or perhaps even a
>hard link) to /dev/ttyS0. So it would be useful to use a lockfile that
>includes the major and minor device number, in addition to using a
>lockfile that is based on the device name. The basic idea is that
>people want to have different device names to refer to the same device,
>so we need to lock based the major/minor devices.

What about just using flock() instead of writing locks to the
lockdirectory of the year? About the only reason I can think
of for using the lockdirectory of the year is for applications
that wish to root through the process table to identify who's
got the device open, and that's a good use for /proc/locks.

Major/minor locks are a solution in search of a problem; is it
reasonable for the kernel to accomodate them?

____
david parsons \bi/ flock(), at least in libc4.8.0, works very nicely
\/ for me.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu