Lines Matching defs:stripe
56 devconfig_t **stripe);
64 devconfig_t **stripe);
69 devconfig_t **stripe);
85 * nbytes - the desired capacity of the stripe
92 * PURPOSE: Main layout driver for composing stripe volumes.
94 * Attempts to construct a stripe of size nbytes.
97 * build widest stripe possible across as many HBAs as possible.
102 * 1 - stripe across similar HBAs
106 * 2 - stripe within a single HBA
110 * 3 - stripe across all available disks on similar HBAs
114 * 4 - stripe across all available HBAs
118 * 5 - stripe across all available disks on all HBAs
122 * Each strategy tries to compose a stripe with the
126 * get allowed minimum number of stripe components
127 * get allowed maximum number of stripe components
131 * for (each HBA grouping) and (stripe not composed) {
133 * for (strategy[1,2,3]) and (stripe not composed) {
134 * compose stripe using HBAs in group
138 * if (stripe not composed) {
139 * for (strategy[4,5]) and (stripe not composed) {
140 * compose stripe using all HBAs
144 * if (stripe composed) {
145 * append composed stripe to results
176 devconfig_t *stripe = NULL;
199 * determine the min/max number of stripe components
212 (error == 0) && (stripe == NULL) && (iter != NULL);
221 (stripe == NULL) && (error == 0);
239 gettext(" -->Strategy 1: use 1 disk from %d-%d similar HBAs - stripe across HBAs\n"),
247 mincomp, NULL, &stripe);
264 gettext(" -->Strategy 2: use %d-%d disks from any single HBA - stripe within HBA\n"),
271 mincomp, maxcomp, &stripe);
288 gettext(" -->Strategy 3: use %d-%d disks from %d similar HBAs - stripe across HBAs\n"),
297 mincomp, NULL, &stripe);
326 if ((stripe == NULL) && (error == 0)) {
332 (stripe == NULL) && (error == 0);
350 gettext(" -->Strategy 4: use 1 disk from %d-%d available HBAs - stripe across any HBAs\n"),
359 mincomp, NULL, &stripe);
377 gettext(" -->Strategy 5: use %d-%d disks from %d available HBA - stripe across any HBAs\n"),
386 mincomp, NULL, &stripe);
401 if (stripe != NULL) {
404 if ((item = dlist_new_item(stripe)) == NULL) {
430 * devconfig_t **stripe)
433 * nbytes - desired stripe size
437 * composition may affect this stripe
440 * OUTPUT: stripe - pointer to a devconfig_t to hold resulting stripe
445 * PURPOSE: Helper to populate a stripe with the specified number of
450 * chosen for the stripe must not on the same disks as any
453 * If sufficient slice components can be found, the stripe
463 devconfig_t **stripe)
477 *stripe = NULL;
505 * each stripe component needs to be this size.
506 * Note that the stripe interlace doesn't need to be
508 * slice selected as a stripe component will be oversized
581 if ((error = assemble_stripe(request, comps, stripe)) == 0) {
611 * PURPOSE: Processes the input stripe request that specifies explicit
618 * The net size of the stripe is determined by the slice
621 * The stripe devconfig_t is assembled and appended to the
632 devconfig_t *stripe = NULL;
669 error = assemble_stripe(request, comps, &stripe);
673 if ((item = dlist_new_item(stripe)) == NULL) {
689 * dlist_t *othervols, devconfig_t **stripe)
692 * nbytes - desired stripe size
697 * composition may affect this stripe
700 * OUTPUT: stripe - pointer to a devconfig_t to hold resulting stripe
705 * PURPOSE: Attempt to compose a stripe of capacity nbytes, with
707 * The number of components in the stripe should be in the
710 * If a stripe can be composed, a pointer to it will be
711 * returned in the stripe devconfig_t.
724 devconfig_t **stripe)
728 *stripe = NULL;
730 for (; (error == 0) && (*stripe == NULL) && (max >= min); max--) {
732 request, nbytes, disks, max, othervols, stripe);
741 * int maxcomp, int mincomp, dlist_t **stripe)
745 * nbytes - the desired capacity for the stripe
746 * maxcomp - the maximum number of stripe components
747 * mincomp - the minimum number of stripe components
749 * OUTPUT: stripe - pointer to a stripe devconfig_t result
754 * PURPOSE: Layout function which compose a stripe of the desired size
757 * The number of components within the composed stripe will be
762 * available disks and total space sufficient for the stripe.
764 * If the stripe can be composed, a pointer to it is returned in
765 * the stripe devconfig_t *.
768 * while (more hbas and stripe not composed) {
774 * use # disks as max # of stripe components
775 * try to compose stripe
786 devconfig_t **stripe)
792 *stripe = NULL;
795 (iter != NULL) && (error == 0) && (*stripe == NULL);
814 min, NULL, stripe);
828 * devconfig_t **stripe)
833 * OUPUT: stripe - pointer to a devconfig_t to hold final stripe
838 * PURPOSE: Helper which creates and populates a stripe devconfig_t
842 * Determines the name of the stripe either from the request
845 * Sets the interlace for the stripe if a value is specified
854 devconfig_t **stripe)
860 if ((error = new_devconfig(stripe, TYPE_STRIPE)) == 0) {
861 /* set stripe name, use requested name if specified */
874 error = devconfig_set_name(*stripe, name);
878 error = devconfig_set_name(*stripe, name);
885 error = devconfig_set_stripe_interlace(*stripe, ilace);
896 error = devconfig_set_size_in_blocks(*stripe, nbytes/DEV_BSIZE);
902 devconfig_set_components(*stripe, comps);
904 free_devconfig(*stripe);
905 *stripe = NULL;
912 * Order the given stripe component list such that the number of
945 * INPUT: comps - pointer to a list of stripe components
946 * ilace - the expected stripe interlace in bytes
953 * PURPOSE: Helper which computes the usable size of a stripe taking
955 * libmeta uses: a stripe component's size is rounded down to
964 * stripe component slices and determines the smallest usable
967 * The usable stripe capacity is then that component capacity
1029 /* size of stripe = smallest component size * n components */