Print this page
4782 usba shouldn't abuse ddi_get_time(9f)
Reviewed by: Robert Mustacchi <rm@joyent.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/sys/usb/hubd/hubdvar.h
          +++ new/usr/src/uts/common/sys/usb/hubd/hubdvar.h
↓ open down ↓ 14 lines elided ↑ open up ↑
  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 2009 Sun Microsystems, Inc.  All rights reserved.
  23   23   * Use is subject to license terms.
  24   24   */
       25 +/*
       26 + * Copyright 2014 Nexenta Systems, Inc.  All rights reserved.
       27 + */
  25   28  
  26   29  #ifndef _SYS_USB_HUBDVAR_H
  27   30  #define _SYS_USB_HUBDVAR_H
  28   31  
  29   32  
  30   33  #ifdef  __cplusplus
  31   34  extern "C" {
  32   35  #endif
  33   36  
  34   37  #include <sys/sunndi.h>
↓ open down ↓ 49 lines elided ↑ open up ↑
  84   87          /* this is the bit mask of the power states that device has */
  85   88          uint8_t         hubp_pwr_states;
  86   89  
  87   90          int             hubp_busy_pm;   /* device busy accounting */
  88   91  
  89   92          /* wakeup and power transition capabilities of an interface */
  90   93          uint8_t         hubp_pm_capabilities;
  91   94  
  92   95          uint8_t         hubp_current_power;     /* current power level */
  93   96  
  94      -        time_t          hubp_time_at_full_power;        /* timestamp 0->3 */
       97 +        hrtime_t        hubp_time_at_full_power;        /* timestamp 0->3 */
  95   98  
  96      -        uint8_t         hubp_min_pm_threshold;          /* in seconds */
       99 +        hrtime_t        hubp_min_pm_threshold;          /* in nanoseconds */
  97  100  
  98  101          /* power state of all children are tracked here */
  99  102          uint8_t         *hubp_child_pwrstate;
 100  103  
 101  104          /* pm-components properties are stored here */
 102  105          char            *hubp_pmcomp[5];
 103  106  
 104  107          usba_cfg_pwr_descr_t    hubp_confpwr_descr; /* config pwr descr */
 105  108  } hub_power_t;
 106  109  
↓ open down ↓ 327 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX