Print this page
remove support for non-ANSI compilation

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/sys/sunpm.h
          +++ new/usr/src/uts/common/sys/sunpm.h
↓ open down ↓ 11 lines elided ↑ open up ↑
  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 + * Copyright 2014 Garrett D'Amore <garrett@damore.org>
       23 + *
  22   24   * Copyright 2009 Sun Microsystems, Inc.  All rights reserved.
  23   25   * Use is subject to license terms.
  24   26   */
  25   27  
  26   28  #ifndef _SYS_SUNPM_H
  27   29  #define _SYS_SUNPM_H
  28   30  
  29   31  /*
  30   32   * Sun Specific Power Management definitions
  31   33   */
↓ open down ↓ 60 lines elided ↑ open up ↑
  92   94   * Useful strings for creating pm-components property for these devices.
  93   95   * If a device driver wishes to provide more specific description of power
  94   96   * levels (highly recommended), it should NOT use following generic defines.
  95   97   */
  96   98  #define PM_LEVEL_D3_STR         "0=Device D3 State"
  97   99  #define PM_LEVEL_D2_STR         "1=Device D2 State"
  98  100  #define PM_LEVEL_D1_STR         "2=Device D1 State"
  99  101  #define PM_LEVEL_D0_STR         "3=Device D0 State"
 100  102  
 101  103  /*
 102      - * If you add or remove a function or data reference, please
 103      - * remember to duplicate the action below the #else clause for
 104      - * __STDC__.
 105      - */
 106      -
 107      -#ifdef  __STDC__
 108      -
 109      -/*
 110  104   * Generic Sun PM definitions.
 111  105   */
 112  106  
 113  107  /*
 114  108   * These are obsolete power management interfaces, they will be removed from
 115  109   * a subsequent release.
 116  110   */
 117      -int
 118      -pm_create_components(dev_info_t *dip, int num_components);
      111 +int pm_create_components(dev_info_t *dip, int num_components);
 119  112  
 120      -void
 121      -pm_destroy_components(dev_info_t *dip);
      113 +void pm_destroy_components(dev_info_t *dip);
 122  114  
 123      -void
 124      -pm_set_normal_power(dev_info_t *dip, int component_number, int level);
      115 +void pm_set_normal_power(dev_info_t *dip, int component_number, int level);
 125  116  
 126      -int
 127      -pm_get_normal_power(dev_info_t *dip, int component_number);
      117 +int pm_get_normal_power(dev_info_t *dip, int component_number);
 128  118  
 129  119  /*
 130  120   * These are power management interfaces.
 131  121   */
 132  122  
 133      -int
 134      -pm_busy_component(dev_info_t *dip, int component_number);
      123 +int pm_busy_component(dev_info_t *dip, int component_number);
 135  124  
 136      -int
 137      -pm_idle_component(dev_info_t *dip, int component_number);
      125 +int pm_idle_component(dev_info_t *dip, int component_number);
 138  126  
 139      -int
 140      -pm_get_current_power(dev_info_t *dip, int component, int *levelp);
      127 +int pm_get_current_power(dev_info_t *dip, int component, int *levelp);
 141  128  
 142      -int
 143      -pm_power_has_changed(dev_info_t *, int, int);
      129 +int pm_power_has_changed(dev_info_t *, int, int);
 144  130  
 145      -int
 146      -pm_trans_check(struct pm_trans_data *datap, time_t *intervalp);
      131 +int pm_trans_check(struct pm_trans_data *datap, time_t *intervalp);
 147  132  
 148      -int
 149      -pm_lower_power(dev_info_t *dip, int comp, int level);
      133 +int pm_lower_power(dev_info_t *dip, int comp, int level);
 150  134  
 151      -int
 152      -pm_raise_power(dev_info_t *dip, int comp, int level);
      135 +int pm_raise_power(dev_info_t *dip, int comp, int level);
 153  136  
 154      -int
 155      -pm_update_maxpower(dev_info_t *dip, int comp, int level);
      137 +int pm_update_maxpower(dev_info_t *dip, int comp, int level);
 156  138  
 157      -#else   /* __STDC__ */
 158      -
 159      -/*
 160      - * Obsolete interfaces.
 161      - */
 162      -extern int pm_create_components();
 163      -extern void pm_destroy_components();
 164      -extern void pm_set_normal_power();
 165      -extern int pm_get_normal_power();
 166      -
 167      -/*
 168      - * PM interfaces
 169      - */
 170      -extern int pm_busy_component();
 171      -extern int pm_idle_component();
 172      -extern int pm_get_current_power();
 173      -extern int pm_power_has_changed();
 174      -extern int pm_trans_check();
 175      -extern int pm_lower_power();
 176      -extern int pm_raise_power();
 177      -extern int pm_update_maxpower();
 178      -
 179      -#endif  /* __STDC__ */
 180      -
 181  139  #endif  /* _KERNEL */
 182  140  
 183  141  #ifdef  __cplusplus
 184  142  }
 185  143  #endif
 186  144  
 187  145  #endif  /* _SYS_SUNPM_H */
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX