Sun Microsystems Netra CP3010 Operating instructions

Copyright 2006 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, California 95054, U.S.A. All rights reserved.
Sun Microsystems, Inc. has intellectual property rights relating to technology that is described in this document. In particular, and without
limitation, these intellectual property rights may include one or more of the U.S. patents listed at http://www.sun.com/patents and one or
more additional patents or pending patent applications in the U.S. and in other countries.
This document and the product to which it pertains are distributed under licenses restricting their use, copying, distribution, and
decompilation. No part of the product or of this document may be reproduced in any form by any means without prior written authorization of
Sun and its licensors, if any.
Third-party software, including font technology, is copyrighted and licensed from Sun suppliers.
Parts of the product may be derived from Berkeley BSD systems, licensed from the University of California. UNIX is a registered trademark in
the U.S. and in other countries, exclusively licensed through X/Open Company, Ltd.
Sun, Sun Microsystems, the Sun logo, Java, AnswerBook2, docs.sun.com, Netra, OpenBoot, and Solaris are trademarks or registered
trademarks of Sun Microsystems, Inc. in the U.S. and in other countries.
All SPARC trademarks are used under license and are trademarks or registered trademarks of SPARC International, Inc. in the U.S. and in other
countries. Products bearing SPARC trademarks are based upon an architecture developed by Sun Microsystems, Inc.
The OPEN LOOK and Sun™ Graphical User Interface was developed by Sun Microsystems, Inc. for its users and licensees. Sun acknowledges
the pioneering efforts of Xerox in researching and developing the concept of visual or graphical user interfaces for the computer industry. Sun
holds a non-exclusive license from Xerox to the Xerox Graphical User Interface, which license also covers Sun’s licensees who implement OPEN
LOOK GUIs and otherwise comply with Sun’s written license agreements.
U.S. Government Rights—Commercial use. Government users are subject to the Sun Microsystems, Inc. standard license agreement and
applicable provisions of the FAR and its supplements.
DOCUMENTATION IS PROVIDED "AS IS" AND ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES,
INCLUDING ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT,
ARE DISCLAIMED, EXCEPT TO THE EXTENT THAT SUCH DISCLAIMERS ARE HELD TO BE LEGALLY INVALID.
Copyright 2006 Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, Californie 95054, Etats-Unis. Tous droits réservés.
Sun Microsystems, Inc. a les droits de propriété intellectuels relatants à la technologie qui est décrit dans ce document. En particulier, et sans la
limitation, ces droits de propriété intellectuels peuvent inclure un ou plus des brevets américains énumérés à http://www.sun.com/patents et
un ou les brevets plus supplémentaires ou les applications de brevet en attente dans les Etats-Unis et dans les autres pays.
Ce produit ou document est protégé par un copyright et distribué avec des licences qui en restreignent l’utilisation, la copie, la distribution, et la
décompilation. Aucune partie de ce produit ou document ne peut être reproduite sous aucune forme, par quelque moyen que ce soit, sans
l’autorisation préalable et écrite de Sun et de ses bailleurs de licence, s’il y ena.
Le logiciel détenu par des tiers, et qui comprend la technologie relative aux polices de caractères, est protégé par un copyright et licencié par des
fournisseurs de Sun.
Des parties de ce produit pourront être dérivées des systèmes Berkeley BSD licenciés par l’Université de Californie. UNIX est une marque
déposée aux Etats-Unis et dans d’autres pays et licenciée exclusivement par X/Open Company, Ltd.
Sun, Sun Microsystems, le logo Sun, Java, AnswerBook2, docs.sun.com, Netra, OpenBoot, et Solaris sont des marques de fabrique ou des
marques déposées de Sun Microsystems, Inc. aux Etats-Unis et dans d’autres pays.
Toutes les marques SPARC sont utilisées sous licence et sont des marques de fabrique ou des marques déposées de SPARC International, Inc.
aux Etats-Unis et dans d’autres pays. Les produits portant les marques SPARC sont basés sur une architecture développée par Sun
Microsystems, Inc.
L’interface d’utilisation graphique OPEN LOOK et Sun™ a été développée par Sun Microsystems, Inc. pour ses utilisateurs et licenciés. Sun
reconnaît les efforts de pionniers de Xerox pour la recherche et le développement du concept des interfaces d’utilisation visuelle ou graphique
pour l’industrie de l’informatique. Sun détient une license non exclusive de Xerox sur l’interface d’utilisation graphique Xerox, cette licence
couvrant également les licenciées de Sun qui mettent en place l’interface d ’utilisation graphique OPEN LOOK et qui en outre se conforment
aux licences écrites de Sun.
LA DOCUMENTATION EST FOURNIE "EN L’ÉTAT" ET TOUTES AUTRES CONDITIONS, DECLARATIONS ET GARANTIES EXPRESSES
OU TACITES SONT FORMELLEMENT EXCLUES, DANS LA MESURE AUTORISEE PAR LA LOI APPLICABLE, Y COMPRIS NOTAMMENT
TOUTE GARANTIE IMPLICITE RELATIVE A LA QUALITE MARCHANDE, A L’APTITUDE A UNE UTILISATION PARTICULIERE OU A
L’ABSENCE DE CONTREFAÇON.

iii
Contents
Preface ix
1. Environmental Monitoring 1
Power Requirements 2
Inlet, Exhaust, and CPU Temperatures 2
2. Flash Device Driver 5
Software Requirements 6
Storing Data and Applications 6
Switch Settings 6
OpenBoot PROM Device Tree and Properties 7
Flash Device Files 7
Interface (Header) File 8
Flash Memory 8
Accessing the Flash Device 8
Using Structures in IOCTL Arguments 9
Resolving Structure Errors 10
Developing Programs 11
Example Read Program 11
Example Write Program 13

vi Netra CP3010 Board Programming Guide •January 2006

vii
Code Examples
CODE EXAMPLE 2-1 PROM Information Structure 9
CODE EXAMPLE 2-2 Flash User Interface Structure 10
CODE EXAMPLE 2-3 Read Action on Flash Device 11
CODE EXAMPLE 2-4 Write Action on Flash Device 13
CODE EXAMPLE 2-5 Block Erase Action on Flash Device 15
CODE EXAMPLE 2-6 Flash Application Program 17

viii Netra CP3010 Board Programming Guide •January 2006

ix
Preface
The Netra™CP3010 board is a crucial building block that network equipment
providers and carriers can use when scaling and improving the availability of next-
generation, carrier-grade systems.
This Netra CP3010 Board Programming Guide is written for program developers and
users who want to program this board to design original equipment manufacturer
(OEM) systems, supply additional capability to an existing compatible system, or
work in a laboratory environment for experimental purposes.
Note – You are required to have a basic knowledge of computers and digital logic
programming to fully use the information in this document.

xNetra CP3010 Board Programming Guide •January 2006
How This Book Is Organized
Chapter 1 describes environmental monitoring of the Netra CP3010 board.
Chapter 2 describes the user flash driver device for the Netra CP3010 onboard flash
PROMs and how to use the device.
Using UNIX Commands
This document might not contain information about basic UNIX®commands and
procedures such as shutting down the system, booting the system, and configuring
devices. Refer to the following for this information:
■Software documentation that you received with your system
■Solaris™ Operating System documentation, which is at:
http://docs.sun.com
Shell Prompts
Shell Prompt
C shell machine-name%
C shell superuser machine-name#
Bourne shell and Korn shell $
Bourne shell and Korn shell superuser #

Preface xi
Typographic Conventions
Related Documentation
The documents listed as online are available at:
http://www.sun.com/products-n-solutions/hardware/docs/
Typeface*
* The settings on your browser might differ from these settings.
Meaning Examples
AaBbCc123 The names of commands, files,
and directories; on-screen
computer output
Edit your.login file.
Use ls -a to list all files.
% You have mail.
AaBbCc123 What you type, when contrasted
with on-screen computer output
% su
Password:
AaBbCc123 Book titles, new words or terms,
words to be emphasized.
Replace command-line variables
with real names or values.
Read Chapter 6 in the User’s Guide.
These are called class options.
You must be superuser to do this.
To delete a file, type rm filename.
Title Part Number
Netra CP3010 Board Product Notes 819-1181-xx
Netra CP3010 Board Getting Started Guide 819-1182-xx
Netra CP3010 Board User’s Guide 819-1183-xx
Netra CP3010 Board Software Installation Guide 819-1184-xx
Netra CP3010 Board Transition Card Getting Started Guide 819-1186-xx
Netra CP3010 Board Transition Card User’s Guide 819-1187-xx
Important Safety Information for Sun Hardware Systems 817-7190-10

xii Netra CP3010 Board Programming Guide •January 2006
Third-Party Web Sites
Sun is not responsible for the availability of third-party web sites mentioned in this
document. Sun does not endorse and is not responsible or liable for any content,
advertising, products, or other materials that are available on or through such sites
or resources. Sun will not be responsible or liable for any actual or alleged damage
or loss caused by or in connection with the use of or reliance on any such content,
goods, or services that are available on or through such sites or resources.
Documentation, Support, and Training
Sun Welcomes Your Comments
Sun is interested in improving its documentation and welcomes your comments and
suggestions. You can submit your comments by going to:
http://www.sun.com/hwdocs/feedback
Please include the title and part number of your document with your feedback:
Netra CP3010 Board Programming Guide, part number 819-1185-10
Sun Function URL Description
Documentation http://www.sun.com/documentation/ Download PDF and HTML documents,
and order printed documents
Support and
Training
http://www.sun.com/supportraining/ Obtain technical support, download
patches, and learn about Sun courses

1
CHAPTER 1
Environmental Monitoring
The Netra CP3010 board uses an intelligent fault detection environmental
monitoring system that increases uptime and manageability of the board. Through
an Intelligent Platform Management Controller (IPMC) and system management
software, the Netra CP3010 board monitors voltage, temperature, and power on
sensors.
This chapter contains the following topics:
■“Power Requirements” on page 2
■“Inlet, Exhaust, and CPU Temperatures” on page 2

2Netra CP3010 Board Programming Guide •January 2006
Power Requirements
The onboard voltage controller allows power to the CPU of the Netra CP3010 board
only when the following conditions are met:
■VDD core-1.7-volt supply voltage is greater than 1.53 volts (within 10 percent of
nominal)
■12-volt supply voltage is greater than 10.8 volts (within 10 percent of nominal)
■5-volt supply voltage is greater than 4.5 volts (within 10 percent of nominal)
■3.3-volt supply voltage is greater than 3.0 volts (within 10 percent of nominal)
The controller requires these conditions to be true for at least 100 milliseconds to
help ensure the supply voltages are stable. If any of these conditions become untrue,
the voltage monitoring circuit shuts down the CPU power of the board.
Inlet, Exhaust, and CPU Temperatures
The following table summarizes the functions on the Netra CP3010 board that
monitor the hardware environment.
The CPU diode sensor reading might vary from slot to slot and from board to board
in a system, and is dependent primarily on system cooling. As an example, a system
might have sensor readings for the CPU diode from 35˚C to 49˚C with an ambient
inlet of 21˚C across many boards, with a variety of configurations and positions
within a chassis. You must take care when setting the alarm and shutdown
temperatures based on the CPU diode sensor value. This sensor typically is linear
across the operating range of the board.
TABLE 1-1 Hardware Environmental Monitoring Functions
Function Description
Board exhaust air
temperature
Senses the air temperature at the trailing edge of the board.
(Assumes air direction from the processor/heatsink toward the PCI
mezzanine card (PMC) slots.)
CPU diode
temperature
Senses a diode temperature in the processor junction.
Board inlet air
temperature
Senses the air temperature at the leading edge of the board under
the solder-side cover. (Assumes air direction from the
processor/heatsink toward the PMC slots.)

Chapter 1 Environmental Monitoring 3
The exhaust sensor measures the local air temperature at the trailing edge of the
board for systems with bottom-to-top airflow. This value depends on the character
and volume of the airflow across the board. Typical values in a chassis might range
from a delta over inlet ambient of 0˚C to 12˚C, depending on the power dissipation
of the board configuration and the position in the chassis. The exhaust sensor is
nonlinear with respect to ambient inlet temperature.
The inlet sensor measures the local air temperature at the leading edge of the board
under the solder-side cover. This value typically can range from a reading of 0˚C to
13˚C above inlet system ambient in a chassis. You must understand the application
and installation of the board to use this temperature sensor.
A sudden drop of all temperature sensors close to or near room ambient temperature
can mean loss of power to one or more Netra CP3010 boards.
A gradual increase in the delta temperature from inlet to outlet can be due to dust
clogging system filters.
The CPU diode temperature can be used to prevent damage to the board by shutting
the board down if this sensor exceeds predetermined limits.

4Netra CP3010 Board Programming Guide •January 2006

5
CHAPTER 2
Flash Device Driver
The Netra CP3010 board is equipped with flash memory. This chapter introduces the
flash device driver for the onboard flash PROM and describes how to use the device.
This chapter contains the following topics:
■“Software Requirements” on page 6
■“Storing Data and Applications” on page 6
■“Accessing the Flash Device” on page 8
■“Developing Programs” on page 11

6Netra CP3010 Board Programming Guide •January 2006
Software Requirements
The following software releases support the flash driver:
■Solaris 9 (9/04) Operating System (Solaris OS) and newer releases
■Required OS patches
■Netra CP3010 board OpenBoot PROM
Storing Data and Applications
The Solaris OS uflash is the device driver for the flash device on the Netra CP3010
board. On the Netra CP3010 board, one driver is supported. Users can use this
device driver for storing data and applications.
Multiple reads and writes can be submitted concurrently, however, they are
serialized by the uflash device. For example, the driver blocks additional reads and
writes to the device while a read or write is in progress.
The driver supports erase and lock features. Applications can use them through the
IOCTL interface. The device is divided into logical blocks. Applications that issue
these operations supply a block number or a range of blocks that are a target of these
operations. Locks are preserved across reboots. Locking a block prevents an erase or
write operation on that block.
Switch Settings
The flash modules on the Netra CP3010 board are write-enabled by default. The
flash device is detected during OpenBoot™ PROM boot.

Chapter 2 Flash Device Driver 7
OpenBoot PROM Device Tree and Properties
The following information describes the OpenBoot PROM device node and its
properties.
The OpenBoot PROM device node is as follows:
/pci@1e,600000/isa@7/flashprom@2,0
TABLE 2-1 lists the flash node properties.
Flash Device Files
The flash device files are located in the following path:
/dev/uflash0
TABLE 2-1 Flash Node Properties
Property Description/Value
sunw,location U55
model SUNW,254-0078
boot-banks 00 00 00 00 00 00 00 02 00 00 00 04 00 00 00 06
system-banks 00 00 00 00 00 00 00 01 00 00 00 02 00 00 00 03
flash-banks 00 00 00 00 00 00 00 1f
write-window 00 08 00 00 00 08 00 00
boot-window 00 00 00 00 00 08 00 00
bank-size 00080000
version OBP 4.21.0 2005/11/22 16:48 Netra CP3010
OBDIAG 4.x.0 2005/11/22 17:00
POST 4.50.48 2005/11/22 17:12
name flashprom
compatible isa-flashprom
reg 00000002 00000000 00100000
00000000 00000700 00000002

8Netra CP3010 Board Programming Guide •January 2006
Interface (Header) File
The flash header file is located in the following path:
/usr/platform/SUNW,Netra-CP3010/include/sys/uflash_if.h
Flash Memory
The Netra CP3010 board has a 16-megabyte flash chip that is logically divided into
two partitions:
■2-megabyte system flash for storing copies of the OpenBoot PROM image. Users
do not have access to this partition.
■14-megabyte user flash for storing any user data and performing operations such
as read and write. The user flash includes a flash PROM chip that can be
programmed. The physical address of the user flash is 1ff.f000.0000.
Accessing the Flash Device
You can access the flash device from the Solaris OS through an application or user C
program. No command-line tool is available. Access to the driver is carried out
through open, read, write, pread, pwrite and ioctl system interfaces. User
programs open the device file, then issue read, write, or ioctl commands.
System calls are listed in the following table.
TABLE 2-2 System Calls
Call Description
read(), pread() Reads device
write(),
pwrite()
Writes device
ioctl() Erases device, queries device parameters
Table of contents
Other Sun Microsystems Single Board Computer manuals
Popular Single Board Computer manuals by other brands

Glitch Works
Glitch Works R6501Q User Manual and Assembly Guide

TQ-Systems
TQ-Systems MBLS1012AL Preliminary user's manual

Advantech
Advantech PCM-5862E user manual

Advantech
Advantech PCI-6873 Startup manual

ADLINK Technology
ADLINK Technology LEC-BASE 2.0 Technical reference

ADLINK Technology
ADLINK Technology cPCI-6880 Series user manual