HP DriveGuard for Linux
=======================

GENERAL
-------
This is a program suite for supporting HP DriveGuard feature available
on many HP laptops.  It protects the unexpected harddisk damage by a
sudden impact on the machine by parking the HD head quickly after the
sensor detected the movement.  The disk-access after that is
prohibited for a certain time (2 seconds as default).  Then the daemon
re-enables the disk access.

This program works only on a machine with hp_accel kernel driver
running.  Check whether you have /dev/freefall file to see whether the
service is available or not.  The kernel driver should be available on
all recent 2.6 Linux kernel versions.

The package consists of the following software components:

 - DriveGuard daemon
 - DriveGuard applet

The daemon must be started as a system daemon.  It accesses
/dev/freefall device that is governed by hp_accel kernel driver.
A sample init script (for SUSE distro) is included in the package.

A desktop user can start DriveGuard applet.  It remains in the
taskbar and shows a notification when the drive is parked or
re-enabled.  A pulldown menu will appear by a right-click on the
applet icon.  The following menu items are available:

 - About: show the basic information of the applet
 - Quit: quit the applet
 - Pause/Start Protection: temporarily pause or re-start the HD
   protection.  This feature is useful, e.g. during a presentation.
   The state won't be saved at the next boot.
 - Setup: open a setup-dialog.  There you can turn on/off the
   DriveGuard service permanently.

The daemon setup is stored in /etc/hp-drive-guard-daemon.conf.  Some
items can be changed via the setup-dialog.

DESIGN
------
The daemon actually starts a sub-process to work as a "core".
The core part runs in a higher realtime-scheduler priority to get
notification from the device file and react as quickly as possible.

Another part of daemon communicates with user processes.  It transmits
notifications further to user applets when the core part gets
notified, and also updates the daemon setup changed by user.  The
communication is done over D-Bus.

The daemon also communicates with HAL or upower.  When the laptop is
running in battery mode and the lid is closed, it'll be switched to
"extended mode".  In this state, the disk head is parked for a longer
time, 20 seconds as default.  The timeout length can be changed via
the config file (or setup dialog).

LICENSE
-------
Distributed under GPL v2 or later.  See COPYRIGHT file for details.
