Eject and Unplug

Hello,

Could somebody please explain the difference between Eject and Unplug ?

Thanks
Puja

Different bits turned on in the DEVICE_CAPABILITIES struct returned in
response to IRP_MN_QUERY_CAPABILITIES :slight_smile:

If a PDO sets the EjectSupported bit, then it may receive an IRP_MN_EJECT
IRP after the last IRP_MN_REMOVE IRP. The device is expected to
physically remove itself from its enclosure, whereas Removable simply
means the user can unplug it while the host machine is online,
preferably after a controlled remove process (IRP_MN_REMOVE).

If a device is merely Removable, one can nonetheless call
CM_Request_Device_Eject() from user-mode to initiate removal. It
just won’t get an eject IRP at the end.


Dave Cox
Hewlett-Packard Co.
HPSO/SSMO (Santa Barbara)
https://ecardfile.com/id/Dave+Cox

-----Original Message-----
From: xxxxx@usa.net [mailto:xxxxx@usa.net]
Sent: Thursday, May 25, 2000 12:45 PM
To: NT Developers Interest List
Subject: [ntdev] Eject and Unplug

Hello,

Could somebody please explain the difference between Eject and Unplug ?

Thanks
Puja


You are currently subscribed to ntdev as: david_cox2@hp.com
To unsubscribe send a blank email to $subst(‘Email.Unsub’)

From:
Sent: Thursday, May 25, 2000 7:44 PM

> Hello,
>
> Could somebody please explain the difference between Eject and Unplug ?

“Unplugging” implies that the user physically disconnects a device
attached to the computer. This can occur in a controlled (computer asked to
“allow” the unplugging first) or uncontrolled (computer not asked) manner.
Imagine a user frantically yanking out the cord for their USB camera because
Elvis just walked by their cubicle (this would be an example of the
uncontrolled case).

“Ejecting” means that the computer releases something that has been
inserted into it or it inserted into (media, port replicator, etc.) usually
only in an automatic, controlled manner. For example, imagine a motorized
CD-ROM drawer opening or PC Card popping out after the user has somehow
issued the appropriate “eject” command.

- Matt