All of lore.kernel.org
 help / color / mirror / Atom feed
From: "W. Michael Petullo" <mike@flyn.org>
To: linux-kernel@vger.kernel.org
Subject: Dm-crypt, device-mapper and sysfs
Date: Mon, 1 Nov 2004 13:52:00 -0600	[thread overview]
Message-ID: <20041101195200.GA11321@imp.flyn.org> (raw)

I am interested in allowing the Hardware Abstraction Layer (HAL) to
interface with dm-crypt devices.  I would like to see hald have the
ability to automatically mount removable encrypted drives when they are
plugged in.

I have a working prototype of this idea except for one issue.
Currently, dm-crypt registers its managed devices in the kernel's
sysfs.  This is good.  However, unlike most of the devices in
/sys, dm-crypt devices don't have a link named device.  For most
devices, this link specifies the bus the device is connected to.
On my iBook, for example, /sys/block/hda/device points to
/sys/devices/pci0002:02/0002:02:0d.0/ide0/0.0.  This is my IDE bus.

Hald expects to find a link like this when it is building its device tree.

I've discussed this issue on the dm-crypt mailing list and Christophe
thinks this is a more general device-mapper issue.  So I don't put words
in his mouth, here is what he said:

> dm-crypt is a device-mapper target, it doesn't do any sysfs interaction.
> There were some plans, even patches, to export more device-mapper
> functionality into sysfs. Besides, a mapped device can consist of
> several other devices and different targets. cryptsetup has the ability
> to query an existing device, it will tell you if it is a "valid
> cryptsetup'ed device". Also there a are plans to put some metadata into
> the first blocks of the device so that it can be automatically
> recognized as encrypted device.

So my question is this:

Should the device-mapper driver be modified to provide a device link?
If so, what should it point to?

-- 
Mike

:wq

                 reply	other threads:[~2004-11-02  5:39 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20041101195200.GA11321@imp.flyn.org \
    --to=mike@flyn.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.