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

Re: Bug#28383: Ejecting PCMCIA cards at suspend time



Avery Pennarun <apenwarr@worldvisions.ca> wrote:

> On Wed, Oct 21, 1998 at 05:36:53PM +0200, sam@debian.org wrote:

> > On my Toshiba laptop, as on many others, using "apm -s" with PCMCIA
> > cards inserted will cause the machine to freeze. It would be great if
> > apmd was setup so that a card "ejection" took place (using cardctl)
> > if cardmgr is running at this time (using a wrapper script for
> > example to check at this time if cardmgr is up).

> Yes, that would be useful.  You can add scripts to do it in
> /etc/apm/suspend.d and resume.d.  I think these scripts would be better
> included in the PCMCIA packages than the apmd package, though.

> Does anyone have any comments on this?

Not all controllers or cards have trouble suspending.  I can add the
scripts, but I they should be optional.  That is, cardctl eject and
insert should not be performed by default, but the pcmcia-cs postinst
script should ask the following question:

	If you use advanced power management (available in the apmd
	package), your PCMCIA cards will automatically be suspended with
	your system.  This however has been known to cause problems.
	Some drivers, notably the PCMCIA SCSI drivers, cannot recover
	from a suspend/resume cycle and suspending PCMCIA on some laptops
	has been known to cause the system to freeze.

	To prevent this, apmd can be configured to automatically shut
	down all PCMCIA drivers (equivalent to physically ejecting all
	cards) prior to entering suspend mode.	This will, of course,
	disrupt all services provided by the PCMCIA cards when this
	occurs, which might not always be desirable.

	Do you want apmd to automatically shut down all PCMCIA cards
	before entering suspend mode?  (If you have a PCMCIA SCSI card,
	you probably should answer y.) [n]

If the system administrator answers yes, then the postinst script will
enable the /etc/apm/suspend.d and resume.d scripts.

Does anyone know of a good way for pcmcia-cs to provide these scripts
and optionally activate them in the postinst script?

Brian


Reply to: