|
NAMEg_new_providerf ,
g_destroy_provider ,
g_error_provider —
GEOM providers management
SYNOPSIS#include <geom/geom.h>
struct g_provider *
void
void
DESCRIPTIONA GEOM provider is the front gate at which a geom offers service. A provider is “a disk-like thing which appears in /dev” – a logical disk in other words. All providers have three main properties: name, sectorsize and size.The The The RESTRICTIONS/CONDITIONSg_new_provider ():
RETURN VALUESTheg_new_providerf () function returns a pointer to the
newly created provider.
EXAMPLESCreate an example provider, set its parameters and make it usable.struct g_provider * create_example_provider(struct g_geom *gp) { struct g_provider *pp; g_topology_lock(); pp = g_new_providerf(gp, "example_provider"); g_topology_unlock(); pp->mediasize = 65536; pp->sectorsize = 512; g_error_provider(pp, 0); return (pp); } SEE ALSOgeom(4), DECLARE_GEOM_CLASS(9), g_access(9), g_attach(9), g_bio(9), g_consumer(9), g_data(9), g_event(9), g_geom(9), g_provider_by_name(9), g_wither_geom(9)AUTHORSThis manual page was written by Pawel Jakub Dawidek <pjd@FreeBSD.org>.
Visit the GSP FreeBSD Man Page Interface. |