daemon_linux_lvm2_lv_create (Daemon *daemon,
                             const gchar *group_uuid,
                             const gchar *name,
                             guint64 size,
                             guint num_stripes,
                             guint64 stripe_size,
                             guint num_mirrors,
                             gchar **options,
                             char *fstype,
                             char **fsoptions,
                             DBusGMethodInvocation *context)
{
  daemon_local_check_auth (daemon,
                           NULL,
                           "org.freedesktop.udisks.linux-lvm2",
                           "LinuxLvm2LVCreate",
                           TRUE,
                           daemon_linux_lvm2_lv_create_authorized_cb,
                           context,
                           9,
                           g_strdup (group_uuid),
                           g_free,
                           g_strdup (name),
                           g_free,
                           g_memdup (&size, sizeof (guint64)),
                           g_free,
                           GUINT_TO_POINTER (num_stripes),
                           NULL,
                           g_memdup (&stripe_size, sizeof (guint64)),
                           g_free,
                           GUINT_TO_POINTER (num_mirrors),
                           NULL,
                           g_strdupv (options),
                           g_strfreev,
                           g_strdup (fstype),
                           g_free,
                           g_strdupv (fsoptions),
                           g_strfreev);

  return TRUE;
}

daemon_linux_lvm2_lv_create (Daemon *daemon,
                             const gchar *group_uuid,
                             const gchar *name,
                             guint64 size,
                             guint num_stripes,
                             guint64 stripe_size,
                             guint num_mirrors,
                             gchar **options,
                             char *fstype,
                             char **fsoptions,
                             DBusGMethodInvocation *context)
{
  daemon_local_check_auth (daemon,
                           NULL,
                           "org.freedesktop.udisks.linux-lvm2",
                           "LinuxLvm2LVCreate",
                           TRUE,
                           daemon_linux_lvm2_lv_create_authorized_cb,
                           context,
                           9,
                           g_strdup (group_uuid),
                           g_free,
                           g_strdup (name),
                           g_free,
                           g_memdup (&size, sizeof (guint64)),
                           g_free,
                           GUINT_TO_POINTER (num_stripes),
                           NULL,
                           g_memdup (&stripe_size, sizeof (guint64)),
                           g_free,
                           GUINT_TO_POINTER (num_mirrors),
                           NULL,
                           g_strdupv (options),
                           g_strfreev,
                           g_strdup (fstype),
                           g_free,
                           g_strdupv (fsoptions),
                           g_strfreev);

  return TRUE;
}
