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

Re: [dm-devel] if i create a new dm target type, do i need to add its init to the _inits[] and its exit to the _exits[]?



Ah. Makes sense.
tnx!
johnu
________________________________________
From: Mike Snitzer [snitzer redhat com]
Sent: Wednesday, May 07, 2014 6:09 AM
To: John Utz
Cc: dm-devel redhat com
Subject: Re: if i create a new dm target type, do i need to add its init to the _inits[] and its exit to the _exits[]?

On Wed, May 07 2014 at 12:45am -0400,
John Utz <John Utz wdc com> wrote:

> Hello;
>
> While looking thru dm.c trying to figure out how to add new target
> specific errors and sense codes I came across the following arrays:
>
> static int (*_inits[])(void) __initdata = {
>         local_init,
>         dm_target_init,
>         dm_linear_init,
>         dm_stripe_init,
>         dm_io_init,
>         dm_kcopyd_init,
>         dm_interface_init,
>         dm_statistics_init,
> };
>
> static void (*_exits[])(void) = {
>         local_exit,
>         dm_target_exit,
>         dm_linear_exit,
>         dm_stripe_exit,
>         dm_io_exit,
>         dm_kcopyd_exit,
>         dm_interface_exit,
>         dm_statistics_exit,
> };
>
>
> What are the rules for what goes in to these? I don't see every dm-*
> target listed in these and i am curious as to what are the differences
> between what goes into these arrays and what does not.

These are only for the targets and services provided by the DM core
(dm-mod.ko went built as a module).


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