A GEOM provider is the front gate at which a geom offers service. A provider is "a disk-like thing which appears in /dev" [en] a logical disk in other words. All providers have three main properties: name, sectorsize and size.
The g_new_providerf function creates a new provider on given geom gp. The name of the provider, which will appear as device in devfs(5), is created in a printf 3 -like way from the rest of the arguments. After creation, the caller has to set the providers mediasize and sectorsize, as well as other desired initializations, and then call g_error_provider to reset the providers error, which is initially set to ENXIO.
The g_destroy_provider function destroys the given provider, cancels all related pending events and removes the corresponding devfs entry.
The g_error_provider function is used to set the providers error value. If set to a nonzero, all I/O requests will be denied, as well as increasing its access count will not be possible (error error will be returned).