Print this page
re #13613 rb4516 Tunables needs volatile keyword

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/sun/io/eri/eri.c
          +++ new/usr/src/uts/sun/io/eri/eri.c
↓ 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 2010 Sun Microsystems, Inc.  All rights reserved.
  23   23   * Use is subject to license terms.
  24   24   */
       25 +/*
       26 + * Copyright 2013 Nexenta Systems, Inc.  All rights reserved.
       27 + */
  25   28  
  26   29  /*
  27   30   * SunOS MT STREAMS ERI(PCI) 10/100 Mb Ethernet Device Driver
  28   31   */
  29   32  
  30   33  #include        <sys/types.h>
  31   34  #include        <sys/debug.h>
  32   35  #include        <sys/stropts.h>
  33   36  #include        <sys/stream.h>
  34   37  #include        <sys/strsubr.h>
↓ open down ↓ 304 lines elided ↑ open up ↑
 339  342   * and internal arbitration behavior.
 340  343   * for equal TX and RX bursts, set the following in global
 341  344   * configuration register.
 342  345   * static       int     global_config = 0x42;
 343  346   */
 344  347  
 345  348  /*
 346  349   * ERI ERX Interrupt Blanking Time
 347  350   * Each count is about 16 us (2048 clocks) for 66 MHz PCI.
 348  351   */
 349      -static  int     intr_blank_time = 6;    /* for about 96 us */
 350      -static  int     intr_blank_packets = 8; /*  */
      352 +volatile int    intr_blank_time = 6;    /* for about 96 us */
      353 +volatile int    intr_blank_packets = 8; /*  */
 351  354  
 352  355  /*
 353  356   * ERX PAUSE Threshold Register value
 354  357   * The following value is for an OFF Threshold of about 15.5 Kbytes
 355  358   * and an ON Threshold of 4K bytes.
 356  359   */
 357  360  static  int rx_pause_threshold = 0xf8 | (0x40 << 12);
 358  361  static  int eri_reinit_fatal = 0;
 359  362  #ifdef  DEBUG
 360  363  static  int noteri = 0;
↓ open down ↓ 5185 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX