Print this page
NEX-14754 sd: get rid of ssd cruft
Reviewed by: Dan Fields <dan.fields@nexenta.com>
Reviewed by: Evan Layton <evan.layton@nexenta.com>
Reviewed by: Rick McNeal <rick.mcneal@nexenta.com>
Revert "Revert "6602 lofi should support labeled devices""
This reverts commit 21386c8bd8477810b291eee22e08f1382e70cdf3.
Revert "6602 lofi should support labeled devices"
This reverts commit 406fc5100dac8d225a315a6def6be8d628f34e24.
OS-92 NexentaStor 4.0.1-PASSIV-12022013: Cannot mount root after install

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/sys/cmlb.h
          +++ new/usr/src/uts/common/sys/cmlb.h
↓ open down ↓ 10 lines elided ↑ open up ↑
  11   11   * and limitations under the License.
  12   12   *
  13   13   * When distributing Covered Code, include this CDDL HEADER in each
  14   14   * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  15   15   * If applicable, add the following below this CDDL HEADER, with the
  16   16   * fields enclosed by brackets "[]" replaced with your own identifying
  17   17   * information: Portions Copyright [yyyy] [name of copyright owner]
  18   18   *
  19   19   * CDDL HEADER END
  20   20   */
       21 +
  21   22  /*
  22      - * Copyright 2016 Toomas Soome <tsoome@me.com>
  23   23   * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  24   24   * Use is subject to license terms.
  25   25   */
  26   26  
       27 +/*
       28 + * Copyright 2016 Toomas Soome <tsoome@me.com>
       29 + * Copyright 2017 Nexenta Systems, Inc.
       30 + */
       31 +
  27   32  #ifndef _SYS_CMLB_H
  28   33  #define _SYS_CMLB_H
  29   34  
  30   35  #ifdef  __cplusplus
  31   36  extern "C" {
  32   37  #endif
  33   38  
  34   39  #include <sys/dktp/fdisk.h>
       40 +#include <sys/sunddi.h>
  35   41  
  36   42  /*
  37   43   * structure used for getting phygeom and virtgeom from target driver
  38   44   */
  39   45  typedef struct cmlb_geom {
  40   46          unsigned int    g_ncyl;
  41   47          unsigned short  g_acyl;
  42   48          unsigned short  g_nhead;
  43   49          unsigned short  g_nsect;
  44   50          unsigned short  g_secsize;
↓ open down ↓ 277 lines elided ↑ open up ↑
 322  328   *      EINVAL  invalid arg, unsupported tg_ops version
 323  329   *
 324  330   */
 325  331  int
 326  332  cmlb_attach(dev_info_t *devi, cmlb_tg_ops_t *tgopsp, int device_type,
 327  333      boolean_t is_removable, boolean_t is_hotpluggable, char *node_type,
 328  334      int alter_behavior, cmlb_handle_t cmlbhandle, void *tg_cookie);
 329  335  
 330  336  
 331  337  /*
      338 + * cmlb_workaround_off_by_one:
      339 + *
      340 + *      Enables the workaround for the ancient off-by-one bug in sd.
      341 + *      See comment preceding cmlb_attach().
      342 + *
      343 + * Arguments
      344 + *      cmlbhandle      cmlb handle associated with device.
      345 + *
      346 + *
      347 + * Notes:
      348 + *      This should only be called by sd_unit_attach(), and only before
      349 + *      validating the label for the first time.
      350 + *
      351 + * Return values:
      352 + *      None.
      353 + */
      354 +void
      355 +cmlb_workaround_off_by_one(cmlb_handle_t cmlbhandle);
      356 +
      357 +/*
 332  358   * cmlb_validate:
 333  359   *
 334  360   *      Validates label.
 335  361   *
 336  362   * Arguments
 337  363   *      cmlbhandle      cmlb handle associated with device.
 338  364   *
 339  365   *      int             flags
 340  366   *                      currently used for verbosity control.
 341  367   *                      CMLB_SILENT is the only current definition for it
↓ open down ↓ 254 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX