Re: device mapper target vs personality, how do you decide to pick one or the other?

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

 



Bryn and Mike Thankyou very much for your help. I have a dm target that now loads when the appropriate arguments are passed to dmcreate.

tnx!

johnu
________________________________________
From: dm-devel-bounces@xxxxxxxxxx [dm-devel-bounces@xxxxxxxxxx] on behalf of John Utz [John.Utz@xxxxxxx]
Sent: Monday, July 14, 2014 10:15 AM
To: Mike Snitzer
Cc: dm-devel@xxxxxxxxxx
Subject: Re:  device mapper target vs personality, how do you decide to pick one or the other?

Thankyou for the further clarification.

My apologies for not being clear about my end goal. Indeed, I do wish to do remapping because I am coding a ZAC simulator.
________________________________________
From: Mike Snitzer [snitzer@xxxxxxxxxx]
Sent: Friday, July 11, 2014 5:36 PM
To: John Utz
Cc: dm-devel@xxxxxxxxxx
Subject: Re: device mapper target vs personality, how do you decide to pick one or the other?

On Fri, Jul 11 2014 at  5:56pm -0400,
John Utz <John.Utz@xxxxxxx> wrote:

> Hi Mike
>
> tnx so much for the prompt response!
>
> sorry i wasnt clear enuf, example of the 'personality code' that i was
> writing about below.
...
> FOR EXAMPLE, here is a little bit of linear.c that contains it:
>
> static struct md_personality linear_personality =
> {
>       .name           = "linear",
>       .level          = LEVEL_LINEAR,
>       .owner          = THIS_MODULE,
>       .make_request   = linear_make_request,
>       .run            = linear_run,
>       .stop           = linear_stop,
>       .status         = linear_status,
>       .hot_add_disk   = linear_add,
>       .size           = linear_size,
> };
>
> static int __init linear_init (void)
> {
>       return register_md_personality (&linear_personality);
> }
>
> static void linear_exit (void)
> {
>       unregister_md_personality (&linear_personality);
> }

The above is MD raid code.  So what you're talking about are the
different MD raid personalities.

> > so, based on this speculation, i *think* i should be using the target
> > construct for the new device mapper module that i am currently
> > coding.
> >
> > am i correct?
>
> Probably.

The target construct is provided by DM.  You haven;t said what you're
looking to do but if it is remapping IO and has nothing to do with raid
then you'd probably want to develop a new DM target.

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel




[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux