[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Bug#78011: storeio (in)activation (was: Re: CDROM lock)

From: Marcus Brinkmann
Subject: Bug#78011: storeio (in)activation (was: Re: CDROM lock)
Date: Mon, 19 Feb 2001 12:11:50 +0100
User-agent: Mutt/1.3.12i

On Sun, Feb 18, 2001 at 06:50:30PM -0500, Roland McGrath wrote:
> > Well, the patch below does just that, but it doesn't work. It seems that
> > opening with STORE_INACTIVE is not supported. 
> Ok.  Well, if the changes to storeio succeed in making that libstore calls
> we think are right (and in particular deactivating the store when peropens
> goes to zero on a close), then you can check those changes in before we
> worry about how libstore should be fixed.  The count you added should be in
> struct dev, not a global variable, and locked by the existing mutex there.
> But other than that, it looks good so you can check it in with that cleanup.

Ah yes, that's much better.

> I think I agree with you about the libstore changes.  But it is a decent
> interim solution to just leave libstore as it is and change storeio as you
> have.  Then the store gets activated when storeio first starts up, but is
> properly deactivated after the first open+close.  

It gets, but because the way the code is written, dopen in libstore will be
run twice, and one port to the device gets leaked. This lost port will block
the drive until storeio is killed. (A workaround might be to check in dopen
if the drive was already opened, or to check in store_set_flags if the flag
is already set, likewise for clear).


reply via email to

[Prev in Thread] Current Thread [Next in Thread]