#
# Copyright (c) 2002-2017 Brocade Communications Systems, Inc.
# All rights reserved.
#
# This file contains the atom description of the CHASSIS service for its
# startup, fss and swd config initialization. You must understand the
# implecations before you make change following the conventions below:
#	1. add a new component into the kernel or user-space section
#	   based on its type in the alphamerical order.
#	2. if a new component is a fss-compliant, the service major
#	   version needs to be bumped up.
#	3. If any component partition version is changed, the service
#	   partition version needs to be increased as well.
#
# Each 'ATOM' has the following attributes:
#
#  TYPE	F1 F2
#	F1: [user|kernel] to indicate a user-space or kernel-space atom.
#	F2: optional, or indicate shared/max.

#  SWD	F1 F2
#	F1: SWD time window of 'I AM ALIVE period'.
#	F2: optional, 'RES' means atom restartable.
#
#  FSS	F1 F2 F3 F4 F5
#	F1: current version of component
#	F2: minimum version to which this component can sync up.
#	F3: distrbuted partition version. 0 reserved for a centralized model.
#	F4: dump stage, this field can have any value from 0 onwards. It
#	    indicates the stage at which FSS will command the component to
#	    dump its states. More than one component could be at the same
#           dump stage. A component having a dumpstage of 0, gets command
#           to dump its states before a component having dumpstage of 1.
#           A component X that depends on some other component Y in sync,
#           before it can start sync, X should have dumpstage number greater
#	F5: sync control flag, if set to 1, FSS guarantees serilization
#	    while replaying the data back to the component. This is used
#	    for Hot Code Load.
#           Currently this facility is used only for em. When replaying the
#           data, em needs to create all data structures (fabos kernel-space
#	    objects which other components use. So till fss loopback is done
#	    replaying data back to em, no other components are delivered their
#	    state updates. Note this shall not be abused as it is expensive.
#
#  PATH	F1 F2...
#	F1: atom executable path (for user-space atom)
#	F2: optional arguments.
#
MAJORVER	11	# service major version
MINORVER_A	7	# service minor version, used as minimum ver supported as active
MINORVER_S	1	# service minor version, used as minimum ver supported as standby
PARTIVER	0	# partition version
STRIGGER	YES	# sync trigger policy

#
# kernel-space atoms
#
ATOM   core[21,29,32,34,37,42,43,44,45,46,49,51,58,61,62,64,66,67,70,71,72,73,75,76,77,79,80,83,86,87,92,109,117,118,124,125,129,130,133,134,141,142,148,171,149,150,156,157,158,161,162,165,166,167,169,170,172,173,178]
{
	TYPE	KERNEL	2
	FSS	7 1 0 3
}

# this is a dummy instance for
# backward compatibility
ATOM   fcoek[62,76,77,141,142]
{
	TYPE	USER	2
	FSS 	1 1 0 2
	PATH /fabos/libexec/fcoed
}

ATOM   fcoek[165,166,173]
{
	TYPE	KERNEL	2
	FSS 	1 1 0 2
}

ATOM   lpm[42,62,64,66,71,72,76,77,83,92,109,118,133,141,142,171,148,161,162,165,166,169,170,172,173,178]
{
	TYPE	KERNEL	2
	FSS 	2 1 0 3
}

ATOM   kap[148,165,166,173,178]
{
	TYPE	KERNEL	2
	FSS 	1 1 0 3
}

#Legacy RTE SWBDs
ATOM   rte[21.5,23,29,32,34,37,42.5,43,44,45,46,49,51,58,61]
{
	TYPE	KERNEL	2
	FSS	4 2 0 3
}

#New RTE SWBDs
ATOM   rte[62,64,66,67,70,71,72,73,75,76,77,79,80,83,86,87,92,109,117,118,124,125,129,130,133,134,141,142,148,171,149,150,156,157,158,161,162,165,166,167,169,170,172,173,178]
{
	TYPE	KERNEL	2
	FSS	12 2 0 3
}

#
# user-space atoms
#
ATOM   proxy[42.5,62,77,141,142,165,166]
{
	TYPE	USER
	PATH	/fabos/libexec/proxy -d 0
}

ATOM   raslog
{
	TYPE	USER
	SWD	500	RES
	PATH	/fabos/libexec/raslogd
}

ATOM   rm[62,64,66,67,71,76,77,83,92,109,117,118,129,130,133,141,142,148,171,149,150,156,157,158,161,162,165,166,167,169,170,172,173,178]
{
       TYPE    USER
       SWD     500     RES
       PATH    /fabos/libexec/rmd -p $SWBD
}

ATOM   trace
{
	TYPE	USER
	SWD	500	RES
	PATH	/fabos/libexec/traced -p $SWBD
}

ATOM   bm[42.5,46,62,67,77,79,80,83,141,142,148,171,165,166,178]
{
	TYPE	USER
	SWD	500
	FSS	1 1 0 3
	PATH	/fabos/libexec/bmd -d
}

ATOM   diag[~63]
{
	TYPE	USER
	SWD	500
	PATH	/fabos/libexec/diagd
}

ATOM   em[~63]
{
	TYPE	USER
	SWD     500
	FSS	20 1 0 1 2		# sync flag 2: serial
	PATH	/fabos/libexec/emd
}
#TBD
#ATOM   fcoe[62,76,77,141,142,169,170,172,173]
#{
#   	TYPE	USER 1
#   	SWD	500
#	FSS	1 1 0 3
#	PATH 	/fabos/libexec/fcoed
#}

ATOM   mm[37,73]
{
	TYPE	USER
	PATH	/fabos/libexec/mmd
}

ATOM   svp[87,149]
{
	TYPE	USER
	PATH	/fabos/libexec/svpd
}

ATOM   blvswm[129]
{
	TYPE	USER 1
	PATH	/fabos/libexec/blvswmd
}

ATOM   canmic[157,158]
{
	TYPE	USER	1
	PATH	/fabos/libexec/canmicd
}

ATOM   tecal[124,125,134,156]
{
	TYPE	USER
	PATH	/fabos/libexec/tecald
}

ATOM   tecalip[150]
{
	TYPE	USER
	PATH	/fabos/libexec/tecalipd
}
ATOM   sigmad[72]
{
	TYPE	USER
	PATH	/fabos/libexec/sigmad
}

ATOM   smc[167]
{
	TYPE	USER
	PATH	/fabos/libexec/smcd
}

# increased swd timeout to 1000 seconds because pdm recovers from errors
# by using FFDC which can get delayed by doing lots of other FFDC stuff
# (tracedumps, errdumps, etc.)
ATOM   pdm[~63]
{
	TYPE	USER 1
	SWD	1000
	FSS	9 1 0 3
	PATH	/fabos/libexec/pdmd
}

ATOM   pttest[~63]
{
	TYPE	USER
	PATH	/fabos/libexec/porttestd
}

# included here just for co-cpu startup so that we have at
# least one component in the service.

ATOM   xyz[63]
{
	TYPE	USER 1
	SWD	500
	FSS	1 1 0 1 1
	PATH	/fabos/libexec/xyzd
}

ATOM   lfm[62,64,66,71,72,76,77,83,92,109,118,133,141,142,148,171,161,162,165,166,169,170,172,173,178]
{
	TYPE	USER 1
	SWD	500
	FSS	1 1 0 3
	PATH	/fabos/libexec/lfmd
}


ATOM   sslp[117]
{
        TYPE    USER 1
        SWD     500 RES
        PATH    /fabos/libexec/sslpd
}
